Persist ImGui panel layout to disk; quiet audio set_audio_ring log spam
Layout persistence: re-enable io.IniFilename (was nullptr "for the spike"), anchored to a coop_layout.ini next to the exe so window positions/sizes survive restarts even when Steam launches us under the donor appid (CWD is unreliable). Path is UTF-8 for ImGui's file IO. When a saved layout is restored at startup, suppress the computed-default force so it does not clobber the user's positions; Reset layout (and a fresh install with no .ini) still applies the default. Log spam: the worker thread re-attaches every audio ring every tick (idempotent), and set_audio_ring logged unconditionally, flooding the log. Only log when the ring pointer actually changes. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -600,9 +600,14 @@ void set_audio_ring(unsigned index, AudioRingHeader* ring)
|
||||
{
|
||||
return;
|
||||
}
|
||||
g_rings[index].store(ring, std::memory_order_release);
|
||||
logf("set_audio_ring: index=%u ring=%p capture_enabled=%u", index, ring,
|
||||
ring ? ring->capture_enabled.load(std::memory_order_relaxed) : 0u);
|
||||
// The worker thread re-attaches every tick (idempotent); only log when the ring
|
||||
// pointer actually changes so the log isn't flooded with identical lines.
|
||||
AudioRingHeader* const prev = g_rings[index].exchange(ring, std::memory_order_acq_rel);
|
||||
if (prev != ring)
|
||||
{
|
||||
logf("set_audio_ring: index=%u ring=%p capture_enabled=%u", index, ring,
|
||||
ring ? ring->capture_enabled.load(std::memory_order_relaxed) : 0u);
|
||||
}
|
||||
// The stream may already be registered (game was playing before we injected and
|
||||
// before the host created the ring); publish its format so the host stops waiting
|
||||
// and consumes the ring instead of falling back to loopback.
|
||||
|
||||
Reference in New Issue
Block a user