Plasma Engine  2.0
Loading...
Searching...
No Matches
SetColorMessage.h
1#pragma once
2
3#include <Core/CoreDLL.h>
4#include <Foundation/Communication/Message.h>
5
8{
9 using StorageType = plUInt32;
10
23};
24
25PL_DECLARE_REFLECTABLE_TYPE(PL_CORE_DLL, plSetColorMode);
26
31struct PL_CORE_DLL plMsgSetColor : public plMessage
32{
33 PL_DECLARE_MESSAGE_TYPE(plMsgSetColor, plMessage);
34
37
40
42 void ModifyColor(plColor& ref_color) const;
43
45 void ModifyColor(plColorGammaUB& ref_color) const;
46
47 virtual void Serialize(plStreamWriter& inout_stream) const override;
48 virtual void Deserialize(plStreamReader& inout_stream, plUInt8 uiTypeVersion) override;
49};
A 8bit per channel unsigned normalized (values interpreted as 0-1) color storage format that represen...
Definition Color8UNorm.h:99
plColor represents an RGBA color in linear color space. Values are stored as float,...
Definition Color.h:44
Base class for all message types. Each message type has it's own id which is used to dispatch message...
Definition Message.h:22
virtual void Deserialize(plStreamReader &inout_stream, plUInt8 uiTypeVersion)
Definition Message.h:66
virtual void Serialize(plStreamWriter &inout_stream) const
Implement this for efficient transmission across process boundaries (e.g. network transfer etc....
Definition Message.h:63
Interface for binary in (read) streams.
Definition Stream.h:22
Interface for binary out (write) streams.
Definition Stream.h:107
A custom enum implementation that allows to define the underlying storage type to control its memory ...
Definition Enum.h:37
A message to modify the main color of some thing.
Definition SetColorMessage.h:32
plEnum< plSetColorMode > m_Mode
The mode with which to apply the color to the target.
Definition SetColorMessage.h:39
plColor m_Color
The color to apply to the target.
Definition SetColorMessage.h:36
Describes how a color should be applied to another color.
Definition SetColorMessage.h:8
Enum
Definition SetColorMessage.h:12
@ AlphaBlend
Modifies the target RGBA values by interpolating from the previous color towards the incoming color u...
Definition SetColorMessage.h:17
@ Additive
Adds to the RGBA values.
Definition SetColorMessage.h:18
@ SetRGB
Overrides the RGB values but leaves Alpha untouched.
Definition SetColorMessage.h:14
@ Default
Multiplies the RGBA values.
Definition SetColorMessage.h:21
@ SetRGBA
Overrides all four RGBA values.
Definition SetColorMessage.h:13
@ SetAlpha
Overrides Alpha, leaves RGB untouched.
Definition SetColorMessage.h:15