Android翻页效果,电子书(10)
来源:未知 责任编辑:责任编辑 发表时间:2015-09-17 09:43 点击:次
this.mRotation = (float)(-this.mRotation * 180.0D / 3.141592653589793D);
return true;
}
private float firstHalfPageTurn(PointF pageDim, PointF pageTurnCorner, PointF oppositeCorner, float xPivot, float slope, float y) {
float width = pageDim.x;
float height = pageDim.y;
View child = this.mPage.getChildAt(0);
int innerOffsetX = child.getLeft() - this.mPage.getLeft();
int innerOffsetY = child.getTop() - this.mPage.getTop();
float y1 = height + y;
float x2 = (float)(2.0D * y / (slope + 1.0D / slope));
float y2 = height + x2 / slope;
float page_slope = (height - y2) / (x2 - this.mPivotX);
if ((this.mCorner & 0x1) != 0) {
x2 = width - x2;
page_slope = -page_slope;
}
if ((this.mCorner & 0x2) != 0) {
y1 = height - y1;
y2 = height - y2;
page_slope = -page_slope;
}
float x0 = xPivot;
float x1 = pageTurnCorner.x;
相关新闻>>
最新推荐更多>>>
- 发表评论
-
- 最新评论 更多>>