AnyLogic
Expand
Font size
  • java.lang.Object
    • com.anylogic.engine.presentation.Texture
All Implemented Interfaces:
java.awt.Paint, java.awt.Transparency, java.io.Serializable

public class Texture
extends java.lang.Object
implements java.awt.Paint, java.io.Serializable
Objects of this class may be used to define the appearance of shapes' parts. Texture may be used in the shapes instead of Color.
Additionally to the color, this class supports textures.
Example: UtilitiesColor.brickRedTexture - texture with red bricks, may be used as a fill for a rectangle:
rectangle.setFillColor(brickRedTexture);
Author:
AnyLogic North America, LLC https://anylogic.com
See Also:
Serialized Form

Field Summary

Fields inherited from interface java.awt.Transparency

BITMASK, OPAQUE, TRANSLUCENT

Method Summary

All Methods Instance Methods Concrete Methods Deprecated Methods 
java.awt.PaintContext createContext​(java.awt.image.ColorModel cm, java.awt.Rectangle deviceBounds, java.awt.geom.Rectangle2D userBounds, java.awt.geom.AffineTransform xform, java.awt.RenderingHints hints)
Deprecated.
this method will be removed in future releases.
boolean equals​(java.lang.Object obj)  
java.awt.Color getAmbientColor()
Deprecated.
this method will be removed in future releases.
java.awt.Color getDiffuseColor()
Deprecated.
this method will be removed in future releases.
java.lang.String getName()
Returns internal name of the texture
java.awt.Paint getPaint_xjal()
Deprecated.
this method will be removed in future releases.
java.awt.Color getSpecularColor()
Deprecated.
this method will be removed in future releases.
int getTransparency()
Deprecated.
this method will be removed in future releases.
int hashCode()  
java.lang.String toString()  
Modifier and Type Method Description

Methods inherited from class java.lang.Object

getClass, notify, notifyAll, wait, wait, wait

Method Detail

getName

public java.lang.String getName()
Returns internal name of the texture
Returns:
internal name of the texture

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

getAmbientColor

@Deprecated
public java.awt.Color getAmbientColor()
Deprecated.
this method will be removed in future releases.

getDiffuseColor

@Deprecated
public java.awt.Color getDiffuseColor()
Deprecated.
this method will be removed in future releases.

getSpecularColor

@Deprecated
public java.awt.Color getSpecularColor()
Deprecated.
this method will be removed in future releases.

getPaint_xjal

@Deprecated
public java.awt.Paint getPaint_xjal()
Deprecated.
this method will be removed in future releases.

createContext

@Deprecated
public java.awt.PaintContext createContext​(java.awt.image.ColorModel cm,
                                           java.awt.Rectangle deviceBounds,
                                           java.awt.geom.Rectangle2D userBounds,
                                           java.awt.geom.AffineTransform xform,
                                           java.awt.RenderingHints hints)
Deprecated.
this method will be removed in future releases.
Specified by:
createContext in interface java.awt.Paint

getTransparency

@Deprecated
public int getTransparency()
Deprecated.
this method will be removed in future releases.
Specified by:
getTransparency in interface java.awt.Transparency

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

equals

public boolean equals​(java.lang.Object obj)
Overrides:
equals in class java.lang.Object
How can we improve this article?