#pragma once #include namespace charcoal { namespace builtin { template class Pipeline : public charcoal::Pipeline { public: void render() override { prepare_opengl(); charcoal::Pipeline::m_shader_program.use(); prepare_uniforms(); for (auto iter = charcoal::Pipeline::m_batches.begin(); iter != charcoal::Pipeline::m_batches.end(); ++iter) { BatchType* batch = *iter; batch->render(); } } protected: virtual void prepare_opengl() {}; virtual void prepare_uniforms() {}; }; } }