User Tools

Site Tools


DzTextureModifier

A modifier for a DzTexture.

More...

Inherits :

Enumerations

Properties

Constructors

DAZ Script
DzTextureModifier ()

Methods

DAZ Script
NumbercalcOffset ( Modifications modificationFlags )
NumbercalcOffset ( Modifications modificationFlags, Boolean flipPolarity )
NumbercalcScale ( Modifications modificationFlags )
NumbercalcScale ( Modifications modificationFlags, Boolean flipPolarity )
DzTextureModifierduplicate ()
voidgetAttributes ( DzSettings settings, Modifications modFlags )
NumbergetGrayscaleMode ( Modifications modificationFlags )
NumbergetHorizontalTiles ( Modifications modificationFlags )
NumbergetHorizontalTilingOffset ( Modifications modificationFlags )
NumbergetOffset ( Modifications modificationFlags )
NumbergetScale ( Modifications modificationFlags )
NumbergetVerticalTiles ( Modifications modificationFlags )
NumbergetVerticalTilingOffset ( Modifications modificationFlags )
BooleanisDefault ( Modifications modificationFlags )
BooleanisInverted ( Modifications modificationFlag, Boolean flipPolaritys )
BooleanisInverted ( Modifications modificationFlags )
voidreset ()
voidsetAttributes ( DzSettings settings, Modifications modFlags, DzTextureModifier oldMod=null )

Signals

Detailed Description

Enumerations


: GrayscaleMode

TODO: Add description.

  • Alpha - Uses the alpha channel from the texture as the grayscale value.
  • Average - Uses the average of the R, G and B values for a given pixel in the texture as the grayscale value.
  • Luminance - Use the luminance as calculated from the R, G and B values for a given pixel in the texture as the grayscale value.
  • Maximum - Uses the maximum as calculated from the R, G and B values for a given pixel in the texture as the grayscale value.
  • RedChannel - Uses the R value for a given pixel in the texture as the grayscale value. Since: 4.14.0.2
  • GreenChannel - Uses the G value for a given pixel in the texture as the grayscale value. Since: 4.14.0.2
  • BlueChannel - Uses the B value for a given pixel in the texture as the grayscale value. Since: 4.14.0.2
  • GrayscaleDefault - The same as Average.

—–

: Modifications

Since:

  • 4.11.0.180
  • NoModification - Does not modify the texture.
  • Scale - Modifies the scale of the texture.
  • Offset - Modifies the position of the texture.
  • Invert - Inverts the colors of the texture.
  • Grayscale - Modifies the grayscale mode of the texture.
  • LocalTiling - Modifies the local tiling of the texture.
  • InvalidModification - The modification is invalid.

Properties


GrayscaleMode : grayscaleMode

Holds the grayscale mode of this texture modifier.


Number : horizontalTiles

Holds the number of horizontal tiles for this texture modifier.


Number : horizontalTilingOffset

Holds the horizontal tiling offset of this texture modifier.


Boolean : invert

Holds whether or not this texture modifier inverts colors.


Number : offset

Holds the offset of this texture modifier.


Number : scale

Holds the scale of this texture modifier.


Number : verticalTiles

Holds the number of vertical tiles for this texture modifier.


Number : verticalTilingOffset

Holds the vertical tiling offset of this texture modifier.

Constructors


DzTextureModifier()

Default constructor.

Methods


