apivideo/api.video-reactnative-live-stream

[Feat]: Frame drops

Opened this issue · 5 comments

Version

2.0.0

Environment that reproduces the issue

Use case description

Hi, is there any method or callback that can tell us the frame drops in our stream?

Proposed solution

there should be a callback function that tells us the frame drop after some interval of time

Alternative solutions

No response

Hi,

There isn't such APIs.
To understand the need, I have to understand:

  • Why do you need it? (how do you plan to use it?)
  • What is a frame? (video/audio/network packet)

We would also like to have frame drops in some callback due to the reason, that some times when we stream to a specific RTMP server, the stream seems pixelated and stuttering.

Having this option can enable us to adjust bitrate dynamically for high latency and poor internet connection users.

Frame drops are audio video frames. If its not possible, then a packet drops will suffice as well.

Hi,

There isn't such APIs. To understand the need, I have to understand:

  • Why do you need it? (how do you plan to use it?)
  • What is a frame? (video/audio/network packet)

yes i second @xoraingroup , the need is to change the bitrate when the users have high latency due to poor connection. to give them a seem less and fine streaming experience.

Ok, so you want to know if the connection is reliatable or not. That made more senses for RTMP than a callback with frame drops as RTMP is based on TCP.
I would rather add a small optional mechanism (maybe customizable with custom algorithm) to reduce bitrate when sender internal buffer are too large.
But it is a complicated topic.

Yes thats true, TCP connection do resend packets, but as observed in OBS, it drops frames at source may be due to wrong time stamps???

Basically, an optional parameter with max and min bitrate would be ideal, in which it should automatically reduce bitrate to the min level if there is too much retransmission of packets due to latency, bad network etc.