![]() You might be able to create your custom class (by refactoring this code) to grab the song information. Pay close attention to this part in src/core/mpris2.cpp (line 109 and 336) You can look at: src/core/mpris2.h,src/core/mpris2.cpp: Using the below as a template is probably better than manually accessing the playlist song information, through the shared_ptr: I believe this is what is causing your code to generate a Segmentation Fault (SIGSEGV). It doesn't provide any sort of thread-safety ![]() Std::shared_ptr is only a smart pointer that ensures the memory is deallocated when the last holder releases its hold on the ptr. (Which is not being done in the code currently). The only way (that I know of) to do that is use mutexes or other thread synchronization techniques to ensure that the shared_ptr is accessed correctly. Search and play your local music library. It is inspired by Amarok 1.4, focusing on a fast and easy-to-use interface for searching and playing your music. Clementine is a multiplatform music player. There doesn't (currently) seem to be a way to check/verify that the Metadata is valid, that the shared_ptr is still valid. Clementine is a modern music player and library organizer. PlaylistItemPtr itemptr = playlist-> item_at ( row ) Ĭhecking if PlaylistItemPtr is not null before attempting to access the song metadata is probably not very useful.ĭue to multi-threading is possible for the PlaylistItemPtr to be valid when checked, but be invalid when the call to Metadata() is made. Playlist* playlist = app_-> playlist_manager()->active()
0 Comments
Leave a Reply. |