When to use Alpha Blending, RotoZoom and etc...

Started by
2 comments, last by EdwardKoo 23 years, 4 months ago
Hello, Anyone here can explain in detail when should these techniques be apply 1)Alpha blending 2)Trasparent draw 3)Roto zoom 4)Dirty rectangle btw, is there any articles out there that explain all the 2D 16-bit graphics technique and effect like fire, water, wave and etc? Thank you!
Advertisement
well,

1) you need alpha blending when you wanna do levels of transparency
2) you need transparent draw when you wanna draw ... transparent things
3) roto zomm --> a zoom combined with a rotation of an image or texture
4) i don''t know what is ''dirty rectangle''

and for effects such as fire and water, they are 8 bit effects !!!
anyway you can do them in any bitdepth you want, by using a ''virtual palette''
and well the fire effect is really simple :
you have some colors spotted randomly at the bottom of your screen, and for each pixel of each frame, you apply a blur like this one :

pixel[x][y] = (pixel[x-1][y]+pixel[x+1][y]+pixel[x][y+1]+pixel[x][y+2])/4

thats all !!

anyway there are faster and prettyer ways to do this, but thats just tweaking an existaing algo ...

flure
Dirty rectangles are used for 2D apps where you don''t want to redraw the entire screen each time.

When an object moves over the background, a dirty-rect is created in the place where it moved. Thus you only need to re-draw your dirty rect areas to update the scene.

Commonly used in 2D games to save having to redraw the entire screen each time, just redraw the bits left over when sprites move.
I see...

Thank you!

This topic is closed to new replies.

Advertisement