Gst.DeviceProviderClass

Fields

Name

Type

Access

Description

factory

Gst.DeviceProviderFactory

r

a pointer to the Gst.DeviceProviderFactory that creates this provider

metadata

object

r

parent_class

Gst.ObjectClass

r

the parent Gst.ObjectClass structure

probe

object

r

Returns a list of devices that are currently available. This should never block. The devices should not have a parent and should be floating.

start

object

r

Starts monitoring for new devices. Only subclasses that can know that devices have been added or remove need to implement this method.

stop

object

r

Stops monitoring for new devices. Only subclasses that implement the start() method need to implement this method.

Methods

add_metadata (key, value)

add_static_metadata (key, value)

get_metadata (key)

set_metadata (longname, classification, description, author)

set_static_metadata (longname, classification, description, author)

Details

class Gst.DeviceProviderClass

The structure of the base Gst.DeviceProviderClass

New in version 1.4.

add_metadata(key, value)[source]
Parameters:
  • key (str) – the key to set

  • value (str) – the value to set

Set key with value as metadata in self.

New in version 1.4.

add_static_metadata(key, value)[source]
Parameters:
  • key (str) – the key to set

  • value (str) – the value to set

Set key with value as metadata in self.

Same as Gst.DeviceProviderClass.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.)

New in version 1.4.

get_metadata(key)[source]
Parameters:

key (str) – the key to get

Returns:

the metadata for key.

Return type:

str or None

Get metadata with key in self.

New in version 1.4.

set_metadata(longname, classification, description, author)[source]
Parameters:
  • longname (str) – The long English name of the device provider. E.g. “File Sink”

  • classification (str) – 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 (str) – Sentence describing the purpose of the device provider. E.g: “Write stream to a file”

  • author (str) – Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: “Joe Bloggs <joe.blogs at foo.com>”

Sets the detailed information for a Gst.DeviceProviderClass.

This function is for use in _class_init functions only.

New in version 1.4.

set_static_metadata(longname, classification, description, author)[source]
Parameters:
  • longname (str) – The long English name of the element. E.g. “File Sink”

  • classification (str) – 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 (str) – Sentence describing the purpose of the element. E.g: “Write stream to a file”

  • author (str) – Name and contact details of the author(s). Use \n to separate multiple author metadata. E.g: “Joe Bloggs <joe.blogs at foo.com>”

Sets the detailed information for a Gst.DeviceProviderClass.

This function is for use in _class_init functions only.

Same as Gst.DeviceProviderClass.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.)

New in version 1.4.