Nameless Engine
Loading...
Searching...
No Matches
Globals.h
1#pragma once
2
3// Standard.
4#include <filesystem>
5#include <string>
6
7// Custom.
8#include "math/GLMath.hpp"
9
10namespace ne {
12 class Globals {
13 Globals() = delete;
14
15 public:
19 static inline const glm::vec3 up = glm::vec3(0.0F, 0.0F, 1.0F); // NOLINT: short name
20
22 static inline const glm::vec3 right = glm::vec3(0.0F, 1.0F, 0.0F);
23
25 static inline const glm::vec3 forward = glm::vec3(1.0F, 0.0F, 0.0F);
26 };
27
33 static constexpr size_t getDefaultWorldSize() { return iDefaultWorldSize; }
34
40 static std::string getApplicationName();
41
47 static std::string getResourcesDirectoryName();
48
54 static std::string getEngineDirectoryName();
55
63 static std::string wstringToString(const std::wstring& sText);
64
72 static std::wstring stringToWstring(const std::string& sText);
73
80 static std::string getDebugOnlyLoggingPrefix();
81
82 private:
84 static constexpr auto sBaseEngineDirectoryName = "nameless-engine";
85
87 static constexpr auto sDebugOnlyLoggingPrefix = "Debug mode only";
88
90 static constexpr auto sResDirectoryName = "res";
91
93 static constexpr size_t iDefaultWorldSize = 128; // NOLINT: start small and increase when needed
94 };
95} // namespace ne
Definition: Globals.h:12
static std::string getResourcesDirectoryName()
Definition: Globals.cpp:101
static std::string getDebugOnlyLoggingPrefix()
Definition: Globals.cpp:99
static constexpr size_t getDefaultWorldSize()
Definition: Globals.h:33
static std::string wstringToString(const std::wstring &sText)
Definition: Globals.cpp:55
static constexpr auto sResDirectoryName
Definition: Globals.h:90
static std::string getApplicationName()
Definition: Globals.cpp:21
static constexpr auto sDebugOnlyLoggingPrefix
Definition: Globals.h:87
static std::wstring stringToWstring(const std::string &sText)
Definition: Globals.cpp:82
static constexpr size_t iDefaultWorldSize
Definition: Globals.h:93
static constexpr auto sBaseEngineDirectoryName
Definition: Globals.h:84
static std::string getEngineDirectoryName()
Definition: Globals.cpp:103
Definition: Globals.h:17
static const glm::vec3 up
Definition: Globals.h:19
static const glm::vec3 forward
Definition: Globals.h:25
static const glm::vec3 right
Definition: Globals.h:22