Android翻页效果,电子书(13)
来源:未知 责任编辑:责任编辑 发表时间:2015-09-17 09:43 点击:次
float y1 = 0.0F;
float x1 = width - (height + width) * (width - this.mPivotX) / width;
float x3 = (float)(2.0D * y / (slope + 1.0D / slope));
float y3 = height + x3 / slope;
float page_slope = (height - y3) / (x3 - this.mPivotX);
float b = height - x1 * page_slope;
float x2 = (float)((-y - b) / (page_slope + 1.0D / page_slope));
float y2 = (x1 - x2) * page_slope;
if ((this.mCorner & 0x1) != 0) {
x1 = width - x1;
x2 = width - x2;
x3 = width - x3;
page_slope = -page_slope;
}
if ((this.mCorner & 0x2) != 0) {
y1 = height - y1;
y2 = height - y2;
y3 = height - y3;
page_slope = -page_slope;
}
float x0 = xPivot;
this.mForegroundPath.moveTo(xOffset + x1, yOffset + y1);
this.mForegroundPath.lineTo(xOffset + oppositeCorner.x, yOffset + oppositeCorner.y);
this.mForegroundPath.lineTo(xOffset + oppositeCorner.x, yOffset + pageTurnCorner.y);
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 更多>>