Page 1 of 1
animated texture
Posted: Mon Oct 10, 2005 3:42 pm
by gedimaster
i've been looking into the forum posts but couldn't find much info on animated textures. i'm trying to put together an explosion effect using a series of animated textures but there doesn't seem to be an example available.
can anyone point me to somewhere? thanks.
Posted: Mon Oct 10, 2005 4:59 pm
by xavier
Render-to-texture is what you are looking for. A search on "RTT" or "render to texture" should turn up quite a few topics. The Wiki should also have RTT info as well.
Posted: Tue Oct 11, 2005 3:20 am
by gedimaster
not really. i'm thinking of animated texture from a series of texture rather than procedurally generating them like in rtt.
say i have a series of 30 textures of a fire animation and i want to run through them like a repeated video on a billboard, how i can do that in ogre? via the material settings?
Posted: Tue Oct 11, 2005 4:06 am
by discipline
Look at the DynTex demo.
Posted: Tue Oct 11, 2005 4:34 am
by pjcast
or alternatively, you can look at ogreaddons/videplugin/TheoraVideo which plays Theora Movies to a texture. A little overkill for this, but, it should also give you ideas.
Posted: Tue Oct 11, 2005 8:09 am
by :wumpus:
gedimaster wrote:not really. i'm thinking of animated texture from a series of texture rather than procedurally generating them like in rtt.
say i have a series of 30 textures of a fire animation and i want to run through them like a repeated video on a billboard, how i can do that in ogre? via the material settings?
See texture_anim in the manual. It does exactly that.
Posted: Tue Oct 11, 2005 8:18 am
by nfz
Why not just use an animated texture? Check out the manual:
http://www.ogre3d.org/docs/manual/manual_18.html#SEC58.
An Example:
Code: Select all
material MyAnimatedTexture
{
technique
{
pass
{
texture_unit
{
anim_texture frame.png 30 1
}
}
}
}
this will cycle through frame_0.png, frame_1.png, frame_2.png... upto frame_29.png in 1 second. So its animating 30 frames per second.
In Azathoth there is a limit of 32 frames for an animated texture. In Dagon there is no imposed limit.
[Edit] ok, wumpus typed faster than me[/Edit]