hgtransform
Create transform object
Syntax
h = hgtransform
h = hgtransform('PropertyName
',propertyvalue,...)
h = hgtransform(ax,...)
Properties
For a list of properties, see Transform Properties.
Description
h = hgtransform
creates
a Transform
object and returns its handle.
h = hgtransform('
creates
a PropertyName
',propertyvalue,...)Transform
object with the property value settings
specified in the argument list. For a description of the properties,
see Transform Properties.
h = hgtransform(ax,...)
creates the Transform
object
in the axes specified by ax
instead of in the current
axes (gca
). The option ax
can
precede any of the input argument combinations in the previous syntaxes.
Transform
objects can contain other objects,
which lets you treat the Transform
object and its
children as a single entity with respect to visibility, size, orientation,
etc. You can group objects by parenting them to a single Transform
object
(i.e., setting the object's Parent
property to
the transform object's handle):
h = hgtransform; surface('Parent',h,...)
The primary advantage of parenting objects to a Transform
object
is that you can perform transforms (for example,
translation, scaling, rotation, etc.) on the child objects in unison.
The parent of a Transform
object is either
an Axes
object or another Transform
object.
Although you cannot see a Transform
object,
setting its Visible
property to off
makes
all its children invisible as well.
Exceptions and Limitations
A
Transform
object can be the parent of any number of axes child objects belonging to the same axes, except for light objects.Transform
objects can never be the parent of axes objects and therefore can contain objects only from a single axes.Transform
objects can be the parent of other transform objects within the same axes.You cannot transform
Image
objects because images are not true 3-D objects. Texture mapping the image data to a surfaceCData
enables you to produce the effect of transforming an image in 3-D space.Transforms do not affect text objects unless the text object uses data units. If a
Text
object has a position specified in data units, then the transform moves the lower left corner of the text. The transform does not affect the font size or orientation. To change the font size and orientation, use text properties.
Note
Many plotting functions clear the axes (remove axes children)
before drawing the graph. Clearing the axes also deletes any Transform
objects
in the axes.
Examples
Version History
Introduced before R2006a