Lightning effect in opengl es
Is there a way to create lightning fast effect on iPhone using opengl? (for example this app )
I have now modified the glpaint pattern to draw random dots around the line (between the two dots the user touches) and then connect them, but the result is a zig-zag line that constantly jumps around and falls horribly on the actual device.
source to share
An easy way to create a lightning effect is to calculate the lightning path using 2D Perlin function, transfer it to a glow buffer, blur it with a Gaussian blur, and combine it with the scene. You can make the lightning move by calculating two paths (start and end) with the same number of path nodes and moving each node of the launch path sequentially to the corresponding node of the final path. Once the final path is reached, it becomes the start path and a new final path is calculated.
source to share