Adventure Game Studio

AGS Support => Advanced Technical Forum => Topic started by: julius on Thu 16/06/2011 10:40:07

Title: sprite antialising
Post by: julius on Thu 16/06/2011 10:40:07
hi guys,
i'm creating sprites using flash cs5 and when i save the image in .bmp form it automaticlly adds a little bit of antialising to the image.
the problem is that Ags doesnt recognize antialising, and so my sprites have grayish-white(or what ever color i use for the sprite background) borders.

is there anyway around this?
??? ??? ??? ???
Title: Re: sprite antialising
Post by: Khris on Thu 16/06/2011 11:01:37
Asked and answered many times already.

First of all, bmp is evil, period. You should never use it at all.

Save the sprites as 24bit PNGs. Then make sure your game is set to 32bit color depth. When you import a sprite, AGS should detect its alpha channel, you'll get a dialog box mentioning it.
Even though it might now look that way in the editor, in-game your sprites should now have alpha transparency i.e. edges should blend with the background.
Title: Re: sprite antialising
Post by: Derrick Freeland on Mon 25/07/2011 23:35:14
I had this same problem at first, and PNG's definitely did the trick.  The cool thing about PNG's also, is that they will maintain a transparency.  So, if you have a window, or some other translucent object it will stay translucent in the game.
Title: Re: sprite antialising
Post by: monkey0506 on Tue 26/07/2011 00:10:33
That's because PNG is the only "mainstream" image format (of which I'm aware) that actually supports full alpha transparency. GIF supports single-color transparency, but not a full alpha channel. In my experience it also compresses better than JPEG despite being lossless (whereas JPEG is lossy).