-
Notifications
You must be signed in to change notification settings - Fork 360
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add refract node #1698
Add refract node #1698
Conversation
Signed-off-by: Jonathan Stone <jstone@lucasfilm.com>
Signed-off-by: Jonathan Stone <jstone@lucasfilm.com>
@ld-kerley @kwokcb One remaining question in my mind is whether this index of refraction should be named Here are two examples of the current pattern for IOR in MaterialX nodes: https://github.com/AcademySoftwareFoundation/MaterialX/blob/main/libraries/pbrlib/pbrlib_defs.mtlx#L136 |
I think consistency is important - so +1 vote for |
Correct me if I have the wrong interpretation but isn't |
I alway refer to The Bible whenever I'm confused. "The speed reduction is commonly summarized using the index of refraction (IOR). For example, a material with an IOR of 2 propagates light at half the speed of light. For common materials, the value is in the range 1.0–2.5 and furthermore varies with the wavelength of light. We will use the Greek letter , pronounced “eta,” to denote this quantity." |
@kwokcb All of the IOR inputs in MaterialX nodes can be thought of as being relative to the IOR of the exterior medium (which is 1.0 by default), but we don't make such a distinction in our naming conventions. Following that convention, I can see the name |
Sounds good to go with |
…itions, per Jonathans suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This looks excellent, thanks @ld-kerley!
a81ed0c
into
AcademySoftwareFoundation:main
Adding
refract
node to partner with thereflect
node, with a similar named interface, and implementation as a nodegraph taken from the OSL specwhich also lines up with the Kronos implementation here too.