private static Bitmap.Config[] getInConfigs(Bitmap.Config requested) {
        switch (requested) {
            case ARGB_8888:
                return ARGB_8888_IN_CONFIGS;
            case RGB_565:
                return RGB_565_IN_CONFIGS;
            case ARGB_4444:
                return ARGB_4444_IN_CONFIGS;
            case ALPHA_8:
                return ALPHA_8_IN_CONFIGS;
            default:
                return new Bitmap.Config[] { requested };
        }
    }
Keys {@link Bitmap Bitmaps} using both {@link Bitmap#getAllocationByteCount()} and
the {@link Bitmap.Config} returned from {@link Bitmap#getConfig()}.

<p>
    Using both the config and the byte size allows us to safely re-use a greater variety of
    {@link Bitmap Bitmaps}, which increases the hit rate of the pool and therefore the performance
    of applications. This class works around #301 by only allowing re-use of {@link Bitmap Bitmaps}
    with a matching number of bytes per pixel.
</p>
core/src/main/java/com/bumptech/glide/load/engine/bitmap_recycle/SizeConfigStrategy.java