title: Notification LargeIcon setting on Center position | Android Kotlin
body: <p>Below is My Code i set largeIcon in Notification(as in Image below) but icon is not able to set in center of Icon View. I used Below code but has not fixed my error. Thanks in Advance.</p>
  
  <pre><code>var mBuilder = NotificationCompat.Builder(this)
  mBuilder.setLargeIcon(getCircleBitmap(it))
  </code></pre>
  
  <p>=========================</p>
  
  <pre><code>private fun getCircleBitmap(bitmap: Bitmap): Bitmap {
      val output = Bitmap.createBitmap(96,96, Bitmap.Config.ARGB_8888)
      val canvas = Canvas(output)
      val color = Color.parseColor("#f1f2f5")
      val paint = Paint()
      val rect = Rect(0, 0, 96, 96)
      val rectF = RectF(rect)
      paint.isAntiAlias = true
      canvas.drawARGB(0, 0, 0, 0)
      paint.color = color
      canvas.drawOval(rectF, paint)
      paint.xfermode = PorterDuffXfermode(PorterDuff.Mode.SRC_IN)
      canvas.drawBitmap(bitmap, rect, rect, paint)
      bitmap.recycle()
      return output
  }
  </code></pre>
  
  <p><a href="https://i.stack.imgur.com/VctPm.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/VctPm.png" alt="enter image description here"></a></p>