|
-
Jun 5th, 2008, 09:35 AM
#1
Thread Starter
Frenzied Member
How to insall ffmpeg in apache (creating video thamnail)
How to create .avi and mpeg video thumbnail?
Hi all. i got a huge list of video(.avi and mepeg) in my pc. I want to create a php script that displays all the video names along with its thamnail.(I already have video name and path in mysql db).
After searching google i came to this program called ffmpeg and i tried to install it but it never work.The page takes for ever to load and nothing happens. Could any one help me install it in Apache/1.3.33 (Win32) (wamp server). My main goal is to create thamnail for all these videos and store the location of those thambs in db too. I hope some one help me.Thanks
Installation method that doesn't work:
Download the latest version from:
http://ffdshow.faireal.net/mirror/ffmpeg/
Install:
unzip it to a folder on your computer. that´s all!
This is how I use ffmpeg and PHP
<?php
// movie.avi.... name of the movie you want to take a screenshot from
// 00:00:00.... Where in the movie do you wanna take your screenshot, 10 seconds from start? ex: 00:00:10
// picname..... name your generated pic
exec("START c:/ffmpeg/ffmpeg -vcodec png -i movie.avi -ss 00:00:00 -vframes frames picname%d.png");
?>
-
Jun 5th, 2008, 05:46 PM
#2
Re: How to insall ffmpeg in apache (creating video thamnail)
the script is taking a while because it is loading the video, going to that location, and taking a picture. did you go to c:/ffmpeg/ffmpeg/picname%d.pnh and see if it exists?
My usual boring signature: Something
-
Jun 5th, 2008, 06:38 PM
#3
Thread Starter
Frenzied Member
Re: How to insall ffmpeg in apache (creating video thamnail)
 Originally Posted by dclamp
the script is taking a while because it is loading the video, going to that location, and taking a picture. did you go to c:/ffmpeg/ffmpeg/picname%d.pnh and see if it exists?
Yes i tried it just now. I heared a dang voice and then i got a white page. i checked the directory where i placed the video and ffmpeg files and no image was found!!
-
Jun 5th, 2008, 06:44 PM
#4
Re: How to insall ffmpeg in apache (creating video thamnail)
check in the directory where the php file is
My usual boring signature: Something
-
Jun 5th, 2008, 06:47 PM
#5
Re: How to insall ffmpeg in apache (creating video thamnail)
ah, i found where you got your code, and you are doing the incorrect method. I have not yet found the correct method however.
My usual boring signature: Something
-
Jun 5th, 2008, 07:27 PM
#6
Thread Starter
Frenzied Member
Re: How to insall ffmpeg in apache (creating video thamnail)
dclmp yeah i found that link from google but couldn't make it to work !! Hope i get some help there.Thanks
-
Jun 5th, 2008, 07:52 PM
#7
Re: How to insall ffmpeg in apache (creating video thamnail)
this link looks like it has some promising material. The FFMPEG API Guide
My usual boring signature: Something
-
Jun 7th, 2008, 04:28 AM
#8
Re: How to insall ffmpeg in apache (creating video thamnail)
Even if you were to get it working it would still be very slow. The operation you are carrying out is designed to be carried out as a batch process. I suggest you write a small batch script which the Windows task scheduler fires off every 5mins, which will run the program and produce the thumbnails for you.
-
Jun 7th, 2008, 06:48 AM
#9
Thread Starter
Frenzied Member
Re: How to insall ffmpeg in apache (creating video thamnail)
VisualAd thanks for your reply. Still i couldn't make it work for one file!! I am sure it can be done. Youtube creates 3 thumnails for each video and i am sure it is has been done with code not human!!
-
Jun 7th, 2008, 07:08 AM
#10
Re: How to insall ffmpeg in apache (creating video thamnail)
I am not sure what your issue is? Using a batch script does not require a human. Can you run this command from the command line and does it work? If it doesn't does it show any errors?
When you upload a video to Youtube there is a delay, usually about several minuets between you posting your video and the video appearing on the site. I do not work for Google but I think it is safe to say that the upload gets put in a queue for periodic batch processing and it is this batch processing which converts the video to a playable format and produces the thumbnails of the video.
-
Jun 7th, 2008, 07:27 AM
#11
Thread Starter
Frenzied Member
Re: How to insall ffmpeg in apache (creating video thamnail)
I tried to run the code in command line and it just loaded the folder with no image created !! No error nothing!! DId you try it in your side if it worked?
batch script is good idea after i make it work for one video I will probably try to learn that :-)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|