ImageIndex: Consolidate layer/cube face.

In terms of the Texture or Image resource, a cube face
refers to a layer of a 2D texture. This layer has a special
meaning for cube textures, but it is represented as a layer
with a layer index. Cube array textures are no different,
they just use a different indexing scheme for the array
layers.

This also cleans up the ImageIndex helper to have a class
structure with private data, and cleans up a few cases to
use generic Make functions and iterators where they were
setting properties of the index directly.

This will make it easier to have ImageIndexes address
entire levels of a Cube map in the future, and makes the
layer count logic in Vulkan cleaner.

Bug: angleproject:2318
Change-Id: Iea9842e233f974a9896282ca224cb001f7882bd1
Reviewed-on: https://chromium-review.googlesource.com/987525
Reviewed-by: Luc Ferron <lucferron@chromium.org>
Reviewed-by: Yuly Novikov <ynovikov@chromium.org>
Commit-Queue: Jamie Madill <jmadill@chromium.org>
diff --git a/src/libANGLE/Framebuffer.h b/src/libANGLE/Framebuffer.h
index 4e99a89..6342163 100644
--- a/src/libANGLE/Framebuffer.h
+++ b/src/libANGLE/Framebuffer.h
@@ -40,13 +40,13 @@
 class Context;
 class ContextState;
 class Framebuffer;
+class ImageIndex;
 class Renderbuffer;
 class State;
 class Texture;
 class TextureCapsMap;
 struct Caps;
 struct Extensions;
-struct ImageIndex;
 struct Rectangle;
 
 class FramebufferState final : angle::NonCopyable