spacer spacer spacer
spacer spacer spacer
spacer
NASA Logo - Jet Propulsion Laboratory    + View the NASA Portal
spacer
JPL Home Earth Solar System Stars & Galaxies Technology
ParVox Parallel Volume Rendering System
ParVox Home ../Images & Animations ParVox Document Download Source PAT Home Section 387 Division 38
spacer
spacer spacer spacer
spacer

vlgradient_shade


NAME

    vlgradient_shade -  Calculate the gradient vectors and shade the volume

SYNOPSIS

    #include <parvox.h>

    void vlgradient_shade(vlvolume *vol, vlvariable *variable,  int time_step)


DESCRIPTION

    vlgradient_shade()  shade the data volume of a specific variable at a given time_step with the light sources and the material properties previously defined in vllight() and vlmaterial().  The Torrance-Sparrow reflection model introduced by Blinn ("Models of Light Reflection for Computer Synthesized Pictures", Proceedings of SIGGRAPH 1997) is used in ParVox.  Blinn's shading model is less expensive in computation comparing to Phong's model, but has comparable image quality.    The shading process requires the calculation of a normalized gradient vector for each voxel.   The magnitude of the gradient vector is also required for classification.   vlgradient_shade() will calculate the gradient vectors, save the maginitudes of the gradient vectors in vlvariable data structure, but discard the normalized vector after shading is done.   Isosurface classification can be done seperately by calling vliso_surface().   ParVox also provides an API vliso_shade() which combines the shading and classification in one function.

Shading is only needed for isosurface rendering; direct volume and slice rendering do not need shading.  The volume needs to be reshaded when the light source is changed or the material setting is changed. 


SEE ALSO

    vlgradient_shade, vliso_surfacevllight, vlmaterial


 
BACK TO INDEX
spacer
spacer spacer spacer
spacer
Privacy / Copyrights FAQ Contact JPL Sitemap
spacer
spacer spacer spacer
spacer
FIRST GOV   NASA Home Page This page, http://pat.jpl.nasa.gov/public/ParVox/API/vlgradient_shade.html, is maintained by Peggy Li and was last modified Wednesday, 09-Mar-2005 16:39:45 PST
spacer
spacer spacer spacer
spacer spacer spacer
JPL NASA Caltech