<div dir="ltr"><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Hi Team,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">I have a
working RTSP server setup (with reference from examples/test-video).</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Once the RTSP SETUP request is received, it assigns the server ports to receive the RTCP packets from client.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">As we need to pickup the server ports from a pre-defined list, I have configured the address pool as below:</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">pool = gst_rtsp_address_pool_new ();<br> if(pool != NULL ){<br><br> if(gst_rtsp_address_pool_add_range(pool, GST_RTSP_ADDRESS_POOL_ANY_IPV4, GST_RTSP_ADDRESS_POOL_ANY_IPV4, xx, yy, 0) != 1)<br> g_print ("\n Failed to add to pool !!!! \n");<br><br> gst_rtsp_address_pool_dump(pool);<br> gst_rtsp_media_factory_set_address_pool (factory, pool );<br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">}</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">This code is setting up the address pool correctly and once the stream is started, it picks up the port number from the assigned range. Works well.</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Now, i would like to get the port numbers assigned (dynamically) for each stream once it is configured. Could you please advise which signal/callback helps to get it for each Media-stream. </div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">i saw the method "<span style="background-color:rgb(245,242,240);color:black;font-family:Consolas,Monaco,"Andale Mono","Ubuntu Mono",monospace;font-size:13px">gst_rtsp_stream_get_server_port()". But how do i get the stream object ? Which Callback can help here.</span></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><br></div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">We need to support N number of clients with the same media stream. So the ports assigned will be different and needs to assign the firewall rules dynamically before getting the PLAY command for each stream.</div><div><br></div><div><br></div><div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small">Thank You,</div><div class="gmail_default" style="font-family:arial,helvetica,sans-serif;font-size:small"><span style="font-family:Arial,Helvetica,sans-serif">-- </span><br></div></div><div dir="ltr" class="gmail_signature" data-smartmail="gmail_signature">
<i style="color:rgb(153,51,0)"><b><font face="georgia, serif">With Best Regards,</font></b></i><div><b style="color:rgb(153,51,0)"><i> Ansa </i></b><div><b style="font-family:arial black,sans-serif"><font color="#993300"><i></i></font></b><font color="#993300"><i><br></i></font><br></div></div></div></div>