Functions

barcode_type_from_string (string)

get_diagnostic_info ()

init (argv)

is_barcode_detection_enabled ()

is_initialized ()

media_capture_error_quark ()

Details

Aperture.barcode_type_from_string(string)
Parameters:

string (str) –

Return type:

Aperture.Barcode

Aperture.get_diagnostic_info()
Returns:

the diagnostic string. Free with GLib.free().

Return type:

str

Gets a string containing useful debugging information, suitable for including in bug reports, for example. This could include versions of relevant libraries, basic software and hardware information, etc.

No guarantees are made about the format of the string.

New in version 0.1.

Aperture.init(argv)
Parameters:

argv ([str] or None) – pointer to the program’s command line arguments, or None

Returns:

pointer to the program’s command line arguments, or None

Return type:

argv: [str]

Initializes the Aperture library, if it hasn’t been initialized already.

This will initialize GStreamer for you. If you don’t want this, initialize GStreamer yourself before calling Aperture.init().

New in version 0.1.

Aperture.is_barcode_detection_enabled()
Returns:

True if barcode detection is available, otherwise False

Return type:

bool

Determines whether the barcode detection features of Aperture are enabled.

This is based on whether the zbar element is available to GStreamer. It is part of the gst-plugins-bad package. Note that many distributions don’t enable the zbar component of gst-plugins-bad by default, because it needs an extra dependency (the zbar library). You may need to find a gst-plugins-bad-extras package or similar, or compile that particular plugin yourself. For a Flatpak example, see the demo application in Aperture’s source code.

Note that Aperture itself does *not* need to be recompiled to enable barcode detection. It is based solely on whether the GStreamer plugin is available.

New in version 0.1.

Aperture.is_initialized()
Returns:

True if the library is initialized, otherwise False

Return type:

bool

Gets whether Aperture is initialized.

New in version 0.1.

Aperture.media_capture_error_quark()
Return type:

int