Package org.oscim.backend.canvas
Interface Bitmap
public interface Bitmap
The Interface Bitmap.
-
Method Summary
Modifier and TypeMethodDescriptionvoideraseColor(int color) Erase color, clear Bitmap.intGets the height.int[]Gets the pixels as ARGB int array.byte[]intgetWidth()Gets the width.booleanisValid()voidrecycle()Recycle.voidscaleTo(int width, int height) voiduploadToTexture(boolean replace) Upload Bitmap to currently bound GL texture.
-
Method Details
-
getWidth
int getWidth()Gets the width.- Returns:
- the width
-
getHeight
int getHeight()Gets the height.- Returns:
- the height
-
recycle
void recycle()Recycle. -
getPixels
int[] getPixels()Gets the pixels as ARGB int array.- Returns:
- the pixels
-
eraseColor
void eraseColor(int color) Erase color, clear Bitmap.- Parameters:
color- the color
-
uploadToTexture
void uploadToTexture(boolean replace) Upload Bitmap to currently bound GL texture.- Parameters:
replace- true, when glSubImage2D can be used for upload
-
isValid
boolean isValid() -
getPngEncodedData
byte[] getPngEncodedData() -
scaleTo
void scaleTo(int width, int height)
-