|
Beatmup Java package
|
Android bitmap wrapping. More...
Public Member Functions | |
| android.graphics.Bitmap | getBitmap () |
| synchronized void | dispose () |
| Destroys the native object. More... | |
| Bitmap | clone () |
Public Member Functions inherited from Beatmup.Bitmap | |
| Bitmap (Context context, int width, int height, PixelFormat pixelFormat) | |
| Creates new internally managed bitmap. More... | |
| int | getWidth () |
| int | getHeight () |
| IntRectangle | clientRectangle () |
| PixelFormat | getPixelFormat () |
| void | zero () |
| Sets all bitmap pixels to zero. More... | |
| Bitmap | clone (PixelFormat pixelFormat) |
| Bitmap | copyRegion (IntRectangle region) |
| Creates a bitmap containing a copy of a rectangular region. More... | |
| void | projectOn (Bitmap bitmap, int left, int top) |
| Copies a rectangular area to another bitmap. More... | |
| void | invert () |
| Pixelwise bitmap inversion. More... | |
| void | pullPixels () |
| Transfers pixel data from GPU to CPU. More... | |
Static Public Member Functions | |
| static Bitmap | decodeStream (Context context, InputStream inputStream) throws OutOfMemoryError |
| Decodes a bitmap from stream. More... | |
| static Bitmap | decodeFile (Context context, String path, BitmapFactory.Options options) throws OutOfMemoryError |
| Loads a bitmap from file. More... | |
| static Bitmap | decodeFileDescriptor (Context context, FileDescriptor file, android.graphics.Rect outPadding, BitmapFactory.Options options) throws OutOfMemoryError |
| Loads a bitmap from file. More... | |
| static Bitmap | createColorBitmap (Context context, int width, int height) |
| Creates empty ARGB bitmap of specified size. More... | |
| static Bitmap | createGrayscaleBitmap (Context context, int width, int height) |
| Creates empty grayscale bitmap of specified size. More... | |
Static Public Member Functions inherited from Beatmup.Bitmap | |
| static Bitmap | createEmpty (Bitmap bitmap) |
| Creates an empty bitmap of the same size and pixel format as a given bitmap. More... | |
Private Member Functions | |
| Bitmap (Context context, android.graphics.Bitmap bitmap) | |
| Creates new bitmap from Android bitmap object without memory copy. More... | |
Static Private Member Functions | |
| static Bitmap | createEnsuringPixelFormat (Context context, android.graphics.Bitmap bitmap) |
| Creates new bitmap from a source Android bitmap converting the data into appropriate pixel format if necessary. More... | |
Private Attributes | |
| android.graphics.Bitmap | source |
| wrapped Android bitmap More... | |
Additional Inherited Members | |
Protected Member Functions inherited from Beatmup.Bitmap | |
| Bitmap (Context context, android.graphics.Bitmap bitmap) throws BadPixelFormat | |
| Creates new bitmap from Android bitmap object. More... | |
Protected Attributes inherited from Beatmup.Object | |
| long | handle |
| pointer to the native object More... | |
Android bitmap wrapping.
Enables access to Android bitmaps from inside the Beatmup engine without memory copy.
Definition at line 32 of file Bitmap.java.
|
inlineprivate |
Creates new bitmap from Android bitmap object without memory copy.
| context | Beatmup context |
| bitmap | source bitmap |
Definition at line 40 of file Bitmap.java.
|
inlinestaticprivate |
Creates new bitmap from a source Android bitmap converting the data into appropriate pixel format if necessary.
| context | the context handling the new bitmap |
| bitmap | the source; may be recycled |
Definition at line 51 of file Bitmap.java.
|
inlinestatic |
Decodes a bitmap from stream.
| context | a Beatmup context |
| inputStream | the stream to decode |
Definition at line 66 of file Bitmap.java.
|
inlinestatic |
Loads a bitmap from file.
If the pixel format is not supported, this function tries to convert the source data to a 32-bit color bitmap.
| context | a Beatmup context |
| path | path to the file to decode |
| options | bitmap loader options |
Definition at line 80 of file Bitmap.java.
|
inlinestatic |
Loads a bitmap from file.
| context | a Beatmup context |
| file | a file descriptor of the content to decode |
| outPadding | outPadding returned by BitmapFactory.decodeFileDescriptor |
| options | decoding options |
Definition at line 95 of file Bitmap.java.
|
inlinestatic |
Creates empty ARGB bitmap of specified size.
| context | a Beatmup context |
| width | width of the new bitmap in pixels |
| height | height of the new bitmap in pixels |
Definition at line 115 of file Bitmap.java.
|
inlinestatic |
Creates empty grayscale bitmap of specified size.
| context | a Beatmup context |
| width | width of the new bitmap in pixels |
| height | height of the new bitmap in pixels |
Definition at line 126 of file Bitmap.java.
|
inline |
Definition at line 133 of file Bitmap.java.
|
inline |
Destroys the native object.
After the native object is destroyed, its Java counterpart likely becomes unusable.
Reimplemented from Beatmup.Object.
Definition at line 138 of file Bitmap.java.
|
inline |
Reimplemented from Beatmup.Bitmap.
Definition at line 149 of file Bitmap.java.
|
private |
wrapped Android bitmap
Definition at line 33 of file Bitmap.java.