Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

If the payload format numbers for video and audio in a stream are the same, the video will not recive. #139

Open
vincentiger opened this issue May 31, 2024 · 0 comments

Comments

@vincentiger
Copy link

Bug Description

When the payload format numbers for video and audio in a stream are the same, the video does not display.

Steps to Reproduce

  1. Ensure that the payload format numbers for both video and audio in a stream are set to the same value.
  2. Attempt to display the video stream.

Expected Behavior

The video stream should display correctly, regardless of the payload format numbers.

Actual Behavior

The video stream does not display when the payload format numbers for video and audio are the same.

Workaround

To focus on receiving only the video stream, I use the following code:

while (!string.IsNullOrEmpty(line = sdpStreamReader.ReadLine()))
{
    if (line[0] == 'm')
    {
        ParseMediaLine(line);
    }
    else if (line[0] == 'a')
    {
        ParseAttributesLine(line);
    }

    if (line.Contains("track1"))
    {
        break;
    }
}

The loop stops reading lines once it encounters a line containing "track1", focusing the parsing process on the relevant video stream data.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant