com.badlogic.gdx.scenes.scene2d.utils
Class TiledDrawable
java.lang.Object
com.badlogic.gdx.scenes.scene2d.utils.BaseDrawable
com.badlogic.gdx.scenes.scene2d.utils.TextureRegionDrawable
com.badlogic.gdx.scenes.scene2d.utils.TiledDrawable
- All Implemented Interfaces:
- Drawable
public class TiledDrawable
- extends TextureRegionDrawable
Draws a TextureRegion
repeatedly to fill the area, instead of stretching it.
- Author:
- Nathan Sweet
Method Summary |
void |
draw(SpriteBatch batch,
float x,
float y,
float width,
float height)
Draws this drawable at the specified bounds. |
Methods inherited from class com.badlogic.gdx.scenes.scene2d.utils.BaseDrawable |
getBottomHeight, getLeftWidth, getMinHeight, getMinWidth, getRightWidth, getTopHeight, setBottomHeight, setLeftWidth, setMinHeight, setMinWidth, setRightWidth, setTopHeight |
TiledDrawable
public TiledDrawable()
TiledDrawable
public TiledDrawable(TextureRegion region)
TiledDrawable
public TiledDrawable(TextureRegionDrawable drawable)
draw
public void draw(SpriteBatch batch,
float x,
float y,
float width,
float height)
- Description copied from interface:
Drawable
- Draws this drawable at the specified bounds. The drawable should be tinted with
SpriteBatch.getColor()
, possibly by
mixing its own color.
- Specified by:
draw
in interface Drawable
- Overrides:
draw
in class TextureRegionDrawable
Copyright © 2013. All Rights Reserved.