Class TranslatePoint

    • Field Detail

      • DEFAULT_TRANSLATE_POINT_X

        public static final double DEFAULT_TRANSLATE_POINT_X
        Default translation factor applied to the x coordinate for the TranslatePoint noise module.
        See Also:
        Constant Field Values
      • DEFAULT_TRANSLATE_POINT_Y

        public static final double DEFAULT_TRANSLATE_POINT_Y
        Default translation factor applied to the y coordinate for the TranslatePoint noise module.
        See Also:
        Constant Field Values
      • DEFAULT_TRANSLATE_POINT_Z

        public static final double DEFAULT_TRANSLATE_POINT_Z
        Default translation factor applied to the z coordinate for the TranslatePoint noise module.
        See Also:
        Constant Field Values
    • Constructor Detail

      • TranslatePoint

        public TranslatePoint()
      • TranslatePoint

        public TranslatePoint​(Module source)
        Create a new TranslatePoint module with the source modules pre-configured.
        Parameters:
        source - the input module
    • Method Detail

      • getXTranslation

        public double getXTranslation()
        Get the translation amount to apply to the x coordinate of the input value.
        Returns:
        the translation amount to apply to the x coordinate
        See Also:
        DEFAULT_TRANSLATE_POINT_X
      • setXTranslation

        public void setXTranslation​(double xTranslation)
        Set the translation amount to apply to the x coordinate of the input value.

        The getValue(double, double, double) method moves the (x, y, z) coordinates of the input value by a translation amount before returning the output value from the source module.

        Parameters:
        xTranslation - the translation amount to apply to the x coordinate
      • getYTranslation

        public double getYTranslation()
        Get the translation amount to apply to the y coordinate of the input value.
        Returns:
        the translation amount to apply to the y coordinate
        See Also:
        DEFAULT_TRANSLATE_POINT_Y
      • setYTranslation

        public void setYTranslation​(double yTranslation)
        Set the translation amount to apply to the y coordinate of the input value.

        The getValue(double, double, double) method moves the (x, y, z) coordinates of the input value by a translation amount before returning the output value from the source module.

        Parameters:
        yTranslation - the translation amount to apply to the y coordinate
      • getZTranslation

        public double getZTranslation()
        Get the translation amount to apply to the z coordinate of the input value.
        Returns:
        the translation amount to apply to the z coordinate
        See Also:
        DEFAULT_TRANSLATE_POINT_Y
      • setZTranslation

        public void setZTranslation​(double zTranslation)
        Set the translation amount to apply to the z coordinate of the input value.

        The getValue(double, double, double) method moves the (x, y, z) coordinates of the input value by a translation amount before returning the output value from the source module.

        Parameters:
        zTranslation - the translation amount to apply to the z coordinate
      • setTranslations

        public void setTranslations​(double x,
                                    double y,
                                    double z)
        Set the translation amount to apply to the (x, y, z) coordinates of the input value.

        The getValue(double, double, double) method moves the (x, y, z) coordinates of the input value by a translation amount before returning the output value from the source module.

        Parameters:
        x - the translation amount to apply to the x coordinate
        y - the translation amount to apply to the y coordinate
        z - the translation amount to apply to the z coordinate
      • getValue

        public double getValue​(double x,
                               double y,
                               double z)
        Description copied from class: Module
        Generates an output value given the coordinates of the specified input value.

        All source modules required by this module must have been connected with the Module.setSourceModule(int, Module) method. If these source modules are not connected, this method will throw a NoModuleException.

        To determine the number of source modules required by this noise module, call the Module.getSourceModuleCount() method.

        Specified by:
        getValue in class Module
        Parameters:
        x - the x coordinate of the input value
        y - the y coordinate of the input value
        z - the z coordinate of the input value
        Returns:
        the output value