diff --git a/all-is-cubes-ui/src/apps/session.rs b/all-is-cubes-ui/src/apps/session.rs index 5560ba63d..2b7134f1c 100644 --- a/all-is-cubes-ui/src/apps/session.rs +++ b/all-is-cubes-ui/src/apps/session.rs @@ -965,6 +965,7 @@ impl SpaceWatchState { // TODO: do not discard spatial information; and add source information Some(sf.fluff.clone()) }) + .with_stack_buffer::<10>() // TODO: non-arbitrary number .gate(); space_read.fluff().listen(fluff_forwarder); Ok(Self { diff --git a/all-is-cubes-ui/src/inv_watch.rs b/all-is-cubes-ui/src/inv_watch.rs index 9a025e636..d419d9126 100644 --- a/all-is-cubes-ui/src/inv_watch.rs +++ b/all-is-cubes-ui/src/inv_watch.rs @@ -107,13 +107,16 @@ impl InventoryWatcher { Ok(cg) => { character_guard = cg; if let Some(l) = listener_to_install { - character_guard.listen(l.filter(|cc| match cc { - // This match is useless now, but in the future there will probably - // be CharacterChange messages we want to ignore. - CharacterChange::Inventory(_) | CharacterChange::Selections => { - Some(WatcherChange::NeedsUpdate) - } - })); + character_guard.listen( + l.filter(|cc| match cc { + // This match is useless now, but in the future there will probably + // be CharacterChange messages we want to ignore. + CharacterChange::Inventory(_) | CharacterChange::Selections => { + Some(WatcherChange::NeedsUpdate) + } + }) + .with_stack_buffer::<100>(), + ); } ( character_guard.inventory(), diff --git a/all-is-cubes/src/raytracer/updating.rs b/all-is-cubes/src/raytracer/updating.rs index 4cee28111..1cbef3c77 100644 --- a/all-is-cubes/src/raytracer/updating.rs +++ b/all-is-cubes/src/raytracer/updating.rs @@ -71,7 +71,10 @@ where // TODO: Placeholder for more detailed graphics options updating graphics_options.listen( - TodoListener(Arc::downgrade(&todo)).filter(|&()| Some(SpaceChange::EveryBlock)), + // TODO: this filter should be coalescing instead of having a large buffer + TodoListener(Arc::downgrade(&todo)) + .filter(|&()| Some(SpaceChange::EveryBlock)) + .with_stack_buffer::<1000>(), ); Self {