# HG changeset patch # User sam # Date 1711702913 -25200 # Node ID e3ef8ebdda46e36610ec01f1d57114750fd46b89 # Parent 459066429a72e8da460eab727c2e61e5a121ae34 did: cleanup unnecessasry annotations, comments diff -r 459066429a72 -r e3ef8ebdda46 semicongine/audio.nim --- a/semicongine/audio.nim Fri Mar 29 15:44:17 2024 +0700 +++ b/semicongine/audio.nim Fri Mar 29 16:01:53 2024 +0700 @@ -269,7 +269,7 @@ mixer[] = initMixer() audiothread.createThread(audioWorker) debug "Created audio thread" - when defined(window): + when defined(windows): SetThreadPriority(audiothread.handle(), THREAD_PRIORITY_TIME_CRITICAL) when defined(linux): discard pthread_setschedprio(Pthread(audiothread.handle()), cint(-20)) diff -r 459066429a72 -r e3ef8ebdda46 semicongine/engine.nim --- a/semicongine/engine.nim Fri Mar 29 15:44:17 2024 +0700 +++ b/semicongine/engine.nim Fri Mar 29 16:01:53 2024 +0700 @@ -1,5 +1,3 @@ -{.experimental: "codeReordering".} - import std/options import std/sequtils import std/logging @@ -51,6 +49,8 @@ eventHandler: proc(engine: var Engine, event: Event) fullscreen: bool +# forward declarations +func getAspectRatio*(engine: Engine): float32 proc destroy*(engine: var Engine) = checkVkResult engine.device.vk.vkDeviceWaitIdle() @@ -88,6 +88,8 @@ if debug: instanceExtensions.add "VK_EXT_debug_utils" layers.add "VK_LAYER_KHRONOS_validation" + # This stuff might be usefull if we one day to smart GPU memory allocation, + # but right now it just clobbers up the console log # putEnv("VK_LAYER_ENABLES", "VK_VALIDATION_FEATURE_ENABLE_BEST_PRACTICES_EXT") putEnv("VK_LAYER_ENABLES", "VALIDATION_CHECK_ENABLE_VENDOR_SPECIFIC_AMD,VALIDATION_CHECK_ENABLE_VENDOR_SPECIFIC_NVIDIA,VK_VALIDATION_FEATURE_ENABLE_SYNCHRONIZATION_VALIDATION_EXTVK_VALIDATION_FEATURE_ENABLE_GPU_ASSISTED_EXT,VK_VALIDATION_FEATURE_ENABLE_SYNCHRONIZATION_VALIDATION_EXT")