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 733233 - chromaprint: notify fingerprint also via property notify
chromaprint: notify fingerprint also via property notify
Status: RESOLVED FIXED
Product: GStreamer
Classification: Platform
Component: gst-plugins-bad
git master
Other Linux
: Normal enhancement
: 1.9.1
Assigned To: GStreamer Maintainers
GStreamer Maintainers
Depends on:
Blocks:
 
 
Reported: 2014-07-16 00:46 UTC by Marcin Kolny (IRC: loganek)
Modified: 2016-04-07 19:57 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proposed solution (3.11 KB, patch)
2014-07-16 00:46 UTC, Marcin Kolny (IRC: loganek)
needs-work Details | Review
proposed solution v2 (2.12 KB, patch)
2014-07-16 23:44 UTC, Marcin Kolny (IRC: loganek)
committed Details | Review

Description Marcin Kolny (IRC: loganek) 2014-07-16 00:46:31 UTC
Created attachment 280773 [details] [review]
proposed solution

I think, chromaprint plugin should notify user about fingerprint not by Tag, but by property change notification. I implemented notify-based solution, and left tag-method too, for backward compatibility.
Comment 1 Sebastian Dröge (slomo) 2014-07-16 14:56:51 UTC
Comment on attachment 280773 [details] [review]
proposed solution

Please get rid of all the unrelated whitespace changes. And I think for consistency it would be good to just store all pspecs in an array indexed by the property enum
Comment 2 Tim-Philipp Müller 2014-07-16 15:06:01 UTC
I would just emit the notify by name, the pspec thing is only really needed if this is something you might be doing a *lot* and performance is important. Not sure that is the case here.

The reason we tend to not notify such things via properties is that the notification will come from a streaming thread, which causes all kinds of problems.
Comment 3 Marcin Kolny (IRC: loganek) 2014-07-16 23:44:54 UTC
Created attachment 280895 [details] [review]
proposed solution v2

Thanks for your advices, I improved my patch a little.
Comment 4 Tim-Philipp Müller 2016-04-07 19:57:02 UTC
Thanks, pushed (I removed the line break in the property registration and your copyright addition - we usually don't add copyright notices for minor additions):

commit ac8a14d1c825d572fc901490f7658f1a08ff68fe
Author: Marcin Kolny <marcin.kolny@gmail.com>
Date:   Wed Jul 16 02:44:42 2014 +0200

    chromaprint: emit notify::fingerprint signal when fingerprint is ready
    
    In addition to adding the fingerprint to the tags.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=733233