java.lang.IllegalStateException: Immutable bitmap passed to Canvas constructor

tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    How to create a mutable bitmap using picasso?

    Stack Overflow | 5 months ago | Ngoc Thang Pham
    java.lang.IllegalStateException: Immutable bitmap passed to Canvas constructor
  2. 0

    Immutable bitmap crash error

    Stack Overflow | 4 years ago | Yerry Huntry
    java.lang.IllegalStateException: Immutable bitmap passed to Canvas constructor

Root Cause Analysis

  1. java.lang.IllegalStateException

    Immutable bitmap passed to Canvas constructor

    at android.graphics.Canvas.<init>()
  2. Android Platform
    Canvas.<init>
    1. android.graphics.Canvas.<init>(Canvas.java:127)
    1 frame
  3. com.example.sev_user
    MapFragment$1.onBitmapLoaded
    1. com.example.sev_user.smarthome.gui.fragment.MapFragment$1.onBitmapLoaded(MapFragment.java:108)
    1 frame
  4. Picasso
    Picasso$1.handleMessage
    1. com.squareup.picasso.TargetAction.complete(TargetAction.java:36)
    2. com.squareup.picasso.Picasso.deliverAction(Picasso.java:557)
    3. com.squareup.picasso.Picasso.complete(Picasso.java:509)
    4. com.squareup.picasso.Picasso$1.handleMessage(Picasso.java:116)
    4 frames
  5. Android Platform
    ActivityThread.main
    1. android.os.Handler.dispatchMessage(Handler.java:99)
    2. android.os.Looper.loop(Looper.java:137)
    3. android.app.ActivityThread.main(ActivityThread.java:4950)
    3 frames
  6. Java RT
    Method.invoke
    1. java.lang.reflect.Method.invokeNative(Native Method)
    2. java.lang.reflect.Method.invoke(Method.java:511)
    2 frames
  7. Android
    ZygoteInit.main
    1. com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:997)
    2. com.android.internal.os.ZygoteInit.main(ZygoteInit.java:764)
    2 frames
  8. Android Platform
    NativeStart.main
    1. dalvik.system.NativeStart.main(Native Method)
    1 frame