aws / amazon-chime-sdk-js

A JavaScript client library for integrating multi-party communications powered by the Amazon Chime service.
Apache License 2.0
709 stars 477 forks source link

Video resolution not matching configuration #2804

Closed dbish closed 8 months ago

dbish commented 10 months ago

What happened and what did you expect to happen?

We have set video resolution to the following ` meetingSession.audioVideo.chooseVideoInputQuality(960, 540, 15);

meetingSession.audioVideo.startVideoInput(videoDevice); `

However, 99% of the time, the recorded video looks very low resolution (checking the media pipeline and playing back the video). I know there is some dynamic resolution stuff that goes on behind the scenes but even when we record 1 camera (see meeting ID: 7e3b8077-fdb3-4114-90af-43f01e2c6404) on what is a decent office internet connection, setting the resolution higher doesn't seem to actually do anything since Chime is doing somehting on the backend.

Here's a screenshot, I don't think that resolution looks right.

Screenshot 2023-11-20 at 14 19 30

Also, if we set any higher resolution then this, the resulting recording seems to actually drop in resolution.

What are we doing wrong? Thanks.

Have you reviewed our existing documentation?

Reproduction steps

Set resolution for the video: meetingSession.audioVideo.chooseVideoInputQuality(960, 540, 15);

Create a media capture pipeline with following config:

            ChimeSdkMeetingConfiguration={
                "ArtifactsConfiguration": {
                    "Audio": {"MuxType": "AudioWithActiveSpeakerVideo"},
                    "Video": {"State": "Enabled", "MuxType": "VideoOnly"},
                    "Content": {"State": "Disabled"},
                }
            }

Check the S3 files and see the resolution is not what you expect.

Amazon Chime SDK for JavaScript version

3.14

What browsers are you seeing the problem on?

Chrome

Browser version

Version 119.0.6045.159

Meeting and Attendee ID Information.

meeting ID: 7e3b8077-fdb3-4114-90af-43f01e2c6404, only one attendee

Browser console logs

this is about hte final resolution in replay

shi-su commented 10 months ago

I checked the meeting, the encoding resolution started at 180p (this is expected at the beginning and it will adapt as it have more info about the network). 6 seconds after the video was turned on, the resolution switched up to 270p, and then 360p 4 seconds later. It took another 4 seconds for the video to end up at 540p and stayed at 540p for the rest of the meeting (only 3 seconds though). The eventual bitrate was about 1400 kbps. The metrics does show resolution is configured properly and all behavior looks expected. Just that it takes a bit for resolution to adapt to network and the meeting was very short that the 540p resolution lasted for a very limited period of time.