CeresEngine 0.2.0
A game development framework
Loading...
Searching...
No Matches
Common.hpp
Go to the documentation of this file.
1//
2// CeresEngine - A game development framework
3//
4// Created by Rogiel Sulzbach.
5// Copyright (c) 2018-2022 Rogiel Sulzbach. All rights reserved.
6//
7
8#pragma once
9
11
12#include <imgui.h>
13
14#include <cstdint>
15#include <type_traits>
16
18
19 template<typename T> struct DataType;
20
21 template<> struct DataType<float> { static constexpr ImGuiDataType_ type = ImGuiDataType_Float; };
22
23 template<> struct DataType<double> { static constexpr ImGuiDataType_ type = ImGuiDataType_Double; };
24
25 template<> struct DataType<Int32> { static constexpr ImGuiDataType_ type = ImGuiDataType_S32; };
26
27 template<> struct DataType<UInt32> { static constexpr ImGuiDataType_ type = ImGuiDataType_U32; };
28
29 template<> struct DataType<Int64> { static constexpr ImGuiDataType_ type = ImGuiDataType_S64; };
30
31 template<> struct DataType<UInt64> { static constexpr ImGuiDataType_ type = ImGuiDataType_U64; };
32
33} // namespace CeresEngine::Graphics::UI::Component
Definition Checkbox.hpp:14
std::uint64_t UInt64
Definition DataTypes.hpp:26
std::int32_t Int32
Definition DataTypes.hpp:21
std::int64_t Int64
Definition DataTypes.hpp:24
std::uint32_t UInt32
Definition DataTypes.hpp:23
constexpr size_t hash(const T &v)
Generates a hash for the provided type.
Definition Hash.hpp:25