Back to project page feup-lpoo-android-tower-defense.
The source code is released under:
MIT License
If you think the Android project feup-lpoo-android-tower-defense listed in this page is inappropriate, such as containing malicious code/tools or violating the copyright, please email info at java2s dot com, thanks.
package pt.up.fe.lpoo.framework.implementation; //from ww w .j a va2 s .c o m import pt.up.fe.lpoo.framework.Image; import pt.up.fe.lpoo.framework.Graphics.ImageFormat; import android.graphics.Bitmap; /** * Information about the implementation of the framework can be found at * http://www.kilobolt.com/day-6-the-android-game-framework-part-ii.html */ public class AndroidImage implements Image { Bitmap bitmap; ImageFormat format; public AndroidImage(Bitmap bitmap, ImageFormat format) { this.bitmap = bitmap; this.format = format; } @Override public int getWidth() { return bitmap.getWidth(); } @Override public int getHeight() { return bitmap.getHeight(); } @Override public ImageFormat getFormat() { return format; } @Override public void dispose() { bitmap.recycle(); } }