Tatooine
atomiccounterbuffer.h
Go to the documentation of this file.
1#ifndef TATOOINE_GL_ATOMIC_COUNTER_BUFFER_H
2#define TATOOINE_GL_ATOMIC_COUNTER_BUFFER_H
3//==============================================================================
4#include <initializer_list>
5#include <iostream>
6#include <vector>
10//==============================================================================
11namespace tatooine::gl {
12//==============================================================================
14 : public buffer<GL_ATOMIC_COUNTER_BUFFER, GLuint> {
15 public:
19
21
22 atomiccounterbuffer(const this_type& other) = default;
23 atomiccounterbuffer(this_type&& other) noexcept = default;
24
25 auto operator=(const this_type& other) -> atomiccounterbuffer& = default;
26 auto operator=(this_type&& other) noexcept -> atomiccounterbuffer& = default;
27
29
33 DLL_API explicit atomiccounterbuffer(const std::vector<GLuint>& data,
35 DLL_API atomiccounterbuffer(std::initializer_list<GLuint>&& data);
36
37 DLL_API auto set_all_to(GLuint val) -> void;
38 auto to_zero() { set_all_to(0); }
39 DLL_API auto bind(GLuint i) const -> void;
40 DLL_API static auto unbind(GLuint i) -> void;
41};
42//==============================================================================
43} // namespace tatooine::gl
44//==============================================================================
45#endif
Definition: atomiccounterbuffer.h:14
atomiccounterbuffer(const this_type &other)=default
DLL_API atomiccounterbuffer(buffer_usage usage=default_usage)
DLL_API atomiccounterbuffer(GLsizei n, buffer_usage usage=default_usage)
auto operator=(this_type &&other) noexcept -> atomiccounterbuffer &=default
atomiccounterbuffer(this_type &&other) noexcept=default
DLL_API atomiccounterbuffer(const std::vector< GLuint > &data, buffer_usage usage=default_usage)
static DLL_API auto unbind(GLuint i) -> void
DLL_API auto bind(GLuint i) const -> void
auto operator=(const this_type &other) -> atomiccounterbuffer &=default
DLL_API auto set_all_to(GLuint val) -> void
DLL_API atomiccounterbuffer(std::initializer_list< GLuint > &&data)
DLL_API atomiccounterbuffer(GLsizei n, GLuint initial, buffer_usage usage=default_usage)
static const auto default_usage
Definition: atomiccounterbuffer.h:18
auto to_zero()
Definition: atomiccounterbuffer.h:38
buffer base class for each of the OpenGL buffer types
Definition: buffer.h:405
Definition: ansiformat.h:6
buffer_usage
Definition: buffer_usage.h:8