-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathconfigNoisy.hpp
48 lines (38 loc) · 1.35 KB
/
configNoisy.hpp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#pragma once
#define NS_PATH "C:/Users/nicol/source/repos/noisyEngine/noisyEngine/Source/"
//#define NS_PATH "C:/Users/nicol/Documents/noisyEngine/"
#define CONFIG_FILE "config.yaml"
#define NS_MATERIAL_FILE_EXTENSION ".nsmat"
#ifndef NDEBUG
#define USE_IMGUI
#else
#define USE_IMGUI
#endif // !NDEBUG
#ifdef USE_IMGUI
#define NS_TEXTURE_VIEW_STORE_POINTER
#endif
//when false allow to save a lot of memory on each geometric object3d but this remove access to the translation, scaling and rotation matrix
#define NS_GEOMETRIC_OBJECT3D_STORE_ALL_MATRICES false
#define OPENGL_LOG_PERFORMANCE_ISSUES false
//macros to make sintax faster and more readable
#define dout std::cout //ns::Debug::get()
#define newl '\n'
#include <glm/glm.hpp>
namespace ns{
using LengthType = float;
using HeightType = float;
using PartitionType = size_t;
using ChunkPartitionType = glm::vec<2, PartitionType>;
using MapLengthType = glm::vec<2, LengthType>;
using GridPositionType = glm::ivec2;
constexpr ChunkPartitionType defaultSize = glm::vec<2, PartitionType>(32);
constexpr unsigned int maximunRenderDistance = 100;
//simple cast to LengthType
constexpr LengthType operator""_lt(long double number) {
return static_cast<LengthType>(number);
}
//simple cast to HeightType
constexpr HeightType operator""_ht(long double number) {
return static_cast<HeightType>(number);
}
}