Code Monkey home page Code Monkey logo

xamarin.arthurhub.android-image-cropper's People

Contributors

anthonynjuguna avatar gilles-leblanc avatar ian-hamlin avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

xamarin.arthurhub.android-image-cropper's Issues

Exception being throw by Image Cropper library

When targetting SDK level 28 or higher, calling CropImageView's SetCropShape with CropImageView.CropShape.Oval results in an java.lang.IllegalArgumentException: Invalid Region.Op - only INTERSECT and DIFFERENCE are allowed exception.

At:
at android.graphics.Canvas.checkValidClipOp(Canvas.java:779) at android.graphics.Canvas.clipPath(Canvas.java:1007) at com.theartofdev.edmodo.cropper.CropOverlayView.drawBackground(CropOverlayView.java:635) at com.theartofdev.edmodo.cropper.CropOverlayView.onDraw(CropOverlayView.java:579)

This was working correctly while targeting earlier SDK versions.

After a quick investigation this is because ArthurHub/Android-Image-Cropper 2.7.0 (which is used by the binding) uses Region.Op.XOR which isn't supported anymore.
https://github.com/ArthurHub/Android-Image-Cropper/blob/092a39533aa760472299a442773c7e2eee404de8/cropper/src/main/java/com/theartofdev/edmodo/cropper/CropOverlayView.java#L635

This has been fixed in the 2.8.0 version of the library and it is compatible with SDK level 28.
To fix this issue, the bindings would need to be updated to the 2.8.0 version.

I tried updating the bindings myself by forking the project, but I've run into the problem where most of the classes don't appear in the final binding or the api.xml file so it's not working.

Crop button missing

I am able to see the picture taken then the crop bound box appears but there is no "Crop Button". Thus, only way to return to invoking activity is by pressing the back key which cancels the process. Such a good library but can't be used because of this!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.