HSRCAD:

Path: AerospaceUtils/CAD

% Finds the visible surfaces given a vertex and face list. 
 Does backface culling. Uses the infinite line method for determining
 whether a point is within a polygon. The ordering of vertices is
 consistent with Polygon.m

 Includes a built-in demo.
--------------------------------------------------------------------------
   Form:
   [aV, cV, area] = HSRCAD( v, f, z, n, showScans )
--------------------------------------------------------------------------

   ------
   Inputs
   ------
   v           (:,3) Vertex list
   f           (:,3) Face list
   z           (3,1) Unit vector to the source
   n           (1,1) Number of scan lines
   showScans   (1,1) Any argument will cause a plot to be drawn

   -------
   Outputs
   -------
   aV          (1,:) Visible area per face
   cV          (3,:) Centroid for each face
   area        (n,n) Matrix showing the ID of the visible surface
                     0 means no surface is visible

--------------------------------------------------------------------------

Children:

Common: General/DeBlankLT
Common: Graphics/PltStyle
Common: Graphics/XLabelS
Common: Graphics/YLabelS
Common: Graphics/ZLabelS
Math: Linear/Cross
Math: Linear/Unit

Back to the AerospaceUtils Module page