开发者

Android Center Oversized Bitmap On Canvas

I have a bitmap that has greater开发者_运维知识库 dimensions than the canvas to which it will be drawn. Can anyone suggest a method to center this bitmap on the canvas, i.e. the center point of the bitmap should overlap with the center point of the canvas?


Canvas.drawBitmap(Bitmap bitmap, float left, float top, Paint paint) with left and top new coordinates outside of the canvas, or using Canvas.drawBitmap (Bitmap bitmap, Rect src, RectF dst, Paint paint) with src null

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