INtime SDK Help
ntxAllocateRtMemory
INtime SDK v7 > About INtime > INtime Kernel > Memory management > ntxAllocateRtMemory

Allocates RT memory and returns a handle to the memory object. A subsequest call to ntxMapRtSharedMemoryEx must be made in order to access the memory.  

Note:   You can use ntxFreeRtMemory to deallocate the memory.
NTXHANDLE ntxAllocateRtMemory(
    NTXLOCATION hLoc,
    DWORD nSize
);

Parameters

hLoc
Location of the realtime kernel from which the memory is allocated.
nSize
Size of the allocation in bytes.

Return Values

An NTXHANDLE for the memory object.
Success
NTX_BAD_NTXHANDLE
Function failed.

Status

E_OK 0x0000
No exceptional conditions occurred.
E_MEM 0x0002
This request requires more available physical memory than currently exists.
E_VMEM 0x00F0
Satisfying this request requires more virtual memory than is available to the process.
E_PARAM 0x8004
One of the following conditions is true:
cbSize contains a value larger than the virtual segment size, or 0 (zero).
The value of qwLowFilter is greater than the value of qwHighFilter.
The value of cbAlignement is not a multiple of 4096.

Requirements

Versions Defined in Include Link to
INtime 3.0 intime/nt/include/ntx.h ntx.h ntxext.lib
INtime 4.01 intime/nt/include/ntx.h ntx.h ntxext64.lib (for 64-bit Windows)

See Also

Memory management system calls, ntxMapRtSharedMemoryEx, ntxFreeRtMemory