Skip to main content
GameDev.net gamedev.net
🔒 Locked

Simple plamsa fx?

Started by tidilipom Dec 8, 2000 at 8:21 PM 0 replies 300+ views
Original Post
tidilipom
tidilipom
Okay, I have done some plasmas in mode13 (DOS) but i can''t really figure out how to do them in OpenGL...Am i just plain dumb or a too whack newbie @ opengl? Well you tell me, please give some instructions or URL''s to teach me. Thanks!
--Peace.
Seaman
Seaman
Right this is one way, simply draw your plasma effect to a texture.
So for exmaple:-
GLubyte MyTexture[Size_x][Size_y][RGB];

And draw you plasma to this, obviously Size_x and Size_y must be valid texture sizes.
Then if you want to update it every fram do:-

glBindTexture(GL_TEXTURE_2D, texture[PLASMA_TEXTURE]);
glTexSubImage2D(GL_TEXTURE_2D, 0, 0, 0, Size_x, Size_y,
GL_RGB, GL_UNSIGNED_BYTE, MyTexture);

I hope thats usefull, if you want any more info just ask and I''ll try and help, if I can.

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.