3

I am working on Cocos2d Android,in cocos2d images are saved in assets folder, here we can't take images ldpi,hdipi,mdpi images. So which size images are best for supporting multiple devices(phones and tablets). I have taken small size image(240x320), I am resizing images, so its supporting for all devices, but images are looking blur. so which size image is best to support all screens both tablet and phones. Please suggest me.

Aamir Abro
  • 838
  • 12
  • 24

2 Answers2

1

the best way is taking the highest resolutions pictures ie. the size of the highest android screen size. and cocos2d will adjust for small android phones according to the screen sizes. Blur will happen when you take small images and enlarge it for big screen android phones.

But if you use multiple png files it increases the app size.

source-I made a game using cocos2d in android.

Sandeep R
  • 2,284
  • 3
  • 25
  • 51
-1

This is how you can arrange stuff in project

res/layout/my_layout.xml // layout for normal screen size ("default") res/layout-small/my_layout.xml // layout for small screen size res/layout-large/my_layout.xml // layout for large screen size res/layout-xlarge/my_layout.xml // layout for extra large screen size res/layout-xlarge-land/my_layout.xml // layout for extra large in landscape orientation

res/drawable-mdpi/my_icon.png        // bitmap for medium density
res/drawable-hdpi/my_icon.png        // bitmap for high density
res/drawable-xhdpi/my_icon.png       // bitmap for extra high density

and this link will tell rest of the story

DjHacktorReborn
  • 2,908
  • 2
  • 20
  • 29