Passthrough Shader Example Needed
- Dominant language
- Rust
- Stars
- 48.2k
- Forks
- 4.8k
- Avg merge
- 3d 22h
- Merged PRs (30d)
- 161
Description
## What problem does this solve or what need does it fill?
When we write a shader we lose the default material shading by default. It would be good to know how to write a passthrough shader. Writing shaders that extend the default shaders should be simple.
## What solution would you like?
An example with both vertex and fragment shaders that are passing through default shader behaviour would be very helpful to people new to writing shaders.
## What alternative(s) have you considered?
Not writing custom shaders and trying to achieve visual effects by other means.
## Additional context
Some of the existing shaders from the other examples can be helpful to nearly achieve passthrough shading. I've tried functions like `mesh_position_local_to_world` and `apply_pbr_lighting`, but I still don't know the correct combination to achieve a passthrough that achieves the default shading. If I have a cube the sides should be shaded at different levels on each side as determined by the light sources as they are by default (if that's what I want to achieve).
Contributor guide
Assessment
This issue has not been assessed yet.