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
Audioscrobbler (last.fm) support for MediaPortal!
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="zombiepig" data-source="post: 85459" data-attributes="member: 12049"><p>Hey rtv - i think i've tracked down the problem with missing artist images.</p><p></p><p>In GUIMusicPlayingNow.cs:</p><p></p><p>function UpdateTrackInfo() has the lines:</p><p></p><p>[CODE]</p><p>if (CurrentTrackTag.Artist != PreviousTrackTag.Artist)</p><p> UpdateArtistInfo();</p><p>[/CODE]</p><p></p><p>So - if the artist is different to the last artist played, it runs UpdateArtistInfo, starts the ArtistInfoRequest thread, and then runs OnUpdateArtistInfoCompleted when the thread is complete. </p><p></p><p>OnUpdateArtistInfoCompleted handles the actual adding of artist art to the viz window:</p><p>[CODE]</p><p>CurrentThumbFileName = Util.Utils.GetCoverArtName(Thumbs.MusicArtists, Util.Utils.FilterFileName(CurrentTrackTag.Artist));</p><p> if (CurrentThumbFileName.Length > 0)</p><p> {</p><p> AddImageToImagePathContainer(CurrentThumbFileName);</p><p> UpdateImagePathContainer();</p><p> }</p><p>[/CODE]</p><p></p><p>Catch is, if the same artist is played twice in a row, UpdateArtistInfo will never be called and the artist thumbnail is not added to the container.</p><p></p><p>The code in UpdateTrackInfo() should be something like:</p><p>[CODE]</p><p>if (CurrentTrackTag.Artist != PreviousTrackTag.Artist)</p><p> UpdateArtistInfo();</p><p>else </p><p>{</p><p> CurrentThumbFileName = Util.Utils.GetCoverArtName(Thumbs.MusicArtists, Util.Utils.FilterFileName(CurrentTrackTag.Artist));</p><p> if (CurrentThumbFileName.Length > 0)</p><p> {</p><p> AddImageToImagePathContainer(CurrentThumbFileName);</p><p> UpdateImagePathContainer();</p><p> }</p><p>}</p><p>[/CODE]</p><p></p><p></p><p>Should fix it up <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite8" alt=":D" title="Big Grin :D" loading="lazy" data-shortname=":D" /></p><p></p><p>Also, is there any chance on getting </p><p>[CODE]</p><p>invalidSingleChars.Add('.');</p><p>[/CODE]</p><p>Removed from getValidURLLastFMString in AudioscrobblerUtils.cs for the reasons outlined in <a href="https://forum.team-mediaportal.com/showpost.php?p=83891&postcount=174" target="_blank">this post</a>? <img src="data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7" class="smilie smilie--sprite smilie--sprite8" alt=":D" title="Big Grin :D" loading="lazy" data-shortname=":D" /></p><p></p><p>Hope that all helps!!</p></blockquote><p></p>
[QUOTE="zombiepig, post: 85459, member: 12049"] Hey rtv - i think i've tracked down the problem with missing artist images. In GUIMusicPlayingNow.cs: function UpdateTrackInfo() has the lines: [CODE] if (CurrentTrackTag.Artist != PreviousTrackTag.Artist) UpdateArtistInfo(); [/CODE] So - if the artist is different to the last artist played, it runs UpdateArtistInfo, starts the ArtistInfoRequest thread, and then runs OnUpdateArtistInfoCompleted when the thread is complete. OnUpdateArtistInfoCompleted handles the actual adding of artist art to the viz window: [CODE] CurrentThumbFileName = Util.Utils.GetCoverArtName(Thumbs.MusicArtists, Util.Utils.FilterFileName(CurrentTrackTag.Artist)); if (CurrentThumbFileName.Length > 0) { AddImageToImagePathContainer(CurrentThumbFileName); UpdateImagePathContainer(); } [/CODE] Catch is, if the same artist is played twice in a row, UpdateArtistInfo will never be called and the artist thumbnail is not added to the container. The code in UpdateTrackInfo() should be something like: [CODE] if (CurrentTrackTag.Artist != PreviousTrackTag.Artist) UpdateArtistInfo(); else { CurrentThumbFileName = Util.Utils.GetCoverArtName(Thumbs.MusicArtists, Util.Utils.FilterFileName(CurrentTrackTag.Artist)); if (CurrentThumbFileName.Length > 0) { AddImageToImagePathContainer(CurrentThumbFileName); UpdateImagePathContainer(); } } [/CODE] Should fix it up :D Also, is there any chance on getting [CODE] invalidSingleChars.Add('.'); [/CODE] Removed from getValidURLLastFMString in AudioscrobblerUtils.cs for the reasons outlined in [URL="https://forum.team-mediaportal.com/showpost.php?p=83891&postcount=174"]this post[/URL]? :D Hope that all helps!! [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
MediaPortal 1
MediaPortal 1 Plugins
Audioscrobbler (last.fm) support for MediaPortal!
Contact us
RSS
Top
Bottom