Capturing Video stream with JMF under LINUX??

Ok, i am confused! I have read lots of info over this subject, but at some sites and forums i read that some people did not succeed in capturing ( and displaying) a live video stream with Java under Linux.
Is it possible? and if so, can someone give me a sample code or a link to a sample code? thankz a lot!!

Cross-posted
http://forum.java.sun.com/post.jsp?forum=54&thread=456420&message=2083138&reply=true

Similar Messages

  • Using cinepak codec and JMF under linux mandrake

    Hello,
    I have a big problem using JMF under linux to read video files encoded with the Cinepak codec.
    I don't know if i'm the only one in this situation, so if you are too please let me know :)
    I tested my project under both windows and linux. Under Windows, no problem : the cinepak encoded file is read perfectly. Under linux, it doesn't work. Even if i try to read it with JMStudio. So i think it may be a problem of codec under linux, but it isn't because i can read the video file with a linux video player.
    I don't know what to do and it's very important for my project that i can read cinepak under linux.
    Thanks in advance for any help
    Alex

    well, your not the only one.
    I have it working in Debian, and JDS.(JMF is setup automatically in JDS).(2.6.6 kernel)
    I looked at the installation structure of JDS, and was able to duplicate what they did for Debian.
    Maybe it will work for Mandrake two??
    ok, all you have to do is copy or create soft links from your Mozilla directory, just like you did with the java plugin, and link to all the *.so files in JMF-2.1.1e/lib directory.
    Should work.
    I also read that not haveing the native files only matters if you are doing Capture. not play.
    to get your ATI All-in-Wonder 128 to work, make sure you install the correct driver, and have it working under linux, then try it in JMSTUDIO

  • P2p video streaming using jmf (is it possible to "forward" the stream ?)

    Hello
    In my project a peer will start streaming captured video from the webcam to his neighbors and then his neighbors will have to display the video and forward(stream) it to their neighbors and so on . So my question is can i do this using jmf , a simple scenario will be : peer_1 streams to peeer_2 and then peer_2 to forward(stream) the video received from peer_1 to peer_3 .
    I've read the jmf2_0 guide and i've seen that it's only possible to stream from a server to a client and that's about it , but i want also the client to pass the stream forward to another client ... like for example [http://img72.imageshack.us/img72/593/p2pjmf.gif|http://img72.imageshack.us/img72/593/p2pjmf.gif]
    I want to know at least if this it's possible with jmf or should i start looking for another solution ? and do you have any examples of such projects or examples of forwarding the stream with jmf ....
    thanks for any suggestions

    _Cris_ wrote:
    I want to know at least if this it's possible with jmf or should i start looking for another solution ? and do you have any examples of such projects or examples of forwarding the stream with jmf .... You can do what with JMF. Once you receive the stream, it's just a video stream. You can do anything you want with it...display it, record it, or send it as an RTP stream.

  • Capture video stream from network

    Hi all,
    I have application to broadcast video to network.
    And I want to write app use jmf to capture video stream.
    if you have any sample source code, please send to me
    (my mail: [email protected]).
    Thank you.

    yap
    avtransmit2 is giveing ERROR (line:123 "Couldn't create DataSource") so i thing medialocator is not finding so datasource is not created but variable locator is not NULL.
    i am trying to transmit from webcam (realtime).

  • How to play live Video Stream with Flex?

    I'm trying to get Flex Builder 3 to play a live video stream with Flash Media
    Server and Flash Live Media Encoder.
    I'm able to stream pre-recrorded (vod) flvs in flex from flash media server.
    I'm able to stream live video using Flash/FMS/Flas Live Media Encoder, but not
    with Flex.
    This code streams pre-recorded Video on Demand flvs, but not live streams:
    If I change source to "rtmp://localhost/live/livesream.flv, I get nothing.
    What am I doing wrong?
    <?xml version="1.0"?>
    <!-- controls\videodisplay\VideoDisplayFMS.mxml -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
        <mx:HBox>
            <mx:Label text="RTMP FMS 2.0"/>
            <mx:VideoDisplay
                autoBandWidthDetection="false"
                source="rtmp://localhost/vod/Legend.flv"/>
        </mx:HBox>
    </mx:Application>
    Oh and sorry for the double post. I didn't know there was a seperate FMS forum.

    That worked! Thanks  *very* much. Stupid of me to forget to set the live attribute to true. Also removed the .flv. BTW: what video component do you prefer?
    Here's the working code:
    <?xml version="1.0"?>
    <!-- controls\videodisplay\VideoDisplayFMS.mxml -->
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
        <mx:HBox>
            <mx:VideoDisplay
                live="true"
                autoBandWidthDetection="false"
                source="rtmp://localhost/live/livestream"/>
        </mx:HBox>
    </mx:Application>

  • RTP (UDP) multicast stream with JMF...?!

    Hi.
    I am quiet new in the material of jmf and its plugins. I have a network which offers me an UDP stream (mpeg2 or mpeg4 both could be available). I can watch this stream with an freewareplayer called VLC.
    When using the JMF Studio tool, I can't watch the stream ... The Player is waiting for signals and breaks after 60 seconds. So, okay ... Maybe the JMF doesn't bring the right codec with it.
    Now I've installed jffmpeg, but that doesn't help a lot. I write done the JAR File in Classpath and installed the Plugin, MimeType and Demultiplexer (as described) in the JMF Registry. The behaviour of JMF Studio is the same. Does anybody have an idea wether jffmpeg supports this kind of streaming
    and/or what I can do to get the stream?! Maybe there is an better Plugin for my solution.
    I can't suppose that nobody here ever tried to get an Mpeg2 or Mpeg4 multicast stream with JMF. There must be an solution.
    Many thanks for your help and reply!
    Jan Stanetzki

    Hi funnyjanni,
    May be I am writing this after 4 years.
    I am also in the stage when you faced the same problem. You might have found the solution to this.
    Please help me on this. I am trying to use jffmpeg to play UDP mutlicast stream.
    Thanks
    jklanka

  • Play RTSP stream with JMF

    hello, all, i tried to play RTSP stream with JMF, but i always get error:
         connection info: IN IP4 0.0.0.0
         connection info: IN IP4 0.0.0.0
         Failed to realize: Server is not responding
    But when i play RTSP stream with VLC, everything is well.
    Anybody can help me?
    Regards,
    lefish

    JMF does not. JMF only plays RTP-protocol streams.I doubt it.....though I have never tried to play RTSP streams using JMF but seeing following links I do think client side RTSP is supported by JMF:
    [http://java.sun.com/javase/technologies/desktop/media/jmf/reference/faqs/index.html#jmf2-rtsp-features]
    [http://java.sun.com/javase/technologies/desktop/media/jmf/2.1.1/support-rtsp.html]
    Thanks!

  • How does exactly AMS sync a video stream with another stream of audio only ?

    I have the following situation: 2 instances of FMLE on one machine and another machine with AMS Starter.
    The instances of the FMLE are:
    1. Video H.264 + audio MP3
    2. Audio only MP3 - track 1
    The application on AMS is a livepkgr/_definst_ and i am using HDS with a live event
    I have an OSMF based player to consume the streams and to do audio switch using late binding audio.
    When I consume the Video with the Default audio everything works just fine. The problem is that when I try to consume the Video with the other audio track, the audio tack has a 1 second delay compared to the video.
    I have tried to fix this by changing the configurations on the FMLE, but it doesnt seem to work. So I really want to know how does exactly AMS syncronize differents streams, in this case a video stream with a different audio stream.

    First, what is the file format, and its specs. for the remote recorder?
    Though the rates of modern cameras and digital recorders SHOULD match 100%, in the real-world, they seldom do. This make perfect syncing a labor intensive process.
    One should do tests between the cameras and the recorders, to find out the % or error. Then, adjust their Audio to match first. As an example, one user in the PrPro Forum tested his Panasonic cameras, and his Zoom recorders, and found that the Zooms were off by 0.04% constantly. To correct this, he used the Time Remapping (with Maintain Pitch checked), and would apply that adjustment to all of the Zooms' files - perfect sync.
    As for the Waveform not displaying for your remote recorder, did you allow those files to completely Conform (creation of the CFA and PEK files, the latter is the Waveform Display)? See this article: http://forums.adobe.com/thread/726693?tstart=30
    Also, you should be able to increase the vertical zoom of your Audio Tracks, and hence any Clips on them, by hovering the Cursor over the junction between Tracks, in the Track Header, and when it turns into a = sign, with up/down arrows, click+drag. Then, you should be able to find commonality in the beginning, to sync up to. Tip: for this critical work, toggle the Snap feature OFF, with the S key.
    Good luck,
    Hunt

  • Play audio file with jmf on linux?

    a simple audio player as flow:
    import javax.media.*;
    import java.io.File;
    import java.net.URL;
    public class SimpleAudioPlayer {
        private Player audioPlayer = null;
        public SimpleAudioPlayer(URL url) throws Exception {
            audioPlayer = Manager.createRealizedPlayer(url);
        public SimpleAudioPlayer(File file) throws Exception {
            this(file.toURL());
        public void play() {
            audioPlayer.start();
        public void stop() {
            audioPlayer.close();
        public static void main(String[] args) throws Exception {
            File file = new File("/usr/local/download/1.wav");
            SimpleAudioPlayer sap = new SimpleAudioPlayer(file);
            sap.play();
    }when run the program
    javac -cp jmf.jar SimpleAudioPlayer.java
    java -cp .:jmf.jar SimpleAudioPlayer
    the output as flow:
    Unable to handle format: ima4/ms, 8000.0 Hz, 4-bit, Mono, Unsigned, 4027.0 frame rate, FrameSize=4096 bits
    Failed to prefetch: com.sun.media.PlaybackEngine@defa1a
    Error: Unable to prefetch com.sun.media.PlaybackEngine@defa1a
    How can I play wav file with jmf on linux?(OS is debian5 and jmf cross-platform pack)

    thanks for your reply.
    I tried to replace the wav file "1.wav" with the linear encoded WAV download from pscode.org,and run the code again,but
    BasicTrackControl:prefetchTrack():96 1 bm = com.sun.media.BasicRendererModule@1186fab
    BasicRendererModule.doPrefetch:155 Render : true
    Render buffer size: 32768
    BasicRenderModule.doPrefetch:159
    javax.media.ResourceUnavailableException: Cannot intialize audio device for playback
    at com.sun.media.renderer.audio.JavaSoundRenderer.open(JavaSoundRenderer.java:93)
    at com.sun.media.BasicRendererModule.doPrefetch(BasicRendererModule.java:158)
    at com.sun.media.BasicTrackControl.prefetchTrack(BasicTrackControl.java:99)
    at com.sun.media.PlaybackEngine.doPrefetch1(PlaybackEngine.java:682)
    at com.sun.media.PlaybackEngine.doPrefetch(PlaybackEngine.java:658)
    at com.sun.media.PrefetchWorkThread.process(BasicController.java:1430)
    !!!!!!!§§§§§§§§§§§ BasicTrackControl:prefetchTrack():96
    at com.sun.media.StateTransitionWorkThread.run(BasicController.java:1339)
    Unable to handle format: LINEAR, 16000.0 Hz, 16-bit, Mono, LittleEndian, Signed, 32000.0 frame rate, FrameSize=16 bits
    Failed to prefetch: com.sun.media.PlaybackEngine@26e431
    Error: Unable to prefetch com.sun.media.PlaybackEngine@26e431

  • Video Streaming with JSP and JMF.

    Hi. I have this problem. I'm projecting (not building yet) a system. In this system i have a Local Computer, a server, and a Web Page (JSP). The Local Computer is going to capture video from a WebCam with JMF. This videos is going to be passed to the server by RTP Control. A Web Page (JSP) is gonna acess the server to get this video and show it (Real Time Streaming).
    My doubt is, how I can do that on JSP ? How i can get the video from server (remebering that this one is getting the video from the local computer) and show it in my page ?

    no one ????

  • Capture a several streams with jmf?

    i want to capture streams from 4 USB webcams in the same times.
    it's possible with JMF? and how?
    the JMStudio know just one capture device, if i link 2 webcams i capture just one stream?????
    please if you have solution send it to me,
    think you!!

    I think you don't have problems, because you should query the JMFRegistry, and you'll obtain the list of all multimedia devices installed in your system.
    Also, I suggest you a visit to Solutions section, look at "monitor.zip", there are some interesting files, regarding query of JMFRegistry. Good luck. :)

  • Cannot install JMF under Linux Mandrake 10

    I simply cannot install JMF under the Mandrake 10 Official Linux distribution. I downloaded the jmf-2_1_1e-linux-i586.bin file and tried to execute it as root. It unzipped some files then showed me an error message about AWT and GTK+. I found a hack consisting of modifying the .bin file to have the PATH variable point to SUN JDK, the error does not show up, but the installation still does not work. In fact, the installation works, but the Diagnostics applet keeps telling me than class files are not present. My Mozilla 1.6 Java plugin is working and displaying the applet. My JMF lib directory does not contain sound.jar, such jmf.jar. I set the CLASSPATH and LD_LIBRARY_PATH according to the readme.html file. I would like to know if it is a compatibility problem with Mandrake 10, the 2.6 kernel or if JMF just DO NO work under Linux. In the latter case, JMF is a violation to the Java portability philosophy and I would never use it on my own initiative, just if I were asked to.
    After the files are unzipped, I have the following warning and error messages.
    Warning:
    Name: HorScrollBar
    Class: XmScrollBar
    The specified scrollbar value is greater than the maximum
    scrollbar value minus the scrollbar slider size.
    JavaSound Capture Supported = true
    JavaSoundAuto: Committed ok
    java.lang.Error: Can't open video card 0
    java.lang.Error: Can't open video card 1
    java.lang.Error: Can't open video card 2
    java.lang.Error: Can't open video card 3
    java.lang.Error: Can't open video card 4
    java.lang.Error: Can't open video card 5
    java.lang.Error: Can't open video card 6
    java.lang.Error: Can't open video card 7
    java.lang.Error: Can't open video card 8
    java.lang.Error: Can't open video card 9
    Done.
    Even if I do not have a working video capture card (I have an ATI All-in-Wonder 128 but it is not working under 2.6 kernel), JMF should work because some people do not have a video capture card. I also tried with the cross-platform ZIP file, but this one does not contain sound.jar either and the Diagnostics applet keeps complaining about missing class files. I tried to search on the Web for solutions to this problem or for a way to change the CLASSPATH used by the Mozilla Java plug-in (if it uses a different CLASSPATH than the one from the environment variable), but nothing, nothing. Is there a distribution from which JMF would work better than Mandrake 10? Or can JMF work only under Microsoft Windows or Sun Solaris? I also tried Blackdown, but a README file directed me to the Sun's page, nothing to download here about JMF.

    well, your not the only one.
    I have it working in Debian, and JDS.(JMF is setup automatically in JDS).(2.6.6 kernel)
    I looked at the installation structure of JDS, and was able to duplicate what they did for Debian.
    Maybe it will work for Mandrake two??
    ok, all you have to do is copy or create soft links from your Mozilla directory, just like you did with the java plugin, and link to all the *.so files in JMF-2.1.1e/lib directory.
    Should work.
    I also read that not haveing the native files only matters if you are doing Capture. not play.
    to get your ATI All-in-Wonder 128 to work, make sure you install the correct driver, and have it working under linux, then try it in JMSTUDIO

  • How to receive video stream with different codec

    Hello Experts,
    I am transmitting the video stream from a system using RGBFormat with dimension 320x240 but at the receiver side in the absence this CODEC I need to receive the stream with RGBFormat dimension 160x120.
    I request you to please guide me that how can I do this.
    Apart from this please let me know that is there a way through which I can add codec RGBFormat with dimension 320x240 ?

    I am transmitting the video stream from a system using RGBFormat with dimension 320x240 but at the receiver side in the absence this CODEC I need to receive the stream with RGBFormat dimension 160x120.You need to do what exactly? Can you explain that better, because, that doesn't make much sense to me. You want to transmit a video stream at 320x240 and have the client receive it at a different resolution that you sent it at... that just doesn't make sense.
    I'd like to mail you a letter on a legal sized sheet of paper, but I'd like for you to receive it on standard paper... See? Doesn't really make any sense...
    Apart from this please let me know that is there a way through which I can add codec RGBFormat with dimension 320x240 ?The RGB format is already defined for JMF, it just doesn't have an RGB-RTP variant for sending over RTP...and creating all of the things you have to create to make JMF send in RGB is pretty complex, complicated stuff.

  • Synchronize on video stream with mplayer

    Hello,
    I recently bought an EasyCap DC60+ USB adapter. It is an RCA -> USB adapter which is recognized as an USB webcam by the kernel.
    I installed the easycapd60 module and it works fine for video with no sound, but I can't get audio working correctly. It looks like my audio stream is 1 second late on the video stream (I get the sound one second after the image).
    The problem is that mplayer is synchronizing the playback on the audio stream (I think). That means that my video stream is delayed in order for it to be in sync with the audio stream. As I want to use this DC60+ adapter to play video games on my computer screen, I can't tolerate a 1 second delay.
    A solution to this problem would be to ask mplayer to synchronize on the video stream instead of the audio stream, then play with the A/V sync parameters to get the audio synchronized. But I can't find the parameter to do this in the mplayer manpage.
    So my question is the following : does this parameter exist ? And is there another solution I didn't think of which could solve my problem ?
    Last edited by delroth (2010-06-06 00:26:14)

    Did you have to do anything special to get the DC60+ to work?  I've got one installed using the em28xx driver and it eventually makes my USB mouse stop responding, and sometimes the whole system crashes after that.

  • Can quicktime pro capture video stream?

    Can QT pro record video streams off the internet? I thought it was only able to capture embedded video files. Video streams aren't donwloaded into cache, so they have to be saved as they're received. Could someone clarify? Thank you.

    Pro can't save true streaming media.

Maybe you are looking for

  • Unable to check documents in CS using MaxDB

    Good Day Just implemented ECC 6.0 and Content Server using MaxDB 7.8. Think everything is working and locking o.k. (connections, CR, etc.). But I still can't check in any document. Always receive a Message: Error while checking in and storing: C:\tem

  • HP Photosmart Premium All-in-One Printer --reverts to offline mode and can't get back online

    What is the quickest, easiest way to get the printer back online?   There seems to be no way to get it back online.  I'm using Windows Vista OS.  Printer is running on wireless network (2wire).   Appreciate a quick resolution. Thanks!

  • Servlet Hello World

    I'm tying to run the hello world Thinking in Entreprise Java servlet: //: c15:servlets:ServletsRule.java // {Depends: j2ee.jar} import javax.servlet.*; import javax.servlet.http.*; import java.io.*; public class ServletsRule extends HttpServlet {   i

  • How to detect Non-English characters

    I have a report containing Korean language and English in a single column. My requirement is to detect the Korean language and pass it to the place holder column and detect English language and pass it to other place holder column. Please help me guy

  • Opportunity not showing whan searched by an Account

    Hi In Web UI, when the user is trying to search for a particular opprtunity by Opportunity ID and  the system shows it however when the user tries to search it  by its account the system doesn't show any result. The status of this opportunity is "Com