Skip to content

Custom shaders

Nicholas Milef requested to merge NickMilef/iMSTK:CustomShaders into master

This MR contains a custom mapper and improvements to the light class.

Edit: I removed normal mapping an tissue shader for now to make this merge request smaller. Plus, as we discuss shader work plans, the implementation of this may change.

Custom shaders (#108 (closed)):

  • Implement metal shaders
  • Implement linear color space in shader
  • Implement tone mapping

Improved light class (#137 (closed)):

The light class has changed, and will undergo more changes:

  • Light intensity has been added since there's currently no way to have a light brighter than (1, 1, 1)
  • Lights will follow the inverse square law (physically accurate and cheaper to compute) rather than a quadratic attenuation function. It also makes more intuitive sense (only only parameter to control rather than 3).
  • Support for up to 16 lights (VTK limit is 6, but the custom mapper can break free from this)
  • Renaming of lights: lights should be renamed to something more consistent with computer graphics (scene lights -> point lights/spot lights, etc.)
Edited by Nicholas Milef

Merge request reports