wasabeef / picasso-transformations

An Android transformation library providing a variety of image transformations for Picasso
Apache License 2.0
1.69k stars 238 forks source link

CropCircleTransformation creates an extra Bitmap #2

Closed pushbit closed 9 years ago

pushbit commented 9 years ago

I believe it's not necessary to create squaredBitmap. Instead, the BitmapShader can be given a Matrix that has setTranslate(-width, -height). This should accomplish the same thing that creating squaredBitmap does, shifting the viewport on source so that its centre is drawn into bitmap.

wasabeef commented 9 years ago

Hi.

Let's follow up on that issue.

pushbit commented 9 years ago

Created pull request #3 to resolve this.