JMF RTP/RTCP Packets

I' m using the Java JMF Environment and I want to write or show on the Screen the hole RTP and RTCP Packets. Not using a Processor to write only the data to a file.
I want to view how a hole RTP/RTCP packet is looking like when it is arrived to me.
Can somebody help me. I have sleeples nights.
Thank you very much.

Hi HagIP,
try using the DataSourceReader:
http://java.sun.com/products/java-media/jmf/2.1.1/solutions/DataSourceReader.html
After reading a Buffer from the Stream, you can convert it into its raw format using e.g.:
javax.media.Buffer b=new javax.media.Buffer();
byte[] data;
stream.read(b);
if ((b.getLength()>0)&&(!b.isDiscard())) {
data=(byte[])b.getData();
The actual typecast may depend on the internal representation of your data in the buffer, this example is for raw streams.
Now you just have to think of a way to visualize your data.
HTH,
Thomas

Similar Messages

  • Is it possible for JMF to monitor RTCP packet from another application?

    Hello Everybody.
    I'm developing an application that will gather statistics in Live Streaming transmissions.
    For that, I'll get bandwidth use and RTCP packets so I can put in a graphic packet loss and other relevant data that are put into RTCP Packet.
    I wanted to know if it's possible for JMF to monitor an existing stream (not created by the Java program), so I can use in my application (Java-based).
    Thanks a lot for the attention.
    Cheers,
    Bentow.

    Bentow wrote:
    And, what about a class that it have in the com.sun.media.rtp package? RTCPPacket?
    It doesn't have any docs about it. The problem is the the parent type is Packet, but different than the one, that in this case is used by the JPCAP. :(Like I said, JMF has the code in there to parse RTCP packets. But they aren't a peice of JMF you're supposed to be using. You'll just have to hack and slash to try to get something working with it. ;-)

  • URGENT !!! ANY GOOD BOOK FOR JMF - RTP programming ????

    Can you propose some books about JMF and RTP/RTCP programming ??
    Thanks in advance !!!

    The only JMF books available are "Essential JMF - Java Media Framework" by Rob Gordon (ISBN 0130801046), "Core Java Media Framework" by Linden deCarmo (ISBN 0130115193) and "Programming with the Java Media Framework" by Sean C. Sullivan, et. al. (ISBN 0471251690). All of them are very out-of-date and only cover JMF 1.x (i.e. no audio / video capture and no RTP). All of them were not very good to begin with but "Essential JMF" is probably the better of the three.

  • Monitoring RTP Data / Packet Loss / Packet Delay

    hiya folks
    what is everyone using to monitor their incoming and outgoing data in terms of packet delay and loss and myabe even load on the CPU??
    thanking anyone in advance for any help you provide

    i managed to do this now without the use of an external program, once you have finished transmitting the stream.
    you can run the following bit of code on thr rtp manager which shows you the following
    GlobalTransmissionStats stats;
    for (int i = 0; i < rtpMgrs.length; i++) {
    stats = rtpMgrs.getGlobalTransmissionStats ();
    System.out.println( "The total number of RTP packets transmitted :" + stats.getRTPSent() );
    System.out.println( "The total number of bytes sent :" + stats.getBytesSent() );
    System.out.println( "The total number of RTCP packets sent :" + stats.getRTCPSent() );
    System.out.println( "The total number of local collisions :" + stats.getLocalColls() );
    System.out.println( "The total number of remote collisions :" + stats.getRemoteColls() );
    System.out.println( "The number of packets that failed to get transmitted :" + stats.getTransmitFailed() );
              rtpMgrs[i].removeTargets( "Session ended.");
              rtpMgrs[i].dispose();

  • Turning off sending and receiving RTCP packets ?

    How do I turn off the automatic send of RTCP packets?

    I am using the rtpmanager and I am using it to send and receive rtp audio. But it is sending out RTCP packets. I have no need for RTCP packets. How do I tell the RTPManager not to send RTCP Packets?

  • JMF-RTP issues that I am facing on my network PC's

    Hello there,
    JMF-RTP issues that I am facing on my network PC's. -
    (1) I am using JMF whenever I am tring to receive RTP sessions I get purple color screen and shows nothing that is captured by CAM.
    (2) I am using AVReceive2.java to receive RTP sessions then again, only purple color screen and showing nothing.
    Waiting for feedback / solutions. And is there any forum that I can use to get solutions of these kind of problems.
    regards
    Chetan Kulthe
    CEO,ZeusCoder.com
    Web- http://www.zeuscoder.com
    Cell- +91-98 600 233 29

    Hello there,
    I dont think it is video card driver issue because when I click on JMStudio ->Transmit -> Capture , I can able to view my cam. If it is problem of video card as per you are saying, I cant able to view my cam. I think the problem is something else.
    I tried RTPApplet code to receive RTP sessions, I tried AVReveive also but same problem - Purple screen. I also tried same on JMStudio, but when i check statics it is showing data is transfered, I am not sure why this purple screen when I tried RTP Session. Last time on same PC, I can able to get RTP sessions properly using JMStudio. Now I reinstalled JMStudio, I dont know why this is so?
    Finally I have to use some Code to receive RTP session in some project that we are developing.
    regards
    Chetan Kulthe
    CEO, ZeusCoder.com
    Web- http://www.zeuscoder.com
    Cell- +91-98 600 233 29

  • Is Sun's JMF RTP RFC3550 compliant?

    I have been tasked with making sure Sun's JMF RTP library is compliant with the RFC 3550 spec. Does anyone know if this is true? I have been searching through this site and haven't been able to find a definitive answer.
    Here is a link to the IETF specification in case it helps.
    http://www.ietf.org/rfc/rfc3550.txt
    Thanks.

    I have been tasked with making sure Sun's JMF RTP library is compliant with the RFC 3550 spec. Does anyone know if this is true? I have been searching through this site and haven't been able to find a definitive answer.
    Here is a link to the IETF specification in case it helps.
    http://www.ietf.org/rfc/rfc3550.txt
    Thanks.

  • How to capture the video in a file using JMF-RTP?

    Please someone help in capturing the live streaming in a file using JMF......
    Thanks..

    Hi, I have a problem with RTPExport output video files. One side streams H263/RTP(AVTransmit2.java) and other write this steam to a file by RTPExport.java. When network conditions are ideal, output video file has same fps and same number of frames like original file. Problem occures, when theres packet lost in network, then output file has different fps,and also has less frames like original video(because it didnt write missing frames to file, and thats why it get shorter). Pls how can I achieve output file that will have the same fps like original one? How to write to file an identical copy of what I can see while receiveing video with AVReceive2.java? Its there a way to modifi rtpexport or avreceiver to do this? Thanks!

  • How to transfer multimedia file using JMF/RTP through Bluetooth

    Hi,
    I am trying to stream a multimedia file via bluetooth but I don't know how to wrap RTP into bluetooth connection.
    I also tried to cut the multimedia file in small pieces but they can't be read by the player.
    How can I stream a multimedia file via Bluetooth using JMF ??
    Regards,
    Danix

    -danix- wrote:
    Hi,
    I am trying to stream a multimedia file via bluetooth but I don't know how to wrap RTP into bluetooth connection.I know absolutely nothing about Bluetooth networking, but I assume you don't wrap protocols into connections with it...
    How can I stream a multimedia file via Bluetooth using JMF ??You'd need to write a custom RTPConnector that would transmit the RTP packets over a Bluetooth connection rather than the standard UDP socket...
    [http://java.sun.com/javase/technologies/desktop/media/jmf/2.1.1/solutions/RTPConnector.html]
    There's some code to get you started. You'll need to update the SockOutputStream & SockOutputStream classes of the RTPConnector to read/write to a Bluetooth connection rather than a UDP socket.
    Good luck.

  • RTP/RTCP  Port query for JXTA

    Hello,everyone~I got a question about JXTA.
    I am trying to develop a video transmisstion system using AVRecevie3.java and AVTransmit3.java.I have already make GUIs for both sides,they work pretty well.
    By replacing the default DataProgramSocket with JxtaMulticastSocket,i then wanna implement P2P.In RTPJxtaSocketAdapter.java(implemented by myself),rtp and rtcp read two different unrelated advs to communicate,the transmitter side seems being able to transmit packet,but the receiver-side cannot recevie the stream with a message:"watiing for rtp data to arrive......"What is the problem?Or am i toally wrong about the design?
    Since RTP and RTCP use neighboring ports to coordinate the transmission,what am i supposed to do to so that the receiver-side can get the rtp stream in JXTA?
    Sorry about poor english,hope myself clear enough...
    Looking forward to your reply....Thanks

    I had the same problem and when I saw that post, I was angry that no one let an answer. So, I will do.
    My application is switching Transmitter and Receiver to make a half-duplex communication. The ports number are static. A user (receiver) always use the same port and the transmitter connect to all the ports.
    Example :
    User A -> port 22222
    User B -> port 22225
    User A talk to user B with port 22225
    User A let control to user B
    User B talk to user A with port 22222
    The fix is very simple: let at least 3 ports between each user.
    I hope this could help someone.

  • Jmf -- RTP over TCP

    Not sure whether my question is logical..
    JMF transmits RTP Packets over UDP . Is there a way to configure to use TCP for media transmission instead of UDP?
    or is there any other way to use jmf for media transport between udp blocked networks.. any other way to do so.
    Please let me know.
    Edited by: alphonse.s on May 5, 2008 4:07 AM

    Hello alphonse.s
    I try to resolve this problem too. If you find any solution I will be very grateful for feedback :-)
    bye

  • VoIP using JMF - RTP tx, rx - doubt

    Hi, I am computer engineering graduate from India doing a VOIP project.
    I am using JMF to develop the software and I have a few doubts :
    1. There are quite a few techniques for RTP transmission :
    a) Using RTPSocket and a custom UDP handler.
    b) Using RTPManager to start a session.
    c) Using a medialocator (rtp//inet addr.port//ttl) and a Datasink.
    and may there are other methods too ?!
    Now which of these should I use so that I have the best quality voice ?
    Please advise.
    2. Secondly, I read that H.323 is the ITU-T standard for multimedia networks. Is it necessary for my software to adhere to this standard ? If yes, how can I go about it?
    My email-id is : [email protected]
    Thank you,
    Arun .K

    well friend it depends totolly on you, what sort of thing u want to do i mean using media locator to send and recieve the media streams u can only response to single stream.While using RTPManager u can have mutiple streams in a session and using custom UDP protocols u can have much more controll over the media stream.
    I think u should send me a little detail about what you want so that i can guide u properly.
    thank you
    bye

  • JMF , RTP and  IPV6

    Hello! How are you? I need to know if it is possible with the functions of JMF of RTP to transmit video and sound but using a direction IPV6� and if there is to modify something by where to begin� Thank you very much! So long.

    More debugging, but still at a block:
    It seems: com.sun.media.rtp.RTPSessionMgr is instantiated as the rtpmanager.
    There is no source for this and so cannot figure out why this fails.
    Best regards,
    -Arun.

  • JMF, RTP and SIP

    Hi,
    I am building an application that shall send streaming data to a mobile client (personaljava) with jmf. I read that RTP is blocked by many firewalls, so I wonder if it is possible to use an alternative protocol (SIP?) with advantages compared to RTP, still using JMF.
    Any hint appreciated..

    SIP is a signaling protocol and as far as I know it does not transport the media, it uses rtp to do so.

  • JMF RTP and Linux/Fedora Core3

    Hello,
    I am attempting to use JMF 2.1.1e with Linux/Fedora Core3, and see an exception as:
    java.io.IOException: Can't open local data port: 51450
    at com.sun.media.datasink.rtp.Handler.open(Handler.java:141)
    Debugging more, I can see the Handler.open fails when it is trying to
    rtpmanager.initialize(localaddr);
    where localaddr is "SessionAddress()" (no args to the constructor).
    I am unable to debug beyond this. Any help?
    Best regards,
    -Arun.

    More debugging, but still at a block:
    It seems: com.sun.media.rtp.RTPSessionMgr is instantiated as the rtpmanager.
    There is no source for this and so cannot figure out why this fails.
    Best regards,
    -Arun.

Maybe you are looking for