{"id":15068956,"url":"https://github.com/sheinbergon/jna-aac-encoder","last_synced_at":"2025-04-10T17:33:41.119Z","repository":{"id":57740690,"uuid":"121976233","full_name":"sheinbergon/jna-aac-encoder","owner":"sheinbergon","description":"AAC encoding capabilities for the JVM","archived":false,"fork":false,"pushed_at":"2025-02-13T20:12:20.000Z","size":51585,"stargazers_count":29,"open_issues_count":1,"forks_count":7,"subscribers_count":5,"default_branch":"main","last_synced_at":"2025-02-13T21:19:42.242Z","etag":null,"topics":["aac","aac-audio","aac-encoding-capabilities","audio","audio-processing","encoding","fdk-aac","java","java11","jmh","jna","jna-aac-encoder","libfdk-aac","pcm"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"lgpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/sheinbergon.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-02-18T18:03:14.000Z","updated_at":"2025-02-13T20:00:29.000Z","dependencies_parsed_at":"2024-10-13T04:20:52.924Z","dependency_job_id":"825abc3b-8b56-4d01-89b8-67eac7bc1682","html_url":"https://github.com/sheinbergon/jna-aac-encoder","commit_stats":null,"previous_names":[],"tags_count":10,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sheinbergon%2Fjna-aac-encoder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sheinbergon%2Fjna-aac-encoder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sheinbergon%2Fjna-aac-encoder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/sheinbergon%2Fjna-aac-encoder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/sheinbergon","download_url":"https://codeload.github.com/sheinbergon/jna-aac-encoder/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":239325289,"owners_count":19620260,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["aac","aac-audio","aac-encoding-capabilities","audio","audio-processing","encoding","fdk-aac","java","java11","jmh","jna","jna-aac-encoder","libfdk-aac","pcm"],"created_at":"2024-09-25T01:39:50.082Z","updated_at":"2025-02-17T16:31:39.187Z","avatar_url":"https://github.com/sheinbergon.png","language":"Java","funding_links":["https://liberapay.com/sheinbergon/donate","https://www.buymeacoffee.com/sheinbergon"],"categories":[],"sub_categories":[],"readme":"# jna-aac-encoder\n\n[![GitHub](https://img.shields.io/github/license/sheinbergon/jna-aac-encoder?color=pink\u0026style=for-the-badge)](https://github.com/sheinbergon/jna-aac-encoder/blob/master/LICENSE)\n[![GitHub Workflow Status](https://img.shields.io/github/actions/workflow/status/sheinbergon/jna-aac-encoder/ossrh-publication.yml?style=for-the-badge\u0026branch=main)](https://github.com/sheinbergon/jna-aac-encoder/actions?query=workflow%3A\"Multi+Platform+CI\")\n[![GitHub release (latest by date)](https://img.shields.io/github/v/release/sheinbergon/jna-aac-encoder?color=%2340E0D0\u0026style=for-the-badge)](https://github.com/sheinbergon/jna-aac-encoder/releases/latest)\n[![Maven Central](https://img.shields.io/maven-central/v/org.sheinbergon/jna-aac-encoder?color=Crimson\u0026style=for-the-badge)](https://search.maven.org/search?q=g:org.sheinbergon%20a:jna-aac-encoder*)\n[![Coveralls](https://img.shields.io/coveralls/github/sheinbergon/jna-aac-encoder?style=for-the-badge\u0026logo=coveralls)](https://coveralls.io/github/sheinbergon/jna-aac-encoder)\n[![Codacy grade](https://img.shields.io/codacy/grade/8f822d4bfbfa48809d439d4e8e92d287?style=for-the-badge\u0026logo=codacy)](https://app.codacy.com/manual/sheinbergon/jna-aac-encoder)\n[![Liberapay](https://img.shields.io/liberapay/patrons/sheinbergon?logo=liberapay\u0026style=for-the-badge)](https://liberapay.com/sheinbergon/donate)                \n                                                                                                                                                                                                                                                                                 \nThis library provides AAC encoding capabilities for the JVM. \nIt utilizes the [FDK AAC](https://github.com/mstorsjo/fdk-aac) library via JNA in order to do so.\n\n## License\n**Important!** While this library uses LGPL-3, please see\nthe [FDK AAC license](NOTICE) for additional information\nregarding re/distribution and licensing limitations.\n\n## Sponsorship\n\nEnjoying my work? A show of support would be much obliged :grin:\n\n\u003ca href=\"https://liberapay.com/sheinbergon/donate\"\u003e\n\u003cimg src=\"assets/liberapay-donate.png\" height=\"66\" align=\"center\"\u003e\n\u003c/a\u003e\u0026nbsp;\u0026nbsp;\u003ca href=\"https://www.buymeacoffee.com/sheinbergon\"\u003e\n\u003cimg src=\"assets/buymeacoffee-donate.png\" height=\"66\" align=\"center\"\u003e\n\u003c/a\u003e\n\n## Usage\n\n### Dependencies\nArtifacts are available on maven central:\n\n**_Maven_**\n```xml\n\u003cdependency\u003e\n    \u003cgroupId\u003eorg.sheinbergon\u003c/groupId\u003e\n    \u003cartifactId\u003ejna-aac-encoder\u003c/artifactId\u003e\n    \u003cversion\u003e2.1.0\u003c/version\u003e\n\u003c/dependency\u003e\n```\n\n**_Gradle_**\n```groovy\ncompile 'org.sheinbergon:jna-aac-encoder:2.1.0'\n```\n\n#### Additional information\n  * Single artifact containing _libfdk-aac_ shared libraries cross-compiled for:\n    * Linux (64-bit) \n    * Windows (64-bit)\n    * OSX (Intel 64-bit / Apple Silicon, compiled with Xcode 13.3 SDK)\n  * Tested with FDK-AAC version is 2.0.2\n  * Earlier `2.0.x` versions of FDK-AAC might work, but haven't been tested.\n  * For JDK 8 compatibility, please use version `2.0.0` of this library\n  * For `0.1.6`/`0.1.5` FDK-AAC support and Windows 32 bit support, please use version `0.1.9` of this library  \n \n### Encoding using the JVM AudioSystem\n```java\nAudioInputStream input = AudioSystem.getAudioInputStream(...);\nFile output = new File(...);\nAudioSystem.write(input, AACFileTypes.AAC_LC, output);\n```\n\n## Performance\nPerformance benchmarks comparing JNA to a BINARY application(`aac-enc`) are available using [JMH](http://openjdk.java.net/projects/code-tools/jmh/) and [JMH Visualizer](https://github.com/jzillmann/jmh-visualizer):\n\n![alt text](assets/jmh-results-23112023.png)\n\nTo run the benchmarks locally:\n  * Clone this repository onto a Linux host\n  * Ensure that you have `libfdk-aac.so` __2.0.2__ library installed (either from an external repository or manually compiled)\n  * Ensure that you have the `aac-enc` binary installed (either from an external repository or manually compiled)\n  * Run the following command (from within the cloned repository)\n```groovy\n./gradlew -b benchmark.gradle jmh jmhReport\n```\n  * If the aac-enc binary is not installed in /usr/bin/aac-enc, you can a custom path path by adding this gradle property:\n```groovy\n-PaacEncBin=/CUSTOM/PATH/TO/AAC-ENC \n```\n  * The JMH reports can be viewed by opening `build/reports/benchmark/index.html` in your browser.\n\n## Limitations\nCurrently, **_libfdk-aac_ itself** supports only the pcm_s16le WAV input format, meaning:\n  * Sample size - 16 bit(signed)\n  * WAV format - (L)PCM\n  * Byte order - Little Endian\n\nWhile this form of input formatting seems to be the common raw-audio formatting, it's important\nto note that providing input audio with different formatting will cause\nthe encoding process to fail. \n\nAdditional restrictions:\n  * A maximum of 6 audio input/output channels\n  * Only the AAC-LC/HE-AAC/HE-AACv2 encoding profiles are supported\n\n## Roadmap\n  * Improved lower-level interface (with examples).\n  * Support for 24 bit WAV input (via conversion).\n  * M4A encoding.\n  * AAC decoding ???  ","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsheinbergon%2Fjna-aac-encoder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsheinbergon%2Fjna-aac-encoder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsheinbergon%2Fjna-aac-encoder/lists"}