Rockbox Technical Forums

Support and General Use => Plugins/Viewers => Topic started by: johnlee on July 08, 2012, 08:59:22 PM

Title: JPEG Viewers
Post by: johnlee on July 08, 2012, 08:59:22 PM
Hello Forum..

Can someone explain how the JPEG viewer calculates the initial scale? The scaling doesn't seem to be based on the LCD screen size. I've got an image that's 432x341 but the initial scale puts the image at 108x85 which leaves a lot of real estate uncovered. Zooming fills the screen and then some. Is there any way to get the viewer to scale the image so the long edge fits edge-to-edge while maintaining the aspect ratio.

Please response .. Thanks in Advance
Title: Re: JPEG Viewers
Post by: Chronon on July 11, 2012, 07:45:20 PM
I don't think the scaling is very sophisticated.  IIRC it can change the dimension by factors of 2, which would be consistent with what you wrote (108 =432*1/4).  I think it probably selects the largest such zoom setting that doesn't crop the image.