Search code examples
androidcocos2d-iphonecocos2d-android

how to design android cocos2d app for multiple screens


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.


Solution

  • 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