Mark DefaultImageDecoder.BitmapDecoder as @VisibleForTesting

It seems likely we will define a new "image decoder" interface that
returns `ListenableFuture<Bitmap>`, and naming that will be
hard/annoying if we need to keep this interface working too.

It's also not really clear what a non-test implementation of this
interface would be expected to do, since `DefaultImageDecoder` is
documented to always decode using `BitmapFactory`.

#minor-release

PiperOrigin-RevId: 569206325
(cherry picked from commit d50f662b10fd8e8a36fb3ebde22f044a8f134100)
This commit is contained in:
ibaker 2023-09-28 09:30:57 -07:00 committed by Marc Baechinger
parent 6066833081
commit eb9d9457b6

View File

@ -15,6 +15,7 @@
*/
package androidx.media3.exoplayer.image;
import static androidx.annotation.VisibleForTesting.PRIVATE;
import static androidx.media3.common.util.Assertions.checkArgument;
import static androidx.media3.common.util.Assertions.checkNotNull;
import static androidx.media3.common.util.Assertions.checkState;
@ -24,6 +25,7 @@ import android.graphics.Bitmap;
import android.graphics.BitmapFactory;
import android.graphics.Matrix;
import androidx.annotation.Nullable;
import androidx.annotation.VisibleForTesting;
import androidx.exifinterface.media.ExifInterface;
import androidx.media3.common.C;
import androidx.media3.common.Format;
@ -51,6 +53,7 @@ public final class DefaultImageDecoder
implements ImageDecoder {
/** A functional interface for turning byte arrays into bitmaps. */
@VisibleForTesting(otherwise = PRIVATE)
public interface BitmapDecoder {
/**