GstCuda.CudaMemory¶
Fields¶
Name |
Type |
Access |
Description |
---|---|---|---|
context |
r/w |
||
info |
r/w |
||
mem |
r/w |
Methods¶
class |
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- class GstCuda.CudaMemory¶
New in version 1.22.
- classmethod init_once()¶
Ensures that the
GstCuda.CudaAllocator
is initialized and ready to be used.New in version 1.22.
- export()¶
- Returns:
True
if successful- os_handle:
a pointer to OS handle
- Return type:
Exports virtual memory handle to OS specific handle.
On Windows, os_handle should be pointer to HANDLE (i.e., void **), and pointer to file descriptor (i.e., int *) on Linux.
The returned os_handle is owned by self and therefore caller shouldn’t close the handle.
New in version 1.24.
- get_alloc_method()¶
- Return type:
Query allocation method
New in version 1.24.
- get_stream()¶
- Returns:
a
GstCuda.CudaStream
orNone
if default CUDA stream is in use- Return type:
Gets CUDA stream object associated with self
New in version 1.24.
- get_texture(plane, filter_mode)¶
- Parameters:
plane (
int
) – the plane indexfilter_mode (
CudaGst.filter_mode
) – filter mode
- Returns:
True
if successful- texture:
a pointer to CUtexObject object
- Return type:
Creates CUtexObject with given parameters
New in version 1.24.
- get_token_data(token)¶
-
Gets back user data pointer stored via
GstCuda.CudaMemory.set_token_data
()New in version 1.24.
- get_user_data()¶
-
Gets user data pointer stored via
GstCuda.CudaAllocator.alloc_wrapped
()New in version 1.24.
- set_token_data(token, data, notify)¶
- Parameters:
token (
int
) – an user tokennotify (
GLib.DestroyNotify
) – function to invoke with data as argument, when data needs to be freed
Sets an opaque user data on a
GstCuda.CudaMemory
New in version 1.24.
- sync()¶
Performs synchronization if needed
New in version 1.24.