Removed debug FPS limit

This commit is contained in:
Yousef Khadadeh 2026-04-11 16:40:53 +03:00
parent b2fe1ab7ba
commit 767b96bd12
5 changed files with 0 additions and 11 deletions

View file

@ -51,7 +51,6 @@ nlohmann::json GlobalConfig::get_config_json(const InputManager& input) const {
json debugJson;
debugJson["showPerformance"] = showPerformance;
debugJson["fpsLimit"] = fpsLimit;
debugJson["jumpTransitionEasing"] = jumpTransitionEasing;
debugJson["imageLoadMaxThreads"] = ImageResourceDisplay::IMAGE_LOAD_THREAD_COUNT_MAX;
debugJson["cacheNodeResolution"] = DrawingProgramCache::CACHE_NODE_RESOLUTION;
@ -118,7 +117,6 @@ void GlobalConfig::set_config_json(InputManager& input, const nlohmann::json& j,
try{j.at("tablet").at("zoomWhilePenDownAndButtonHeld").get_to(tabletOptions.zoomWhilePenDownAndButtonHeld);} catch(...) {}
try{j.at("debug").at("showPerformance").get_to(showPerformance);} catch(...) {}
try{j.at("debug").at("fpsLimit").get_to(fpsLimit);} catch(...) {}
try{j.at("debug").at("jumpTransitionEasing").get_to(jumpTransitionEasing);} catch(...) {}
try{j.at("debug").at("imageLoadMaxThreads").get_to(ImageResourceDisplay::IMAGE_LOAD_THREAD_COUNT_MAX);} catch(...) {}
try{j.at("debug").at("cacheNodeResolution").get_to(DrawingProgramCache::CACHE_NODE_RESOLUTION);} catch(...) {}

View file

@ -28,7 +28,6 @@ class GlobalConfig {
} tabletOptions;
Vector3f defaultCanvasBackgroundColor = DEFAULT_CANVAS_BACKGROUND_COLOR;
float fpsLimit = 10000.0f;
nlohmann::json get_config_json(const InputManager& input) const;
void set_config_json(InputManager& input, const nlohmann::json& j, VersionNumber version);

View file

@ -67,9 +67,6 @@ MainProgram::MainProgram():
}
void MainProgram::update() {
while(std::chrono::duration_cast<std::chrono::duration<float>>(std::chrono::steady_clock::now() - lastFrameTime).count() < 1.0 / conf.fpsLimit);
lastFrameTime = std::chrono::steady_clock::now();
deltaTime.update_time_since();
deltaTime.update_time_point();

View file

@ -31,8 +31,6 @@ class MainProgram {
InputManager input;
std::chrono::steady_clock::time_point lastFrameTime = std::chrono::steady_clock::now();
Vector3f userColor;
struct Window {

View file

@ -1945,9 +1945,6 @@ void Toolbar::general_settings_inner_gui() {
general_scroll_area("debug settings menu", [&] {
checkbox_boolean_field(gui, "show performance metrics", "Show metrics", &showPerformance);
input_scalars_field(gui, "jump transition easing", "Jump easing", &main.conf.jumpTransitionEasing, 4, -10.0f, 10.0f, { .decimalPrecision = 2 });
#ifndef __EMSCRIPTEN__
input_scalar_field(gui, "fps cap slider", "FPS cap", &main.conf.fpsLimit, 3.0f, 10000.0f);
#endif
input_scalar_field<int>(gui, "image load max threads", "Maximum image loading threads", &ImageResourceDisplay::IMAGE_LOAD_THREAD_COUNT_MAX, 1, 10000);
text_label_light(gui, "Cache related settings");
input_scalar_field<size_t>(gui, "cache node resolution", "Cache node resolution", &DrawingProgramCache::CACHE_NODE_RESOLUTION, 256, 8192);