optionalTransform
Applies the given Transformation for Bitmaps to the default types (Bitmap, android.graphics.drawable.BitmapDrawable, and ) and ignores unknown types.
This will override previous calls to dontTransform.
See also
Parameters
Any Transformation for Bitmaps.
Applies the given Transformation for any decoded resource of the given type and allows unknown resource types to be ignored.
Users can apply different transformations for each resource class. Applying a for a resource type that already has a Transformation will override the previous call.
If any calls are made to the non-optional transform methods, then attempting to transform an unknown resource class will throw an exception. To allow unknown types, users must always call the optional version of each method.
This will override previous calls to dontTransform.
Parameters
The type of resource to transform.
The Transformation to apply.