diff options
author | Konstantin Käfer <mail@kkaefer.com> | 2018-05-04 01:31:43 +0200 |
---|---|---|
committer | Lauren Budorick <lauren@mapbox.com> | 2018-05-03 16:31:43 -0700 |
commit | c3346f473ac7e3d49219c8dbc381d92f8fe3f017 (patch) | |
tree | 7e7d1c1569c849192209b0c5f5a58ef7736896a1 /src/mbgl/gl/context.hpp | |
parent | f6da3ba9be27ff9b279730603c517c4cb5e57007 (diff) | |
download | qtlocation-mapboxgl-c3346f473ac7e3d49219c8dbc381d92f8fe3f017.tar.gz |
[core] Don't crash when attribute count is exceeded
Diffstat (limited to 'src/mbgl/gl/context.hpp')
-rw-r--r-- | src/mbgl/gl/context.hpp | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/mbgl/gl/context.hpp b/src/mbgl/gl/context.hpp index 67624288e2..d95311115e 100644 --- a/src/mbgl/gl/context.hpp +++ b/src/mbgl/gl/context.hpp @@ -226,7 +226,7 @@ public: State<value::BindVertexBuffer> vertexBuffer; State<value::BindVertexArray, const Context&> bindVertexArray { *this }; - VertexArrayState globalVertexArrayState { UniqueVertexArray(0, { this }), *this }; + VertexArrayState globalVertexArrayState { UniqueVertexArray(0, { this }) }; State<value::PixelStorePack> pixelStorePack; State<value::PixelStoreUnpack> pixelStoreUnpack; @@ -239,6 +239,8 @@ public: #endif // MBGL_USE_GLES2 bool supportsHalfFloatTextures = false; + const uint32_t maximumVertexBindingCount; + static constexpr const uint32_t minimumRequiredVertexBindingCount = 8; private: State<value::StencilFunc> stencilFunc; |