java.lang.Object | |
↳ | com.facebook.imagepipeline.transcoder.SimpleImageTranscoder |
Image transcoder using only the Android API. Clients can use this if they don't want to use the native implementation. This image transcoder requires more memory.
Public Constructors | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
SimpleImageTranscoder(boolean resizingEnabled, int maxBitmapSize) |
Public Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
boolean |
canResize(EncodedImage encodedImage, RotationOptions rotationOptions, ResizeOptions resizeOptions)
Whether the input image is resized to make subsequent decodings faster.
| ||||||||||
boolean |
canTranscode(ImageFormat imageFormat)
Whether the input
ImageFormat can be transcoded by the image transcoder. | ||||||||||
String |
getIdentifier()
Gets the identifier of the image transcoder.
| ||||||||||
ImageTranscodeResult |
transcode(EncodedImage encodedImage, OutputStream outputStream, RotationOptions rotationOptions, ResizeOptions resizeOptions, ImageFormat outputFormat, Integer quality)
Transcodes an image to match the specified rotation and resize options.
|
[Expand]
Inherited Methods | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
From class
java.lang.Object
| |||||||||||
From interface
com.facebook.imagepipeline.transcoder.ImageTranscoder
|
Whether the input image is resized to make subsequent decodings faster.
encodedImage | The EncodedImage that will be transcoded. |
---|---|
rotationOptions | The RotationOptions used when transcoding the image. |
resizeOptions | The ResizeOptions used when transcoding the image. |
Whether the input ImageFormat
can be transcoded by the image transcoder.
imageFormat | The ImageFormat that will be transcoded. |
---|
Gets the identifier of the image transcoder. This is mostly used for logging purposes.
Transcodes an image to match the specified rotation and resize options. The most common-use case is to create a resized version of an input image to make subsequent decodings faster.
encodedImage | The EncodedImage that will be transcoded. |
---|---|
outputStream | The OutputStream where the newly created image is written to. |
rotationOptions | The RotationOptions used when transcoding the image. |
resizeOptions | The ResizeOptions used when transcoding the image. |
outputFormat | The desired ImageFormat of the newly created image. If this is null
the same format as the input image will be used. |
quality | The desired quality of the newly created image. If this is null, the default quality of the transcoder will be applied. |
ImageTranscodeResult
generated when encoding the image.