MATLAB Function Reference (Volume 2: Graphics)

MATLAB Function Reference (Volume 2: Graphics) MATLAB Function Reference (Volume 2: Graphics)

12.07.2015 Views

patchCreate the patch by specifying the Faces, Vertices, and FaceVertexCDataproperties as well as the FaceColor property.patch('faces',fac,'vertices',vert,'FaceVertexCData',tcolor,...'FaceColor','flat')V22V31.91.81.71.6Face 11.51.41.31.2Face 21.1V110 0.2 0.4 0.6 0.8 1V4Specifying only unique vertices and their connection matrix can reduce the sizeof the data for patches having many faces. See the descriptions of the Faces,Vertices, and FaceVertexCData properties for information on how to definethem.MATLAB does not require each face to have the same number of vertices. Incases where they do not, pad the Faces matrix with NaNs. To define a patch withfaces that do not close, add one or more NaN to the row in the Vertices matrixthat defines the vertex you do not want connected.ObjectHierarchy2-318

patchRootFigureAxesUicontrolUimenuUicontextmenuImageLightLinePatchRectangleSurfaceTextSetting Default PropertiesYou can set default patch properties on the axes, figure, and root levels.set(0,'DefaultPatchPropertyName',PropertyValue...)set(gcf,'DefaultPatchPropertyName',PropertyValue...)set(gca,'DefaultPatchPropertyName',PropertyValue...)PropertyName is the name of the patch property and PropertyValue is the valueyou are specifying. Use set and get to access patch properties.Property ListThe following table lists all patch properties and provides a brief description ofeach. The property name links take you to an expanded description of theproperties.Property Name Property Description Property ValueData Defining the ObjectFaces Connection matrix for Vertices Values: m-by-n matrixDefault: [1,2,3]VerticesXDataYDataMatrix of x-, y-, and z-coordinates ofthe vertices (used with Faces)The x-coordinates of the vertices ofthe patchThe y-coordinates of the vertices ofthe patchValues: matrixDefault: [0,1;1,1;0,0]Values: vector or matrixDefault: [0;1;0]Values: vector or matrixDefault: [1;1;0]2-319

patchCreate the patch by specifying the Faces, Vertices, and FaceVertexCDataproperties as well as the FaceColor property.patch('faces',fac,'vertices',vert,'FaceVertexCData',tcolor,...'FaceColor','flat')V22V31.91.81.71.6Face 11.51.41.31.2Face 21.1V110 0.2 0.4 0.6 0.8 1V4Specifying only unique vertices and their connection matrix can reduce the sizeof the data for patches having many faces. See the descriptions of the Faces,Vertices, and FaceVertexCData properties for information on how to definethem.<strong>MATLAB</strong> does not require each face to have the same number of vertices. Incases where they do not, pad the Faces matrix with NaNs. To define a patch withfaces that do not close, add one or more NaN to the row in the Vertices matrixthat defines the vertex you do not want connected.ObjectHierarchy2-318

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!