OpenSpace / OpenSpace

This is the official GitHub repository for OpenSpace: an open source astrovisualization project. For instructions on how to build and run OpenSpace, see the Getting Started Guides on the wiki page at http://docs.openspaceproject.com.
http://openspaceproject.com
Other
782 stars 121 forks source link

Adding the ability for any* Renderable to change to custom shaders #2920

Open alexanderbock opened 1 year ago

alexanderbock commented 1 year ago

Taking the RenderableModel and RenderableGalaxy example and expanding it to all Renderable types to be able to exchange the shader that is being used

micahnyc commented 1 year ago

as requested in user group meeting

hedbergj commented 1 year ago

I do realize this is kinda opening up a huge box of possible trouble (and fun). But, the possibility to mess with the shaders is already there, it just is a little awkward and not very robust (i.e. copy existing file, rename, mess with new one). I think this could present a very cool avenue for some folks who might be more into opengl but not so into astro/dataviz to participate. Here are some things I’ve done with shaders that cover the range of sciencey to whimsy.

Lunar Eclipse frequency dependance

lunareclipse

Clouds

https://github.com/OpenSpace/OpenSpace/assets/7926907/791f70f5-9505-494a-ae3e-488749383679

Fireworks

https://github.com/OpenSpace/OpenSpace/assets/7926907/04e30b97-58fe-4f0f-a928-125e8429baef

Eclipse shadow as contours/percentages

eclipse-percents

Depth of Field

dof