Forum > Audio and Video

NON(!)-EXE FFPlay4Laz

<< < (27/28) > >>

BosseB:

--- Quote from: metis on January 24, 2021, 11:31:59 am ---@BosseB


--- Quote ---This works fine except for a minor issue ... It turns out that if I use ffmpeg...
--- End quote ---
I'm really pleased, that I could help You with Your VideoEditor-App, but
I still don't know, why You keep on Putting Your Questions at the wrong Place.  %)

This Thread is - and always will be - about Streaming/Playing with FFmpeg-Libraries and Lazarus.

--- End quote ---
Before posting I tried to find where I had discussed this earlier but failed....

sport123:
Are there ffmpeg components for Lazarus?  Like delphiffmpeg.com  ?

metis:
AFAIK no.

BosseB:

--- Quote from: metis on January 24, 2021, 11:31:59 am ---@BosseB
This Thread is - and always will be - about Streaming/Playing with FFmpeg-Libraries and Lazarus.

Composing FFmpeg-CommandLines is totally different from Writing Code for FFmpeg-Libraries.

--- End quote ---
I must be missing something here (maybe not related to my project):
When you talk about ffmpeg-libraries, what are you referring to?
I thought that ffmpeg is a command line tool on both windows and linux the same, so the "library" would then become the command line interface, right?
Apparently not, so could you in simple terms discuss what the libraries are (plural and all)?

And I am genuinely being curious if there is some package that includes libraries that could ease the use of ffmpeg, no flame intended at all.

metis:
@BosseB


--- Quote ---I thought that ffmpeg is a command line tool
--- End quote ---
The FFmpeg-Project consists of several CommandLine-Tools and Libraries, see here.

The FFmpeg-CommandLine-Tools have a CommandLine-Interface (CLI), and You can pass
Options to them (= FFmpeg-CommandLines), when they start and then communicate with them, when they are running.
Those Tools are: 'ffmpeg.exe', 'ffprobe.exe', 'ffplay.exe' (and 'ffserver.exe', which was removed on 2018-01-06).
Advantage: easy to use; Disadvantage: Slow Communication via Pipes and Strings, restricted to the available Options.

The FFmpeg-Libraries (LIBs) are Collections of FFmpeg-Code, where You can access their
exported Parts and use them in Your own Code as if they were inside of Your Code, means
as if You would have written that Code by Yourself.
Advantage: fast and flexible; Disadvantage: much more complex to use compared to the FFmpeg-CLIs.


--- Quote ---so the "library" would then become the command line interface, right?
--- End quote ---
The FFmpeg-CommandLine-Tools and -Libraries are built and compiled from the FFmpeg-SourceFiles.
This Process depends on the Target-Platform and on diverse Switches, that determine which
Parts of the Sources to include in the TargetFiles (= CLIs and LIBs).

One of those Switches determines, whether the CLIs shall be built "static" or "shared":
Static means, that the CLIs will have all of their LIBs included, so that they run
independently as stand-alone Programs, which results in bigger FileSizes for each CLI.
Shared means, that the CLIs will have all of their LIBs separated, so that each
CLI is smaller, but they only run together with their corresponding LIBs (= Dependencies).
In this Case You have to add the SDL-DLL to run 'ffplay.exe', and
this is, what You need, if You want to use the FFmpeg-LIBs in Your own App.

Now, it's obvious, that there's no Need to rewrite already existing and perfectly running Code so long as
we're Talking about self-contained Tasks (e.g. Convert a VideoFormat to an other), and so long as you're
happy with the available Options for that Task.
You simply launch, e.g. 'ffmpeg.exe' with CommandLine-Arguments, and it will be executed until the Job is done.
This is covered by FFGrab4Laz.

Things are different, if You want e.g. a fast and responsive MediaPlayer with special Features, like:
usually not implemented VideoManipulations, outstanding AudioQuality or TouchScreen-Support.
You actually have to write all by Yourself, where You may use already existing Codes inside of Libraries,
here 'FFmpeg', 'SDL' and 'Portaudio'.
This is covered by this Thread, called FFPlay4Laz.

The SourceCodes to use CLIs are totally different from the SourceCodes to use LIBs.
Therefore all related Issues and Discussions are totally different, as well.
That's why I've started two separated Threads, which I'd like to stay separated.

BTW:
You are just Writing a VideoEditor.
If You want it really fast and precice, You should use Libraries, too, but this is very complex, and
there is already a Bunch of really good VideoEditors, see e.g. in VideoHelp.

Understandable enough ?  :)


--- Quote ---if there is some package that includes libraries that could ease the use of ffmpeg
--- End quote ---
For FreePascal: AFAIK no; for DelphiPascal, see the FFVCL-Site.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version