Support and General Use > Theming and Appearance Customization

How to keep 'no artwork' conditional viewport from briefly appearing?

(1/4) > >>

Carson Dyle:
I've created a WPS for the Sansa Fuze v2 similar to many out there, having artwork on the left and a viewport with track info text immediately to its right.  What I see on my Fuze when I skip a track is that the 'no artwork' viewport always appears for some brief time before the artwork appears and appears to shift the track info text to the right.

Can that behavior be avoided somehow?  I understand that Rockbox doesn't immediately know whether the artwork is available.

Here's the relevant code. The two track info viewports are defined as the last things in the wps file.


--- Code: ---# Preload images, cover
%xl(A,battery.bmp,0,0,23)
%xl(B,repeat.bmp,0,0,4)
%xl(C,shuffle.bmp,27,0)
%xl(D,hold.bmp,47,0)
%xl(E,pbstatus.bmp,0,0,3)
%Cl(0,0,85,85,c,c)

# Conditional viewports
%?C<%Vd(a)|%Vd(b)>            # Track info, with and without cover
%?mv(2)<%Vd(d)|%Vd(c)>        # Volume bar/progress bar
%?Fn<%Vd(e)>                  # Next track info
%?cc<%Vd(f)>                  # Clock

# Track info, with cover
%Vl(a,4,43,85,85,-)
%Cd
%Vl(a,93,43,124,70,5)%Vf(ffffff)
%s%al%?it<%it|%fn>
%s%al%?ia<%ia|%?d(2)<%d(2)|%(root%)>>
%s%al%?id<%id|%?d(1)<%d(1)|%(root%)>>
%Vl(a,93,113,124,15,3)%Vf(ffffff)
%s%al%?iy<%iy>%ar

# Track info, no cover
%Vl(b,4,43,212,70,5)%Vf(ffffff)
%s%al%?it<%it|%fn>
%s%al%?ia<%ia|%?d(2)<%d(2)|%(root%)>>
%s%al%?id<%id|%?d(1)<%d(1)|%(root%)>>
%Vl(b,4,113,212,15,3)%Vf(ffffff)
%s%al%?iy<%iy>%ar

--- End code ---

[Saint]:
No, there is no way to avoid this.

For a brief period while switching tracks, until the check for AA becomes "true", it is "false" and will show the false case.

It is usually an incredibly brief, almost unnoticeable period (in my experience) though.



[St.]

Carson Dyle:
Ok, thanks. I don't see it at all when running on the emulator on my PC, but it's definitely noticeable on the Fuze.

What if... AA were assumed "true" by default instead of the other way around?  I know it would just give the opposite behavior, causing shifting viewports when there's no album art, but wouldn't it be a fairly safe assumption that most people nowadays do take the trouble to have artwork for most tracks?

lilwire:

--- Quote from: Carson Dyle on February 02, 2011, 07:40:43 PM ---What if... AA were assumed "true" by default instead of the other way around?  I know it would just give the opposite behavior, causing shifting viewports when there's no album art, but wouldn't it be a fairly safe assumption that most people nowadays do take the trouble to have artwork for most tracks?

--- End quote ---
Your logic sounds good, I like the idea  ;) (I'm also a victim of this lag) Hopefully some dev with the knowledge can make this more clear

JdGordon:
untill AA is found the wps is going to assume there isnt one (you can ever prove the non-existance of something).

if you always want to show AA why not setup an dummy cover image and use that for when a track has no AA?

Or another option is always displaying something completly different for the first few seconds of the track using %?pS(3)<>

Navigation

[0] Message Index

[#] Next page

Go to full version