Number : calcOffset( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to calaculate the offset from.

Return Value:

  • The calculated offset based on the specified modification flags.

See Also:


Number : calcOffset( Modifications modificationFlags, Boolean flipPolarity )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to calaculate the offset from.
  • flipPolarity - Whether values in the image should be flipped or not (ie black = 1, white = 0)

Return Value:

  • The calculated offset based on the specified modification flags.

See Also:

Since:

  • 4.14.1.8

Number : calcScale( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to calaculate the scale from.

Return Value:

  • The calculated scale based on the specified modification flags.

See Also:


Number : calcScale( Modifications modificationFlags, Boolean flipPolarity )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to calaculate the scale from.
  • flipPolarity - Whether values in the image should be flipped (black = 1, white = 0) or not

Return Value:

  • The calculated scale based on the specified modification flags.

See Also:

Since:

  • 4.14.1.8

DzTextureModifier : duplicate()

Return Value:

  • A deep copy of this texture modifier.

void : getAttributes( DzSettings settings, Modifications modFlags )

Populates the given settings object with the attributes of this texture modifier.

Parameter(s):

  • settings - The settings object to populate.
  • modFlags - A bitwise OR of the modifier flags to set.

See Also:


Number : getGrayscaleMode( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the grayscale mode from.

Return Value:

  • The grayscale mode based on the specified modification flags.

See Also:


Number : getHorizontalTiles( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the number of horizontal tiles from.

Return Value:

  • The number of horizontal tiles for the specified modification flags.

See Also:


Number : getHorizontalTilingOffset( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the horizontal tiling offset from.

Return Value:

  • The horizontal tiling offset based on the specified modification flags.

See Also:


Number : getOffset( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the offset from.

Return Value:

  • The offset based on the specified modification flags.

See Also:


Number : getScale( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the scale from.

Return Value:

  • The scale based on the specified modification flags.

See Also:


Number : getVerticalTiles( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the number of vertical tiles from.

Return Value:

  • The number of vertical tiles for the specified modification flags.

See Also:


Number : getVerticalTilingOffset( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the vertical tiling offset from.

Return Value:

  • The vertical tiling offset based on the specified modification flags.

See Also:


Boolean : isDefault( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags that define 'default.'

Return Value:

  • true if this texture modifier is in its default state, otherwise false.

Boolean : isInverted( Modifications modificationFlag, Boolean flipPolaritys )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the inverted state from.
  • flipPolarity - Whether values in the image should be flipped or not (ie black = 1, white = 0)

Return Value:

  • The inverted state based on the specified modification flags.

See Also:

Since:

  • 4.14.1.8

Boolean : isInverted( Modifications modificationFlags )

Parameter(s):

  • modificationFlags - A bitwise OR of the modification flags to get the inverted state from.

Return Value:

  • The inverted state based on the specified modification flags.

See Also:


void : reset()

Resets this texture modifier.


void : setAttributes( DzSettings settings, Modifications modFlags, DzTextureModifier oldMod=null )

Sets the attributes of this texture modifier using settings.

Parameter(s):

  • settings - The settings with the data to set.
  • modFlags - A bitwise OR of the modifier flags to set.
  • oldMod - The texture modifier (if any) to use for default values if a named value cannot be found in settings.

See Also:

Signals


void : grayscaleModeChanged()

Signature:“grayscaleModeChanged()”

Emitted when the grayscale mode of the texture modifier has changed.


void : horizontalTilesChanged()

Signature:“horizontalTilesChanged()”

Emitted when the number of horizontal tiles for the texture modifier has changed.


void : horizontalTilingOffsetChanged()

Signature:“horizontalTilingOffsetChanged()”

Emitted when the horizontal tiling offset of the texture modifier has changed.


void : invertedChanged()

Signature:“invertedChanged()”

Emitted when the inversion of the texture modifier has changed.


void : offsetChanged()

Signature:“offsetChanged()”

Emitted when the offset of the texture modifier has changed.


void : scaleChanged()

Signature:“scaleChanged()”

Emitted when the scale of the texture modifier has changed.


void : settingsChanged()

Signature:“settingsChanged()”

Emitted when the settings of the texture modifier have changed.


void : verticalTilesChanged()

Signature:“verticalTilesChanged()”

Emitted when the number of vertical tiles for the texture modifier has changed.


void : verticalTilingOffsetChanged()

Signature:“verticalTilingOffsetChanged()”

Emitted when the vertical tiling offset of the texture modifier has changed.