Coder Social home page Coder Social logo

TCP support about libstreaming HOT 11 OPEN

fyhertz avatar fyhertz commented on August 19, 2024
TCP support

from libstreaming.

Comments (11)

tulkas85 avatar tulkas85 commented on August 19, 2024

maybe I found a temporary solution.
Using wireshark on smartphone I see that RtspClient using always same range of udp ports (6970-6978 there are only of my experience)
Adding rule on router to forward these udp ports to my local wowza server all works fine.

Does libstreaming assign these ports in source code ?
If so I would understand how can I manage this range of udp ports.

from libstreaming.

fyhertz avatar fyhertz commented on August 19, 2024

Hi,

Yes, you need to redirect udp ports to your wowza media server if it is behind a NAT. This is not a bug, it's just how things work.

The UDP destination ports of the stream are chosen by wowza during the SETUP request of the RTSP client, not by libstreaming.

I am not a wowza expert, but there may be a way to force those ports somehow... But if you intend to receive streams from more than one client at a time, beware that they will all need to use at least two UDP ports...

from libstreaming.

tulkas85 avatar tulkas85 commented on August 19, 2024

It's possible to work on TCP instead of UDP ?

from libstreaming.

fyhertz avatar fyhertz commented on August 19, 2024

Not right now, but I'm working on it :)

2014-02-21 3:35 GMT-05:00 tulkas85 [email protected]:

It's possible to work on TCP instead of UDP ?

Reply to this email directly or view it on GitHubhttps://github.com//issues/21#issuecomment-35708289
.

from libstreaming.

avaranovich avatar avaranovich commented on August 19, 2024

@fyhertz If one would be willig to contribute into TCP support, can you point to the places where it should be implemented? I understand the RTSP set up should be different, but also a TCP sockets should be used instead of UDP. It should be relatively easy to implement. What do you think?

from libstreaming.

fyhertz avatar fyhertz commented on August 19, 2024

Hi,

I just published a patch that adds TCP support, it's not ready yet, there are still things I need to handle. For instance, if the RTSP server sends RTCP receiver reports back to libstreaming, the RTSP client won't be able to handle them. And if the bandwidth is not good enough, the fifo of the TCP socket will just grow and eventually saturate.

If you want to try it out use that:
mClient.setTransportMode(RtspClient.TRANSPORT_TCP);
before starting the RTSP client.

If you want to improve TCP support go ahead, check the last commit to see the modification I made.

from libstreaming.

hdezela avatar hdezela commented on August 19, 2024

To fix this you have to edit /usr/local/WowzaStreamingEngine/conf/Application.xml, specifically the following lines within the "RTP" section:

<RTSPBindIpAddress>[INTERNAL_IP]</RTSPBindIpAddress>
<RTSPConnectionIpAddress>[EXTERNAL_IP]</RTSPConnectionIpAddress>
<RTSPOriginIpAddress>[EXTERNAL_IP]</RTSPOriginIpAddress>

That should take care of it. Also, rather obviously but worth mentioning, open up the requisite UDP ports on your firewall.

from libstreaming.

tulkas85 avatar tulkas85 commented on August 19, 2024

@fyhertz some news on TCP support ? Now does it works ?

now I need to stream over Internet (peer to peer mode, from android smartphone to client pc) and udp packet usually could be blocked around the Internet network.

from libstreaming.

halsafar avatar halsafar commented on August 19, 2024

I could also make some use of libstreaming if it supported a TCP Socket. Even without any of the RTP stuff. I want to use libstreaming basically with a TCP websocket.

from libstreaming.

irasoftwares7 avatar irasoftwares7 commented on August 19, 2024

@tulkas85 Any news?? I also want to achieve the same you are trying to, and stuck at the same point.

from libstreaming.

wen842520 avatar wen842520 commented on August 19, 2024

如何设置让libstreaming支持rtp over tcp呢 在客户端只支持rtp over tcp的情况下,客户端不能显示视频。

from libstreaming.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.