Rotating pictures or alot of frames?

Started by
1 comment, last by Diemonex 24 years, 7 months ago
In my opinion, the best way to rotate an image is to texture it onto a polygon with DrawPrimitive/D3D/OpenGL...but that can be a pain if you've never worked with them before.

If the images you want to rotate are small and few, then there wouldn't be anything wrong with pre rotating them. If they aren't, you're going to see a mighty large increase in your memory footprint

Most 2D games (like C&C) use pre rotated bitmaps. Newer games tend to be 3D, so everything's done with polygons.

- Yohan

Advertisement
I have started with my first game, a snowmobile game. I will just use it to test things but I'll finnish it somtime around christmas I think, well.... maybe around easter =) My question is: Whe a veichle/unit turns in a game, can you rotate the image instead of doing alot of little frames. This would make it easier for an artist or atleast me who is making everything for my first game and not so good at drawing stuff, and more about programming, and I prefer programming before drawing =). How does the big games like Command and counqer etc. do it? Do they have lots of turning frames or do they rotate the image?

// Martin Björklund

------------------
Martin Björklund

Diemonex Games
It seems my earlier post didnt work so ill try again.
Theres about 3 ways to rotate your images that i know of(theres probally alot more.)
1. read each pixel rotate it then write it (very very slow)
2. make a polygon and texture map it onto it.
3. do the same as 2. but use opengl or direct3d with hardware acceleration.

Just be aware though that unless your getting hardware acceleration its gonna kill your fps to rotate a bunch of stuff.

I myself recommend just pre rotating the image it causes alot more memory to be used but it increases your speed alot. And it generaly looks nicer to (no jagged edges)

This topic is closed to new replies.

Advertisement