项目作者: a-schild

项目描述 :
The JAVE (Java Audio Video Encoder) library is Java wrapper on the ffmpeg project
高级语言: Java
项目地址: git://github.com/a-schild/jave2.git
创建时间: 2013-03-04T08:50:30Z
项目社区:https://github.com/a-schild/jave2

开源协议:GNU General Public License v3.0

下载


JAVE2

jave-core Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-all-deps Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-linux-arm32 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-linux-arm64 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-linux32 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-linux64 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-win32 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-win64 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-osx64 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

jave-nativebin-osxm1 Sonatype Nexus (Releases)
Sonatype Nexus (Snapshots)

The JAVE2 (Java Audio Video Encoder) library is Java wrapper on the ffmpeg
project. Developers can take take advantage of JAVE2 to transcode audio
and video files from a format to another. In example you can transcode
an AVI file to a MPEG one, you can change a DivX video stream into a
(youtube like) Flash FLV one, you can convert a WAV audio file to a MP3 or a
Ogg Vorbis one, you can separate and transcode audio and video tracks, you can
resize videos, changing their sizes and proportions and so on.

Many other formats, containers and operations are supported by JAVE2.

Supported Operating Systems + Requirements

JAVE requires Java 8 or higher

JAVE can also be easily ported to other OS and hardware configurations,
see the JAVE manual for details.

Operating System Windows x32,x64 MacOS intel x64 MacOS m1 Linux x32,x64 Linux arm32,arm64
Supported? Partial,YES YES YES YES Partial,YES

Please note that the arm+win 32 bit versions are still on 4.4.0 and will be removed in a future release
The win32 binaries will be removed in the next release

Projects using Jave2

Usage Example

For the documentation, please have a look at the project wiki pages here

or at this file DefaultFFMPEGLocatorTest.java

Maven Repository URL -> https://mvnrepository.com/artifact/ws.schild/jave-all-deps

Use with Maven

It includes all binaries for the supported platforms

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-all-deps</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

You can use maven dependencies to include the libraries in your projects.
Include the following in your pom files.

[ Remember always to check the latest release here ]

Generally if you want to use for one platform or more what you have to do is add the jave-core:

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-core</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

and then the specific jar(s) for your platform(s) :

For one platform only (Linux 64Bit amd/intel in this case)

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-nativebin-linux64</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

For one platform only (Linux 64Bit arm in this case)

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-nativebin-linux-arm64</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

For one platform only (Linux 32Bit arm in this case)

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-nativebin-linux-arm32</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

For one platform only (Windows 64Bit in this case)

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-nativebin-win64</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

For one platform only (MACOS 64Bit in this case)

  1. <dependency>
  2. <groupId>ws.schild</groupId>
  3. <artifactId>jave-nativebin-osx64</artifactId>
  4. <version>3.5.0</version>
  5. </dependency>

Use with Gradle

It includes all binaries for the supported platforms

  1. compile group: 'ws.schild', name: 'jave-all-deps', version: '3.5.0'

For one platform only (Linux 64Bit in this case)

  1. compile group: 'ws.schild', name: 'jave-core', version: '3.5.0'
  2. compile group: 'ws.schild', name: 'jave-nativebin-linux64', version: '3.5.0'

Main Components of Jave2

Jave2 consists of two main components:

  1. The jave-core dependency, which includes all the java code, which is platform independent
  2. The jave-nativebin-<platform> dependencies, which include the binary executables per platform

There exists a jave-all-deps project, which includes core and all windows und linux binaries.


Examples

Converting any audio to mp3

  1. boolean succeeded;
  2. try {
  3. File source = new File("file path");
  4. File target = new File("file path");
  5. //Audio Attributes
  6. AudioAttributes audio = new AudioAttributes();
  7. audio.setCodec("libmp3lame");
  8. audio.setBitRate(128000);
  9. audio.setChannels(2);
  10. audio.setSamplingRate(44100);
  11. //Encoding attributes
  12. EncodingAttributes attrs = new EncodingAttributes();
  13. attrs.setFormat("mp3");
  14. attrs.setAudioAttributes(audio);
  15. //Encode
  16. Encoder encoder = new Encoder();
  17. encoder.encode(new MultimediaObject(source), target, attrs);
  18. } catch (Exception ex) {
  19. ex.printStackTrace();
  20. succeeded = false;
  21. }

More advanced examples

Can be found here

Changelog

Can be found here

License

JAVE2 is Free Software and it is licensed under GPL3 LICENSE

You will find a copy of the license bundled into the
downloadable software distribution.

Feedback

You can send comments to andre@schild.ws
For bug reports use the github site https://github.com/a-schild/jave2/issues

Credits

Jave is based on the jave version from Carlo Pelliccia
The original project page with source code can be found here:

http://www.sauronsoftware.it/projects/jave/