If this is your first visit, be sure to
check out the FAQ by clicking the
link above. You may have to register
before you can post: click the register link above to proceed. To start viewing messages,
select the forum that you want to visit from the selection below.
Announcement
Collapse
No announcement yet.
Subsonic Plugin - player hang when format changes mp3 -> flac or flac -> mp3
Subsonic Plugin - player hang when format changes mp3 -> flac or flac -> mp3
Hi all,
I'm coding a plugin to use a subsonic server as stream source.
Looks good so far but i face two issues i didn't figure out yet.
For bandwidth reasons music is trancoded on the subsonic side, based on the settings of the plugin pannel.
Transcoding options are mp3 ’64k’, ‘128k’, ‘256k’, ‘320k’, and raw/disabled -> streams the file as is. flac in my case.
When switching from mp3 to flac or from flac to mp3 (switching from 64k to 320k works flawlessly), the player hang and there is noway to replay a song that have been played in the previous format. Songs that have never been played can be played after some delay and after a player (squeezeplay) restart.
I think we'd need much more information (or even the code...) to understand what really is going on there. Eg. are those URLs the URLs that you'd receive browsing the content? Or you use the protocol handler to convert something like myplugin://12345.mp3 into that URL?
The latter actually is what I would recommend you to do. And make sure that URL already comes with the correct extension.
Michael
"It doesn't work - what shall I do?" - "Please check your server.log and/or scanner.log file!"
(LMS: Settings/Information)
I think we'd need much more information (or even the code...) to understand what really is going on there. Eg. are those URLs the URLs that you'd receive browsing the content? Or you use the protocol handler to convert something like myplugin://12345.mp3 into that URL?
The latter actually is what I would recommend you to do. And make sure that URL already comes with the correct extension.
It actually is a "subsonic://" url.
Plugin can be downloaded there
and here is repo xml
I can provide an account to a subsonic server in pm if needed, as you probably don't have that under the hand.
Subsonic Plugin - player hang when format changesmp3 -> flac or flac -> mp3
That's looking pretty promising! And quite snappy, too.
As I mentioned in my first posting I would use a file extension defining
the content type, plus even the bitrate as part of the "filename". I
don't remember the details, but I remember that I failed to have generic
URLs for TIDAL's FLAC/MP3 streams. Eventually went back to using the
file extension, as somewhere deep in the code LMS makes assumptions
about what the file might be based on this.
I know that this means you define the sound quality when you browse the
collection. But IMHO this shouldn't be a problem, as users hardly will
change quality all the time.
So... make it something like 123456-128.mp3 or abcdef.flac. Then use
these chunks of information rather then the prefs to build the actual
URL in the protocol handler.
--
Michael
Michael
"It doesn't work - what shall I do?" - "Please check your server.log and/or scanner.log file!"
(LMS: Settings/Information)
I'll try that suffix thing and see.
But as you said in a normal operation users won't change those settings often, so we may just prevent them that have to wait a little bit or restart and clear everything when they modify the transcoding thing.
That's looking pretty promising! And quite snappy, too.
As I mentioned in my first posting I would use a file extension defining
the content type, plus even the bitrate as part of the "filename". I
don't remember the details, but I remember that I failed to have generic
URLs for TIDAL's FLAC/MP3 streams. Eventually went back to using the
file extension, as somewhere deep in the code LMS makes assumptions
about what the file might be based on this.
I know that this means you define the sound quality when you browse the
collection. But IMHO this shouldn't be a problem, as users hardly will
change quality all the time.
So... make it something like 123456-128.mp3 or abcdef.flac. Then use
these chunks of information rather then the prefs to build the actual
URL in the protocol handler.
--
Michael
Ola Michael,
I did just as you said, recode the thing to get the suffix and bitrate into the url, and you know what?
It did work i'd never figure that out by myself. thank you man, you really are the guy !
By the way i've also implemented one or two more things and i think i'm getting close to a release.
Have you got any idea of where to go next?
Your repo.xml seems to be gone? But you have a web server. Upload the plugin (with a version number in the file name ;-)) and the repo.xml to some public space. Let me know about the repo's URL and I can include it in the main repository.
Michael
"It doesn't work - what shall I do?" - "Please check your server.log and/or scanner.log file!"
(LMS: Settings/Information)
We process personal data about users of our site, through the use of cookies and other technologies, to deliver our services, personalize advertising, and to analyze site activity. We may share certain information about our users with our advertising and analytics partners. For additional details, refer to our Privacy Policy.
By clicking "I AGREE" below, you agree to our Privacy Policy and our personal data processing and cookie practices as described therein. You also acknowledge that this forum may be hosted outside your country and you consent to the collection, storage, and processing of your data in the country where this forum is hosted.
Comment