mirror of
https://github.com/MihailRis/voxelcore.git
synced 2026-10-08 04:21:50 +00:00
fullscreen setting checkbox + smth
This commit is contained in:
parent
8be0d157c2
commit
4861fedf1e
17 changed files with 97 additions and 76 deletions
|
|
@ -1,5 +1,5 @@
|
|||
#ifndef SRC_SETTINGS_H_
|
||||
#define SRC_SETTINGS_H_
|
||||
#ifndef SETTINGS_H_
|
||||
#define SETTINGS_H_
|
||||
|
||||
#include <string>
|
||||
#include <unordered_map>
|
||||
|
|
@ -21,7 +21,7 @@ struct AudioSettings {
|
|||
|
||||
struct DisplaySettings {
|
||||
/// @brief Is window in full screen mode
|
||||
bool fullscreen = false;
|
||||
FlagSetting fullscreen {false};
|
||||
/// @brief Window width (pixels)
|
||||
int width = 1280;
|
||||
/// @brief Window height (pixels)
|
||||
|
|
@ -29,8 +29,8 @@ struct DisplaySettings {
|
|||
/// @brief Anti-aliasing samples
|
||||
int samples = 0;
|
||||
/// @brief VSync on
|
||||
FlagSetting vsync = {true};
|
||||
/// @brief Window title */
|
||||
FlagSetting vsync {true};
|
||||
/// @brief Window title
|
||||
std::string title = "VoxelEngine-Cpp v" +
|
||||
std::to_string(ENGINE_VERSION_MAJOR) + "." +
|
||||
std::to_string(ENGINE_VERSION_MINOR);
|
||||
|
|
@ -38,18 +38,18 @@ struct DisplaySettings {
|
|||
|
||||
struct ChunksSettings {
|
||||
/// @brief Max milliseconds that engine uses for chunks loading only
|
||||
IntegerSetting loadSpeed = {4, 1, 32};
|
||||
IntegerSetting loadSpeed {4, 1, 32};
|
||||
/// @brief Radius of chunks loading zone (chunk is unit)
|
||||
IntegerSetting loadDistance = {22, 3, 66};
|
||||
IntegerSetting loadDistance {22, 3, 66};
|
||||
/// @brief Buffer zone where chunks are not unloading (chunk is unit)
|
||||
IntegerSetting padding = {2, 1, 8};
|
||||
IntegerSetting padding {2, 1, 8};
|
||||
};
|
||||
|
||||
struct CameraSettings {
|
||||
/// @brief Camera dynamic field of view effects
|
||||
bool fovEvents = true;
|
||||
FlagSetting fovEffects {true};
|
||||
/// @brief Camera movement shake
|
||||
FlagSetting shaking = {true};
|
||||
FlagSetting shaking {true};
|
||||
/// @brief Camera field of view
|
||||
NumberSetting fov {90.0f, 10, 120};
|
||||
/// @brief Camera sensitivity
|
||||
|
|
@ -60,12 +60,12 @@ struct GraphicsSettings {
|
|||
/// @brief Fog opacity is calculated as `pow(depth*k, fogCurve)` where k depends on chunksLoadDistance.
|
||||
/// 1.0 is linear, 2.0 is quadratic
|
||||
NumberSetting fogCurve {1.6f, 1.0f, 6.0f};
|
||||
NumberSetting gamma = {1.0f, 0.5f, 2.0f};
|
||||
NumberSetting gamma {1.0f, 0.5f, 2.0f};
|
||||
/// @brief Enable blocks backlight to prevent complete darkness
|
||||
FlagSetting backlight = {true};
|
||||
FlagSetting backlight {true};
|
||||
/// @brief Enable chunks frustum culling
|
||||
bool frustumCulling = true;
|
||||
int skyboxResolution = 64 + 32;
|
||||
FlagSetting frustumCulling {true}; // redutant?
|
||||
IntegerSetting skyboxResolution {64 + 32, 64, 128};
|
||||
};
|
||||
|
||||
struct DebugSettings {
|
||||
|
|
@ -90,4 +90,4 @@ struct EngineSettings {
|
|||
UiSettings ui;
|
||||
};
|
||||
|
||||
#endif // SRC_SETTINGS_H_
|
||||
#endif // SETTINGS_H_
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue