Resolution Independence help???
wroachbarrette
Member Posts: 101
i dont know the first thing about graphic design i just code games but when i enable resolution independence all my images are blurry, any help?
Comments
In short...create the graphics for the large resolution...but create the app for the smaller resolution. GS will scale the app up for the larger resolution devices and scale down the graphics for the smaller resolution devices automatically when the RI checkbox is checked.
Also...
Make sure your images are a multiple of 4 in size. This means that a 120x120 is good since half that size is 60x60 so it will land on a layout point at 30x30 (center). If the imager were 119x119...then half that would be 59.5x59.5 which will be blurry when centered on a layout point.
If you have an image that is 110x110 at high res...then use RI to scale it for 3G. The image is then 55x55. If you then position X (or Y) at display.width/2 (or anything / 2 for that matter)...the image will split a pixel...Unless you place a floor() wrapper on every actor/expression regarding placement.
If you force place the images (and/or they don't move)...then you won't have problems generally...but if you images/actors are dynamically located...then split pixels (and blurring) may occur.
Best to use power of 4...then you avoid pixel shifts on the 320x480 grid.
You don't really need to check all your images if they look okay when you test the app. But if you have blurry images...the first thing you should check is the image size (power of 4) and bit depth...as those 2 things can cause blurring.
Rule of thumb is...always use an even number sized image.
Not too bad though.
I also noticed that if you do not use Resolution independence, images that are rectangular and do not have any transparency will have black lines on an iPhone4...
I reported it in this thread:
http://gamesalad.com/forums/topic.php?id=9378#post-66410
I would definitely test your game on all devices before publishing to make sure it looks ok.
Make the image twice the size of what you normally would. Continue to layout the game at 320x480 (as FMG suggests). You are correct however about scaling your actor size for the smaller layout grid.
The 4 times thing refers to the dimensions of the image and should not be confused with overall image size/resolution. The image height and width "should" be measured as a multiple of 4. For example...images dimensions could be 4, 12, 16, 20, 24, 40, 88, 124, etc....all multiples of 4. This way when GS scales down the image for older devices...they will be multiples of 2...in order to avoid pixel splitting when laying out to a half pixel point.
Odd dimensioned images can at times cause blurring if incorrectly placed. To be safe...use images with the correct multiple...a multiple of 2 if not using RI or a multiple of 4 if using RI.
Thanks