Class Translate2D

    • Field Detail

      • xTranslate

        public TypedIOPort xTranslate
        The amount of translation in the x-axis during firing. If this transform is in accumulate mode, the translation value is accumulated for each firing.
      • yTranslate

        public TypedIOPort yTranslate
        The amount of translation in the y-axis during firing. If this transform is in accumulate mode, the translation value is accumulated for each firing.
      • initialXTranslation

        public Parameter initialXTranslation
        The initial translation in the x-axis This parameter should contain a DoubleToken. The default value of this parameter is 0.0.
      • initialYTranslation

        public Parameter initialYTranslation
        The initial translation in the y-axis This parameter should contain a DoubleToken. The default value of this parameter is 0.0.
    • Method Detail

      • _applyInitialTransform

        protected void _applyInitialTransform​(Figure figure)
                                       throws IllegalActionException
        Set the initial transform of the given figure. This method is invoked by this base class during the initialize() method. Derived classes should implement it to provide class-specific behavior.
        Specified by:
        _applyInitialTransform in class GRTransform2D
        Parameters:
        figure - The figure to transform.
        Throws:
        IllegalActionException - If the value of some parameters can't be obtained.
      • _applyTransform

        protected void _applyTransform​(Figure figure)
                                throws IllegalActionException
        Consume input tokens, and transform the given figure according to the current state of the transform. This method is invoked by this base classes during the fire() method.
        Specified by:
        _applyTransform in class GRTransform2D
        Parameters:
        figure - The figure to transform.
        Throws:
        IllegalActionException - If the value of some parameters can't be obtained.