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

Bosch cameras RTSP media payload is 35 instead 96-127 on SDP #630

Closed
JTejedor opened this issue Oct 8, 2024 · 2 comments
Closed

Bosch cameras RTSP media payload is 35 instead 96-127 on SDP #630

JTejedor opened this issue Oct 8, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@JTejedor
Copy link
Contributor

JTejedor commented Oct 8, 2024

Hi there!
First of all, your libraries are simply awesome! Your mediamtx (old simple server) is a wonderful tool! Thank you really much for so great job.
Focusing on the problem at hand, we are working currently with Bosch cameras. These cameras are not strictly following rfc 3551 to determine the media payload in the SDP in RTSP context. Instead of using a payload between 96-127 to indicate an H26X payload, they are using payload 35. Which does not make much sense (BTW), but unfortunately that's what they make.

When trying to record from these cameras, we have found that it is not possible due to a thorough implementation where the media format is evaluated. If it is not between 96 and 127, it does not evaluate that it is h26x and returns generic, which makes it impossible to record in mediamtx.

Exactly it is on line 91 of the file pkg/format/format.go (

case payloadType >= 96 && payloadType <= 127:
).

We would like to know, if possible, if you consider it wise to include payload 35 in this case on line 91 (after discussion maybe the unassigned interval could be even better from 35 to 71). We understand perfectly well that you decline this request, so in that case, we will most likely fork mediamtx because we require it.

As it is a minimum change, we offer to do the PR ourselves if it is ok with you.

For further documentation you may check:

I prefer show the links directly, this way you can easily visualize that they lead to bosch security or github.

Many thanks in advance

@aler9
Copy link
Member

aler9 commented Oct 8, 2024

Hello, in this library we prioritize compatibility over standards. Provide a patch and it will be merged. Remember to provide the exact model name and a sample SDP too so we can keep track of why we shifted from the specification.

@aler9 aler9 added the bug Something isn't working label Oct 9, 2024
JTejedor added a commit to JTejedor/gortsplib that referenced this issue Oct 10, 2024
…ange 96-127 (bluenviron#630)

Add some test to make sure the unassigned interval is being considered
JTejedor added a commit to JTejedor/gortsplib that referenced this issue Oct 14, 2024
Add some test to make sure the unassigned 35 media type is being considered
JTejedor added a commit to JTejedor/gortsplib that referenced this issue Oct 14, 2024
Add some test to make sure the unassigned 35 media type is being considered
@aler9
Copy link
Member

aler9 commented Dec 4, 2024

This has been fixed by #632

@aler9 aler9 closed this as completed Dec 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants