Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

DarkBASIC Discussion / animated textures?

Author
Message
ruben
19
Years of Service
User Offline
Joined: 22nd Nov 2005
Location:
Posted: 2nd Nov 2006 21:28
ok here are my question:
is it posible to put an animated texture on a plane? Like a flame? And what kind of image should I use for that?

thanks for helping (or at least reading)
Krilik
19
Years of Service
User Offline
Joined: 16th Mar 2006
Location: Arizona, USA
Posted: 2nd Nov 2006 22:02
There's no function to do it in DBC, but it is possible writing your own function.

The way I would go about doing it is drawing out all the frames of the animation and save it as a PNG. Then using the Load Bitmap command in DBC I would load it up to the current bitmap so I get the individual frames using the Get Image command.

Then write a function that would change the image of a certain object, and call it in my main loop.
ruben
19
Years of Service
User Offline
Joined: 22nd Nov 2005
Location:
Posted: 2nd Nov 2006 22:04
ok thanks i'll try that
Mr Tank
22
Years of Service
User Offline
Joined: 25th Nov 2002
Location: United Kingdom
Posted: 2nd Nov 2006 22:32
I want to do this too, because you can get more compression. What i do at the moment for animated textures is to have a series of images, and just change the object texture each loop if required. Seems to work well enough.


You'll be able to click on this someday.
indi
22
Years of Service
User Offline
Joined: 26th Aug 2002
Location: Earth, Brisbane, Australia
Posted: 3rd Nov 2006 01:15
I would try and make the series of images a uniformed strip either vertically or horizontally.

I would try different variables of scroll object texture until the sliding appeared to show each frame in succession.

Login to post a reply

Server time is: 2025-05-25 21:56:48
Your offset time is: 2025-05-25 21:56:48