diff options
Diffstat (limited to 'src/Geometry.h')
-rw-r--r-- | src/Geometry.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Geometry.h b/src/Geometry.h index e471bdfc0..6456af0e8 100644 --- a/src/Geometry.h +++ b/src/Geometry.h @@ -180,6 +180,10 @@ public: return ColourRGBA(co_ | (0xffu << 24)); } + static constexpr ColourRGBA FromIpRGB(intptr_t co_) noexcept { + return ColourRGBA(static_cast<int>(co_) | (0xffu << 24)); + } + constexpr ColourRGBA WithoutAlpha() const noexcept { return ColourRGBA(co & 0xffffff); } |