namespace GL {
/**
-Describes a single attachment of a framebuffer. The values are bitfields laid
-as follows:
+Describes a single attachment of a framebuffer, including the type and index
+of the attachment point and the format of the attached texture.
+
+The values are bitfields laid as follows:
nnnn nn_f _sss _ccc
│ │ │ └╴Number of components
└────────────╴Attachment index
This information is presented for internal documentation purposes only; it is
-inadvisable for programs to rely on it.
+inadvisable for applications to rely on it.
*/
enum FrameAttachment: std::uint16_t
{
private:
enum { MAX_ATTACHMENTS = 7 };
- std::uint8_t count;
- std::uint8_t samples;
+ std::uint8_t count = 0;
+ std::uint8_t samples = 0;
FrameAttachment attachments[MAX_ATTACHMENTS];
public:
- FrameFormat();
+ FrameFormat() = default;
FrameFormat(FrameAttachment);
FrameFormat operator,(FrameAttachment) const;
PixelFormat get_attachment_pixelformat(FrameAttachment);
-unsigned get_gl_attachment(FrameAttachment);
-unsigned get_gl_buffer_bits(const FrameFormat &);
-
} // namespace GL
} // namespace Msp
+#include "frameformat_backend.h"
+
#endif