|
hace 4 años | |
---|---|---|
bin | hace 4 años | |
docs | hace 4 años | |
src | hace 4 años | |
utils | hace 4 años | |
.gitignore | hace 4 años | |
.gitmodules | hace 4 años | |
LICENSE.txt | hace 4 años | |
README.md | hace 4 años | |
pom.xml | hace 4 años |
JVCL (pronounced “Javicle”) is a JSON DSL for audio/video transformations.
Under the hood, it’s all shell commands: ffmpeg
, mediainfo
and so on.
JVCL provides higher-level semantics for working with these lower level tools.
I don’t do much video editing, so I’ve never bothered to learn iMovie or any graphical video editor. My editing needs are usually pretty simple, so I bust out ffmpeg and get it done.
But it seems like every time, there is at least one wrinkle in my requirements that requires some deep research into ffmpeg filter arcana and before I know it, the day is done.
I created JVCL to capture the most common things people usually do to videos: splitting, concatenating, letterboxing, overlaying one video onto another, and so on.
Say you want to split a portion of a video into ten-second chunks. With ffmpeg and bash, you might do something like this:
INCR=10
for ((i=10;i<130;i=(i+INCR))); do
ffmpeg -i /tmp/my/source.mp4 -ss ${i} -t $((i+INCR)) /tmp/my/slice_${i}_$((i+INCR)).mp4
done
With JVCL, you’d write this spec file and save it to a file (for
example my-spec.jvcl
):
{
"assets": [ {"name": "src", "path": "/tmp/my/source.mp4"} ],
"operations": [{
"operation": "split",
"creates": "src_split_files",
"source": "src",
"interval": "10s",
"start": "10s",
"end": "130s"
}]
}
and then run it like this:
jvcl my-spec.jvcl
Yes, the JVCL is longer, but I think many would agree it is easier to read and maintain.
As the number of media assets and operations grows, hand-crafted shell scripts with magical ffmpeg incantations become ever more inscrutable.
JVCL is designed for readability and maintainability. JVCL will continue to evolve towards greater coverage of the full capabilities of ffmpeg.
If you like GUIs, JVCL is probably not for you.
JVCL is not a replacement for Final Cut Pro or even iMovie.
JVCL is for people who like CLIs and automation.
JVCL is for people with relatively simple video composition needs (for now), since the range of operations supported is limited.
Learn more about running jvcl
and other useful tools.
Learn about Assets and Operations, the core concepts of JVCL.
Today, JVCL supports several basic operations.
For each operation listed below, the header links to an example from the JVCL test suite.
Concatenate audio/video assets together into one asset.
For transforming still images into video via a fade-pan (aka Ken Burns) effect.
Transform a video from one size to another size, maintaining the aspect ratio of the video and adding letterboxes on the sides or top/bottom. Handy for embedding mobile videos into other screen formats.
Overlay one asset onto another.
Remove a track from a video asset.
Scale a video asset from one size to another. Scaling can be proportional or anamorphic.
Split an audio/video asset into multiple assets of equal time lengths.
Trim audio/video; crop a section of an asset, becomes a new asset.
Here is a long, complex example that uses every operation.
A cross between a javelin and an icicle? Does that have any positive connotations? I really don’t like naming things.