Heat haze shader

A shader that waves back and forth.

Add an image of your choice called "Image1.jpg" to test.

Three examples are included: a normal wave on that image, the same wave applied to a snapshot, and a wave applied to the image that doesn't discard the "troughs" in the wave pattern. If the discard operation is expensive, this one could be used, say, if the edges of the image would be behind something else, say for windows.

The shader takes a "center" value, which provides the content position of the center of the object. It defaults to the screen center, so in this demo it's not necessary, but to set it yourself, do something like:

image.fill.effect.center = image:localToContent(0, 0)

Low values for "extend" seem to look good for a "heat haze" effect; higher values are useful for flashback sequences. :)

Works with Corona build #: 
2015.2558
Contributor: 
Star Crunch