-std::map<std::string_view, Type(*)(const std::string_view&)> RENDERER_STATE_PROCESSORS{
- { "DEPTH_WRITE", [](const std::string_view&) -> Type { return DEPTH_WRITE; } },
- { "DEPTH_TEST", [](const std::string_view&) -> Type { return DEPTH_TEST; } },
- { "CULL_FRONT", [](const std::string_view&) -> Type { return CULL_FRONT; } },
- { "CULL_BACK", [](const std::string_view&) -> Type { return CULL_BACK; } },
- { "ALPHA_BLEND", [](const std::string_view&) -> Type { return ALPHA_BLEND; } },
- { "DEPTH_FUNC", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ?
- (InterpretComparison(std::string_view(arg.data() + 1, arg.size() - 1)) << DEPTH_FUNCTION_SHIFT) : 0x0;
- return value;
- } },
- { "BLEND_SRC_RGB", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 0) : 0x0;
- return value;
- }},
- { "BLEND_DST_RGB", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 1) : 0x0;
- return value;
- }},
- { "BLEND_SRC_ALPHA", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 2) : 0x0;
- return value;
- }},
- { "BLEND_DST_ALPHA", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 3) : 0x0;
- return value;
- }},
- { "BUFFER_MODE", [](const std::string_view& arg) -> Type {
- Type value = (arg[0] == ':') ? InterpretBufferMode(std::string_view(arg.data() + 1, arg.size() - 1)) : 0x0;
- return value;
- }},
+std::map<std::string_view, Type (*)(const std::string_view&)> RENDERER_STATE_PROCESSORS{
+ {"DEPTH_WRITE", [](const std::string_view&) -> Type { return DEPTH_WRITE; }},
+ {"DEPTH_TEST", [](const std::string_view&) -> Type { return DEPTH_TEST; }},
+ {"CULL_FRONT", [](const std::string_view&) -> Type { return CULL_FRONT; }},
+ {"CULL_BACK", [](const std::string_view&) -> Type { return CULL_BACK; }},
+ {"ALPHA_BLEND", [](const std::string_view&) -> Type { return ALPHA_BLEND; }},
+ {"DEPTH_FUNC", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? (InterpretComparison(std::string_view(arg.data() + 1, arg.size() - 1)) << DEPTH_FUNCTION_SHIFT) : 0x0;
+ return value;
+ }},
+ {"BLEND_SRC_RGB", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 0) : 0x0;
+ return value;
+ }},
+ {"BLEND_DST_RGB", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 1) : 0x0;
+ return value;
+ }},
+ {"BLEND_SRC_ALPHA", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 2) : 0x0;
+ return value;
+ }},
+ {"BLEND_DST_ALPHA", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? InterpretBlendFactor(std::string_view(arg.data() + 1, arg.size() - 1), 3) : 0x0;
+ return value;
+ }},
+ {"BUFFER_MODE", [](const std::string_view& arg) -> Type {
+ Type value = (arg[0] == ':') ? InterpretBufferMode(std::string_view(arg.data() + 1, arg.size() - 1)) : 0x0;
+ return value;
+ }},