dmurdoch / rgl

rgl is a 3D visualization system based on OpenGL. It provides a medium to high level interface for use in R, currently modelled on classic R graphics, with extensions to allow for interaction.
https://dmurdoch.github.io/rgl/
GNU General Public License v2.0
85 stars 20 forks source link

texmode = "replace" doesn't handle lighting #320

Closed dmurdoch closed 1 year ago

dmurdoch commented 1 year ago

The new texmode = "replace" material property default looks bad in e.g. persp3d()`, because it ignores lighting. What we really want is "modulate" but with a base colour of "white".

Maybe change the base colour to "white" in some conditions, but leave the default as "modulate"?

dmurdoch commented 1 year ago

PR #321 changes the default back to "modulate", but doesn't make automatic colour changes -- they look too messy.

Instead, I should add more detailed documentation about how textures are handled.

dmurdoch commented 1 year ago

Fixed by #323.