Functions¶
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Details¶
- GstHip.context_new_hip_device(device)¶
- Parameters:
device (
GstHip.HipDevice) – aGstHip.HipDevice- Returns:
a new
Gst.Contextembedding the device- Return type:
New in version 1.28.
- GstHip.hip_ensure_element_data(element, vendor, device_id, device)¶
- Parameters:
element (
Gst.Element) – theGst.Elementrunning the queryvendor (
GstHip.HipVendor) – aGstHip.HipVendordevice_id (
int) – preferred device-id, pass device_id >=0 when the device_id explicitly required. Otherwise, set -1.device (
GstHip.HipDevice) – the resultingGstHip.HipDevice
- Returns:
whether a
GstHip.HipDeviceexists in device- device:
the resulting
GstHip.HipDevice
- Return type:
(
bool, device:GstHip.HipDevice)
Perform the steps necessary for retrieving a
GstHip.HipDevicefrom the surrounding elements or from the application using theGst.Contextmechanism.If the content of device is not
None, then noGst.Contextquery is necessary forGstHip.HipDevice.New in version 1.28.
- GstHip.hip_handle_context_query(element, query, device)¶
- Parameters:
element (
Gst.Element) – aGst.Elementquery (
Gst.Query) – aGst.Queryof typeGst.QueryType.CONTEXTdevice (
GstHip.HipDeviceorNone) – aGstHip.HipDevice
- Returns:
Whether the query was successfully responded to from the passed context.
- Return type:
New in version 1.28.
- GstHip.hip_handle_set_context(element, context, vendor, device_id, device)¶
- Parameters:
element (
Gst.Element) – aGst.Elementcontext (
Gst.Context) – aGst.Contextvendor (
GstHip.HipVendor) – aGstHip.HipVendordevice_id (
int) – preferred device-id, pass device_id >=0 when the device_id explicitly required. Otherwise, set -1.device (
GstHip.HipDevice) – location of aGstHip.HipDevice
- Returns:
whether the device could be set successfully
- device:
location of a
GstHip.HipDevice
- Return type:
(
bool, device:GstHip.HipDevice)
Helper function for implementing
Gst.Element.do_set_context() in HIP capable elements.Retrieves the
GstHip.HipDevicein context and places the result in device.New in version 1.28.
- GstHip.hip_load_library(vendor)¶
- Parameters:
vendor (
GstHip.HipVendor) – aGstHip.HipVendor- Returns:
Trueif succeeded- Return type:
Opens vendor specific runtime libraries
New in version 1.28.
- GstHip.hip_rtc_compile(device, source, options, num_options)¶
- Parameters:
device (
GstHip.HipDevice) – aGstHip.HipDevicesource (
str) – HIP kernel sourceoptions (
str) – array of compile option stringnum_options (
int) – option array size
- Returns:
Compiled kernel blob or
Noneif failed. *- Return type:
Compiles source with given compile options
New in version 1.28.
- GstHip.hip_rtc_load_library(vendor)¶
- Parameters:
vendor (
GstHip.HipVendor) – aGstHip.HipVendor- Returns:
Trueif succeeded- Return type:
Opens vendor specific runtime compiler libraries
New in version 1.28.
- GstHip.is_hip_memory(mem)¶
- Parameters:
mem (
Gst.Memory) – aGst.Memory- Returns:
Trueif mem is aGstHip.HipMemory- Return type:
New in version 1.28.