Package zombie.core.textures
Class Texture
java.lang.Object
zombie.asset.Asset
zombie.core.textures.Texture
- All Implemented Interfaces:
java.io.Serializable
,IDestroyable
,IMaskerable
,ITexture
- Direct Known Subclasses:
AngelCodeFont.CharDefTexture
,SmartTexture
public class Texture extends Asset implements IDestroyable, ITexture, java.io.Serializable
- See Also:
- Serialized Form
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
Texture.PZFileformat
static class
Texture.TextureAssetParams
Nested classes/interfaces inherited from class zombie.asset.Asset
Asset.ObserverCallback, Asset.State
-
Field Summary
Fields Modifier and Type Field Description static AssetType
ASSET_TYPE
Texture.TextureAssetParams
assetParams
static boolean
bDoingQuad
boolean
bindAlways
static int
BindCount
protected TextureID
dataid
boolean
flip
protected int
height
protected int
heightOrig
static float
la
static int
lastlastTextureID
static int
lastTextureID
static float
lb
static float
lg
static float
lr
protected Mask
mask
protected java.lang.String
name
static java.util.HashSet
nullTextures
float
offsetX
float
offsetY
protected boolean
solid
protected FileSystem.SubTexture
subTexture
static int
totalTextureID
static boolean
WarnFailFindTexture
protected int
width
protected int
widthOrig
float
xEnd
float
xStart
float
yEnd
float
yStart
Fields inherited from class zombie.asset.Asset
m_asset_manager
-
Constructor Summary
Constructors Constructor Description Texture()
Texture(int int1, int int2, int int3)
Texture(int int1, int int2, java.lang.String string, int int3)
Texture(java.lang.String string)
Texture(java.lang.String string, boolean boolean1)
Texture(java.lang.String string, boolean boolean1, boolean boolean2)
Texture(java.lang.String string, int[] intArray)
Texture(java.lang.String string, int int1, int int2, int int3)
Texture(java.lang.String string, java.io.BufferedInputStream bufferedInputStream, boolean boolean1)
Texture(java.lang.String string, java.io.BufferedInputStream bufferedInputStream, boolean boolean1, Texture.PZFileformat pZFileformat)
Texture(java.lang.String string, java.lang.String string2)
Texture(AssetPath assetPath, AssetManager assetManager, Texture.TextureAssetParams textureAssetParams)
Texture(Texture texture)
Texture(TextureID textureID, java.lang.String string)
-
Method Summary
Modifier and Type Method Description void
bind()
void
bind(int int1)
static void
bindNone()
static void
clearTextures()
static void
collectAllIcons(java.util.HashMap hashMap, java.util.HashMap hashMap2)
void
copyMaskRegion(Texture texture, int int1, int int2, int int3, int int4)
void
createMask()
void
createMask(boolean[] booleanArray)
void
createMask(BooleanGrid booleanGrid)
void
createMask(WrappedBuffer wrappedBuffer)
void
destroy()
boolean
equals(Texture texture)
static int[]
flipPixels(int[] intArray, int int1, int int2)
static void
forgetTexture(java.lang.String string)
WrappedBuffer
getData()
static Texture
getEngineMipmapTexture()
static Texture
getErrorTexture()
int
getHeight()
int
getHeightHW()
int
getHeightOrig()
int
getID()
Mask
getMask()
java.lang.String
getName()
float
getOffsetX()
float
getOffsetY()
int
getRealHeight()
int
getRealWidth()
static Texture
getSharedTexture(java.lang.String string)
static Texture
getSharedTexture(java.lang.String string, int int1)
static Texture
getSharedTexture(java.lang.String string, int[] intArray, java.lang.String string2)
static Texture
getSharedTexture(java.lang.String string, java.lang.String string2)
static Texture
getSteamAvatar(long long1)
static Texture
getTexture(java.lang.String string)
TextureID
getTextureId()
AssetType
getType()
boolean
getUseAlphaChannel()
Vector2
getUVScale(Vector2 vector2)
static Texture
getWhite()
int
getWidth()
int
getWidthHW()
int
getWidthOrig()
float
getXEnd()
float
getXStart()
float
getYEnd()
float
getYStart()
boolean
isCollisionable()
boolean
isDestroyed()
boolean
isSolid()
boolean
isValid()
void
loadMaskRegion(java.nio.ByteBuffer byteBuffer)
void
makeTransp(int int1, int int2, int int3)
void
onBeforeReady()
static void
onTexturePacksChanged()
static java.lang.String
processFilePath(java.lang.String string)
static void
reload(java.lang.String string)
void
reloadFromFile(java.lang.String string)
void
render(float float1, float float2)
void
render(float float1, float float2, float float3, float float4)
void
render(float float1, float float2, float float3, float float4, float float5, float float6, float float7, float float8, java.util.function.Consumer consumer)
void
render(ObjectRenderEffects objectRenderEffects, float float1, float float2, float float3, float float4, float float5, float float6, float float7, float float8, java.util.function.Consumer consumer)
void
renderdiamond(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4)
void
rendershader2(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4, float float5, float float6, float float7, float float8)
void
renderstrip(int int1, int int2, int int3, int int4, float float1, float float2, float float3, float float4, java.util.function.Consumer consumer)
void
renderwalln(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4)
void
renderwallnw(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4, int int5, int int6)
void
renderwallw(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4)
void
save(java.lang.String string)
void
saveMask(java.lang.String string)
void
saveMaskRegion(java.nio.ByteBuffer byteBuffer)
void
setAlphaForeach(int int1, int int2, int int3, int int4)
void
setCustomizedTexture()
void
setData(java.nio.ByteBuffer byteBuffer)
void
setHeight(int int1)
void
setMask(Mask mask)
void
setName(java.lang.String string)
void
setNameOnly(java.lang.String string)
void
setOffsetX(int int1)
void
setOffsetY(int int1)
void
setRealHeight(int int1)
void
setRealWidth(int int1)
void
setRegion(int int1, int int2, int int3, int int4)
void
setUseAlphaChannel(boolean boolean1)
void
setWidth(int int1)
Texture
split(int int1, int int2, int int3, int int4)
Texture[]
split(int int1, int int2, int int3, int int4, int int5, int int6, int int7, int int8)
Texture
split(java.lang.String string, int int1, int int2, int int3, int int4)
Texture[][]
split2D(int[] intArray, int[] intArray2)
Texture
splitIcon()
static void
steamAvatarChanged(long long1)
java.lang.String
toString()
static Texture
trygetTexture(java.lang.String string)
Methods inherited from class zombie.asset.Asset
addDependency, getAssetManager, getObserverCb, getPath, getRefCount, getState, isEmpty, isFailure, isReady, onBeforeEmpty, onCreated, removeDependency, setAssetParams
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Field Details
-
nullTextures
public static final java.util.HashSet nullTextures -
BindCount
public static int BindCount -
bDoingQuad
public static boolean bDoingQuad -
lr
public static float lr -
lg
public static float lg -
lb
public static float lb -
la
public static float la -
lastlastTextureID
public static int lastlastTextureID -
totalTextureID
public static int totalTextureID -
lastTextureID
public static int lastTextureID -
WarnFailFindTexture
public static boolean WarnFailFindTexture -
flip
public boolean flip -
offsetX
public float offsetX -
offsetY
public float offsetY -
bindAlways
public boolean bindAlways -
xEnd
public float xEnd -
yEnd
public float yEnd -
xStart
public float xStart -
yStart
public float yStart -
dataid
-
mask
-
name
protected java.lang.String name -
solid
protected boolean solid -
width
protected int width -
height
protected int height -
heightOrig
protected int heightOrig -
widthOrig
protected int widthOrig -
subTexture
-
assetParams
-
ASSET_TYPE
-
-
Constructor Details
-
Texture
public Texture(AssetPath assetPath, AssetManager assetManager, Texture.TextureAssetParams textureAssetParams) -
Texture
-
Texture
public Texture(java.lang.String string) throws java.lang.Exception- Throws:
java.lang.Exception
-
Texture
public Texture(java.lang.String string, java.io.BufferedInputStream bufferedInputStream, boolean boolean1, Texture.PZFileformat pZFileformat) -
Texture
public Texture(java.lang.String string, java.io.BufferedInputStream bufferedInputStream, boolean boolean1) throws java.lang.Exception- Throws:
java.lang.Exception
-
Texture
public Texture(java.lang.String string, boolean boolean1, boolean boolean2) throws java.lang.Exception- Throws:
java.lang.Exception
-
Texture
public Texture(java.lang.String string, java.lang.String string2) -
Texture
public Texture(java.lang.String string, int[] intArray) -
Texture
public Texture(java.lang.String string, boolean boolean1) throws java.lang.Exception- Throws:
java.lang.Exception
-
Texture
public Texture(int int1, int int2, java.lang.String string, int int3) -
Texture
public Texture(int int1, int int2, int int3) -
Texture
public Texture(java.lang.String string, int int1, int int2, int int3) throws java.lang.Exception- Throws:
java.lang.Exception
-
Texture
-
Texture
public Texture()
-
-
Method Details
-
processFilePath
public static java.lang.String processFilePath(java.lang.String string) -
bindNone
public static void bindNone() -
getWhite
-
getErrorTexture
-
getEngineMipmapTexture
-
clearTextures
public static void clearTextures() -
trygetTexture
-
onTexturePacksChanged
public static void onTexturePacksChanged() -
getTexture
-
getSteamAvatar
-
steamAvatarChanged
public static void steamAvatarChanged(long long1) -
forgetTexture
public static void forgetTexture(java.lang.String string) -
reload
public static void reload(java.lang.String string) -
flipPixels
public static int[] flipPixels(int[] intArray, int int1, int int2) -
reloadFromFile
public void reloadFromFile(java.lang.String string) -
bind
public void bind() -
bind
public void bind(int int1) -
copyMaskRegion
-
createMask
public void createMask() -
createMask
public void createMask(boolean[] booleanArray) -
createMask
-
createMask
-
destroy
public void destroy()- Specified by:
destroy
in interfaceIDestroyable
-
equals
-
getData
-
setData
public void setData(java.nio.ByteBuffer byteBuffer) -
getHeight
public int getHeight() -
setHeight
public void setHeight(int int1) -
getHeightHW
public int getHeightHW()- Specified by:
getHeightHW
in interfaceITexture
-
getHeightOrig
public int getHeightOrig() -
getID
public int getID() -
getMask
- Specified by:
getMask
in interfaceIMaskerable
-
setMask
-
getName
public java.lang.String getName() -
setName
public void setName(java.lang.String string) -
getTextureId
-
getUseAlphaChannel
public boolean getUseAlphaChannel() -
setUseAlphaChannel
public void setUseAlphaChannel(boolean boolean1) -
getWidth
public int getWidth() -
setWidth
public void setWidth(int int1) -
getWidthHW
public int getWidthHW()- Specified by:
getWidthHW
in interfaceITexture
-
getWidthOrig
public int getWidthOrig() -
getXEnd
public float getXEnd() -
getXStart
public float getXStart() -
getYEnd
public float getYEnd() -
getYStart
public float getYStart() -
getOffsetX
public float getOffsetX() -
setOffsetX
public void setOffsetX(int int1) -
getOffsetY
public float getOffsetY() -
setOffsetY
public void setOffsetY(int int1) -
isCollisionable
public boolean isCollisionable() -
isDestroyed
public boolean isDestroyed()- Specified by:
isDestroyed
in interfaceIDestroyable
-
isSolid
public boolean isSolid() -
isValid
public boolean isValid() -
makeTransp
public void makeTransp(int int1, int int2, int int3)- Specified by:
makeTransp
in interfaceITexture
-
render
public void render(float float1, float float2, float float3, float float4) -
render
public void render(float float1, float float2) -
render
public void render(float float1, float float2, float float3, float float4, float float5, float float6, float float7, float float8, java.util.function.Consumer consumer) -
render
public void render(ObjectRenderEffects objectRenderEffects, float float1, float float2, float float3, float float4, float float5, float float6, float float7, float float8, java.util.function.Consumer consumer) -
rendershader2
public void rendershader2(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4, float float5, float float6, float float7, float float8) -
renderdiamond
public void renderdiamond(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4) -
renderwallnw
public void renderwallnw(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4, int int5, int int6) -
renderwallw
public void renderwallw(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4) -
renderwalln
public void renderwalln(float float1, float float2, float float3, float float4, int int1, int int2, int int3, int int4) -
renderstrip
public void renderstrip(int int1, int int2, int int3, int int4, float float1, float float2, float float3, float float4, java.util.function.Consumer consumer) -
setAlphaForeach
public void setAlphaForeach(int int1, int int2, int int3, int int4)- Specified by:
setAlphaForeach
in interfaceITexture
-
setCustomizedTexture
public void setCustomizedTexture() -
setNameOnly
public void setNameOnly(java.lang.String string) -
setRegion
public void setRegion(int int1, int int2, int int3, int int4) -
splitIcon
-
split
-
split
-
split
public Texture[] split(int int1, int int2, int int3, int int4, int int5, int int6, int int7, int int8) -
split2D
-
toString
public java.lang.String toString()- Overrides:
toString
in classjava.lang.Object
-
saveMask
public void saveMask(java.lang.String string) -
save
public void save(java.lang.String string) -
loadMaskRegion
public void loadMaskRegion(java.nio.ByteBuffer byteBuffer) -
saveMaskRegion
public void saveMaskRegion(java.nio.ByteBuffer byteBuffer) -
getRealWidth
public int getRealWidth() -
setRealWidth
public void setRealWidth(int int1) -
getRealHeight
public int getRealHeight() -
setRealHeight
public void setRealHeight(int int1) -
getUVScale
-
getType
-
onBeforeReady
public void onBeforeReady()- Overrides:
onBeforeReady
in classAsset
-
collectAllIcons
public static void collectAllIcons(java.util.HashMap hashMap, java.util.HashMap hashMap2)
-