Home > matGeom > geom3d > drawSphericalPolygon.m

drawSphericalPolygon

PURPOSE ^

DRAWSPHERICALPOLYGON Draw a spherical polygon.

SYNOPSIS ^

function varargout = drawSphericalPolygon(sphere, poly, varargin)

DESCRIPTION ^

DRAWSPHERICALPOLYGON  Draw a spherical polygon.

   output = drawSphericalPolygon(input)

   Example
   drawSphericalPolygon

   See also


 ------
 Author: David Legland
 e-mail: david.legland@grignon.inra.fr
 Created: 2012-02-09,    using Matlab 7.9.0.529 (R2009b)
 Copyright 2012 INRA - Cepia Software Platform.

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function varargout = drawSphericalPolygon(sphere, poly, varargin)
0002 %DRAWSPHERICALPOLYGON  Draw a spherical polygon.
0003 %
0004 %   output = drawSphericalPolygon(input)
0005 %
0006 %   Example
0007 %   drawSphericalPolygon
0008 %
0009 %   See also
0010 %
0011 %
0012 % ------
0013 % Author: David Legland
0014 % e-mail: david.legland@grignon.inra.fr
0015 % Created: 2012-02-09,    using Matlab 7.9.0.529 (R2009b)
0016 % Copyright 2012 INRA - Cepia Software Platform.
0017 
0018 nv = size(poly, 1);
0019 
0020 h = zeros(nv, 1);
0021 for i = 1:nv
0022     v1 = poly(i, :);
0023     v2 = poly(mod(i, nv) + 1, :);
0024 
0025     h(i) = drawSphericalEdge(sphere, [v1 v2], varargin{:});
0026 end
0027 
0028 
0029 if nargout > 0
0030     varargout = {h};
0031 end

Generated on Wed 16-Feb-2022 15:10:47 by m2html © 2003-2019