Functions¶
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- GstAllocators.dmabuf_memory_get_fd(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – the memory to get the file descriptor- Returns:
the file descriptor associated with the memory, or -1. The file descriptor is still owned by the
Gst.Memory
. Use dup to take a copy if you intend to use it beyond the lifetime of thisGst.Memory
.- Return type:
Return the file descriptor associated with mem.
New in version 1.2.
- GstAllocators.drm_dumb_memory_export_dmabuf(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – the memory to export from- Returns:
a
Gst.Memory
fromGstAllocators.DmaBufAllocator
wrapping the exported dma-buf file descriptor.- Return type:
Exports a DMABuf from the DRM Bumb buffer object. One can check if this feature is supported using
GstAllocators.DRMDumbAllocator.has_prime_export
();New in version 1.24.
- GstAllocators.drm_dumb_memory_get_handle(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – the memory to get the handle from- Returns:
the DRM buffer object handle associated with the memory, or 0. The handle is still owned by the
Gst.Memory
and cannot be used beyond the lifetime of thisGst.Memory
unless it is being passed to DRM driver, which does handle a refcount internally.- Return type:
Return the DRM buffer object handle associated with mem.
New in version 1.24.
- GstAllocators.fd_memory_get_fd(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) –Gst.Memory
- Returns:
the fd of mem or -1 when there is no fd on mem
- Return type:
Get the fd from mem. Call
GstAllocators.is_fd_memory
() to check if mem has an fd.New in version 1.6.
- GstAllocators.is_dmabuf_memory(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – the memory to be check- Returns:
- Return type:
Check if mem is dmabuf memory.
New in version 1.2.
- GstAllocators.is_drm_dumb_memory(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – the memory to be checked- Returns:
- Return type:
New in version 1.24.
- GstAllocators.is_fd_memory(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) –Gst.Memory
- Returns:
True
when mem has an fd that can be retrieved withGstAllocators.fd_memory_get_fd
().- Return type:
Check if mem is memory backed by an fd
New in version 1.6.
- GstAllocators.is_phys_memory(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – aGst.Memory
- Returns:
whether the memory at mem is backed by physical memory
- Return type:
New in version 1.14.
- GstAllocators.phys_memory_get_phys_addr(mem)[source]¶
- Parameters:
mem (
Gst.Memory
) – aGst.Memory
- Returns:
Physical memory address that is backing mem, or 0 if none
- Return type:
New in version 1.14.