使用 harism page curl 库的 Page Curl 效果,页面背景显示为黑色边框而不是透明度。
Page Curl effect using harism page curl library, page background appears with black border in place of transparency.
您好,我正在使用 Harism 库来实现卷页效果
(https://github.com/harism/android_page_curl). The effect is working fine but my page background has some transparent part which appears black. I have tried the solution mentioned in github forum (https://github.com/harism/android_page_curl/issues/25), its works but after that curl is not working. You can check my query there as well. You can check the attached screen shot as well.
谢谢!
检查 CurlActivity 中的 setMargin() 函数使其为 0 ,0 .!
Comments these lines in the activity
r.left += border;
r.right -= border;
r.top += border;
r.bottom -= border;
r.left += ((r.width() - imageWidth) / 2) - border;
r.right = r.left + imageWidth + border + border;
r.top += ((r.height() - imageHeight) / 2) - border;
r.bottom = r.top + imageHeight + border + border;
replace this function in the CurlView Activity
public void setMargins(float left, float top, float right, float bottom) {
mRenderer.setMargins(left, top, right, bottom);
}
您好,我正在使用 Harism 库来实现卷页效果
(https://github.com/harism/android_page_curl). The effect is working fine but my page background has some transparent part which appears black. I have tried the solution mentioned in github forum (https://github.com/harism/android_page_curl/issues/25), its works but after that curl is not working. You can check my query there as well. You can check the attached screen shot as well.
谢谢!
检查 CurlActivity 中的 setMargin() 函数使其为 0 ,0 .!
Comments these lines in the activity
r.left += border;
r.right -= border;
r.top += border;
r.bottom -= border;
r.left += ((r.width() - imageWidth) / 2) - border;
r.right = r.left + imageWidth + border + border;
r.top += ((r.height() - imageHeight) / 2) - border;
r.bottom = r.top + imageHeight + border + border;
replace this function in the CurlView Activity
public void setMargins(float left, float top, float right, float bottom) {
mRenderer.setMargins(left, top, right, bottom);
}