Fovia's C++ Client/Server API
|
This version of Fovia's HDVR™ Library supports the following headlight Phong Lighting model:
is the diffuse coefficient
is the specular reflection coefficient
the angle between the scalar field's gradient vector and the viewing vector
is the power of specular reflection (shininess)
The Phong lighting model is applied if the gradient magnitude is higher then gradient sensitivity threshold (RENDER_PARAMS::RaycastingPrecision), otherwise the sub-volume would be processed as a homogeneous body. The homogeneous body lighting model assumes that the diffuse reflection component is equal to and
.
The functions as a brightness coefficient (RENDER_PARAMS::Brightness). The
range is allowed to be [0,1], but for the majority of scenes the optimal
range is [0.5,1]. The RENDER_PARAMS::Brightness is normalized to fit the above range, so the actual values are [0,255].
The functions as the specular reflection coefficient (RENDER_PARAMS::Reflection) The valid range for
is [0,1]. RENDER_PARAMS::Reflection will be normalized to the above range from it's actual range [0,255].
The functions as the shininess coefficient (RENDER_PARAMS::Shininess). It emphasizes the bumps/relief of surface. The higher the shininess the more "metal" like the surface looks. The lower shininess the more "matte skin" like the surface looks. The contribution of this component is defined by
. The allowed range for
range is [0,1] however for majority scenes the optimal
range is [0.1, 0.4]. Once again, the actual values to be passed in are [0,255].