GstDeviceProvider
A GstDeviceProvider subclass is provided by a plugin that handles devices if there is a way to programmatically list connected devices. It can also optionally provide updates to the list of connected devices.
Each GstDeviceProvider subclass is a singleton, a plugin should normally provide a single subclass for all devices.
Applications would normally use a GstDeviceMonitor to monitor devices from all relevant providers.
GstDeviceProvider
GObject ╰──GInitiallyUnowned ╰──GstObject ╰──GstDeviceProvider
The structure of the base GstDeviceProvider
Members
Since : 1.4
Class structure
GstDeviceProviderClass
The structure of the base GstDeviceProviderClass
Fields
parent_class
(GstObjectClass)
–
the parent GstObjectClass structure
factory
(GstDeviceProviderFactory *)
–
a pointer to the GstDeviceProviderFactory that creates this provider
Since : 1.4
Gst.DeviceProviderClass
The structure of the base Gst.DeviceProviderClass
Attributes
parent_class
(Gst.ObjectClass)
–
the parent Gst.ObjectClass structure
factory
(Gst.DeviceProviderFactory)
–
a pointer to the Gst.DeviceProviderFactory that creates this provider
Since : 1.4
Gst.DeviceProviderClass
The structure of the base Gst.DeviceProviderClass
Attributes
parent_class
(Gst.ObjectClass)
–
the parent Gst.ObjectClass structure
factory
(Gst.DeviceProviderFactory)
–
a pointer to the Gst.DeviceProviderFactory that creates this provider
Since : 1.4
Gst.DeviceProvider
GObject.Object ╰──GObject.InitiallyUnowned ╰──Gst.Object ╰──Gst.DeviceProvider
The structure of the base Gst.DeviceProvider
Members
parent
(Gst.Object)
–
The parent Gst.Object
devices
([ Object ])
–
a GLib.List of the Gst.Device objects
Since : 1.4
Gst.DeviceProvider
GObject.Object ╰──GObject.InitiallyUnowned ╰──Gst.Object ╰──Gst.DeviceProvider
The structure of the base Gst.DeviceProvider
Members
parent
(Gst.Object)
–
The parent Gst.Object
devices
([ object ])
–
a GLib.List of the Gst.Device objects
Since : 1.4
Methods
gst_device_provider_can_monitor
gboolean gst_device_provider_can_monitor (GstDeviceProvider * provider)
Parameters:
provider
–
Gst.DeviceProvider.prototype.can_monitor
function Gst.DeviceProvider.prototype.can_monitor(): {
// javascript wrapper for 'gst_device_provider_can_monitor'
}
Parameters:
Gst.DeviceProvider.can_monitor
def Gst.DeviceProvider.can_monitor (self):
#python wrapper for 'gst_device_provider_can_monitor'
Parameters:
gst_device_provider_device_add
gst_device_provider_device_add (GstDeviceProvider * provider, GstDevice * device)
Posts a message on the provider's GstBus to inform applications that a new device has been added.
This is for use by subclasses.
device's reference count will be incremented, and any floating reference will be removed (see gst_object_ref_sink).
Since : 1.4
Gst.DeviceProvider.prototype.device_add
function Gst.DeviceProvider.prototype.device_add(device: Gst.Device): {
// javascript wrapper for 'gst_device_provider_device_add'
}
Posts a message on the provider's Gst.Bus to inform applications that a new device has been added.
This is for use by subclasses.
device's reference count will be incremented, and any floating reference will be removed (see gst_object_ref_sink (not introspectable)).
Since : 1.4
Gst.DeviceProvider.device_add
def Gst.DeviceProvider.device_add (self, device):
#python wrapper for 'gst_device_provider_device_add'
Posts a message on the provider's Gst.Bus to inform applications that a new device has been added.
This is for use by subclasses.
device's reference count will be incremented, and any floating reference will be removed (see gst_object_ref_sink (not introspectable)).
Since : 1.4
gst_device_provider_device_changed
gst_device_provider_device_changed (GstDeviceProvider * provider, GstDevice * device, GstDevice * changed_device)
This function is used when changed_device was modified into its new form
device. This will post a DEVICE_CHANGED
message on the bus to let
the application know that the device was modified. GstDevice is immutable
for MT. safety purposes so this is an "atomic" way of letting the application
know when a device was modified.
Parameters:
provider
–
device
(
[transfer: none])
–
the new version of changed_device
changed_device
(
[transfer: floating])
–
the old version of the device that has been updated
Since : 1.16
Gst.DeviceProvider.prototype.device_changed
function Gst.DeviceProvider.prototype.device_changed(device: Gst.Device, changed_device: Gst.Device): {
// javascript wrapper for 'gst_device_provider_device_changed'
}
This function is used when changed_device was modified into its new form
device. This will post a DEVICE_CHANGED
message on the bus to let
the application know that the device was modified. Gst.Device is immutable
for MT. safety purposes so this is an "atomic" way of letting the application
know when a device was modified.
Parameters:
the new version of changed_device
the old version of the device that has been updated
Since : 1.16
Gst.DeviceProvider.device_changed
def Gst.DeviceProvider.device_changed (self, device, changed_device):
#python wrapper for 'gst_device_provider_device_changed'
This function is used when changed_device was modified into its new form
device. This will post a DEVICE_CHANGED
message on the bus to let
the application know that the device was modified. Gst.Device is immutable
for MT. safety purposes so this is an "atomic" way of letting the application
know when a device was modified.
Parameters:
the new version of changed_device
the old version of the device that has been updated
Since : 1.16
gst_device_provider_device_remove
gst_device_provider_device_remove (GstDeviceProvider * provider, GstDevice * device)
Posts a message on the provider's GstBus to inform applications that a device has been removed.
This is for use by subclasses.
Since : 1.4
Gst.DeviceProvider.prototype.device_remove
function Gst.DeviceProvider.prototype.device_remove(device: Gst.Device): {
// javascript wrapper for 'gst_device_provider_device_remove'
}
Posts a message on the provider's Gst.Bus to inform applications that a device has been removed.
This is for use by subclasses.
Since : 1.4
Gst.DeviceProvider.device_remove
def Gst.DeviceProvider.device_remove (self, device):
#python wrapper for 'gst_device_provider_device_remove'
Posts a message on the provider's Gst.Bus to inform applications that a device has been removed.
This is for use by subclasses.
Since : 1.4
gst_device_provider_get_bus
GstBus * gst_device_provider_get_bus (GstDeviceProvider * provider)
Gets the GstBus of this GstDeviceProvider
Parameters:
provider
–
a GstBus
Since : 1.4
Gst.DeviceProvider.prototype.get_bus
function Gst.DeviceProvider.prototype.get_bus(): {
// javascript wrapper for 'gst_device_provider_get_bus'
}
Gets the Gst.Bus of this Gst.DeviceProvider
Parameters:
Since : 1.4
Gst.DeviceProvider.get_bus
def Gst.DeviceProvider.get_bus (self):
#python wrapper for 'gst_device_provider_get_bus'
Gets the Gst.Bus of this Gst.DeviceProvider
Parameters:
Since : 1.4
gst_device_provider_get_devices
GList * gst_device_provider_get_devices (GstDeviceProvider * provider)
Gets a list of devices that this provider understands. This may actually probe the hardware if the provider is not currently started.
If the provider has been started, this will returned the same GstDevice objedcts that have been returned by the GST_MESSAGE_DEVICE_ADDED messages.
Parameters:
provider
–
Since : 1.4
Gst.DeviceProvider.prototype.get_devices
function Gst.DeviceProvider.prototype.get_devices(): {
// javascript wrapper for 'gst_device_provider_get_devices'
}
Gets a list of devices that this provider understands. This may actually probe the hardware if the provider is not currently started.
If the provider has been started, this will returned the same Gst.Device objedcts that have been returned by the Gst.MessageType.DEVICE_ADDED messages.
Parameters:
a GLib.List of Gst.Device
Since : 1.4
Gst.DeviceProvider.get_devices
def Gst.DeviceProvider.get_devices (self):
#python wrapper for 'gst_device_provider_get_devices'
Gets a list of devices that this provider understands. This may actually probe the hardware if the provider is not currently started.
If the provider has been started, this will returned the same Gst.Device objedcts that have been returned by the Gst.MessageType.DEVICE_ADDED messages.
Parameters:
a GLib.List of Gst.Device
Since : 1.4
gst_device_provider_get_factory
GstDeviceProviderFactory * gst_device_provider_get_factory (GstDeviceProvider * provider)
Retrieves the factory that was used to create this device provider.
Parameters:
provider
–
a GstDeviceProvider to request the device provider factory of.
the GstDeviceProviderFactory used for creating this device provider. no refcounting is needed.
Since : 1.4
Gst.DeviceProvider.prototype.get_factory
function Gst.DeviceProvider.prototype.get_factory(): {
// javascript wrapper for 'gst_device_provider_get_factory'
}
Retrieves the factory that was used to create this device provider.
Parameters:
a Gst.DeviceProvider to request the device provider factory of.
the Gst.DeviceProviderFactory used for creating this device provider. no refcounting is needed.
Since : 1.4
Gst.DeviceProvider.get_factory
def Gst.DeviceProvider.get_factory (self):
#python wrapper for 'gst_device_provider_get_factory'
Retrieves the factory that was used to create this device provider.
Parameters:
a Gst.DeviceProvider to request the device provider factory of.
the Gst.DeviceProviderFactory used for creating this device provider. no refcounting is needed.
Since : 1.4
gst_device_provider_get_metadata
const gchar * gst_device_provider_get_metadata (GstDeviceProvider * provider, const gchar * key)
Get metadata with key in provider.
Parameters:
provider
–
provider to get metadata for
key
–
the key to get
the metadata for key.
Since : 1.14
Gst.DeviceProvider.prototype.get_metadata
function Gst.DeviceProvider.prototype.get_metadata(key: String): {
// javascript wrapper for 'gst_device_provider_get_metadata'
}
Get metadata with key in provider.
Parameters:
provider to get metadata for
the key to get
the metadata for key.
Since : 1.14
Gst.DeviceProvider.get_metadata
def Gst.DeviceProvider.get_metadata (self, key):
#python wrapper for 'gst_device_provider_get_metadata'
Get metadata with key in provider.
the metadata for key.
Since : 1.14
gst_device_provider_hide_provider
gst_device_provider_hide_provider (GstDeviceProvider * provider, const gchar * name)
Make provider hide the devices from the factory with name.
This function is used when provider will also provide the devices reported by provider factory name. A monitor should stop monitoring the device provider with name to avoid duplicate devices.
Since : 1.6
Gst.DeviceProvider.prototype.hide_provider
function Gst.DeviceProvider.prototype.hide_provider(name: String): {
// javascript wrapper for 'gst_device_provider_hide_provider'
}
Make provider hide the devices from the factory with name.
This function is used when provider will also provide the devices reported by provider factory name. A monitor should stop monitoring the device provider with name to avoid duplicate devices.
Parameters:
a provider factory name
Since : 1.6
Gst.DeviceProvider.hide_provider
def Gst.DeviceProvider.hide_provider (self, name):
#python wrapper for 'gst_device_provider_hide_provider'
Make provider hide the devices from the factory with name.
This function is used when provider will also provide the devices reported by provider factory name. A monitor should stop monitoring the device provider with name to avoid duplicate devices.
Parameters:
a provider factory name
Since : 1.6
gst_device_provider_is_started
gboolean gst_device_provider_is_started (GstDeviceProvider * provider)
This function can be used to know if the provider was successfully started.
Parameters:
provider
–
Since : 1.20
Gst.DeviceProvider.prototype.is_started
function Gst.DeviceProvider.prototype.is_started(): {
// javascript wrapper for 'gst_device_provider_is_started'
}
This function can be used to know if the provider was successfully started.
Parameters:
Since : 1.20
Gst.DeviceProvider.is_started
def Gst.DeviceProvider.is_started (self):
#python wrapper for 'gst_device_provider_is_started'
This function can be used to know if the provider was successfully started.
Parameters:
Since : 1.20
gst_device_provider_start
gboolean gst_device_provider_start (GstDeviceProvider * provider)
Starts providering the devices. This will cause GST_MESSAGE_DEVICE_ADDED and GST_MESSAGE_DEVICE_REMOVED messages to be posted on the provider's bus when devices are added or removed from the system.
Since the GstDeviceProvider is a singleton, gst_device_provider_start may already have been called by another user of the object, gst_device_provider_stop needs to be called the same number of times.
After this function has been called, gst_device_provider_get_devices will return the same objects that have been received from the GST_MESSAGE_DEVICE_ADDED messages and will no longer probe.
Parameters:
provider
–
TRUE if the device providering could be started
Since : 1.4
Gst.DeviceProvider.prototype.start
function Gst.DeviceProvider.prototype.start(): {
// javascript wrapper for 'gst_device_provider_start'
}
Starts providering the devices. This will cause Gst.MessageType.DEVICE_ADDED and Gst.MessageType.DEVICE_REMOVED messages to be posted on the provider's bus when devices are added or removed from the system.
Since the Gst.DeviceProvider is a singleton, Gst.DeviceProvider.prototype.start may already have been called by another user of the object, Gst.DeviceProvider.prototype.stop needs to be called the same number of times.
After this function has been called, Gst.DeviceProvider.prototype.get_devices will return the same objects that have been received from the Gst.MessageType.DEVICE_ADDED messages and will no longer probe.
Parameters:
Since : 1.4
Gst.DeviceProvider.start
def Gst.DeviceProvider.start (self):
#python wrapper for 'gst_device_provider_start'
Starts providering the devices. This will cause Gst.MessageType.DEVICE_ADDED and Gst.MessageType.DEVICE_REMOVED messages to be posted on the provider's bus when devices are added or removed from the system.
Since the Gst.DeviceProvider is a singleton, Gst.DeviceProvider.start may already have been called by another user of the object, Gst.DeviceProvider.stop needs to be called the same number of times.
After this function has been called, Gst.DeviceProvider.get_devices will return the same objects that have been received from the Gst.MessageType.DEVICE_ADDED messages and will no longer probe.
Parameters:
Since : 1.4
gst_device_provider_stop
gst_device_provider_stop (GstDeviceProvider * provider)
Decreases the use-count by one. If the use count reaches zero, this GstDeviceProvider will stop providering the devices. This needs to be called the same number of times that gst_device_provider_start was called.
Parameters:
provider
–
Since : 1.4
Gst.DeviceProvider.prototype.stop
function Gst.DeviceProvider.prototype.stop(): {
// javascript wrapper for 'gst_device_provider_stop'
}
Decreases the use-count by one. If the use count reaches zero, this Gst.DeviceProvider will stop providering the devices. This needs to be called the same number of times that Gst.DeviceProvider.prototype.start was called.
Parameters:
Since : 1.4
Gst.DeviceProvider.stop
def Gst.DeviceProvider.stop (self):
#python wrapper for 'gst_device_provider_stop'
Decreases the use-count by one. If the use count reaches zero, this Gst.DeviceProvider will stop providering the devices. This needs to be called the same number of times that Gst.DeviceProvider.start was called.
Parameters:
Since : 1.4
gst_device_provider_unhide_provider
gst_device_provider_unhide_provider (GstDeviceProvider * provider, const gchar * name)
Make provider unhide the devices from factory name.
This function is used when provider will no longer provide the devices reported by provider factory name. A monitor should start monitoring the devices from provider factory name in order to see all devices again.
Since : 1.6
Gst.DeviceProvider.prototype.unhide_provider
function Gst.DeviceProvider.prototype.unhide_provider(name: String): {
// javascript wrapper for 'gst_device_provider_unhide_provider'
}
Make provider unhide the devices from factory name.
This function is used when provider will no longer provide the devices reported by provider factory name. A monitor should start monitoring the devices from provider factory name in order to see all devices again.
Parameters:
a provider factory name
Since : 1.6
Gst.DeviceProvider.unhide_provider
def Gst.DeviceProvider.unhide_provider (self, name):
#python wrapper for 'gst_device_provider_unhide_provider'
Make provider unhide the devices from factory name.
This function is used when provider will no longer provide the devices reported by provider factory name. A monitor should start monitoring the devices from provider factory name in order to see all devices again.
Parameters:
a provider factory name
Since : 1.6
Class Methods
gst_device_provider_class_add_metadata
gst_device_provider_class_add_metadata (GstDeviceProviderClass * klass, const gchar * key, const gchar * value)
Set key with value as metadata in klass.
Parameters:
klass
–
class to set metadata for
key
–
the key to set
value
–
the value to set
Since : 1.4
Gst.DeviceProviderClass.prototype.add_metadata
function Gst.DeviceProviderClass.prototype.add_metadata(klass: Gst.DeviceProviderClass, key: String, value: String): {
// javascript wrapper for 'gst_device_provider_class_add_metadata'
}
Set key with value as metadata in klass.
Parameters:
class to set metadata for
the key to set
the value to set
Since : 1.4
gst_device_provider_class_add_static_metadata
gst_device_provider_class_add_static_metadata (GstDeviceProviderClass * klass, const gchar * key, const gchar * value)
Set key with value as metadata in klass.
Same as gst_device_provider_class_add_metadata, but value must be a static string or an inlined string, as it will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)
Parameters:
klass
–
class to set metadata for
key
–
the key to set
value
(
[transfer: full])
–
the value to set
Since : 1.4
Gst.DeviceProviderClass.prototype.add_static_metadata
function Gst.DeviceProviderClass.prototype.add_static_metadata(klass: Gst.DeviceProviderClass, key: String, value: String): {
// javascript wrapper for 'gst_device_provider_class_add_static_metadata'
}
Set key with value as metadata in klass.
Same as Gst.DeviceProviderClass.prototype.add_metadata, but value must be a static string or an inlined string, as it will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)
Parameters:
class to set metadata for
the key to set
the value to set
Since : 1.4
gst_device_provider_class_get_metadata
const gchar * gst_device_provider_class_get_metadata (GstDeviceProviderClass * klass, const gchar * key)
Get metadata with key in klass.
Parameters:
klass
–
class to get metadata for
key
–
the key to get
the metadata for key.
Since : 1.4
Gst.DeviceProviderClass.prototype.get_metadata
function Gst.DeviceProviderClass.prototype.get_metadata(klass: Gst.DeviceProviderClass, key: String): {
// javascript wrapper for 'gst_device_provider_class_get_metadata'
}
Get metadata with key in klass.
Parameters:
class to get metadata for
the key to get
the metadata for key.
Since : 1.4
gst_device_provider_class_set_metadata
gst_device_provider_class_set_metadata (GstDeviceProviderClass * klass, const gchar * longname, const gchar * classification, const gchar * description, const gchar * author)
Sets the detailed information for a GstDeviceProviderClass.
This function is for use in _class_init functions only.
Parameters:
klass
–
class to set metadata for
longname
–
The long English name of the device provider. E.g. "File Sink"
classification
–
String describing the type of device provider, as an unordered list separated with slashes ('/'). See draft-klass.txt of the design docs for more details and common types. E.g: "Sink/File"
description
–
Sentence describing the purpose of the device provider. E.g: "Write stream to a file"
author
–
Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: "Joe Bloggs <joe.blogs at foo.com>"
Since : 1.4
Gst.DeviceProviderClass.prototype.set_metadata
function Gst.DeviceProviderClass.prototype.set_metadata(klass: Gst.DeviceProviderClass, longname: String, classification: String, description: String, author: String): {
// javascript wrapper for 'gst_device_provider_class_set_metadata'
}
Sets the detailed information for a Gst.DeviceProviderClass.
This function is for use in _class_init functions only.
Parameters:
class to set metadata for
The long English name of the device provider. E.g. "File Sink"
String describing the type of device provider, as an unordered list separated with slashes ('/'). See draft-klass.txt of the design docs for more details and common types. E.g: "Sink/File"
Sentence describing the purpose of the device provider. E.g: "Write stream to a file"
Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: "Joe Bloggs <joe.blogs at foo.com>"
Since : 1.4
gst_device_provider_class_set_static_metadata
gst_device_provider_class_set_static_metadata (GstDeviceProviderClass * klass, const gchar * longname, const gchar * classification, const gchar * description, const gchar * author)
Sets the detailed information for a GstDeviceProviderClass.
This function is for use in _class_init functions only.
Same as gst_device_provider_class_set_metadata, but longname, classification, description, and author must be static strings or inlined strings, as they will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)
Parameters:
klass
–
class to set metadata for
longname
(
[transfer: full])
–
The long English name of the element. E.g. "File Sink"
classification
(
[transfer: full])
–
String describing the type of element, as an unordered list separated with slashes ('/'). See draft-klass.txt of the design docs for more details and common types. E.g: "Sink/File"
description
(
[transfer: full])
–
Sentence describing the purpose of the element. E.g: "Write stream to a file"
author
(
[transfer: full])
–
Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: "Joe Bloggs <joe.blogs at foo.com>"
Since : 1.4
Gst.DeviceProviderClass.prototype.set_static_metadata
function Gst.DeviceProviderClass.prototype.set_static_metadata(klass: Gst.DeviceProviderClass, longname: String, classification: String, description: String, author: String): {
// javascript wrapper for 'gst_device_provider_class_set_static_metadata'
}
Sets the detailed information for a Gst.DeviceProviderClass.
This function is for use in _class_init functions only.
Same as Gst.DeviceProviderClass.prototype.set_metadata, but longname, classification, description, and author must be static strings or inlined strings, as they will not be copied. (GStreamer plugins will be made resident once loaded, so this function can be used even from dynamically loaded plugins.)
Parameters:
class to set metadata for
The long English name of the element. E.g. "File Sink"
String describing the type of element, as an unordered list separated with slashes ('/'). See draft-klass.txt of the design docs for more details and common types. E.g: "Sink/File"
Sentence describing the purpose of the element. E.g: "Write stream to a file"
Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: "Joe Bloggs <joe.blogs at foo.com>"
Since : 1.4
Functions
gst_device_provider_register
gboolean gst_device_provider_register (GstPlugin * plugin, const gchar * name, guint rank, GType type)
Create a new device providerfactory capable of instantiating objects of the type and add the factory to plugin.
Parameters:
plugin
(
[allow-none])
–
GstPlugin to register the device provider with, or NULL for a static device provider.
name
–
name of device providers of this type
rank
–
rank of device provider (higher rank means more importance when autoplugging)
type
–
GType of device provider to register
Since : 1.4
Gst.DeviceProvider.prototype.register
function Gst.DeviceProvider.prototype.register(plugin: Gst.Plugin, name: String, rank: Number, type: GObject.Type): {
// javascript wrapper for 'gst_device_provider_register'
}
Create a new device providerfactory capable of instantiating objects of the type and add the factory to plugin.
Parameters:
Gst.Plugin to register the device provider with, or null for a static device provider.
name of device providers of this type
rank of device provider (higher rank means more importance when autoplugging)
GType of device provider to register
Since : 1.4
Gst.DeviceProvider.register
def Gst.DeviceProvider.register (plugin, name, rank, type):
#python wrapper for 'gst_device_provider_register'
Create a new device providerfactory capable of instantiating objects of the type and add the factory to plugin.
Parameters:
Gst.Plugin to register the device provider with, or None for a static device provider.
name of device providers of this type
rank of device provider (higher rank means more importance when autoplugging)
GType of device provider to register
Since : 1.4
Signals
Virtual Methods
probe
GList * probe (GstDeviceProvider * provider)
Returns a list of devices that are currently available. This should never block. The devices should not have a parent and should be floating.
Parameters:
provider
–
start
gboolean start (GstDeviceProvider * provider)
Starts monitoring for new devices. Only subclasses that can know that devices have been added or remove need to implement this method.
Parameters:
provider
–
vfunc_start
function vfunc_start(provider: Gst.DeviceProvider): {
// javascript implementation of the 'start' virtual method
}
Starts monitoring for new devices. Only subclasses that can know that devices have been added or remove need to implement this method.
Parameters:
do_start
def do_start (provider):
#python implementation of the 'start' virtual method
Starts monitoring for new devices. Only subclasses that can know that devices have been added or remove need to implement this method.
Parameters:
stop
stop (GstDeviceProvider * provider)
Stops monitoring for new devices. Only subclasses that implement the start method need to implement this method.
Parameters:
provider
–
vfunc_stop
function vfunc_stop(provider: Gst.DeviceProvider): {
// javascript implementation of the 'stop' virtual method
}
Stops monitoring for new devices. Only subclasses that implement the start method need to implement this method.
Parameters:
do_stop
def do_stop (provider):
#python implementation of the 'stop' virtual method
Stops monitoring for new devices. Only subclasses that implement the start method need to implement this method.
Parameters:
Function Macros
GST_DEVICE_PROVIDER_CAST
#define GST_DEVICE_PROVIDER_CAST(obj) ((GstDeviceProvider *)(obj))
GST_DEVICE_PROVIDER_REGISTER
#define GST_DEVICE_PROVIDER_REGISTER(d_p, plugin) G_PASTE(gst_device_provider_register_, d_p) (plugin)
This macro can be used to register a device provider into a GstPlugin. This method will be usually called in the plugin init function but can also be called with a NULL plugin.
Parameters:
d_p
–
The device provider name in lower case, with words separated by '_'.
plugin
–
The GstPlugin where to register the device provider.
Since : 1.20
GST_DEVICE_PROVIDER_REGISTER_DECLARE
#define GST_DEVICE_PROVIDER_REGISTER_DECLARE(d_p) \ G_BEGIN_DECLS \ gboolean G_PASTE(gst_device_provider_register_, d_p) (GstPlugin * plugin); \ G_END_DECLS
This macro can be used to declare a new device provider. It has to be used in combination with GST_DEVICE_PROVIDER_REGISTER_DEFINE macro and must be placed outside any block to declare the device provider registration function.
Parameters:
d_p
–
The device provider name in lower case, with words separated by '_'.
Since : 1.20
GST_DEVICE_PROVIDER_REGISTER_DEFINE
#define GST_DEVICE_PROVIDER_REGISTER_DEFINE(d_p, d_p_n, r, t) \ G_BEGIN_DECLS \ gboolean G_PASTE (gst_device_provider_register_, d_p) (GstPlugin * plugin) \ { \ return gst_device_provider_register (plugin, d_p_n, r, t); \ } \ G_END_DECLS
A convenience macro to define the entry point of a
device provider gst_device_provider_register_*(GstPlugin* plugin)
.
Parameters:
d_p
–
The device provider name in lower case, with words separated by '_'.
Used to generate gst_device_provider_register_*(GstPlugin* plugin)
.
d_p_n
–
The public name of the device provider
r
–
The GstRank of the device provider (higher rank means more importance when autoplugging, see GstRank)
t
–
The GType of the device provider.
Since : 1.20
GST_DEVICE_PROVIDER_REGISTER_DEFINE_CUSTOM
#define GST_DEVICE_PROVIDER_REGISTER_DEFINE_CUSTOM(d_p, register_func) \ G_BEGIN_DECLS \ gboolean G_PASTE (gst_device_provider_register_, d_p) (GstPlugin * plugin) \ { \ return register_func (plugin); \ } \ G_END_DECLS
A convenience macro to define the entry point of a
device provider gst_device_provider_register_*(GstPlugin* plugin)
which uses
register_func as the main registration method for the device provider.
As an example, you may define the device provider named "device-provider"
with the namespace my
as following using device_provider_register_custom
:
gboolean my_device_provider_register_custom (GstPlugin * plugin)
{
gboolean ret = FALSE;
ret |= gst_device_provider_register (plugin, "my-device-provider",
GST_RANK_PRIMARY, GST_TYPE_MY_DEVICE_PROVIDER);
return TRUE;
}
GST_DEVICE_PROVIDER_REGISTER_DEFINE_CUSTOM (my_device_provider, my_device_provider_register_custom)
Parameters:
d_p
–
The device provider name in lower case, with words separated by '_'.
Used to generate gst_device_provider_register_*(GstPlugin* plugin)
.
register_func
–
pointer to a method with the format: gboolean register_func (GstPlugin* plugin);
Since : 1.20
The results of the search are