answered
2015-11-16 17:58:06 +0200
I recently started packaging ambiences into RPMs to be able to choose them in Situations app.
While doing that I also had problems with the ambience picture size.
The way SailFishOS is treating the picture is defined by the ambience file and (in some mysterious way) also by the size of your picture.
The new SailFishOS 2.0 ambiences have a version line added to the ambience file and it is set to 2 (look to /usr/share/ambience for all pre-installed ambiences). Therefore the 2048x2048px picture is cropped like Kiri described above. Great explanation by the way and very nice backgrounds in your album Kiri!
I found out, that you can re-use your old 540x1600px backgrounds...with just a little optimization:
- make sure your ambience file contains a version line and it is set to 1:
{
"translationCatalog" : "silentambience",
"displayName" : "Silence",
"ringerToneFile" : { "enabled": 1 },
"messageToneFile" : { "enabled": 1 },
"mailToneFile" : { "enabled": 1 },
"internetCallToneFile" : { "enabled": 1 },
"chatToneFile" : { "enabled": 1 },
"calendarToneFile" : { "enabled": 1 },
"clockAlarmToneFile" : { "file": "wakeup.mp3", "enabled": 1 },
"wallpaper" : "silentambience.jpg",
"highlightColor" : "#80bfff",
"secondaryHighlightColor" : "#80bfff99",
"primaryColor" : "#FFFFFFFF",
"secondaryColor" : "#FFFFFF99",
"ringerVolume" : 0,
"version" : 1,
"favorite" : true
}
2. You need to modify your 540x1600px picture, because SFOS is cropping it. From top to bottom the first 58px are cropped. The next 960px are kept and actually visible on the screen. The rest is also cropped. But you need to keep the 540x1600px size to make it work! So if you have important stuff in the first 58px you don't want to miss, simply add 58px (color does not matter as it will not be visible) to the top of the picture and cut 58px at the bottom.
But this only works, if you create a RPM for your ambience. Using an 540x1600px picture to create an ambience directly on the phone (gallery app) will give different result.
I've also been trying to figure out what size the wallpaper should be for the new ambiances... Doesn't seem to be documented anywhere?
Feffe ( 2015-10-09 22:31:52 +0200 )edit