Harlequin RIP SDK

Platform functions to support shared memory framebuffers for eHVD elements. More...

#include "skinkit.h"
#include "hvdshmfb.h"
#include "hqwindows.h"
#include "rhhashmap.h"
#include "skinmon.h"
#include "swcopyf.h"
#include "monlibhvd.h"

Functions

void handlemap_release_key (intptr_t key, void *data)
 Key release function for the shared memory object to shared memory handle map.
 
void handlemap_release_value (intptr_t value, void *data)
 Value release function for the shared memory object to shared memory handle map.
 
void handlemap_remove_address (rh_hashmap_t *handlemap, void *addr)
 Function to remove a shared memory object from the handle map, closing the shared memory handle as appropriate.
 
void * shmfb_create_object (const char *name, size_t size, rh_hashmap_t *handlemap, HqnResult *perr)
 Create a shared memory object with the size specified. More...
 
void * shmfb_open_object (const char *name, rh_hashmap_t *handlemap)
 Try to open an existing shared memory object with the size specified. More...
 

Variables

intptr_t handlemap_invalid = ((intptr_t)NULL)
 

Detailed Description

Platform functions to support shared memory framebuffers for eHVD elements.

Function Documentation

◆ shmfb_create_object()

void* shmfb_create_object ( const char *  name,
size_t  size,
rh_hashmap_t handlemap,
HqnResult perr 
)

Create a shared memory object with the size specified.

Parameters
[in]nameThe name of the shared memory object
[in]sizeThe size of the shared memory object
[in,out]handlemapA hashmap to store the data pointer to shared memory handle correspondence in.
[out]perrA location in which an error code is stored, if the shared memory object could not be created.
Returns
A pointer to the shared memory object, or NULL if it could not be created.

◆ shmfb_open_object()

void* shmfb_open_object ( const char *  name,
rh_hashmap_t handlemap 
)

Try to open an existing shared memory object with the size specified.

Parameters
[in]nameThe name of the shared memory object
[in,out]handlemapA hashmap to store the data pointer to shared memory handle correspondence in.
Returns
A pointer to the shared memory object, or NULL if it did not exist.

Variable Documentation

◆ handlemap_invalid

intptr_t handlemap_invalid = ((intptr_t)NULL)

Invalid value for handle map. CreateFileMapping() returns NULL on failure.