@@ -302,6 +302,7 @@ def __init__(
302302 terminate_event : Optional [asyncio .Event ] = None ,
303303 heartbeat_callback : Optional [Callable [[], None ]] = None ,
304304 realtime_processing : bool = True ,
305+ is_preview : bool = False ,
305306 ):
306307 self ._loop = asyncio_loop
307308 self ._termination_date = termination_date
@@ -361,6 +362,7 @@ def __init__(
361362 cancel_thread_pool_tasks_on_exit = workflow_configuration .cancel_thread_pool_tasks_on_exit ,
362363 video_metadata_input_name = workflow_configuration .video_metadata_input_name ,
363364 model_manager = model_manager ,
365+ _is_preview = is_preview ,
364366 )
365367
366368 def set_track (self , track : MediaStreamTrack , rotation_code : Optional [int ] = None ):
@@ -728,6 +730,7 @@ def __init__(
728730 terminate_event : Optional [asyncio .Event ] = None ,
729731 heartbeat_callback : Optional [Callable [[], None ]] = None ,
730732 realtime_processing : bool = True ,
733+ is_preview : bool = False ,
731734 * args ,
732735 ** kwargs ,
733736 ):
@@ -746,6 +749,7 @@ def __init__(
746749 model_manager = model_manager ,
747750 heartbeat_callback = heartbeat_callback ,
748751 realtime_processing = realtime_processing ,
752+ is_preview = is_preview ,
749753 )
750754
751755 async def _auto_detect_stream_output (
@@ -918,6 +922,7 @@ async def init_rtc_peer_connection_with_loop(
918922 terminate_event = terminate_event ,
919923 heartbeat_callback = heartbeat_callback ,
920924 realtime_processing = webrtc_request .webrtc_realtime_processing ,
925+ is_preview = webrtc_request .is_preview ,
921926 )
922927 else :
923928 # No video track - use base VideoFrameProcessor
@@ -934,6 +939,7 @@ async def init_rtc_peer_connection_with_loop(
934939 terminate_event = terminate_event ,
935940 heartbeat_callback = heartbeat_callback ,
936941 realtime_processing = webrtc_request .webrtc_realtime_processing ,
942+ is_preview = webrtc_request .is_preview ,
937943 )
938944 except (
939945 ValidationError ,
0 commit comments