X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Freflectdata.h;h=a89e7fcf2972c973c89a803501ebbd6739f7f11c;hb=e98188ff6c9bba9761b71f2a69f3be7eb89ba3da;hp=33ef1799ea469805832af7d9752a8888cf555036;hpb=ba55832910f04b90695da360b5889fa85e83c1e1;p=libs%2Fgl.git diff --git a/source/core/reflectdata.h b/source/core/reflectdata.h index 33ef1799..a89e7fcf 100644 --- a/source/core/reflectdata.h +++ b/source/core/reflectdata.h @@ -14,6 +14,12 @@ Reflection data for shader programs. */ struct ReflectData { + enum + { + DEFAULT_BLOCK = -1, + PUSH_CONSTANT = -2 + }; + typedef unsigned LayoutHash; struct UniformBlockInfo; @@ -38,7 +44,7 @@ struct ReflectData { std::string name; unsigned data_size = 0; - int bind_point = -1; + int bind_point = DEFAULT_BLOCK; std::vector uniforms; LayoutHash layout_hash = 0; @@ -49,7 +55,7 @@ struct ReflectData struct AttributeInfo { std::string name; - unsigned location = -1; + int location = -1; unsigned array_size = 0; DataType type = VOID; }; @@ -59,6 +65,7 @@ struct ReflectData LayoutHash layout_hash = 0; std::vector attributes; unsigned n_clip_distances = 0; + unsigned n_descriptor_sets = 0; void update_layout_hash(); };