Newest 'ffmpeg' Questions - Stack Overflow
Les articles publiés sur le site
-
How to install ffmpeg in php
15 mai 2014, par John SanjayI would like to install ffmpeg for my site. But I am using shared server so the hosting will not provide this
Could any one please help me to install ffmpeg(I am not using Linux environment)
-
ffmpeg php video basic uses and types
15 mai 2014, par HackerManiacCan anyone give a code on how do i covert a video using ffmpeg.
As thought currently i have only uploading system.
vu.php(only a part is shown)
define('UPLOAD','../../videos/'); $fileName = time().$file['name']; $target = UPLOAD.$fileName; if(move_uploaded_file($file['tmp_name'],$target)){ exec("ffmpeg -i ".UPLOAD." ".UPLOAD.$filename.".flv"); }
This pice of code block just uploads the video on video folder but does not converts it to
.flv
. I am not sure how to use ffmpeg.My diretory looks like this
www[localhost]->videos[videos folder] www[localhost]->pictures[pictures folder] www[localhost]->resources[folder]->php[folder]->vu.php
I also want to return a
.jpg
image of any frame of video through json by converting via ffmpeg and uploading it topictures
folder.return json_encode(array("thumbnail"=>$image_src));
UPDATE 1
The above stuff was solved but now i have a question regarding video conversion. Suppose i have a file.avi and i want to convert it in 3 sizes of
.flv
format -> Low(320p) ,Medium (720p)and HD(1080p)what commands will i have to send to
shell_exec();
and will that be fast enough? CUrrently what i have is$vidSize = "640x480"; $ffmpeg -i $videoFile -ar 22050 -ab 32 -f flv -s $vidSize $vidFile
And i am not sure what
-ar
and-ab
means and what value will be good for all those 3 sized videos? -
Why i can not listen audio from URL in javaFX WebView ?
15 mai 2014, par Jay JoshiI am developing one media app using javaFX.. so I need to put play audio functionality in the app.. but du to some reason i could not play the audio.
I an new for javaFX so. Is there any ffmpeg media package for it?
-
FFmpeg convert single image into video Android
15 mai 2014, par berserkI am trying to convert a single image into a video using FFmpeg. I have tried following the files:
"ffmpeg -analyzeduration 2147483647 -probesize 2147483647 -i " + packat.get(i).path +"-r 25 -t 1000 -y op.mp4" "ffmpeg -loop 1 -r 23.976 -i input.jpg -t 00:00:02 -vcodec qtrle -an output.mov" "ffmpeg -i c:\rawvideo\mask.bmp -loop 1 -r 29.97 -s 720x480 -aspect 4:3 -t 00:04:05 -vcodec mjpeg -vb 11261600 -an c:\rawvideo\fullmask.avi"
But all of them give me this annoying error:
Can not process SOS before SOF, skipping marker parser used 0 bytes (0 bits) decode frame unused 0 bytes decoding for stream 0 failed Could not find codec parameters for stream 0 (Video: mjpeg): unspecified size Consider increasing the value for the 'analyzeduration' and 'probesize' options /storage/sdcard0/cblVE/temp/0.jpg: could not find codec parameters exit_program: 1
Please help. I have searched for a solution from a week, but I have found nothing.
-
Load bitmap into FFmpegFrameRecorder
15 mai 2014, par DanMhow can I load bitmap into FFmpegFrameRecorder? My old code loaded it from SD card and now I wish to put id directly. I use javacv.
FFmpegFrameRecorder recorder = new FFmpegFrameRecorder(Environment.getExternalStorageDirectory().getPath()+ "/MyApp/Media/test-ffmep.mp4", w, h); public void offerEncoder(Bitmap input) { recorder.record(opencv_highgui.cvLoadImage(input)); //recorder.record(opencv_highgui.cvLoadImage("/sdcard/MyApp/Media/" + input + ".bmp")); //input was string }