From 5f1f0f156b213c235e70bb452ce5703c5e6cdaf2 Mon Sep 17 00:00:00 2001 From: Idan Sheinberg Date: Fri, 24 Nov 2023 02:29:04 +0200 Subject: [PATCH] Removed Dead code Updated GH action steps --- .github/workflows/multi-platform-ci.yml | 2 +- .github/workflows/ossrh-publication.yml | 2 +- README.md | 2 +- .../org/sheinbergon/aac/jna/FdkAACLib.java | 3 -- .../aac/jna/structure/LibInfo.java | 40 ------------------- 5 files changed, 3 insertions(+), 46 deletions(-) delete mode 100644 src/main/java/org/sheinbergon/aac/jna/structure/LibInfo.java diff --git a/.github/workflows/multi-platform-ci.yml b/.github/workflows/multi-platform-ci.yml index fd9b569..627b4e4 100644 --- a/.github/workflows/multi-platform-ci.yml +++ b/.github/workflows/multi-platform-ci.yml @@ -18,7 +18,7 @@ jobs: steps: - name: Git checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Java JDK setup uses: actions/setup-java@v3 diff --git a/.github/workflows/ossrh-publication.yml b/.github/workflows/ossrh-publication.yml index 8dca59b..888b9fe 100644 --- a/.github/workflows/ossrh-publication.yml +++ b/.github/workflows/ossrh-publication.yml @@ -11,7 +11,7 @@ jobs: steps: - name: Git checkout - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Java JDK setup uses: actions/setup-java@v3 diff --git a/README.md b/README.md index 8749938..98de604 100644 --- a/README.md +++ b/README.md @@ -51,7 +51,7 @@ compile 'org.sheinbergon:jna-aac-encoder:2.0.0' * Linux (64-bit) * Windows (64-bit) * OSX (Intel 64-bit / Apple Silicon, compiled with Xcode 13.3 SDK) - * Provided fdk-aac version is 2.0.2 + * Tested with FDK-AAC version is 2.0.2 * Lower `2.0.x` versions of FDK-AAC might work, but haven't been tested. * For `0.1.6`/`0.1.5` FDK-AAC support and Windows 32 bit support, please use version `0.1.9` of this library diff --git a/src/main/java/org/sheinbergon/aac/jna/FdkAACLib.java b/src/main/java/org/sheinbergon/aac/jna/FdkAACLib.java index 24359eb..c8055df 100644 --- a/src/main/java/org/sheinbergon/aac/jna/FdkAACLib.java +++ b/src/main/java/org/sheinbergon/aac/jna/FdkAACLib.java @@ -10,7 +10,6 @@ import org.sheinbergon.aac.jna.structure.AACEncInfo; import org.sheinbergon.aac.jna.structure.AACEncOutArgs; import org.sheinbergon.aac.jna.structure.AACEncoder; -import org.sheinbergon.aac.jna.structure.LibInfo; @SuppressWarnings("MethodName") public final class FdkAACLib { @@ -47,8 +46,6 @@ static native int aacEncEncode( static native int aacEncInfo(AACEncoder hAacEncoder, AACEncInfo pInfo); - static native int aacEncGetLibInfo(LibInfo info); - static native int aacEncoder_SetParam(AACEncoder encoder, int param, int value); private FdkAACLib() { diff --git a/src/main/java/org/sheinbergon/aac/jna/structure/LibInfo.java b/src/main/java/org/sheinbergon/aac/jna/structure/LibInfo.java deleted file mode 100644 index 270d4be..0000000 --- a/src/main/java/org/sheinbergon/aac/jna/structure/LibInfo.java +++ /dev/null @@ -1,40 +0,0 @@ -package org.sheinbergon.aac.jna.structure; - -import com.sun.jna.Structure; -import org.sheinbergon.aac.jna.util.JNASupport; - -import java.util.List; - -/** - * Maps to LIB_INFO struct. - * - * @see fdk-aac/libSYS/include/FDK_audio.h - */ -@SuppressWarnings({"JavadocVariable", "VisibilityModifier", "MemberName"}) -public final class LibInfo extends Structure { - - private static final int VERSION_STRING_SIZE = 32; - - private static final List FIELD_ORDER = JNASupport.structureFieldOrder(LibInfo.class); - - /** - * Library Info mapping. - */ - public LibInfo() { - setAlignType(Structure.ALIGN_NONE); // Make sure field size alignments are as expected - read(); // Read once after initialize from provided pointer - } - - public String title; - public String build_date; - public String build_time; - public int module_id; - public int version; - public int flags; - public byte[] versionStr = new byte[VERSION_STRING_SIZE]; - - @Override - protected List getFieldOrder() { - return FIELD_ORDER; - } -}