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

你好,请问RTSP服务器,多个客户端rtp over tcp连接下,如何区分不同的RTCP的包,提供给rtsp_muxer #311

Open
Pluto-kk opened this issue Sep 21, 2023 · 5 comments

Comments

@Pluto-kk
Copy link

code
如上面代码中,在onrtp回调中,有用户传入参数param和channel,请问如何区分是来自于哪个连接的RTCP包,麻烦有时间看一下,谢谢
if(rtp->onrtp) rtp->onrtp(rtp->param, rtp->channel, rtp->data, rtp->length);

@ireader
Copy link
Owner

ireader commented Sep 22, 2023

这里的rtp_over_rtsp是每个连接独立的,每个rtsp对应一个连接, 多个用户有多个不同rtsp对象。

同样多个用户对应不同的rtp对象。

@Pluto-kk
Copy link
Author

image
image
明白。有个地方,通过rtsp_server_listen创建连接的多个rtsp对象,都是公用的rtsp_server_listen中传入的同个aio_rtsp_handler_t,使用相同的onrtp回调函数,在这个函数中只有区分通道号,区分不了是哪一个rtsp session

@ireader
Copy link
Owner

ireader commented Sep 22, 2023

感谢反馈, onrtp回调确实少了关联信息,我考虑下怎么建立关联关系。

@ireader
Copy link
Owner

ireader commented Sep 22, 2023

设计时只考虑了rtsp拉流模式, 没有充分考虑到推流模式,漏掉了rtp over rtsp推流场景。

@Pluto-kk
Copy link
Author

image
image
你好,发现在rtp over tcp场景下,推流发送使用的是rtsp_server_send_interleaved_data,调用的send阻塞接口,在客户端断网情况下会一直阻塞住

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

2 participants