Jump to content

audio converter ... mp3, wav, ogg, webm


dsdsdsdsd

Recommended Posts

to be honest, I still don't understand ffmpeg ... if you go to the wiki it doesn't even mention php. I keep seeing people refer to 'command line' software, but I am looking for a php script that can do all the conversions.

Most of the time things like this are handled by using exec() to execute an external application with the proper arguments to do the conversion you want. The ffmpeg CLI tool is offered on some hosts and is fairly easy to use. So what you'd do is create a PHP script that lets you specify all the different options you need and then just executes the fmpeg tool to do the actual conversion. Once the conversion is done you can have your PHP script do any further processing that may be necessary.

 

Trying to process the video data within a pure-php solution would likely be painfully slow, if it's possible at all. That is why these types of tasks are done via C either as a PHP extension (if available) or an external CLI tool.

Link to comment
Share on other sites

so is ffmpeg kind of like the GD engine that processes images on the server?

if I am not mistaken, GD is a server-based application, and php has an API to it ... it is the API that I interact with in php scripts.

IF so then getting ffmpeg is a process, really:
1 - download
2 - install onto server

3 - learn how to interface with it via php
... is this correct?

-- thanks.

Link to comment
Share on other sites

  • 1 year later...
This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.