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

fixed bug in examples/rtp-forwarder where packet state is not properl… #2957

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

strangesast
Copy link

@strangesast strangesast commented Nov 24, 2024

fixes corrupt RTP packet issue related to memory initialization/reset in examples/rtp-forwarder that causes frames to be distorted

@Sean-Der
Copy link
Member

@strangesast are you able to reproduce this reliably?

Unmarshal should be safe to use like this! Possibly Padding isn't cleared properly? We might need a deeper fix in pion/rtp

@strangesast
Copy link
Author

yes I get frames that are distorted like this with VP8 encoding. I had tried h.264 and get a different flavor of distortion.
Screenshot 2024-11-26 at 9 33 56 AM

when testing I noticed that I could get the demo to work with TrackRemote.ReadRTP but realized that was just a convenience wrapper around the same logic

it looks like there's an issue with how rtp.Packet.PaddingSize is set by Unmarshal. or at least that's the only value that differs between these approaches.

it's almost certainly related to this and this

@Sean-Der
Copy link
Member

Ok great, I think we should fix that instead. Users have been copying/using this code so we should fix it deeper.

Would you mind making the change here to zero padding size? I believe that's the issue

@strangesast
Copy link
Author

not at all. I've created this pr over there

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

2 participants