Dear developers,
I found an inefficient API, setImageURI(), is used in kontalk.
For setImageURI(), Google says this:
" This does Bitmap reading and decoding on the UI thread, which can cause a latency hiccup. If that's a concern, consider using setImageDrawable(android.graphics.drawable.Drawable) or setImageBitmap(android.graphics.Bitmap) and BitmapFactory instead. "
I noticed that in the following code, setImageURI() is used:
de.hdodenhof.circleimageview.CircleImageView: void setImageURI(),
Do you think the use of setImageURI() will affect performance? If yes, maybe we should move Bitmap reading and decoding to a background thread.
Thanks.
Hello and thanks for reporting.
The method you mentioned belongs to a third-party library we use, and Kontalk doesn't use it anyway, we set the image by means of an already allocated drawable or bitmap.
Dear developers, I found an inefficient API, setImageURI(), is used in kontalk. For setImageURI(), Google says this: " This does Bitmap reading and decoding on the UI thread, which can cause a latency hiccup. If that's a concern, consider using setImageDrawable(android.graphics.drawable.Drawable) or setImageBitmap(android.graphics.Bitmap) and BitmapFactory instead. "
I noticed that in the following code, setImageURI() is used: de.hdodenhof.circleimageview.CircleImageView: void setImageURI(),
Do you think the use of setImageURI() will affect performance? If yes, maybe we should move Bitmap reading and decoding to a background thread. Thanks.