Back to project page multidraw.
The source code is released under:
This source code is available under the following license: Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International Full listing here: http://creativecommons.org/licenses/by-nc-nd/...
If you think the Android project multidraw 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 cz.halt.multidraw.app; /*from w w w .j av a2s.c om*/ import android.graphics.Bitmap; import android.graphics.Canvas; import android.graphics.Color; import android.graphics.Paint; import android.graphics.RectF; /** * Created by Filip on 21. 4. 2014. */ public class ExampleDrawer { public static void drawBitmap(Bitmap bitmap, int width, int height) { Canvas c = new Canvas(bitmap); Paint p = new Paint(); p.setColor(Color.TRANSPARENT); c.drawRect(0, 0, width, height, p); p.setColor(Color.RED); c.drawRect(new RectF(0, 0, 100, 100), p); } }