Main Content

show

Display the mesh as a patch on the current axes

Description

show(mesh) displays the extendedObjectMesh as a patch on the current axes. If there are no active axes, the function creates new axes.

example

show(mesh,ax) displays the object mesh as a patch on the axes ax.

ax = show(mesh) optionally returns the handle to the axes where the mesh was plotted.

[ax,p] = show(mesh) also returns the Patch object that contains the data for the mesh. Use p to query and modify properties of the patch object after it is created. For a list of properties and descriptions, see Patch Properties.

Examples

collapse all

Create an extendedObjectMesh object and translate the object.

Construct a cuboid mesh.

mesh = extendedObjectMesh('cuboid');

Translate the mesh by 5 units along the negative y axis.

mesh = translate(mesh,[0 -5 0]);

Visualize the mesh.

ax = show(mesh);
ax.YLim = [-6 0];

Figure contains an axes object. The axes object contains an object of type patch.

Input Arguments

collapse all

Extended object mesh, specified as an extendedObjectMesh object.

Current axes, specified as an axes object.

Output Arguments

collapse all

Patch object. Use p to query or change properties of the patch object after it is created.

Version History

Introduced in R2020b