#include <cddabasesrc.h>
Public Member Functions | |
virtual | ~CddaBaseSrc () |
GstCddaBaseSrc* | gobj () |
Provides access to the underlying C GObject. | |
const GstCddaBaseSrc* | gobj () const |
Provides access to the underlying C GObject. | |
GstCddaBaseSrc* | gobj_copy () |
Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. | |
Related Functions | |
(Note that these are not member functions.) | |
Glib::RefPtr <GstBase::CddaBaseSrc> | wrap (GstCddaBaseSrc* object, bool take_copy=false) |
A Glib::wrap() method for this object. |
Provides a base class for CDDA sources, which handles things like seeking, querying, discid calculation, tags, and buffer timestamping.
GstBase::CddaBaseSrc registers two Gst::Formats of its own, namely the "track" format and the "sector" format. Applications will usually only find the "track" format interesting. You can retrieve that Gst::Format for use in seek events or queries with Gst::get_format("track").
In order to query the number of tracks, for example, an application would set the CDDA source element to READY or PAUSED state and then query the the number of tracks via Gst::Element::query_duration() using the track format acquired above. Applications can query the currently playing track in the same way.
Alternatively, applications may retrieve the currently playing track and the total number of tracks from the taglist that will be posted on the bus whenever the CD is opened or the currently playing track changes. The taglist will contain Gst::Tag::TRACK_NUMBER and Gst::Tag::TRACK_COUNT tags.
Applications playing back CD audio using playbin and cdda://n URIs should issue a seek command in track format to change between tracks, rather than setting a new cdda://n+1 URI on playbin (as setting a new URI on playbin involves closing and re-opening the CD device, which is much much slower).
CDDA sources will automatically emit a number of tags, details about which can be found in the libgsttag documentation. Those tags are: Gst::Tag::CDDA_CDDB_DISCID, Gst::Tag::CDDA_CDDB_DISCID_FULL, Gst::Tag::CDDA_MUSICBRAINZ_DISCID, Gst::Tag::CDDA_MUSICBRAINZ_DISCID_FULL, among others.
virtual GstBase::CddaBaseSrc::~CddaBaseSrc | ( | ) | [virtual] |
const GstCddaBaseSrc* GstBase::CddaBaseSrc::gobj | ( | ) | const [inline] |
GstCddaBaseSrc* GstBase::CddaBaseSrc::gobj | ( | ) | [inline] |
GstCddaBaseSrc* GstBase::CddaBaseSrc::gobj_copy | ( | ) |
Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
Reimplemented from Gst::PushSrc.
Glib::RefPtr<GstBase::CddaBaseSrc> wrap | ( | GstCddaBaseSrc * | object, | |
bool | take_copy = false | |||
) | [related] |
A Glib::wrap() method for this object.
object | The C instance. | |
take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref. |