Also make PassMap public since it's exposed through get_passes
return get_item(passes, tag);
}
+bool Technique::has_shaders() const
+{
+ for(PassMap::const_iterator i=passes.begin(); i!=passes.end(); ++i)
+ if(i->second.get_shader_program())
+ return true;
+ return false;
+}
+
Technique::Loader::Loader(Technique &t):
DataFile::CollectionObjectLoader<Technique>(t, 0)
void texture(const std::string &, const std::string &);
};
+public:
typedef std::map<Tag, RenderPass> PassMap;
+private:
PassMap passes;
public:
bool has_pass(const GL::Tag &) const;
const RenderPass &get_pass(const GL::Tag &) const;
const PassMap &get_passes() const { return passes; }
+ bool has_shaders() const;
};
} // namespace GL