public class TextureFactory
extends java.lang.Object
Modifier and Type | Method and Description |
---|---|
static TextureFactory |
getInstance()
Get the unique instance of the class.
|
static TextureFactory |
getInstance(float scale)
Get the unique instance of the class, setting the scale of the pattern.
|
java.awt.Paint |
getTexture(int textureId,
java.awt.Color foreground)
Get a texture from a WMF hatch definition, with a foreground color.
|
java.awt.Paint |
getTexture(int textureId,
java.awt.Color foreground,
java.awt.Color background)
Get a texture from a WMF hatch definition, with a foreground and a
background color.
|
void |
reset()
Rest the factory.
|
public static TextureFactory getInstance()
1.0f
public static TextureFactory getInstance(float scale)
scale
- overall scalepublic void reset()
public java.awt.Paint getTexture(int textureId, java.awt.Color foreground)
textureId
- ID of textureforeground
- foreground colorpublic java.awt.Paint getTexture(int textureId, java.awt.Color foreground, java.awt.Color background)
textureId
- ID of textureforeground
- foreground colorbackground
- background color