Jump to content
  • Advertisement
Sign in to follow this  
Mark53

Heat wave in 2D

This topic is 3112 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hi everyone, I'm having much difficulty in finding an algorithm to render a heat wave in 2D (like when the background distorts under the effect of heat). I've implemented a simple algorithm that just shifts the lines of the picture alternatively but I'm not satisfied with it. Thanks in advance, Mark

Share this post


Link to post
Share on other sites
Advertisement
Hi,

You can watch this video:



It's my implementation of heat wave from Render Monkey sample. It you like it, then you can download Render Monkey and have a look. Hope it helps.

Best,

Share this post


Link to post
Share on other sites
Thank you very much, b_thangvn, but that is not really what I'm looking for.

Here is a video with the effect I'm interested in:

Share this post


Link to post
Share on other sites
What are you using to render the background?
Anyway, I think that you just need a good algorithm for calculating how to shift each line - like "y = sin( time + y )". :D

Share this post


Link to post
Share on other sites
Imagine I just draw a static image and apply the heat distortion effect on it. I just need the algorithm, I'll adapt it to my needs. But I fear the effect is more complicated than a line shifting with a sinus (it's what I did but the result isn't good). Look at the effect on the video, the lines of the background are smoothly wrapping one another. Of course, you can see this kind of effect in many other games.

Sorry, I forgot to precise that the effect is visible after 31 sec in that video.

Share this post


Link to post
Share on other sites
Take a look at this guys sin distortion.

Clicky

If you were to lower the scale of distortion, and have a smooth timestamp, it should look fine, how are you currently doing it?

Share this post


Link to post
Share on other sites
The effects showed in www.facewound.com are very interesting, I'll have to try some of them. But as regards the heat wave effect, I don't think a regular curve like sine would do the trick.

The warp map idea is very good. If I understood right, it consists in dividing the picture into squares, deforming the squares and then map the content of the deformed squares to the original squares. But it looks quite difficult to implement, maybe there's a way to use a transformation matrix. The fire effect was amazing.

Nice links!

Share this post


Link to post
Share on other sites
A nice heat wave distortion can be achieved by using a 3D noise texture and animate the v-coordinate upwards, so it looks like rising hot air.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

We are the game development community.

Whether you are an indie, hobbyist, AAA developer, or just trying to learn, GameDev.net is the place for you to learn, share, and connect with the games industry. Learn more About Us or sign up!

Sign me up!