Home Reference VEX VEX functions 

frontface vex function

Contexts: chop , cop , displace , fog , image3d , light , photon , pop , shadow , sop , surface

Tags: shading

If dot(I, Nref) is less than zero, N will be negated.

  1. vector frontface(vector N, vector I)

    This form (which doesn’t take a reference vector) is only available in the shading contexts, where the Ng variable is used.

  2. vector frontface(vector N, vector I, vector Nref)

If dot(I, Nref) is less than zero, N will be negated.