-
Notifications
You must be signed in to change notification settings - Fork 390
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
Capture rtp host and port from sdp #428
base: master
Are you sure you want to change the base?
Conversation
Hi! Could you rebase this against master and fix so all tests succeed? Thanks! |
d8fe5d2
to
8f454e5
Compare
done. I also made find_in_sdp availability independent of compile flags as the PR will allow sending RTP without pcap support. |
Interesting idea. I'm a bit reluctant to allow overloading the last_HEADER for this purpose though, as media_ip is not a header (obviously). It's already a jungle of small little hacks here and there. How about you make it (*) See: 7e62db1 and |
Or perhaps |
@@ -957,6 +955,19 @@ char * call::get_last_header(const char * name) | |||
ERROR("call::get_last_header: Header to parse bigger than %d (%zu)", MAX_HEADER_LEN, strlen(name)); | |||
} | |||
|
|||
if(strcmp(name, "media_ip")==0) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I wonder if it might be slightly better to always call extract_rtp_remote_addr
(at line 2820 or so) instead of guarding it with #ifdef RTP_STREAM
, and store the host/port off as member variables on the call
object, then just use those (in the same way we use the pre-stored peer_tag
when handling E_Message_Peer_Tag_Param
). That would guarantee that the host/port would be retrieved consistently whether you used built-in RTP streaming or this method.
8f454e5
to
50e0e02
Compare
Could you guide me how to achieve this? Where would I have to add the respective code?
Will do once I find some free time
Will do |
This allows the creation of RTP streams with ffmpeg instead of pcap replay. Snippet from UAC scenario: