Rename setAlphaFlags to setUnpremultipliedRequired
Bug: 135133301 Test: I48e49ee08ab1954eddf62ecae87942aeb128c10d There is never any reason to request OPAQUE. If the image is already opaque, using PREMUL or UNPREMUL has no effect. If the image is not opaque, the requesting OPAQUE is an error. This behavior is not helpful. In addition, this matches the Java API for android.graphics.ImageDecoder. Lastly, the old API was confusing for animated images. It is possible for the first frame to be opaque, while a later frame is not. Requesting OPAQUE seems reasonable for this image, until decoding the non-opaque frame, at which point the inconsistency shows. Having a setting of unpremul or not makes it obvious what will happen for the later frame. Change-Id: I3381582e27894e1072db9b8635f3762b801f5d69
Loading
Please register or sign in to comment