Use immutable level count in gl::Texture.

Instead of storing a binary flag indicating if we've created
immutable storage, store a level count. This indicates if or if
not we've created immutable storage, as well as avoiding the
call to the native storage to return the level count.

BUG=angle:781

Change-Id: I08a6bd086d00ddf3255262a7711628be5212b4b7
Reviewed-on: https://chromium-review.googlesource.com/222921
Tested-by: Jamie Madill <jmadill@chromium.org>
Reviewed-by: Brandon Jones <bajones@chromium.org>
diff --git a/src/libGLESv2/libGLESv2.cpp b/src/libGLESv2/libGLESv2.cpp
index bd7774a..64503fc 100644
--- a/src/libGLESv2/libGLESv2.cpp
+++ b/src/libGLESv2/libGLESv2.cpp
@@ -3165,7 +3165,7 @@
                 context->recordError(gl::Error(GL_INVALID_ENUM));
                 return;
             }
-            *params = texture->immutableLevelCount();
+            *params = static_cast<GLint>(texture->immutableLevelCount());
             break;
           case GL_TEXTURE_USAGE_ANGLE:
             *params = texture->getUsage();