Divide Framework 0.1
A free and open-source 3D Framework under heavy development
Loading...
Searching...
No Matches
config.h File Reference

Go to the source code of this file.

Namespaces

namespace  Divide
 Handle console commands that start with a forward slash.
 
namespace  Divide::Config
 
namespace  Divide::Config::Build
 
namespace  Divide::Config::Assert
 
namespace  Divide::Config::Profile
 
namespace  Divide::Config::Lighting
 
namespace  Divide::Config::Lighting::ClusteredForward
 These settings control the clustered renderer and how we batch lights per tile & cluster.
 
namespace  Divide::Config::Networking
 

Macros

#define DVD_CONFIG_H_
 

Variables

constexpr bool Divide::Config::Build::IS_RELEASE_BUILD = true
 
constexpr bool Divide::Config::Build::IS_DEBUG_BUILD = false
 
constexpr bool Divide::Config::Build::IS_PROFILE_BUILD = false
 
constexpr bool Divide::Config::Build::IS_SHIPPING_BUILD = IS_RELEASE_BUILD && false
 
constexpr bool Divide::Config::Build::IS_EDITOR_BUILD = false
 
constexpr bool Divide::Config::Build::ENABLE_EDITOR = !IS_SHIPPING_BUILD
 
constexpr bool Divide::Config::Assert::LOG_ASSERTS = !Build::IS_RELEASE_BUILD
 Log assert fails messages to the error log file.
 
constexpr bool Divide::Config::Assert::SHOW_MESSAGE_BOX = LOG_ASSERTS
 Popup a GUI Message Box on asserts;.
 
constexpr bool Divide::Config::Assert::CONTINUE_ON_ASSERT = false
 Do not call the platform "assert" function in order to continue application execution.
 
constexpr unsigned short Divide::Config::Profile::MAX_PROFILE_TIMERS = 1 << 10
 How many profiling timers are we allowed to use in our applications. We allocate them upfront, so a max limit is needed.
 
constexpr bool Divide::Config::Profile::ENABLE_FUNCTION_PROFILING = !Build::IS_SHIPPING_BUILD
 Enable function level profiling.
 
constexpr float Divide::Config::ALPHA_DISCARD_THRESHOLD = 1.f - 0.05f
 
constexpr unsigned char Divide::Config::MINIMUM_VULKAN_MINOR_VERSION = 3u
 
constexpr unsigned char Divide::Config::DESIRED_VULKAN_MINOR_VERSION = 3u
 
constexpr U16 Divide::Config::TARGET_FRAME_RATE = 60
 Application desired framerate for physics and input simulations.
 
constexpr U8 Divide::Config::MAX_FRAMES_IN_FLIGHT = 3u
 Maximum number of active frames until we start waiting on a fence/sync.
 
constexpr U8 Divide::Config::TICK_DIVISOR = 2u
 
constexpr U16 Divide::Config::MIN_SLEEP_THRESHOLD_MS = 5u
 The minimum threshold needed for a threaded loop to use sleep. Update intervals bellow this threshold will not use sleep!
 
constexpr size_t Divide::Config::REQUIRED_RAM_SIZE_IN_BYTES = 2u * (1024u * 1024 * 1024)
 
constexpr U32 Divide::Config::MAX_POOLED_TASKS = 1 << 16
 How many tasks should we keep in a per-thread pool to avoid using new/delete (must be power of two)
 
constexpr U16 Divide::Config::MAX_BONE_COUNT_PER_NODE = 1 << 7
 Maximum number of bones available per node.
 
constexpr U16 Divide::Config::MAX_VISIBLE_NODES = 1 << 13
 Estimated maximum number of visible objects per render pass (this includes debug primitives)
 
constexpr U16 Divide::Config::MAX_CONCURRENT_MATERIALS = 1 << 14
 Estimated maximum number of materials used in a single frame by all passes combined.
 
constexpr U8 Divide::Config::MAX_CLIP_DISTANCES = 3u
 
constexpr U8 Divide::Config::MAX_CULL_DISTANCES = 1u
 
constexpr U8 Divide::Config::MAX_REFLECTIVE_NODES_IN_VIEW = Build::IS_DEBUG_BUILD ? 3u : 5u
 
constexpr U8 Divide::Config::MAX_REFRACTIVE_NODES_IN_VIEW = Build::IS_DEBUG_BUILD ? 2u : 4u
 Similar to MAX_REFLECTIVE_NODES_IN_VIEW but for custom refraction passes (e.g. Water, special glass, etc). Also a candidate for removal.
 
constexpr U8 Divide::Config::MAX_REFLECTIVE_PROBES_PER_PASS = 6u
 Maximum number of environment probes we are allowed to update per frame.
 
