954,536 Members — Technology Publication meets Social Media
Username:
Password:
Lost login information?
Have something to say? Contribute New Article Reply to this Article

Convert Video into FLV format

Hi,

We have a java web application where users will be submitting videos. I'm trying to write a java program that is able to convert any movie file into compressed SWF video and FLV streaming video formats. The code should convert almost all popular file extensions such as AVI, MPEG, WMV, ASF and 3GP.

I've never worked with filestreaming etc before, so I would appreciate any insight you can provide on how I can go about doing this.

Thanks

alrevolver
Newbie Poster
1 post since Oct 2008
Reputation Points: 10
Solved Threads: 0
 

Pure Java solutions / libraries for converting videos to different formats might be a bit hard to get by. There are a lot of open source / free converters out there [like ffmpeg] which you can use in conjunction with your application to achieve the desired task since re-writing the entire thing in Java would be a significant act.

One of the ways to do it:
• Use your web application as a front end for allowing users to upload their videos.
• When storing the videos, either store them directly to your File system or use a Database; depends on how your project is engineered.
• Run a background process which would pick up the file from a specified directory, convert it and put it in another directory [or table if using Database].
• The background process would run a command line version of the file conversion utility for converting files.

Another way would be to create a thin wrapper around the open source libraries out there which are written in C or C++ and make native calls using JNI.

But on a final note, this is by no means a simple project and having an architect on your team who *knows* things really helps.

~s.o.s~
Failure as a human
Administrator
11,938 posts since Jun 2006
Reputation Points: 3,281
Solved Threads: 734
 

I want a library to use it in my java code. so I allow the user to upload his video in any format and I'll store it somewhere in flv format

rana84
Newbie Poster
1 post since Oct 2008
Reputation Points: 10
Solved Threads: 0
 

I will assume Alrevolver and rana84 are the same person. I will just ask did you understand what s.o.s. just have told? :-| Read his post again and again and try to make sense. Your answer is already given.

orko
Junior Poster
164 posts since Apr 2006
Reputation Points: 46
Solved Threads: 11
 

Java Audio Video Encoder (Jave). Java wrapper for FFMpeg.

test
Newbie Poster
11 posts since Dec 2002
Reputation Points: 10
Solved Threads: 0
 

This article has been dead for over three months

Post: Markdown Syntax: Formatting Help
You