Android Canvas.ClipPath -
i wanna clip circle region, somehow got rectangle, not circle. , here code:
protected boolean drawchild(canvas canvas, view child, long drawtime) { mrevealpath.reset(); mrevealpath.addcircle(mcenterx, mcentery, mrevealradius, path.direction.cw); final int state = canvas.save(); canvas.clippath(mrevealpath); boolean isinvalidate = super.drawchild(canvas, child, drawtime); canvas.restoretocount(state); return isinvalidate; }
i add linearlayout textview in child test.
Comments
Post a Comment