Pvr flipped in cocos2d version 3.2 : dilemma when porting from 2.1

后端 未结 1 1074
小蘑菇
小蘑菇 2021-01-29 09:28

I am currently porting a game from version 2.1 to 3.2 of cocos2d. We have over 3600 pvr.gz files that are NOT flipped, eg were produced and working under 2.1. We tested out with

相关标签:
1条回答
  • 2021-01-29 10:08

    ok, many thanks to Scott Lembcke of cocos2d for pointing me in the right direction. For posterity, hope this helps someone out there. PVRTexToolCLI did the job for me (from ImgTech.com). Free to download, free to use, you must register on their site.

    here is the syntax (for this game's assets strategy)

    PVRTexToolCLI -i old_magie_cleanse-hd.pvr -o magie_cleanse-hd.pvr -flip y,flag -f r8g8b8a8 -legacypvr
    

    notes :

    • I am still using pvr v2 format, just because i like to go one change at a time. After I run my tests, i will switch all textures to pvr v3. Cocos2d 3.2 supports pvr v2 and pvr v3, but who knows for how long.
    • format is rgb8888 in our case, you will have to figure out the format of your own. You can use the PVRTextToolGUI and drag one of your existing textures into it to figure out the current encoding/compression.
    • If you have compressed textures, use "-q pvrtcbest" to prevent artefacts. Slow, hogs tons of CPU, but worth it.
    0 讨论(0)
提交回复
热议问题