home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
MediaPortal 1
MediaPortal 1 Plugins
Pandora Plugin not advancing to the next song
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="mm1352000" data-source="post: 1144047" data-attributes="member: 82144"><p>In case it helps, you can see the relevant code here:</p><p><a href="http://pandora-musicbox.googlecode.com/svn/trunk/Source/MediaPortalPlugin/GUI/MusicBoxGUI.cs" target="_blank">http://pandora-musicbox.googlecode.com/svn/trunk/Source/MediaPortalPlugin/GUI/MusicBoxGUI.cs</a></p><p></p><p>[code]</p><p>private void OnPlayBackEnded(g_Player.MediaType type, string filename) {</p><p> try {</p><p> if (!initialized || handlingEvent) return;</p><p> handlingEvent = true;</p><p></p><p> if (Core.MusicBox.CurrentSong != null && filename == Core.MusicBox.CurrentSong.AudioURL) {</p><p> logger.Debug("Playback ended for current Pandora song.");</p><p> setWorkingAnimationStatus(true);</p><p> PlayNextTrack();</p><p> setWorkingAnimationStatus(false);</p><p> }</p><p> }</p><p> catch (Exception ex) {</p><p> GracefullyFail(ex);</p><p> }</p><p> finally {</p><p> handlingEvent = false;</p><p> }</p><p>}[/code]</p><p></p><p>And in Init():</p><p>[code]g_Player.PlayBackEnded += new g_Player.EndedHandler(OnPlayBackEnded);[/code]</p><p></p><p>So, the plugin is triggered to play the next track when the current one finishes.</p><p></p><p>The log shows that this function is being called by BASS:</p><p><a href="https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/MixerStream.cs#L845" target="_blank">https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/MixerStream.cs#L845</a></p><p></p><p>That function notifies the audio engine to start crossfading:</p><p><a href="https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/BassAudioEngine.cs#L533" target="_blank">https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/BassAudioEngine.cs#L533</a></p><p></p><p>There should not be any next song queued so I don't understand why the log says "BASS: Fading of stream finished." instead of the expected "BASS: Reached end of playlist.".</p></blockquote><p></p>
[QUOTE="mm1352000, post: 1144047, member: 82144"] In case it helps, you can see the relevant code here: [URL]http://pandora-musicbox.googlecode.com/svn/trunk/Source/MediaPortalPlugin/GUI/MusicBoxGUI.cs[/URL] [code] private void OnPlayBackEnded(g_Player.MediaType type, string filename) { try { if (!initialized || handlingEvent) return; handlingEvent = true; if (Core.MusicBox.CurrentSong != null && filename == Core.MusicBox.CurrentSong.AudioURL) { logger.Debug("Playback ended for current Pandora song."); setWorkingAnimationStatus(true); PlayNextTrack(); setWorkingAnimationStatus(false); } } catch (Exception ex) { GracefullyFail(ex); } finally { handlingEvent = false; } }[/code] And in Init(): [code]g_Player.PlayBackEnded += new g_Player.EndedHandler(OnPlayBackEnded);[/code] So, the plugin is triggered to play the next track when the current one finishes. The log shows that this function is being called by BASS: [URL]https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/MixerStream.cs#L845[/URL] That function notifies the audio engine to start crossfading: [URL]https://github.com/MediaPortal/MediaPortal-1/blob/master/mediaportal/Core/MusicPlayer/BASS/BassAudioEngine.cs#L533[/URL] There should not be any next song queued so I don't understand why the log says "BASS: Fading of stream finished." instead of the expected "BASS: Reached end of playlist.". [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
MediaPortal 1 Plugins
Pandora Plugin not advancing to the next song
Contact us
RSS
Top
Bottom