Linear interpolation in triangles


just wanted to ask if there is a node or module for linear interpolation in triangles?

i’d like to generate an interpolated normal of the point i get from Intersect (3d Mesh Ray), depending on the normals i get from the three vertices of the face the point is in.

something like this:

this is for cpu purposes only. from what i understand something similar is done for phong shading, but i just can’t get my head around it :(



i think dottore once did something like that.

tried it myself but am not sure if there is not a more efficient way to do it.

Normal At Intersection Point.v4p (38.1 kB)

thread of the last time we did this.