Package arc.scene.style
Class TiledDrawable
java.lang.Object
arc.scene.style.BaseDrawable
arc.scene.style.TextureRegionDrawable
arc.scene.style.TiledDrawable
- All Implemented Interfaces:
Drawable
,TransformDrawable
Draws a
TextureRegion
repeatedly to fill the area, instead of stretching it.-
Field Summary
Fields inherited from class arc.scene.style.TextureRegionDrawable
region, scale, tint
-
Constructor Summary
ConstructorDescriptionTiledDrawable
(TextureRegion region) TiledDrawable
(TextureRegionDrawable drawable) -
Method Summary
Modifier and TypeMethodDescriptionvoid
draw
(float x, float y, float width, float height) Draws this drawable at the specified bounds.void
draw
(float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation) getColor()
void
setRegion
(TextureRegion region) void
setTileSize
(float w, float h) Creates a new drawable that renders the same as this drawable tinted the specified color.Methods inherited from class arc.scene.style.TextureRegionDrawable
getRegion, imageSize, set, tint
Methods inherited from class arc.scene.style.BaseDrawable
getBottomHeight, getLeftWidth, getMinHeight, getMinWidth, getName, getRightWidth, getTopHeight, setBottomHeight, setLeftWidth, setMinHeight, setMinWidth, setName, setRightWidth, setTopHeight, toString
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
Methods inherited from interface arc.scene.style.Drawable
getBottomHeight, getLeftWidth, getMinHeight, getMinWidth, getRightWidth, getTopHeight, setBottomHeight, setLeftWidth, setMinHeight, setMinWidth, setRightWidth, setTopHeight
-
Constructor Details
-
TiledDrawable
public TiledDrawable() -
TiledDrawable
-
TiledDrawable
-
-
Method Details
-
setRegion
- Overrides:
setRegion
in classTextureRegionDrawable
-
setTileSize
public void setTileSize(float w, float h) -
draw
public void draw(float x, float y, float width, float height) Description copied from interface:Drawable
Draws this drawable at the specified bounds.- Specified by:
draw
in interfaceDrawable
- Overrides:
draw
in classTextureRegionDrawable
-
draw
public void draw(float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation) - Specified by:
draw
in interfaceDrawable
- Specified by:
draw
in interfaceTransformDrawable
- Overrides:
draw
in classTextureRegionDrawable
-
getColor
-
tint
Description copied from class:TextureRegionDrawable
Creates a new drawable that renders the same as this drawable tinted the specified color.- Overrides:
tint
in classTextureRegionDrawable
-