gstreamermm 1.4.3

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Public Attributes | List of all members
Gst::Fourcc Class Reference
gstreamermm Helper Classes

A class that represents a 4 byte identifier (used in codecs). More...

## Public Member Functions
| Fourcc ()
| Construct an undefined Gst::Fourcc. More...
| Fourcc (const Fourcc& src)
| Construct a Gst::Fourcc from another. More...
| Fourcc (char first, char second, char third, char fourth)
| Construct a Gst::Fourcc from 4 characters. More...
| Fourcc (const Glib::ustring& s)
| Construct a Gst::Fourcc from an input string. More...
| Fourcc (guint32 fourcc)
| Construct a Gst::Fourcc from a 32 bit unsigned integer. More...
Fourcc& | operator= (const Fourcc& src)

## Public Attributes
char | first
char | second
char | third
char | fourth

## Detailed Description

A class that represents a 4 byte identifier (used in codecs).

Gst::Fourcc is used to store a four byte identifier in Gst::Structure of Gst::Caps as a value representing a property (see GStreamer Application Development Manual section 8.2.2 and GstValue docs). When the value is set, it is transformed to a GStreamer GType so retrieving the value is a bit different. The class can be used in setting and getting a Gst::Structure field like so:

Glib::Value<Gst::Fourcc> value;
value.init(Glib::Value<Gst::Fourcc>::value_type());
value.set(Gst::Fourcc('M', 'J', 'P', 'G'));
Gst::Structure structure("my-structure");
structure.set_field("id", value);
...
Glib::ValueBase gst_value;
structure.get_field("id", gst_value);
Gst::Fourcc fourcc(gst_value);
char first_char = fourcc.first;
...

## Constructor & Destructor Documentation

Gst::Fourcc::Fourcc | ( |  | ) |

Construct an undefined Gst::Fourcc.

Gst::Fourcc::Fourcc | ( | const Fourcc& | src | ) |

Construct a Gst::Fourcc from another.

Gst::Fourcc::Fourcc | ( | char | first,
|  | char | second,
|  | char | third,
|  | char | fourth
| ) |  |

Construct a Gst::Fourcc from 4 characters.

Gst::Fourcc::Fourcc | ( | const Glib::ustring & | s | ) |
| explicit

Construct a Gst::Fourcc from an input string.

Caller is responsible for ensuring the input string consists of at least four characters.

Gst::Fourcc::Fourcc | ( | guint32 | fourcc | ) |
| explicit

Construct a Gst::Fourcc from a 32 bit unsigned integer.

## Member Function Documentation

Fourcc& Gst::Fourcc::operator= | ( | const Fourcc& | src | ) |

## Member Data Documentation

char Gst::Fourcc::first

char Gst::Fourcc::fourth

char Gst::Fourcc::second

char Gst::Fourcc::third

The documentation for this class was generated from the following file:

- gstreamermm/value.h