Copyright Matus Chochlik. Distributed under the Boost Software License, Version 1.0. See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt
#ifndef OGLPLUS_EXAMPLE_RESOURCES_HPP // NOLINT(llvm-header-guard)
#define OGLPLUS_EXAMPLE_RESOURCES_HPP
class cube_program {
public:
void init(execution_context&, video_context&);
void clean_up(video_context&);
void set_projection(video_context&, const oglp::tmat<float, 4, 4, true>&);
void update(execution_context&, video_context&);
private:
radians_t<float> rad{0.F};
};
class cube_geometry {
public:
void init(execution_context&, video_context&);
void clean_up(video_context&);
void draw(video_context&);
static auto position_loc() noexcept {
}
static auto normal_loc() noexcept {
}
static auto tex_coord_loc() noexcept {
}
private:
oglp::owned_buffer_name positions;
oglp::owned_buffer_name normals;
oglp::owned_buffer_name tex_coords;
oglp::owned_buffer_name indices;
std::vector<oglp::shape_draw_operation> ops;
};
class cube_draw_buffers {
public:
void init(execution_context&, video_context&);
void clean_up(video_context&);
auto back_fbo() const noexcept {
}
auto front_tex_unit() const noexcept {
return objs.front().tex_unit;
}
auto side() const noexcept {
return tex_side;
}
void swap() {
objs.swap();
}
private:
struct _buffer_objects {
};
double_buffer<_buffer_objects> objs{};
};
}
#endif