android: drop HAL_PIXEL_FORMAT_RGBA_{5551,4444}
authorEmil Velikov <emil.l.velikov@gmail.com>
Sun, 27 Jul 2014 02:27:08 +0000 (03:27 +0100)
committerEmil Velikov <emil.l.velikov@gmail.com>
Tue, 12 Aug 2014 23:46:55 +0000 (00:46 +0100)
Upstream Android (system/core) has dropped these formats with commit
6bac41f1bf9(get rid of HAL pixelformats 5551 and 4444) yet does not
mention why.

These formats never really worked so we're safe to drop them as well.

Identical commit is available in the android-x86 external/mesa repo

    commit 06a2d36edcd1e2247440e5800e6bf3028f37aee6
    Author: Chih-Wei Huang <cwhuang@linux.org.tw>
    Date:   Wed Sep 25 01:16:57 2013 +0800

        android: get rid of HAL pixelformats 5551 and 4444

Cc: "10.1 10.2" <mesa-stable@lists.freedesktop.org>
Signed-off-by: Emil Velikov <emil.l.velikov@gmail.com>
src/egl/drivers/dri2/platform_android.c
src/gallium/state_trackers/egl/android/native_android.cpp

index d1f597c66b33f18c5506f222a3909bd0652dfffe..61a99ba68f1e446aa925f16debdafde672b0709d 100644 (file)
@@ -54,8 +54,6 @@ get_format_bpp(int native)
       bpp = 3;
       break;
    case HAL_PIXEL_FORMAT_RGB_565:
-   case HAL_PIXEL_FORMAT_RGBA_5551:
-   case HAL_PIXEL_FORMAT_RGBA_4444:
       bpp = 2;
       break;
    default:
@@ -371,8 +369,6 @@ dri2_create_image_android_native_buffer(_EGLDisplay *disp, _EGLContext *ctx,
       format = __DRI_IMAGE_FORMAT_XBGR8888;
       break;
    case HAL_PIXEL_FORMAT_RGB_888:
-   case HAL_PIXEL_FORMAT_RGBA_5551:
-   case HAL_PIXEL_FORMAT_RGBA_4444:
       /* unsupported */
    default:
       _eglLog(_EGL_WARNING, "unsupported native buffer format 0x%x", buf->format);
index 8620ed865781f48c9960b3d96796ee67f72ade96..889b64422850e9d813a98e310a25f227d534ea2f 100644 (file)
@@ -147,10 +147,6 @@ get_pipe_format(int native)
    case HAL_PIXEL_FORMAT_BGRA_8888:
       fmt = PIPE_FORMAT_B8G8R8A8_UNORM;
       break;
-   case HAL_PIXEL_FORMAT_RGBA_5551:
-      /* fmt = PIPE_FORMAT_A1B5G5R5_UNORM; */
-   case HAL_PIXEL_FORMAT_RGBA_4444:
-      /* fmt = PIPE_FORMAT_A4B4G4R4_UNORM; */
    default:
       ALOGE("unsupported native format 0x%x", native);
       fmt = PIPE_FORMAT_NONE;