X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Fcore%2Fprogram.h;h=dab249f47684546f42cc64b2c0436f538c434126;hb=df9119a9bf2d348a513c515ed92953353da97b54;hp=fd1c1ae09d10e12943ca13140339b96d59cd5ecf;hpb=38712d8ecc57d043a2419ffbaeeb57f7a6586f14;p=libs%2Fgl.git diff --git a/source/core/program.h b/source/core/program.h index fd1c1ae0..dab249f4 100644 --- a/source/core/program.h +++ b/source/core/program.h @@ -13,8 +13,10 @@ namespace Msp { namespace GL { /** -A complete shader program. Programs can be assembled of individual Shaders or -generated with a set of standard features. +A shader program consisting of one or more stages. + +Programs are created from Modules. Specialization values can be applied to +customize behaviour of the module. */ class Program: public ProgramBackend { @@ -62,6 +64,8 @@ private: void collect_uniforms(const SpirVModule &, const std::map &); void collect_block_uniforms(const SpirVModule::Structure &, const std::string &, unsigned, const std::map &, std::vector &); void collect_attributes(const SpirVModule &); + void collect_builtins(const SpirVModule &); + void collect_builtins(const SpirVModule::Structure &); public: ReflectData::LayoutHash get_uniform_layout_hash() const { return reflect_data.layout_hash; } @@ -76,6 +80,7 @@ public: const std::vector &get_attributes() const { return reflect_data.attributes; } const ReflectData::AttributeInfo &get_attribute_info(const std::string &) const; int get_attribute_location(const std::string &) const; + unsigned get_n_clip_distances() const { return reflect_data.n_clip_distances; } using ProgramBackend::set_debug_name; };