Closed rednels closed 6 years ago
@rednels
Can you give me the stacktrace so I can debug what the problem is? I am not able to reproduce it. Also, when you drag the image out of the screen, until the image is re-adjusted to the screen, the cropper won't crop the image. cropBitmap()
will return null. Maybe that's why it's crashing.
Closing the issue as invalid.
Sorry for late.
errer log:
Process: com.fenctose.imagecropper, PID: 31352
Theme: themes:{}
java.lang.RuntimeException: An error occurred while executing doInBackground()
at android.os.AsyncTask$3.done(AsyncTask.java:309)
at java.util.concurrent.FutureTask.finishCompletion(FutureTask.java:354)
at java.util.concurrent.FutureTask.setException(FutureTask.java:223)
at java.util.concurrent.FutureTask.run(FutureTask.java:242)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:234)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
at java.lang.Thread.run(Thread.java:818)
Caused by: java.lang.IllegalArgumentException: x must be >= 0
at android.graphics.Bitmap.checkXYSign(Bitmap.java:364)
at android.graphics.Bitmap.createBitmap(Bitmap.java:684)
at com.fenchtose.nocropper.CropperImageView.getCroppedBitmap(CropperImageView.java:812)
at com.fenchtose.nocropper.CropperImageView.cropBitmap(CropperImageView.java:679)
at com.fenchtose.nocropper.CropperTask.doInBackground(CropperTask.java:24)
at com.fenchtose.nocropper.CropperTask.doInBackground(CropperTask.java:6)
at android.os.AsyncTask$2.call(AsyncTask.java:295)
at java.util.concurrent.FutureTask.run(FutureTask.java:237)
at android.os.AsyncTask$SerialExecutor$1.run(AsyncTask.java:234)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1113)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:588)
at java.lang.Thread.run(Thread.java:818)
error screen record : here
Thanks for the crash log. I'll look into it.
Fixed in 0.2.1
I did the following steps:
after that, it crashes.
update:
it will crash after i scale it smaller but not to fit center. steps: