phronmophobic / clj-media

Read, write, and transform audio and video with Clojure.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

clj-media

Read, write, and transform audio and video with Clojure.

Powered by FFmpeg and clong.

Dependency

com.phronemophobic/clj-media {:mvn/version "2.3"}

Documentation

Guide
API docs

Locally compiled FFmpeg

clj-media also supports using a locally compiled FFmpeg build.

Example compilation:

git clone https://github.com/FFmpeg/FFmpeg.git
cd FFmpeg
./configure  --extra-ldflags='-Wl,-ld_classic' --enable-shared --prefix=`pwd`/build
make
make install

To use the local build:

  1. Add the libraries to the JNA library path
  2. Exclude the ffmpeg dependency, org.bytedeco/ffmpeg-platform

Example alias:

{:aliases
 {:local-ffmpeg
  {:jvm-opts ["-Djna.library.path=/path/to/FFmpeg/build/lib"]
   :deps {com.phronemophobic/clj-media {:mvn/version "2.3"
                                        :exclusions [org.bytedeco/ffmpeg-platform]}}}}}

"Roadmap"

Features get added as time and motivation allows. If you would be excited to see a particular feature, please file an issue and let me know!

  • Reading/writing metadata.
  • Add support for choosing different ffmpeg builds.
  • Improve memory usage.
  • Fix reflection warnings.
  • Add support for creating media from raw samples.
  • Add more options for configuring output codecs.
  • Add iterator+autocloseable to frames interface.
  • Support transformation specification by copy and pasting ffmpeg commands.
  • Add support for creating media from byte buffers.

License

Copyright © 2023 Adrian

The contents of this repository may be distributed under the Apache License v2.0 or the GPLv2.

About

Read, write, and transform audio and video with Clojure.

License:Apache License 2.0


Languages

Language:Clojure 100.0%