jgayfer / bevy_light_2d

General purpose 2D lighting for the Bevy game engine.
MIT License
128 stars 5 forks source link

Add HDR support #11

Closed jgayfer closed 2 months ago

jgayfer commented 2 months ago

Summary

As HDR uses a different texture format, we need to set it on a per view basis.

As the pipeline is currently more of a "one and done" construct, we need to make use of a specialized pipeline. It allows us to dynamically create the render pipeline descriptor, giving us a place to hook into if each view has HDR enabled.

On the view node side of things, we need to ensure we're grabbing the specialized pipeline ID from the view entity, as we are no longer constructing a "static" variant of the pipeline.

Fixes #10

jgayfer commented 2 months ago

@senpaaii Wouldn't mind a quick test on your end to verify this fixes #10 :)

senpaaii commented 2 months ago

Hey @jgayfer, tested it out in my game with the new branch, and it works perfectly! It's great to be able to do some cheap bloom effects on top of the nice lighting from this lib :)

Thanks for the quick fix! looking forward to this evolving further :)