@Beta public class GifOptions extends Object
BitmapFactory.Options| Constructor and Description |
|---|
GifOptions() |
| Modifier and Type | Method and Description |
|---|---|
void |
setInIsOpaque(boolean inIsOpaque)
Indicates whether the content is opaque.
|
void |
setInSampleSize(int inSampleSize)
If set to a value
> 1, requests the decoder to subsample the original
frames, returning a smaller frame buffer to save memory. |
public void setInSampleSize(int inSampleSize)
> 1, requests the decoder to subsample the original
frames, returning a smaller frame buffer to save memory. The sample size is
the number of pixels in either dimension that correspond to a single
pixel in the decoded bitmap. For example, inSampleSize == 4 returns
an image that is 1/4 the width/height of the original, and 1/16 the
number of pixels. Values outside range <1, 65635> are treated as 1.
Unlike BitmapFactory.Options.inSampleSize
values which are not powers of 2 are also supported.
Default value is 1.inSampleSize - the sample sizepublic void setInIsOpaque(boolean inIsOpaque)
Common usage is setting this to true when view where GIF is displayed is known to be non-transparent and its background is irrelevant.In such case even if GIF contains transparent areas, they will appear black.
See also GifTextureView.setOpaque(boolean).
Default value is false, which means that content can be transparent.
inIsOpaque - whether the content is opaque