stream-labs / obs-studio-node

libOBS (OBS Studio) for Node.Js, Electron and similar tools
GNU General Public License v2.0
597 stars 99 forks source link

Using obs_output_is_ready_to_update instead of obs_output_active in getAdvancedOutputStreamingSettings #1402

Closed avoitenko-logitech closed 5 months ago

avoitenko-logitech commented 6 months ago

Description

Attempt to fix rash with the following stacktrace

to_video_type (flv-mux.h:34)
init_connect (rtmp-stream.c:1284)
connect_thread (rtmp-stream.c:1354)
ptw32_threadStart (ptw32_threadStart.c:225)
circlebuf_push_back (circlebuf.h:168)
_acrt_getptd
thread_start<T>
BaseThreadInitThunk
RtlUserThreadStart

Motivation and Context

It happens when RTMP stream is in connection phase because it needs data from encoder, but it is destroyed. RTMP does not have any synchronization for encoder usage, it assumes that encoder is always alive,

How Has This Been Tested?

Windows only, manually

Types of changes