Hacker News new | ask | show | jobs
by mifino 3511 days ago
You are correct, it's a GUI for ffmpeg's -ss -t commands. It's always a tradeoff between ease of installation and development for multiple platforms vs reusing already installed components. I know ffmpeg has historically been changing their API alot between their versions. I wanted to make something that just works, built on battle tested technologies. Space is cheap too, and the size of the app is tiny compared to the videos you are processing. The windows binary of QtAV is btw 35MB (i assume compressed), so quite big too. Fun fact though: ffmpeg is actually bundled twice in LosslessCut. once in Electron(Chromium) and once as a CLI :)
1 comments

> The windows binary of QtAV is btw 35MB (i assume compressed)

Perhaps you're looking at player+SDK. The player alone[0] is 21MB

> ffmpeg is actually bundled twice in LosslessCut. once in Electron(Chromium) and once as a CLI

If you use a custom build of Electron, you can at least cut down ffmpeg to just one version. Like the way my distro does it with Chromium and ffmpeg.

----

0: https://www.microsoft.com/en-us/store/p/qtav-video-player/9n...

Yes, I could call ffmpeg from native code. But it's a bit more of a hassle to do from javascript than to just start the ffmpeg exe. And if the included ffmpeg lib was to crash, I can imagine that the whole application would crash too. But I'm open to suggestions.
That is not what I meant.

I meant using the same version of ffmpeg as the shared lib linked with Electron and linked with the binary.

So, your bundle would have libavutil.so somewhere in a `lib/` folder, and in the `bin/` folder you'd have `ffmpeg` and `electron` (or equivalent) both dynamically linked against the `lib/libavutil.so`.

I see. That should be possible, yes. If the ffmpeg from electron is built with the necessary features for the CLI and cutting to work. It would however require some quite complicated build scripts, I can imagine.
I'm surprised there isn't a Node binding for libav/ffmpeg yet.

I have the same problem with lots of other open source video tools. I wish it was easier to use ffmpeg via library and then more people might do it.

Yes I had trouble finding it too. I guess it's because the ffmpeg API is so enormous and evolving all the time, that if there was to be node bindings for it, it would have to be maintained by the ffmpeg team. I think the CLI is the most stable API contract to the outside world, and everyone in the node world uses the CLI. I had an idea to use node-ffi, though. Which doesn't require linking or bindings or anything. Just call the native ffmpeg code directly from nodejs.