Comments (7)
classic off-by-1 bug :)
fixed in v1.2.5
from android-image-cropper.
Thank you very much for your efficiency!
But some coordinates still manifests the bug that the height is greater than the width:
As I understand it, in some cases, to the height of 1px flops
Actual crop rect: Rect(419, 626 - 2847, 3053)
Actual crop rect.left: 419
Actual crop rect.top: 626
Actual crop rect.right: 2847
Actual crop rect.bottom: 3053
Actual crop rect.width: 2428
Actual crop rect.height: 2427
Actual crop rect: Rect(0, 321 - 2847, 3167)
Actual crop rect.left: 0
Actual crop rect.top: 321
Actual crop rect.right: 2847
Actual crop rect.bottom: 3167
Actual crop rect.width: 2847
Actual crop rect.height: 2846
3053 - 626 = 2427 - height
2847 - 419 = 2428 - width
from android-image-cropper.
are you sure you updated to 1.2.5?
I'm unable to reproduce it now.
from android-image-cropper.
Yes I updated to version 1.2.5.
Also cleared the project, deleted from the phone app and reinstalled everything.
Previously, it was the inaccuracy of 1-2 pixels. Now only 1 pixel.
The bug manifests itself only in portrait mode.
My template:
<com.theartofdev.edmodo.cropper.CropImageView xmlns:custom="http://schemas.android.com/apk/res-auto"
android:id="@+id/cropImageView"
android:layout_width="0dp"
android:layout_height="match_parent"
android:layout_weight="1"
android:background="@drawable/rect_cropper"
custom:cropInitialCropWindowPaddingRatio="0"
custom:cropMinCropResultHeightPX="700"
custom:cropMinCropResultWidthPX="700"
custom:cropScaleType="fitCenter" />
from android-image-cropper.
And not just in the horizontal position of a difference there is in 2 pixel:
Actual crop rect: Rect(0, 0 - 2850, 2848)
Actual crop rect.left: 0
Actual crop rect.top: 0
Actual crop rect.right: 2850
Actual crop rect.bottom: 2848
Actual crop rect.width: 2850
Actual crop rect.height: 2848
from android-image-cropper.
sorry, totally missed that it can be off by 2 =/
please try 1.2.6, let me know if it works
from android-image-cropper.
Everything works fine! Thank you very much for your help!
from android-image-cropper.
Related Issues (20)
- error in manifest about CropImageActivity HOT 1
- Native crash in "libc.so tgkill" at SupportRequestManagerFragment HOT 1
- activity is not found in project or libraies AndroidManifest.xml HOT 1
- The camera not working above android version 11.. HOT 5
- Start Activity with request code HOT 1
- RLÒP?PPÒÌUIUYYYTTTTTRRRÀ¹³⁴¹1L2J⁴⁶⁶⁷⁸⁹⁰=/ HOT 1
- The bottom of the cropped image is not fully displayed HOT 1
- Class referenced in the manifest was not found in the project or the libraries HOT 2
- The dependencies are not found in android 12 HOT 1
- Camera Issues (Android 11 and 12) HOT 6
- Cropped picture clarity is so poor HOT 3
- Could not find com.hendraanggrian.appcompat:socialview:0.3. Required by: project :app Search in build.gradle files HOT 2
- pick from google drive HOT 1
- Not showing any other options but opening camera only HOT 1
- i cant use the crop image !! HOT 1
- Unable to use images from camera HOT 3
- Error while importing HOT 6
- Veracode - vulnerabilities
- i can't build HOT 1
- cant use preview camera view on this cropper
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from android-image-cropper.