After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 551011 - Use chapter info to get track durations
Use chapter info to get track durations
Status: RESOLVED OBSOLETE
Product: rhythmbox
Classification: Other
Component: Removable Media
unspecified
Other Linux
: Normal normal
: ---
Assigned To: RhythmBox Maintainers
RhythmBox Maintainers
Depends on: 540890
Blocks:
 
 
Reported: 2008-09-05 15:22 UTC by Bastien Nocera
Modified: 2018-05-24 13:37 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Be faster at listing CDs (3.29 KB, patch)
2008-09-08 10:28 UTC, Bastien Nocera
committed Details | Review

Description Bastien Nocera 2008-09-05 15:22:34 UTC
It takes a _long_ time for all the tracks in a CD to appear in the UI. This should be pretty much instant when the TOC has been read.

Either we need to use something other than GStreamer to get the duration of the tracks, or we need to use GStreamer differently.
Comment 1 Jonathan Matthew 2008-09-07 06:07:28 UTC
It looks like a GStreamer solution to this is some way off, so until then it'd be good to have an alternative as long as it wasn't too weird a dependency and it actually made a noticeable difference.
Comment 2 Bastien Nocera 2008-09-07 16:52:36 UTC
Tim had a work-around he mentioned on IRC.
Comment 3 Tim-Philipp Müller 2008-09-07 17:19:18 UTC
You *could* access this information by casting the source element to a GstCddaBaseSrc and then accessing the private section of that base classe's instance structure, e.g. something like:

  gst_tag_list_get_uint64 (GST_CDDA_BASE_SRC(src)->tracks[i].tags, GST_TAG_DURATION, &dur);

Needs linking against libgstcdda-0.10 from -base and is of course a bit dodgy. If you don't want to do that and think this needs fixing sooner rather than later, some kind of gst_cdda_base_src_get_tags_for_track() could probably also been added.

Comment 4 Bastien Nocera 2008-09-07 18:09:29 UTC
(In reply to comment #3)
> You *could* access this information by casting the source element to a
> GstCddaBaseSrc and then accessing the private section of that base classe's
> instance structure, e.g. something like:
> 
>   gst_tag_list_get_uint64 (GST_CDDA_BASE_SRC(src)->tracks[i].tags,
> GST_TAG_DURATION, &dur);
> 
> Needs linking against libgstcdda-0.10 from -base and is of course a bit dodgy.
> If you don't want to do that and think this needs fixing sooner rather than
> later, some kind of gst_cdda_base_src_get_tags_for_track() could probably also
> been added.

I'd rather use the hack than have you add API that you'll have to support for a long while. It's fine using the hack while bug 540890 is getting fixed.
Comment 5 Bastien Nocera 2008-09-08 10:28:07 UTC
Created attachment 118288 [details] [review]
Be faster at listing CDs

Much much faster indeed.
Comment 6 Bastien Nocera 2008-09-08 23:39:31 UTC
Leaving this opened to do it the proper way, as mentioned in blocker bug.

2008-09-09  Bastien Nocera  <hadess@hadess.net>

	* configure.ac:
	* plugins/audiocd/Makefile.am:
	* plugins/audiocd/rb-audiocd-source.c
	(rb_audiocd_create_track_entry): Link against libgstcdda,
	and access the tags directly to get the duration of the tracks,
	avoids a lot of slow seeking on the CD, and makes loading CDs
	awfully fast (Helps: #551011)
Comment 7 GNOME Infrastructure Team 2018-05-24 13:37:06 UTC
-- GitLab Migration Automatic Message --

This bug has been migrated to GNOME's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/rhythmbox/issues/620.