Note that there are some explanatory texts on larger screens.

plurals
  1. POBlitzMax - generating 2D neon glowing line effect to png file
    text
    copied!<p>I'm looking to create a glowing line effect in BlitzMax, something like a Star Wars lightsaber or laserbeam. Doesn't have to be realtime, but just to TImage objects and then maybe saved to PNG for later use in animation. I'm happy to use 3D features, but it will be for use in a 2D game.</p> <p>Since it will be on black/space background, my strategy is to draw a series of white blurred lines with color and high transparency, then eventually central lines less blurred and more white. What I want to draw is actually bezier curved lines. Drawing curved lines is easy enough, but I can't use the technique above to create a good laser/neon effect because it comes out looking very segmented. So, I think it may be better to use a blur effect/shader on what does render well, which is a 1-pixel bezier curve.</p> <p>The problems I've been having are:</p> <ul> <li>Applying a shader to just a certain area of the screen where lines are drawn. If there's a way to do draw lines to a texture and then blur that texture and save the png, that would be great to hear about. There's got to be a way to do this, but I just haven't gotten the right elements working together yet. Any help from someone familiar with this stuff would be greatly appreciated.</li> <li>Using just 2D calls could be advantageous, simpler to understand and re-use.</li> <li>It would be very nice to know how to save a PNG that preserves the transparency/alpha stuff.</li> </ul> <p>p.s. I've reviewed this post (and others), have the samples working, and even developed my own 5x5 shader. But, it's 3D and a scene-wide thing that doesn't seem to convert to 2D or just a certain area very well. <a href="http://www.blitzbasic.com/Community/posts.php?topic=85263" rel="nofollow">http://www.blitzbasic.com/Community/posts.php?topic=85263</a></p>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload