From 6ca73c665bbb0873d9a33bf60bc06aaf69f2d754 Mon Sep 17 00:00:00 2001 From: lebaudantoine Date: Tue, 2 Sep 2025 14:24:09 +0200 Subject: [PATCH] =?UTF-8?q?=E2=9A=A1=EF=B8=8F(frontend)=20use=20initial=20?= =?UTF-8?q?processor=20reference=20to=20avoid=20track=20recreation?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Leverage reference to initial processor choice to prevent unnecessary preview track recreation when updating processor options. Improves performance by maintaining existing track instance during processor updates instead of creating new tracks, eliminating visual interruptions and reducing resource overhead. --- src/frontend/src/features/rooms/components/Join.tsx | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/frontend/src/features/rooms/components/Join.tsx b/src/frontend/src/features/rooms/components/Join.tsx index e883eac1..d4b49356 100644 --- a/src/frontend/src/features/rooms/components/Join.tsx +++ b/src/frontend/src/features/rooms/components/Join.tsx @@ -146,10 +146,9 @@ export const Join = ({ video: !!initialUserChoices.current && initialUserChoices.current?.videoEnabled && { deviceId: initialUserChoices.current.videoDeviceId, - processor: - BackgroundProcessorFactory.deserializeProcessor( - processorSerialized - ), + processor: BackgroundProcessorFactory.deserializeProcessor( + initialUserChoices.current.processorSerialized + ), }, }, onError