Git Product home page Git Product logo

Comments (7)

vr000m avatar vr000m commented on July 22, 2024

Is there guidance on what low and high mean here?

from webrtc-stats.

alvestrand avatar alvestrand commented on July 22, 2024

It's well defined for VP8, H.264, VP9 and HEVC, I think. Not redefining it would seem to be a Good Thing.
(low means not very compressed, high means very compressed, if I remember right).

from webrtc-stats.

vr000m avatar vr000m commented on July 22, 2024

Yes, the CL states the value is between 1-127. which would important to add. I suppose there is sufficient information to guess what low and high means. A value in the 20s is better than in the 50s.

from webrtc-stats.

jesup avatar jesup commented on July 22, 2024

To make use of this, we need to know the video codec in use, reset it on codec change, and also ensure this is per-track since each track will have different QP (or even different codecs)..

I think it is a reasonable thing to feed back to the application.

from webrtc-stats.

alvestrand avatar alvestrand commented on July 22, 2024

Hm. I'm trying to work out how this hangs together.
Frames are counted in RTCMediaStreamTrackStats, and you have to divide the sum-of-QP by the number of frames to get the average QP value.

But the codec information (necessary to know what the QP value means) hangs off RTCCodecStats, which is linked to the codecId of the RTCRtpStreamStats. The linkage between the two is taht RTCMediaStreamTrackStats has a sequence of SSRCs that can be used to find the RTCRtpStreamStats involved.

Should we put the sum of QP values on the RTCRtpStreamStats, since that has a single codec? Should we then put the FramesReceived there too, so that if a MediaStreamTrack switches codecs mid-flight, the QP values can be counted sensibly for each codec?

from webrtc-stats.

vr000m avatar vr000m commented on July 22, 2024

Frames that are not decoded but received do not have a QP value, ergo, FramesDecoded would be more appropriate than Frames Received.

Frames may be received by the endpoint and not decoded, may occur when a new user joins and starts receiving an existing stream or a user that was not in the filmstrip starts speaking. The decoding depends if the first frame is a full reference or not.

I suppose this would not be an issue if a stream is paused and resumed by the sender?

from webrtc-stats.

alvestrand avatar alvestrand commented on July 22, 2024

Summarizing status:

  • The basic approach makes sense. The question is where to place the counters.
  • To interpret the number, we need to know the codec. That's only visible in RTCRtpStreamStats (via "codecId" that references an RTCCodecStats object).
  • To get the average QP on reception, we need to know the number of decoded frames. At the moment, that's an RTCMediaStreamTrackStats value.

Suggestion:

  • Add the proposed counters to RTCRtpStreamStats
  • Add a FramesDecoded value to RTCRtpInboundStreamStats
  • Add a FramesEncoded value to RTCRtpOutboundStreamStats

I think that should make the counters usable without too much tree-walking.
As long as RTCRtpStream remains 1:1 with RTCMediaStreamTrack, the counters should have the same value as those other counters, but that won't necessarily be true always - the big exception is simulcast, where there would be multiple RtpStreams all pointing to the same RTCMediaStreamTrack.

from webrtc-stats.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.