]> git.tdb.fi Git - libs/gl.git/blobdiff - source/glsl/spirv.h
Use standard fixed-size integer types
[libs/gl.git] / source / glsl / spirv.h
index c023adae9af3cc5e75a637298afc8f98fd244fc7..669342f36a5bb3297bb76ac8a9e8e74913d210bb 100644 (file)
@@ -1,5 +1,5 @@
-#ifndef MSP_GL_SL_SPIRV
-#define MSP_GL_SL_SPIRV
+#ifndef MSP_GL_SL_SPIRV_H_
+#define MSP_GL_SL_SPIRV_H_
 
 #include <map>
 #include <string>
@@ -30,7 +30,7 @@ private:
                char arg_types[5];
                char extension[13];
                Word opcode;
-               UInt8 arg_order[4];
+               std::uint8_t arg_order[4];
                Word capability;
                void (SpirVGenerator::*handler)(FunctionCall &, const std::vector<Id> &);
        };
@@ -80,6 +80,7 @@ private:
        std::map<Node *, Declaration> declared_ids;
        std::map<std::string, Id> declared_uniform_ids;
        std::map<TypeKey, Id> standard_type_ids;
+       std::map<Id, Id> image_type_ids;
        std::map<TypeKey, Id> array_type_ids;
        std::map<TypeKey, Id> pointer_type_ids;
        std::map<std::string, Id> function_type_ids;
@@ -149,6 +150,7 @@ private:
        virtual void visit(FunctionCall &);
        void visit_constructor(FunctionCall &, const std::vector<Id> &, bool);
        void visit_builtin_matrix_comp_mult(FunctionCall &, const std::vector<Id> &);
+       void visit_builtin_texture_query(FunctionCall &, const std::vector<Id> &);
        void visit_builtin_texture(FunctionCall &, const std::vector<Id> &);
        void visit_builtin_texel_fetch(FunctionCall &, const std::vector<Id> &);
        void visit_builtin_interpolate(FunctionCall &, const std::vector<Id> &);