Uses of Class
com.badlogic.gdx.graphics.g2d.TextureRegion
-
-
Uses of TextureRegion in com.badlogic.gdx.graphics.g2d
Subclasses of TextureRegion in com.badlogic.gdx.graphics.g2d Modifier and Type Class Description static classParticleEmitter.ParticleclassSpriteHolds the geometry, color, and texture information for drawing 2D sprites usingBatch.static classTextureAtlas.AtlasRegionDescribes the region of a packed image and provides information about the original image before it was packed.static classTextureAtlas.AtlasSpriteA sprite that, if whitespace was stripped from the region when it was packed, is automatically positioned as if whitespace had not been stripped.Methods in com.badlogic.gdx.graphics.g2d that return TextureRegion Modifier and Type Method Description TextureRegionBitmapFont. getRegion()Returns the first texture region.TextureRegionBitmapFont. getRegion(int index)Returns the texture page at the given index.TextureRegionPolygonRegion. getRegion()TextureRegion[][]TextureRegion. split(int tileWidth, int tileHeight)Helper method to create tiles out of this TextureRegion starting from the top left corner going to the right and ending at the bottom right corner.static TextureRegion[][]TextureRegion. split(Texture texture, int tileWidth, int tileHeight)Helper method to create tiles out of the givenTexturestarting from the top left corner going to the right and ending at the bottom right corner.Methods in com.badlogic.gdx.graphics.g2d that return types with arguments of type TextureRegion Modifier and Type Method Description Array<TextureRegion>BitmapFont. getRegions()Returns the array of TextureRegions that represents each texture page of glyphs.Methods in com.badlogic.gdx.graphics.g2d with parameters of type TextureRegion Modifier and Type Method Description voidSpriteCache. add(TextureRegion region, float x, float y)Adds the specified region to the cache.voidSpriteCache. add(TextureRegion region, float x, float y, float width, float height)Adds the specified region to the cache.voidSpriteCache. add(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)Adds the specified region to the cache.TextureAtlas.AtlasRegionTextureAtlas. addRegion(java.lang.String name, TextureRegion textureRegion)Adds a region to the atlas.voidBatch. draw(TextureRegion region, float x, float y)Draws a rectangle with the bottom left corner at x,y having the width and height of the region.voidBatch. draw(TextureRegion region, float x, float y, float width, float height)Draws a rectangle with the bottom left corner at x,y and stretching the region to cover the given width and height.voidBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)Draws a rectangle with the bottom left corner at x,y and stretching the region to cover the given width and height.voidBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation, boolean clockwise)Draws a rectangle with the texture coordinates rotated 90 degrees.voidBatch. draw(TextureRegion region, float width, float height, Affine2 transform)Draws a rectangle transformed by the given matrix.voidCpuSpriteBatch. draw(TextureRegion region, float x, float y)voidCpuSpriteBatch. draw(TextureRegion region, float x, float y, float width, float height)voidCpuSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)voidCpuSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation, boolean clockwise)voidCpuSpriteBatch. draw(TextureRegion region, float width, float height, Affine2 transform)voidPolygonSpriteBatch. draw(TextureRegion region, float x, float y)voidPolygonSpriteBatch. draw(TextureRegion region, float x, float y, float width, float height)voidPolygonSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)voidPolygonSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation, boolean clockwise)voidPolygonSpriteBatch. draw(TextureRegion region, float width, float height, Affine2 transform)voidSpriteBatch. draw(TextureRegion region, float x, float y)voidSpriteBatch. draw(TextureRegion region, float x, float y, float width, float height)voidSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation)voidSpriteBatch. draw(TextureRegion region, float x, float y, float originX, float originY, float width, float height, float scaleX, float scaleY, float rotation, boolean clockwise)voidSpriteBatch. draw(TextureRegion region, float width, float height, Affine2 transform)PolygonRegionPolygonRegionLoader. load(TextureRegion textureRegion, FileHandle file)Loads a PolygonRegion from a PSH (Polygon SHape) file.voidBitmapFont.BitmapFontData. setGlyphRegion(BitmapFont.Glyph glyph, TextureRegion region)voidRepeatablePolygonSprite. setPolygon(TextureRegion region, float[] vertices)Sets polygon with repeating texture region, the size of repeating grid is equal to region sizevoidRepeatablePolygonSprite. setPolygon(TextureRegion region, float[] vertices, float density)Sets polygon with repeating texture region, the size of repeating grid is equal to region sizevoidTextureRegion. setRegion(TextureRegion region)Sets the texture and coordinates to the specified region.voidTextureRegion. setRegion(TextureRegion region, int x, int y, int width, int height)Sets the texture to that of the specified region and sets the coordinates relative to the specified region.Method parameters in com.badlogic.gdx.graphics.g2d with type arguments of type TextureRegion Modifier and Type Method Description voidPixmapPacker. updateTextureRegions(Array<TextureRegion> regions, Texture.TextureFilter minFilter, Texture.TextureFilter magFilter, boolean useMipMaps)CallsupdateTexturefor each page and adds a region to the specified array for each page texture.Constructors in com.badlogic.gdx.graphics.g2d with parameters of type TextureRegion Constructor Description AtlasRegion(TextureRegion region)BitmapFont(FileHandle fontFile, TextureRegion region)Creates a BitmapFont with the glyphs relative to the specified region.BitmapFont(FileHandle fontFile, TextureRegion region, boolean flip)Creates a BitmapFont with the glyphs relative to the specified region.BitmapFont(BitmapFont.BitmapFontData data, TextureRegion region, boolean integer)Constructs a new BitmapFont from the givenBitmapFont.BitmapFontDataandTextureRegion.DistanceFieldFont(FileHandle fontFile, TextureRegion region)DistanceFieldFont(FileHandle fontFile, TextureRegion region, boolean flip)DistanceFieldFont(BitmapFont.BitmapFontData data, TextureRegion region, boolean integer)NinePatch(TextureRegion region)Construct a degenerate "nine" patch with only a center component.NinePatch(TextureRegion... patches)Construct a nine patch from the given nine texture regions.NinePatch(TextureRegion region, int left, int right, int top, int bottom)Create a ninepatch by cutting up the given texture region into nine patches.NinePatch(TextureRegion region, Color color)Construct a degenerate "nine" patch with only a center component.PolygonRegion(TextureRegion region, float[] vertices, short[] triangles)Creates a PolygonRegion by triangulating the polygon coordinates in vertices and calculates uvs based on that.Sprite(TextureRegion region)Creates a sprite based on a specific TextureRegion, the new sprite's region is a copy of the parameter region - altering one does not affect the otherSprite(TextureRegion region, int srcX, int srcY, int srcWidth, int srcHeight)Creates a sprite with width, height, and texture region equal to the specified size, relative to specified sprite's texture region.TextureRegion(TextureRegion region)Constructs a region with the same texture and coordinates of the specified region.TextureRegion(TextureRegion region, int x, int y, int width, int height)Constructs a region with the same texture as the specified region and sets the coordinates relative to the specified region.Constructor parameters in com.badlogic.gdx.graphics.g2d with type arguments of type TextureRegion Constructor Description BitmapFont(BitmapFont.BitmapFontData data, Array<TextureRegion> pageRegions, boolean integer)Constructs a new BitmapFont from the givenBitmapFont.BitmapFontDataand array ofTextureRegion.DistanceFieldFont(BitmapFont.BitmapFontData data, Array<TextureRegion> pageRegions, boolean integer) -
Uses of TextureRegion in com.badlogic.gdx.graphics.g3d.attributes
Methods in com.badlogic.gdx.graphics.g3d.attributes with parameters of type TextureRegion Modifier and Type Method Description static TextureAttributeTextureAttribute. createAmbient(TextureRegion region)static TextureAttributeTextureAttribute. createBump(TextureRegion region)static TextureAttributeTextureAttribute. createDiffuse(TextureRegion region)static TextureAttributeTextureAttribute. createEmissive(TextureRegion region)static TextureAttributeTextureAttribute. createNormal(TextureRegion region)static TextureAttributeTextureAttribute. createReflection(TextureRegion region)static TextureAttributeTextureAttribute. createSpecular(TextureRegion region)voidTextureAttribute. set(TextureRegion region)Constructors in com.badlogic.gdx.graphics.g3d.attributes with parameters of type TextureRegion Constructor Description TextureAttribute(long type, TextureRegion region) -
Uses of TextureRegion in com.badlogic.gdx.graphics.g3d.decals
Fields in com.badlogic.gdx.graphics.g3d.decals declared as TextureRegion Modifier and Type Field Description protected TextureRegionDecalMaterial. textureRegionMethods in com.badlogic.gdx.graphics.g3d.decals that return TextureRegion Modifier and Type Method Description TextureRegionDecal. getTextureRegion()Methods in com.badlogic.gdx.graphics.g3d.decals with parameters of type TextureRegion Modifier and Type Method Description static DecalDecal. newDecal(float width, float height, TextureRegion textureRegion)Creates a decal using the region for texturingstatic DecalDecal. newDecal(float width, float height, TextureRegion textureRegion, boolean hasTransparency)Creates a decal using the region for texturingstatic DecalDecal. newDecal(float width, float height, TextureRegion textureRegion, int srcBlendFactor, int dstBlendFactor)Creates a decal using the region for texturing and the specified blending parameters for blendingstatic DecalDecal. newDecal(float width, float height, TextureRegion textureRegion, int srcBlendFactor, int dstBlendFactor, DecalMaterial material)Creates a decal using the region for texturing and the specified blending parameters for blendingstatic DecalDecal. newDecal(TextureRegion textureRegion)Creates a decal assuming the dimensions of the texture regionstatic DecalDecal. newDecal(TextureRegion textureRegion, boolean hasTransparency)Creates a decal assuming the dimensions of the texture region and adding transparencyvoidDecal. setTextureRegion(TextureRegion textureRegion)Sets the texture region -
Uses of TextureRegion in com.badlogic.gdx.graphics.g3d.particles.influencers
Methods in com.badlogic.gdx.graphics.g3d.particles.influencers with parameters of type TextureRegion Modifier and Type Method Description voidRegionInfluencer. add(TextureRegion... regions)voidRegionInfluencer.AspectTextureRegion. set(TextureRegion region)Constructors in com.badlogic.gdx.graphics.g3d.particles.influencers with parameters of type TextureRegion Constructor Description Animated(TextureRegion textureRegion)AspectTextureRegion(TextureRegion region)Random(TextureRegion textureRegion)RegionInfluencer(TextureRegion... regions)All the regions must be defined on the same TextureSingle(TextureRegion textureRegion) -
Uses of TextureRegion in com.badlogic.gdx.graphics.g3d.utils
Methods in com.badlogic.gdx.graphics.g3d.utils with parameters of type TextureRegion Modifier and Type Method Description voidMeshBuilder. setUVRange(TextureRegion region)voidMeshPartBuilder. setUVRange(TextureRegion r)Set range of texture coordinates from the specified TextureRegion. -
Uses of TextureRegion in com.badlogic.gdx.maps
Methods in com.badlogic.gdx.maps that return TextureRegion Modifier and Type Method Description TextureRegionImageResolver.AssetManagerImageResolver. getImage(java.lang.String name)TextureRegionImageResolver.DirectImageResolver. getImage(java.lang.String name)TextureRegionImageResolver. getImage(java.lang.String name)TextureRegionImageResolver.TextureAtlasImageResolver. getImage(java.lang.String name) -
Uses of TextureRegion in com.badlogic.gdx.maps.objects
Methods in com.badlogic.gdx.maps.objects that return TextureRegion Modifier and Type Method Description TextureRegionTextureMapObject. getTextureRegion()Methods in com.badlogic.gdx.maps.objects with parameters of type TextureRegion Modifier and Type Method Description voidTextureMapObject. setTextureRegion(TextureRegion region)Constructors in com.badlogic.gdx.maps.objects with parameters of type TextureRegion Constructor Description TextureMapObject(TextureRegion textureRegion)Creates texture map object with the given region -
Uses of TextureRegion in com.badlogic.gdx.maps.tiled
Methods in com.badlogic.gdx.maps.tiled that return TextureRegion Modifier and Type Method Description TextureRegionAtlasTmxMapLoader.AtlasResolver.AssetManagerAtlasResolver. getImage(java.lang.String name)TextureRegionAtlasTmxMapLoader.AtlasResolver.DirectAtlasResolver. getImage(java.lang.String name)TextureRegionTiledMapImageLayer. getTextureRegion()TextureRegionTiledMapTile. getTextureRegion()Methods in com.badlogic.gdx.maps.tiled with parameters of type TextureRegion Modifier and Type Method Description protected voidBaseTmxMapLoader. addStaticTiledMapTile(TiledMapTileSet tileSet, TextureRegion textureRegion, int tileId, float offsetX, float offsetY)voidTiledMapImageLayer. setTextureRegion(TextureRegion region)voidTiledMapTile. setTextureRegion(TextureRegion textureRegion)Sets the texture region used to render the tileConstructors in com.badlogic.gdx.maps.tiled with parameters of type TextureRegion Constructor Description TiledMapImageLayer(TextureRegion region, float x, float y) -
Uses of TextureRegion in com.badlogic.gdx.maps.tiled.tiles
Methods in com.badlogic.gdx.maps.tiled.tiles that return TextureRegion Modifier and Type Method Description TextureRegionAnimatedTiledMapTile. getTextureRegion()TextureRegionStaticTiledMapTile. getTextureRegion()Methods in com.badlogic.gdx.maps.tiled.tiles with parameters of type TextureRegion Modifier and Type Method Description voidAnimatedTiledMapTile. setTextureRegion(TextureRegion textureRegion)voidStaticTiledMapTile. setTextureRegion(TextureRegion textureRegion)Constructors in com.badlogic.gdx.maps.tiled.tiles with parameters of type TextureRegion Constructor Description StaticTiledMapTile(TextureRegion textureRegion)Creates a static tile with the given region -
Uses of TextureRegion in com.badlogic.gdx.scenes.scene2d.ui
Methods in com.badlogic.gdx.scenes.scene2d.ui that return TextureRegion Modifier and Type Method Description TextureRegionSkin. getRegion(java.lang.String name)Returns a registered texture region.Methods in com.badlogic.gdx.scenes.scene2d.ui that return types with arguments of type TextureRegion Modifier and Type Method Description Array<TextureRegion>Skin. getRegions(java.lang.String regionName)Constructors in com.badlogic.gdx.scenes.scene2d.ui with parameters of type TextureRegion Constructor Description Image(TextureRegion region)Creates an image stretched, and aligned center. -
Uses of TextureRegion in com.badlogic.gdx.scenes.scene2d.utils
Methods in com.badlogic.gdx.scenes.scene2d.utils that return TextureRegion Modifier and Type Method Description TextureRegionTextureRegionDrawable. getRegion()Methods in com.badlogic.gdx.scenes.scene2d.utils with parameters of type TextureRegion Modifier and Type Method Description static voidTiledDrawable. draw(Batch batch, TextureRegion textureRegion, float x, float y, float width, float height, float scale, int align)voidTextureRegionDrawable. setRegion(TextureRegion region)Constructors in com.badlogic.gdx.scenes.scene2d.utils with parameters of type TextureRegion Constructor Description TextureRegionDrawable(TextureRegion region)TiledDrawable(TextureRegion region) -
Uses of TextureRegion in com.badlogic.gdx.utils
Methods in com.badlogic.gdx.utils that return TextureRegion Modifier and Type Method Description static TextureRegionScreenUtils. getFrameBufferTexture()Returns the current framebuffer contents as aTextureRegionwith a width and height equal to the current screen size.static TextureRegionScreenUtils. getFrameBufferTexture(int x, int y, int w, int h)Returns a portion of the current framebuffer contents specified by x, y, width and height as aTextureRegionwith the same dimensions.
-