Add layered image support to gralloc1 hal.

Bug: 31686534
Test: manual
Change-Id: I6442413072cef2a19abd3aacddf964ca1f4e7481
diff --git a/graphics/allocator/2.0/IAllocator.hal b/graphics/allocator/2.0/IAllocator.hal
index 8accb82..ff08a7e 100644
--- a/graphics/allocator/2.0/IAllocator.hal
+++ b/graphics/allocator/2.0/IAllocator.hal
@@ -26,11 +26,16 @@
          * is supported.
          */
         TEST_ALLOCATE = 1,
+
+        /*
+         * layerCount must be 1 unless this capability is supported.
+         */
+        LAYERED_BUFFERS = 2,
     };
 
     struct BufferDescriptorInfo {
         /*
-         * The width specifies how many columns of pixels should be in the
+         * The width specifies how many columns of pixels must be in the
          * allocated buffer, but does not necessarily represent the offset in
          * columns between the same column in adjacent rows. The rows may be
          * padded.
@@ -38,11 +43,16 @@
         uint32_t width;
 
        /*
-        * The height specifies how many rows of pixels should be in the
+        * The height specifies how many rows of pixels must be in the
         * allocated buffer.
         */
         uint32_t height;
 
+       /*
+        * The number of image layers that must be in the allocated buffer.
+        */
+        uint32_t layerCount;
+
         /* Buffer pixel format. */
         PixelFormat format;