Hello group.:sign0085:
I am building an home automation app and one of the features is screen saver / picture frame mode when user is not interacting with the screen for a while.
The idea is that user (me) is going to periodically load images (possibly formatted to specific size/resolution) onto SD or network location.
When no activity is detected, new activity starts and loads a layout that is made out of ImageView only and pictures slowly load and or transition.
Problem is picture fitting.
I have made the activity to be full screen no title 800x480
Image View is also set 800x480.
I formatted some pictures (*.jpg) to be 800x480 as well as 640x480 just to see how they will show up.
I have tried gravity setting to Center, Fill, and Top Left.
All with the same result, meaning that pictures are always "larger than scree" in other words cropped.
They are formatted to be equal or smaller (640x480) but still large portions close to 20% of height and width are chopped.
I would prefer not to have to format the pictures but just have the application / view to fit the larger dimension into the screen so that any picture you throw at it would display in its entirety even if it means black bars on sides or top / bottom.
Is it possible and what am I doing wrong.
Tried it on real device (Galaxy S) and Emulator with same results.
Thank you,
M.
I am building an home automation app and one of the features is screen saver / picture frame mode when user is not interacting with the screen for a while.
The idea is that user (me) is going to periodically load images (possibly formatted to specific size/resolution) onto SD or network location.
When no activity is detected, new activity starts and loads a layout that is made out of ImageView only and pictures slowly load and or transition.
Problem is picture fitting.
I have made the activity to be full screen no title 800x480
Image View is also set 800x480.
I formatted some pictures (*.jpg) to be 800x480 as well as 640x480 just to see how they will show up.
I have tried gravity setting to Center, Fill, and Top Left.
All with the same result, meaning that pictures are always "larger than scree" in other words cropped.
They are formatted to be equal or smaller (640x480) but still large portions close to 20% of height and width are chopped.
I would prefer not to have to format the pictures but just have the application / view to fit the larger dimension into the screen so that any picture you throw at it would display in its entirety even if it means black bars on sides or top / bottom.
Is it possible and what am I doing wrong.
Tried it on real device (Galaxy S) and Emulator with same results.
Thank you,
M.