31 lines
596 B
C++
31 lines
596 B
C++
#pragma once
|
|
|
|
#include <tuple>
|
|
#include <cinttypes>
|
|
#include "util/enum_bitfield_operators.hpp"
|
|
|
|
namespace assets::texture_components
|
|
{
|
|
|
|
using red = std::uint8_t;
|
|
using green = std::uint8_t;
|
|
using blue = std::uint8_t;
|
|
using luminance = std::uint8_t;
|
|
|
|
enum class flags : std::uint8_t
|
|
{
|
|
none = 0,
|
|
luminance = 1 << 1,
|
|
red = 1 << 2,
|
|
green = 1 << 3,
|
|
blue = 1 << 4,
|
|
alpha = 1 << 5
|
|
};
|
|
|
|
using all = std::tuple<red, green, blue, luminance>;
|
|
constexpr inline auto count = std::tuple_size_v<all>;
|
|
|
|
} // namespace texture_components
|
|
|
|
DEFINE_ENUM_BITFIELD_OPERATORS(assets::texture_components::flags)
|