[英]Android: How to implement Rotatable Semi-circular?
I want to rotate the semi-circular as the upper picture(maybe the view's backgroud). 我想将半圆形旋转为上方图片(可能是视图的背景)。 How to implement it? 如何执行呢?
It should be rotated by the gesture . 应该通过手势旋转它。 It maybe like the rotatable circular, but only display the half of the one. 它可能像可旋转的圆形,但仅显示一个圆形的一半。 I had implemented the rotatable circular using the matrix , but I have no idea about the semi-circular. 我已经使用矩阵实现了可旋转的圆形,但是对半圆形我一无所知。
I had solved the problem, like these: 我已经解决了这个问题,就像这样:
Rect rect = new Rect(0, 0, w, h/2);
canvas.clipRect(rect);
canvas.save();
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.