Game Development Community

Bug with PVR and Tilemaps?

by Eric Sapp · in iTorque 2D · 02/11/2012 (12:34 am) · 4 replies

Hi all,

I'm starting to optimize my game and I'm having issues with PVR images displaying properly in Tilemaps. The tilemap is displaying all my PVRs as flipped.

-I've exported using both flipped and non-flipped PVRs and if I create a single cell object the PVR displays correctly, but for some reason the tilemap is all screwed up.

Any help would be greatly appreciated.


Thanks,

Eric

#1
02/12/2012 (3:13 am)
I think it's a bad idea to use PVRs in a tilemap. They're really designed to be used as textures on 3D objects, not in 2D games. They're so heavily compressed that obvious compression artifacts will be visible and this will only be exaggerated in a tiled situation.

Technically it should work, and this is a legitimate bug, but I'd stick to PNGs if possible.
#2
02/12/2012 (3:52 am)
PVRs can work, but it's always a real lottery. Busy sprites won't be so noticeable when done right, though. The best way to get make sprite sheets work is to leave a little space between each sprite (PVR compression bleeds like a slaughterhouse - try 2 to 4 pixels gap), and use sourcerects.
#3
02/12/2012 (11:48 pm)
I basically only use PVR images, since they eat a lot less memory. The compression artifacts and bleeding can actually be kept quite low if you learn how to work with them. I use a newer version of PVRTexTool than the one that comes with iTorque and it is a lot better at keeping image quality. Smooth transitions in semi-transparent areas causes the most problems for me, like smoke or fog. One trick that I use sometimes is to have black pixels instead of transparent ones and then use special blend-mode settings in iTorque to treat black as transparent. It's easier to get the PVR image to look better with black background instead of transparency.
#4
02/13/2012 (8:45 am)
Thanks for the replies! I fixed the bug, Optimize = 1 was reset to 0 in my datablocks, I guess changing the image settings in TGB and saving wipes out that setting.

Conor, Yeah...after experimenting with several different compression settings and options, I couldn't get the results I wanted. So, I'm opting to use a large background image( PVR compression ) with a smaller tilemap and tileset with straight pngs.

Ronny, I'm trying to use PVRs whenever possible, another trick is to use a slightly larger source image ( 512 instead of 256 ) since it's PVR the performance will still be good and the quality will be a little better too.

Simon, thanks for the info, I'll download the latest version of PVRTexttool. I'll have to try out your transparency trick with my SFX sprites. Thanks!