Estella
0.113.0
A fast 2D and 3D game engine powered by WebAssembly and ECS
Loading...
Searching...
No Matches
UIMask.hpp
Go to the documentation of this file.
1
// SPDX-License-Identifier: Apache-2.0
2
// SPDX-FileCopyrightText: Copyright (c) 2024-present ESEngine Team
3
#pragma once
4
5
#include "
../../core/Types.hpp
"
6
#include "
../../core/Reflection.hpp
"
7
8
namespace
esengine::ecs
{
9
10
ES_ENUM
()
11
enum class
MaskMode
:
u8
{
12
Scissor
,
13
Stencil
14
};
15
16
ES_COMPONENT
()
17
struct
UIMask
{
18
ES_PROPERTY
()
19
bool
enabled
{
true
};
20
ES_PROPERTY
()
21
MaskMode
mode
{
MaskMode::Scissor
};
22
28
ES_PROPERTY
(tooltip=
"Stencil only: above 0, clip to the mask sprite's shape instead of its box."
)
29
f32
alphaCutoff
{0.0f};
30
};
31
32
}
// namespace esengine::ecs
Reflection.hpp
Reflection and metadata system for automatic binding generation.
ES_COMPONENT
#define ES_COMPONENT(...)
Mark a struct/class as a component that should be exposed to scripts.
Definition
Reflection.hpp:46
ES_ENUM
#define ES_ENUM(...)
Mark an enum that should be exposed to scripts.
Definition
Reflection.hpp:119
ES_PROPERTY
#define ES_PROPERTY(...)
Mark a field as a property that should be exposed to scripts.
Definition
Reflection.hpp:95
Types.hpp
Core type definitions and utilities for ESEngine.
esengine::ecs
Definition
AotComponents.generated.hpp:8
esengine::ecs::MaskMode
MaskMode
Definition
UIMask.hpp:11
esengine::ecs::MaskMode::Scissor
@ Scissor
Definition
UIMask.hpp:12
esengine::ecs::MaskMode::Stencil
@ Stencil
Definition
UIMask.hpp:13
esengine::u8
std::uint8_t u8
Unsigned 8-bit integer.
Definition
Types.hpp:41
esengine::f32
float f32
32-bit floating point
Definition
Types.hpp:59
esengine::ecs::UIMask
Definition
UIMask.hpp:17
esengine::ecs::UIMask::mode
MaskMode mode
Definition
UIMask.hpp:21
esengine::ecs::UIMask::enabled
bool enabled
Definition
UIMask.hpp:19
esengine::ecs::UIMask::alphaCutoff
f32 alphaCutoff
Definition
UIMask.hpp:29
src
esengine
ecs
components
UIMask.hpp
Generated by
1.15.0