|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectde.matthiasmann.twl.renderer.lwjgl.TextureAreaBase
de.matthiasmann.twl.renderer.lwjgl.LWJGLDynamicImage
public class LWJGLDynamicImage
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface de.matthiasmann.twl.renderer.DynamicImage |
|---|
DynamicImage.Format |
| Field Summary |
|---|
| Fields inherited from class de.matthiasmann.twl.renderer.lwjgl.TextureAreaBase |
|---|
height, tx0, tx1, ty0, ty1, width |
| Constructor Summary | |
|---|---|
LWJGLDynamicImage(LWJGLRenderer renderer,
int target,
int id,
int width,
int height,
int texWidth,
int texHeight,
Color tintColor)
|
|
| Method Summary | |
|---|---|
Image |
createTintedVersion(Color color)
Creates a new image with is tinted with the specified color. |
void |
destroy()
After destroying a resurce it is no longer useable. |
void |
draw(AnimationState as,
int x,
int y)
Draws the image in it's original size at the given location |
void |
draw(AnimationState as,
int x,
int y,
int width,
int height)
Draws the image scaled to the given size at the given location |
void |
update(java.nio.ByteBuffer data,
DynamicImage.Format format)
Updates the complete image. |
void |
update(java.nio.ByteBuffer data,
int stride,
DynamicImage.Format format)
Updates the complete image. |
void |
update(int xoffset,
int yoffset,
int width,
int height,
java.nio.ByteBuffer data,
DynamicImage.Format format)
Updates a region of the image with new data. |
void |
update(int xoffset,
int yoffset,
int width,
int height,
java.nio.ByteBuffer data,
int stride,
DynamicImage.Format format)
Updates a region of the image with new data. |
| Methods inherited from class de.matthiasmann.twl.renderer.lwjgl.TextureAreaBase |
|---|
getHeight, getWidth |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Methods inherited from interface de.matthiasmann.twl.renderer.Image |
|---|
getHeight, getWidth |
| Constructor Detail |
|---|
public LWJGLDynamicImage(LWJGLRenderer renderer,
int target,
int id,
int width,
int height,
int texWidth,
int texHeight,
Color tintColor)
| Method Detail |
|---|
public void destroy()
Resource
destroy in interface Resource
public void update(java.nio.ByteBuffer data,
DynamicImage.Format format)
DynamicImage
update in interface DynamicImagedata - The new texelsformat - The format of the texel data
public void update(java.nio.ByteBuffer data,
int stride,
DynamicImage.Format format)
DynamicImage
update in interface DynamicImagedata - The new texelsstride - The number of bytes from one row to the nextformat - The format of the texel data
public void update(int xoffset,
int yoffset,
int width,
int height,
java.nio.ByteBuffer data,
DynamicImage.Format format)
DynamicImage
update in interface DynamicImagexoffset - Specifies a texel offset in the x direction within the imageyoffset - Specifies a texel offset in the y direction within the imagewidth - Specifies the width of the update areaheight - Specifies the height of the update areadata - The new texelsformat - The format of the texel data
public void update(int xoffset,
int yoffset,
int width,
int height,
java.nio.ByteBuffer data,
int stride,
DynamicImage.Format format)
DynamicImage
update in interface DynamicImagexoffset - Specifies a texel offset in the x direction within the imageyoffset - Specifies a texel offset in the y direction within the imagewidth - Specifies the width of the update areaheight - Specifies the height of the update areadata - The new texelsstride - The number of bytes from one row to the nextformat - The format of the texel datapublic Image createTintedVersion(Color color)
Image
createTintedVersion in interface Imagecolor - The color used for tinting.
public void draw(AnimationState as,
int x,
int y)
Image
draw in interface Imageas - A time source for animation - may be nullx - left coordinatey - top coordinate
public void draw(AnimationState as,
int x,
int y,
int width,
int height)
Image
draw in interface Imageas - A time source for animation - may be nullx - left coordinatey - top coordinatewidth - the width in pixelsheight - the height in pixels
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||