Need help in java converting mp4 video to wmv video - java

I have done some research on converting mp4 to wmv in java but have not found anything but advertisements on applications that convert mp4 to wmv. I do not know where to start when converting videos in java and I would be most grateful if anyone could help. I'm not into fancy graphical java apps so just command line would do nicely. Thank you.

to convert mp4 to wmv take a look at ffmpeg

Have you tried JFFMPEG. Also you may want to look into mencoder and ffmpeg.

Related

How to build an mp4 from a set of still images and an audio file in Java

I want to take a few still images and an audio file and turn them into an mp4 file. I am most familiar with java, so that is what I'd prefer to do the coding in. Is there any way to do this, or any library I should look into? I looked at mp4parser, but I couldn't see how to do what I am looking for.
Is there a reason to be doing this in java? Something like ffmpeg can do this, but it's a command line tool.
Well, also a C++ library. I guess there's a Java binding for it, too: https://code.google.com/p/jjmpeg/
For that matter, you could take a look at the ffmpeg source, figure out what they're doing here:
ffmpeg -start_number n -i test_%d.jpg -vcodec mpeg4 test.mp4
Mux in some audio, and you're off. Anyhow, that's how I'd start out. Perhaps someone else will chime in with better specifics.

Convert WMA and AAC to MP3 in Java

I'm looking for an Java API able to convert various audio formats, especially WMA and AAC, to MP3. Any clue?
I doubt that you will find native code for that, but you can take a look at one of the Java wrappers from ffmpeg like FMJ or Jffmpeg.

Need Sample code to capture audio in mp3 format and play it using Java

I need to capture audio in mp3 format using Java and was looking for any sample code. Any code that converts wave file into mp3 would also work. The code should work on Windows and Mac. I looked at JLayer but could not find any sample code. I used JMF but the CaptureDeviceManager does not find any device.Please let me know the usage code as well.
It ain't sample code, but there is a library here http://www.javazoom.net/mp3spi/mp3spi.html that works with mp3 format in Java. I hope it can help. I only have sample code of this library in Jython...

Is there a simple way to play a rtmp stream in java?

I want to play an MP4 videon streamed over rtmp protocol in java.
I found a few rtmp libraries (yuv, red5), but nothing on mp4 display.
Is there a (possibly simple and maybe platform-indenpendent) solution to do it in java?
Most rtmp streams in my experience tend not to be MP4. There's nothing particularly clever about rtmp streaming though, and if you really can't find anything to fit your needs the way to go is to get hold of a copy of rtmpdump, rip the stream to file and play it.
BTW I'm playing with the IBM MP4 sdk toolkit at the moment, downloadable from http://www.alphaworks.ibm.com/tech/tk4mpeg4 . Seems straightforward enough, dled, unzipped and had the Swing demo app playing MP4s in NetBeans in under 5 minutes. If the stream you're talking to is genuinely MP4 you could probably figure out how to hotwire it to the stream fairly quickly from what I'm seeing of the IBM MP4 API.

100% Java encoder for AVI animation

I am looking for a 100% Java solution for encoding software generated images into an AVI stream together with an uncompressed audio track.
At the moment I am using JMF, but its size and installation problems make it a bad solution for my purpose.
While it does not support audio, I created an MJPEG AVI Java class some years ago. You basically just tell it the resolution of your output video, along with the frame rate, then you just keep adding images to it. When you are done, you tell it to finish and it'll close out the AVI. It is based off of the Microsoft documentation on AVI, RIFF, and BITMAP file formats.
Other than not supporting audio, the only real problem is it implements the version of the AVI format limited to 2GB per file. While the class will write out a much larger file, I am uncertain that any players or video editors would be able to read it.
The way I've used this code in the past, is to generate an MJPEG AVI for processing in a video editor (adding audio, etc. in the editor). It helped me with automating some tedious slide show generation. Not sure if this code will help you, as is, but it might help if you are trying to roll your own solution. MJPEGGenerator.java is available if you are interested!
You can use JMF, see this nice example.
There is a nice blog entry here:
http://www.randelshofer.ch/blog/2008/08/writing-avi-videos-in-pure-java/
By Werner Randelshofer

Categories