Reputation: 357
What is the different between them?
where and why we need to convert from one type to another?
Upvotes: 8
Views: 6049
Reputation: 267734
Bitmap actually refers to the Images like png, jpg, etc.
ImageView is a view that is used to display an image. You can call
imageView.setImageBitmap(your_bitmap) // displays your bitmap
imageView.setImageDrawable(your_drawable) // displays your drawable
imageView.setImageResource(R.drawable.your_drawable_file) // displays drawable from resource
imageView.setImageURI(Uri_here) // displays from Uri
Drawable is something that can be drawn like layout, vector, image, etc.
Upvotes: 0