I would like to know if is there a possibility to read Table of
contents ( audio tracks only ) of a Audio CD using gstreamer. I want to know how many Audio tracks are present in the CD and their main informations ( length ,name etc..). Thanks in advance for any suggestion. Giorgio. _______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
On Tue, 2012-06-26 at 14:03 +0200, giorgio wrote:
Hi Giorgio, > I would like to know if is there a possibility to read Table of > contents ( audio tracks only ) of a Audio CD using gstreamer. > I want to know how many Audio tracks are present in the CD and their > main informations ( length ,name etc..). Sure. If your audio cd source (like cdparanoiasrc) derives from GstCddaBaseSrc [0], you can just poke at the GstCddaBaseSrcTrack *tracks array in the structure directly. Alternatively, you can do a duration query in "track" format (GstFormat), that will give you the number of tracks. You would have to switch to (do a seek in "track" format) each track in turn to get the track-specific tags, or do a duration query in TIME format for each track after switching to it. This info is all in the tracks array as well though. In 0.11/1.0 we'll make Audio CD sources announce the TOC using the GstToc API. Cheers -Tim _______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Thanks, Tim,
do you have a simple example? My skill on gstreamer is very low, I should like to have something to use as guide. Giorgio. Il giorno mar, 26/06/2012 alle 13.34 +0100, Tim-Philipp Müller ha scritto: > On Tue, 2012-06-26 at 14:03 +0200, giorgio wrote: > > Hi Giorgio, > > > I would like to know if is there a possibility to read Table of > > contents ( audio tracks only ) of a Audio CD using gstreamer. > > I want to know how many Audio tracks are present in the CD and their > > main informations ( length ,name etc..). > > Sure. If your audio cd source (like cdparanoiasrc) derives from > GstCddaBaseSrc [0], you can just poke at the GstCddaBaseSrcTrack > *tracks array in the structure directly. > > Alternatively, you can do a duration query in "track" format > (GstFormat), that will give you the number of tracks. You would have to > switch to (do a seek in "track" format) each track in turn to get the > track-specific tags, or do a duration query in TIME format for each > track after switching to it. This info is all in the tracks array as > well though. > > In 0.11/1.0 we'll make Audio CD sources announce the TOC using the > GstToc API. > > Cheers > -Tim > > > _______________________________________________ > gstreamer-devel mailing list > [hidden email] > http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel _______________________________________________ gstreamer-devel mailing list [hidden email] http://lists.freedesktop.org/mailman/listinfo/gstreamer-devel |
Free forum by Nabble | Edit this page |