Help with Dynalight!


(Tobias Helsing) #1

Hey! does dynalight from punk.fx work with the current version of flashpunk? :smiley:

and if so could somone be sooo kind and show a code snippet of how to actually implement it?

thank you!


(azrafe7) #2

Sadly Adobe had dropped support for Pixel Bender shaders, so although DynaLight works with the current version of FlashPunk, you’ll get FPS crawling around 4-5.

From punk.fx repo’s readme:

WARNING: Adobe has recently (july/august 2013) pulled hardware/JIT support from their Pixel Bender library, causing extreme lag to all apps using it. This means that using effects with the PB suffix (like PBWaterFallFX, PBLineSlideFX, etc.) with punk.fx will dramatically reduce your FPS ( the other effects will still play nice! ). You can avoid this drop in performance by ensuring the use of a Flash Player with a version below 11.7.

If you’d like to share your thoughts about Adobe’s choice to severely degrade the performance of a crucial library without any advance warning, here’s the bug report on Adobe’s website: https://bugbase.adobe.com/index.cfm?event=bug&id=3591185.

Here’s some lighting-related posts you can find useful:

If you still want to play with DynaLight by using a FlashPlayer < 11.7 (but I won’t recommend it), this should be the code I used for the demo:

DynaLightDemo - alpha0.zip (760.0 KB)


(Tobias Helsing) #3

ahh thats a shame! but thanks for the reply! i appriciate it :smile: