Hacker News new | ask | show | jobs
by Snarwin 1225 days ago
A number of command-line programs are actually just wrappers around a more strongly-typed library API. For example, curl and libcurl, or ffmpeg and a whole collection of audio/video libraries. [1]

Of course, in the POSIX world, "library API" means "C API", so if you want to write nice-looking Python code like in the article, there is still some more work to do.

[1] https://trac.ffmpeg.org/wiki/Using%20libav*

1 comments

ffmpeg is a bad example as libav is a library specialized towards making ffmpeg. It's not a generic audio/video manipulation library.
Where does the requirement for it being a generic library come from? The point is that a lot of things that are available as command-line utilities for shell scripts already have a C API available as well.

And libav* is used by a lot more than /usr/bin/ffmpeg