|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdanger.ui.Bitmap
danger.ui.IntBitmap
public class IntBitmap
It's like a Bitmap, but the pixel data is an int[]. Fantastic.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class danger.ui.Bitmap |
|---|
Bitmap.FromResource |
| Field Summary |
|---|
| Constructor Summary | |
|---|---|
IntBitmap(int[] pixels,
int width,
int height,
int colorspace,
int transparentColor,
int paletteSize)
Construct an instance with int[] pixel data. |
|
IntBitmap(IntBitmap src)
|
|
| Method Summary | |
|---|---|
int[] |
getInts()
Returns a reference to the pixel array for this bitmap |
int |
getPoint(int x,
int y)
Returns the 32-bit ARGB color of an individual pixel. |
void |
setInts(int[] pixels)
Set the pixels of this bitmap from the array passed in. |
void |
setTransparentColor(int color)
Directly set the transparent color for this bitmap. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public IntBitmap(int[] pixels,
int width,
int height,
int colorspace,
int transparentColor,
int paletteSize)
pixels - null-ok; the pixels of the bitmap, or null
if the bitmap is to be initially blank; if non-null then
the pixels become shared (modifying the original array affects the
constructed instance)width - >= 0; the width of the bitmapheight - >= 0; the height of the bitmapcolorspace - the colorspace; see ColorSpacetransparentColor - what color ought to be considered "transparent"
when drawing the bitmap; use -1 if there is to be no
transparencypaletteSize - the number of colors in the palette; if >=
0, then the palette is located just past the end of the pixel
data per se in pixelspublic IntBitmap(IntBitmap src)
| Method Detail |
|---|
public void setInts(int[] pixels)
pixels - the new pixel array for this bitmapgetInts()public int[] getInts()
setInts(int[])
public int getPoint(int x,
int y)
Bitmap
getPoint in class Bitmapx - the x coordinate of the pixely - the y coordinate of the pixel
public void setTransparentColor(int color)
Bitmap
setTransparentColor in class Bitmapcolor - A colorspace dependent integer to use as the
transparent color.
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||