title: How to rotate image using glide library? (Like in picasso)
body: <p>I am trying to rotate the image using glide library. Previously, was able to do with Picasso (due to an issue, I moved to glide). Now I am missing rotate functionality in glide. I tried using transformations but didn't work.</p>
  
  <p>// Code used</p>
  
  <pre><code>public class MyTransformation extends BitmapTransformation {
  
  private float rotate = 0f;
  
  public MyTransformation(Context context, float rotate) {
      super(context);
      this.rotate = rotate;
  }
  
  @Override
  protected Bitmap transform(BitmapPool pool, Bitmap toTransform,
                             int outWidth, int outHeight) {
      return rotateBitmap(toTransform, rotate);
  }
  
  @Override
  public String getId() {
      return "com.example.helpers.MyTransformation";
  }
  
  public static Bitmap rotateBitmap(Bitmap source, float angle)
  {
      Matrix matrix = new Matrix();
      matrix.postRotate(angle);
      return Bitmap.createBitmap(source, 0, 0, source.getWidth(), source.getHeight(), matrix, true);
  }
  }
  </code></pre>
  
  <p>// glide</p>
  
  <pre><code>Glide.with(context)
                  .load(link)
                  .asBitmap()
                  .transform(new MyTransformation(context, 90))
                  .into(imageView);
  </code></pre>
  
  <p>Thanks in advance.</p>