Support and General Use > Theming and Appearance Customization

iText new WPS (WAS: Same hardware, different volume limits?)

(1/3) > >>

Yotto:
First, to show off my new WPS-in-progress, iText.  It's inspired by (and would be impossible had the research not been done by) Bascule and his all-text themes.

First, a screen shot of the theme working:

I think it looks pretty good.  I had some issue getting the "border" lines to stay still while the volume dB level changed string length, but I finally got it working due to some code that I'm both proud and ashamed of.  Note, in the next screen shot, that the length of both the volume dB and the battery percent are different than in the first screen shot, but the rest of the WPS stays in line:

So, that's not my problem.  My problem is, in the simulator, the limit of volume is -40dB, but on my actual 5G (not 5.5G) iPod Video, the limit of volume is -58dB.  The way I am adjusting the lines to fit the spaces in is dependent on how many steps there are, so with the current iteration of the code (which works perfectly on my actual iPod, that goes to -58dB) looks like this for a couple volume clicks:

Here's the "proof" that the simulator goes to -40dB and stops:


So, after all this, here's my question: Is the simulator just wonky, and all iPods go to -58dB, so I can release my code so long as it looks good on my iPod?  Or is there something that could cause two different iPods to have two different "floors" of range?  I am hoping it's just the simulator, because I can't think of another way to do what I want to do without changing the layout of the WPS, and I like the layout of the WPS.

Llorean:
All iPod Videos should go to -58. Other models of iPod (4G, Nano, etc) have different hardware and may have a different floor (or rather, do) but all Videos should be fine, so you should be okay I believe.

bascule:
Cool...

...and thanks for the mention :)

EDIT: I'm a bit confused as to what your actual problem is. Is it purely with the numeric 'dB' indicator , not the volume bar length?

If so, I don't see how a different 'floor' value has any bearing on that, as the only adjustment you need to make is for the different number of characters from 1 (0-6dB) to 3 (-10dB and below)

You could post a code snippet and I'll have a look...

I'm also puzzled as to why the volume bar changes length, which IMHO looks odd, but as you seem happy with that, I'll let it lie.

Yotto:
The volume bar changing length is a joke, actually, because volume goes to "11" and breaks the bounds of the gray background. The problem I'm having (or not, if iPod Videos are always -58 to +6 dB) is with the reported dB only.

Below is the code for that line. I'm not pretending it's pretty and I'm not pretending it's the most efficient way to do it. I expanded %?pv out 60 times. 49 of these evaluate empty (for -58 to -10), 9 of them evaluate as a single space (To pad -9 to -1), and the final 2 evaluate as two spaces (To pad 0 to 6).

It doesn't seem that I could cut down the number of options within the brackets, but I didn't try.

Here's the entire line, all that matters is after %ar though.

--- Code: ---%?mh─┼─Hold   │%ac%?fv%ar│   %?pv%pv dB    

--- End code ---

bascule:

--- Quote from: Yotto on September 14, 2007, 05:35:02 AM ---The volume bar changing length is a joke, actually, because volume goes to "11" and breaks the bounds of the gray background.
--- End quote ---

I had a suspicion that was the case  ;D  Spinal Tap strikes again!


--- Quote from: Yotto on September 14, 2007, 05:35:02 AM ---Below is the code for that line. I'm not pretending it's pretty and I'm not pretending it's the most efficient way to do it. I expanded %?pv out 60 times. 49 of these evaluate empty (for -58 to -10), 9 of them evaluate as a single space (To pad -9 to -1), and the final 2 evaluate as two spaces (To pad 0 to 6).

--- End quote ---

OK, I see the problem now...

Obviously it works as you want it on target, but it certainly ain't pretty or easily portable to other targets.

As the CBR/VBR text length is fixed, you could just keep the code for that (%?fv) and the right-hand border graphic in the left-aligned section padded with spaces into the centre:


--- Code: ---%?mh─┼─Hold   │    %?fv   |%ar%pv dB

--- End code ---

Navigation

[0] Message Index

[#] Next page

Go to full version