2014-11-17 38 views
2

我有一個在屏幕上繪製一些形狀的應用程序。問題在於抗鋸齒功能不適用於使用Path繪製的形狀,但只能在縮放(縮放)之後使用。 另一方面,繪圖圓(即使在縮放後)也沒有問題。縮放工作正常,只是後來形狀不夠銳利。在畫布上縮放後在路徑上消除鋸齒

... 
// Matrix m = new Matrix(); 
// m.setValues(createMatrix()); 
// canvas.concat(m); 
//or 
canvas.scale(6.0f, 6.0f); // the upper code is used on real, but the same problem occures with this call 
... 
RectF oval = new RectF(x, y, x + width, y + height); 
currentPaint.setAntiAlias(true); 
canvas.drawOval(oval, currentPaint); 

currentPaint.setAntiAlias(true); 
canvas.drawPath(getPathOfShape(), currentPaint); 

有人可以幫助我嗎?

回答