title: How to draw bitmap with rounded corners?
body: <p>I had the image that i get from url and put in the bitmap. Now I need to draw this bitmap with canvas and it required to be with rounded corners.</p>
  
  <p>P.S</p>
  
  <p>ImageView is not option here for me because there would be a lot of such images that should be drawn.  </p>
  
  <pre><code>var url = "someurl"
  var mediaMetadataRetriever = MediaMetadataRetriever()
  mediaMetadataRetriever.setDataSource(url, HashMap&lt;String, String&gt;())
  var frame:Bitmap = mediaMetadataRetriever.getFrameAtTime(time)          // get image from url 
  var rect = Rect(left, top, right, bottom)                               // coordinates for bitmap
  canvas.drawBitmap(frame, null, rect, paint)
  </code></pre>