constexpr U8 Divide::Config::MAX_LOCAL_PLAYER_COUNT = 4u
 Maximum number of players we support locally. We store per-player data such as key-bindings, camera positions, etc.
 
constexpr U8 Divide::Config::MAX_DEBUG_SCOPE_DEPTH = 32u
 Maximum number of nested debug scopes we support in the renderer.
 
constexpr U8 Divide::Config::Lighting::MAX_SHADOW_CASTING_DIRECTIONAL_LIGHTS = 2u
 How many lights (in order as passed to the shader for the node) should cast shadows.
 
constexpr U8 Divide::Config::Lighting::MAX_SHADOW_CASTING_POINT_LIGHTS = 4u
 
constexpr U8 Divide::Config::Lighting::MAX_SHADOW_CASTING_SPOT_LIGHTS = 6u
 
constexpr U8 Divide::Config::Lighting::MAX_SHADOW_CASTING_LIGHTS = MAX_SHADOW_CASTING_DIRECTIONAL_LIGHTS + MAX_SHADOW_CASTING_POINT_LIGHTS + MAX_SHADOW_CASTING_SPOT_LIGHTS
 Maximum number of shadow casting lights processed per frame.
 
constexpr U8 Divide::Config::Lighting::MAX_CSM_SPLITS_PER_LIGHT = 4u
 Used for CSM or PSSM to determine the maximum number of frustum splits.
 
constexpr U16 Divide::Config::Lighting::MAX_ACTIVE_LIGHTS_PER_FRAME = 1 << 12
 Maximum number of lights we process per frame. We need this upper bound for pre-allocating arrays and setting up shaders. Increasing it shouldn't hurt performance in a linear fashion.
 
constexpr U16 Divide::Config::Lighting::ClusteredForward::MAX_LIGHTS_PER_CLUSTER = 100u
 Upper limit of lights used in a cluster. The lower, the better performance at the cost of pop-in/glitches. At ~100, any temporal issues should remain fairly hidden.
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_X = 16u
 Controls compute shader dispatch. e.g. Dispatch Z count = CLUSTERS_Z / CLUSTERS_Z_THREADS.
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_Y = 8u
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_Z = 24u
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_X_THREADS = CLUSTERS_X
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_Y_THREADS = CLUSTERS_Y
 
constexpr U8 Divide::Config::Lighting::ClusteredForward::CLUSTERS_Z_THREADS = CLUSTERS_Z / 6u
 
constexpr U16 Divide::Config::Lighting::ClusteredForward::MAX_COMPUTE_THREADS = 1024u
 
constexpr U16 Divide::Config::Networking::NETWORK_SEND_FREQUENCY_HZ = 20
 How often should the client send messages to the server.
 
constexpr U16 Divide::Config::Networking::NETWORK_SEND_RETRY_COUNT = 3
 How many times should we try to send an update to the server before giving up?
 
constexpr bool Divide::Config::ENABLE_GPU_VALIDATION = !Build::IS_SHIPPING_BUILD
 Error callbacks, validations, buffer checks, etc. are controlled by this flag. Heavy performance impact!
 
constexpr bool Divide::Config::ENABLE_LOCALE_FILE_WATCHER = !Build::IS_SHIPPING_BUILD && Build::ENABLE_EDITOR
 Scan changes to shader source files, script files, etc to hot-reload assets. Isn't needed in shipping builds or without the editor enabled.
 
constexpr char Divide::Config::DEFAULT_PROJECT_NAME [] = "Default"
 
constexpr char Divide::Config::DEFAULT_SCENE_NAME [] = "Default"
 
constexpr char Divide::Config::DELETED_FOLDER_NAME [] = "Deleted"
 
constexpr char Divide::Config::ENGINE_NAME [] = "Divide Framework"
 
constexpr auto Divide::Config::ENGINE_VERSION_MAJOR = 0u
 
constexpr auto Divide::Config::ENGINE_VERSION_MINOR = 1u
 
constexpr auto Divide::Config::ENGINE_VERSION_PATCH = 0u
 
constexpr char OUTPUT_LOG_FILE [] = "console.log"
 
constexpr char ERROR_LOG_FILE [] = "errors.log"
 

Macro Definition Documentation

◆ DVD_CONFIG_H_

#define DVD_CONFIG_H_

Definition at line 34 of file config.h.

Variable Documentation

◆ ERROR_LOG_FILE

constexpr char ERROR_LOG_FILE[] = "errors.log"
constexpr

Definition at line 209 of file config.h.

◆ OUTPUT_LOG_FILE

constexpr char OUTPUT_LOG_FILE[] = "console.log"
constexpr

Definition at line 208 of file config.h.