mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-06 21:00:22 +00:00
integrate jni; need to keep from crashing
This commit is contained in:
parent
c243718ed4
commit
021df9eceb
@ -51,6 +51,7 @@ import org.sleuthkit.autopsy.coreutils.MessageNotifyUtil;
|
|||||||
import org.sleuthkit.autopsy.coreutils.ModuleSettings;
|
import org.sleuthkit.autopsy.coreutils.ModuleSettings;
|
||||||
import org.sleuthkit.autopsy.coreutils.PlatformUtil;
|
import org.sleuthkit.autopsy.coreutils.PlatformUtil;
|
||||||
import org.sleuthkit.autopsy.modules.filetypeid.FileTypeDetector;
|
import org.sleuthkit.autopsy.modules.filetypeid.FileTypeDetector;
|
||||||
|
import org.sleuthkit.autopsy.modules.pictureanalyzer.impls.HeifJNI;
|
||||||
import org.sleuthkit.autopsy.python.JythonModuleLoader;
|
import org.sleuthkit.autopsy.python.JythonModuleLoader;
|
||||||
import org.sleuthkit.autopsy.texttranslation.TextTranslationService;
|
import org.sleuthkit.autopsy.texttranslation.TextTranslationService;
|
||||||
|
|
||||||
|
@ -80,8 +80,8 @@ public class HEICProcessor implements PictureProcessor {
|
|||||||
public HEICProcessor() {
|
public HEICProcessor() {
|
||||||
HeifJNI heifJNI;
|
HeifJNI heifJNI;
|
||||||
try {
|
try {
|
||||||
heifJNI = new HeifJNI();
|
heifJNI = HeifJNI.getInstance();
|
||||||
} catch (Exception ex) {
|
} catch (UnsatisfiedLinkError ex) {
|
||||||
logger.log(Level.SEVERE, "libheif native dependencies not found. HEIC functionality will be automatically disabled.", ex);
|
logger.log(Level.SEVERE, "libheif native dependencies not found. HEIC functionality will be automatically disabled.", ex);
|
||||||
heifJNI = null;
|
heifJNI = null;
|
||||||
}
|
}
|
||||||
|
@ -20,18 +20,25 @@ package org.sleuthkit.autopsy.modules.pictureanalyzer.impls;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* Interop with libheif dll's.
|
* Interop with libheif native dependencies.
|
||||||
*/
|
*/
|
||||||
public class HeifJNI {
|
public class HeifJNI {
|
||||||
|
|
||||||
// static {
|
private static HeifJNI instance = null;
|
||||||
// System.load("C:\\Users\\gregd\\Documents\\Source\\heif_convert_test\\HeifConvertTestJNI\\dist\\Release\\libx265.dll");
|
|
||||||
// System.load("C:\\Users\\gregd\\Documents\\Source\\heif_convert_test\\HeifConvertTestJNI\\dist\\Release\\libde265.dll");
|
public static HeifJNI getInstance() throws UnsatisfiedLinkError {
|
||||||
// System.load("C:\\Users\\gregd\\Documents\\Source\\heif_convert_test\\HeifConvertTestJNI\\dist\\Release\\heif.dll");
|
if (instance == null) {
|
||||||
// System.load("C:\\Users\\gregd\\Documents\\Source\\heif_convert_test\\HeifConvertTestJNI\\dist\\Release\\jpeg62.dll");
|
System.loadLibrary("libx265");
|
||||||
// System.load("C:\\Users\\gregd\\Documents\\Source\\heif_convert_test\\HeifConvertTestJNI\\dist\\Release\\heif-convert.dll");
|
System.loadLibrary("libde265");
|
||||||
//
|
System.loadLibrary("heif");
|
||||||
// }
|
System.loadLibrary("jpeg62");
|
||||||
|
System.loadLibrary("heif-convert");
|
||||||
|
instance = new HeifJNI();
|
||||||
|
}
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
|
||||||
|
private HeifJNI() {}
|
||||||
|
|
||||||
public native int convertToDisk(byte[] data, String jpgOutputPath);
|
public native int convertToDisk(byte[] data, String jpgOutputPath);
|
||||||
}
|
}
|
||||||
|
BIN
thirdparty/libheif/Release/lib/x86_64/heif-convert.dll
vendored
Normal file
BIN
thirdparty/libheif/Release/lib/x86_64/heif-convert.dll
vendored
Normal file
Binary file not shown.
BIN
thirdparty/libheif/Release/lib/x86_64/heif.dll
vendored
Normal file
BIN
thirdparty/libheif/Release/lib/x86_64/heif.dll
vendored
Normal file
Binary file not shown.
BIN
thirdparty/libheif/Release/lib/x86_64/jpeg62.dll
vendored
Normal file
BIN
thirdparty/libheif/Release/lib/x86_64/jpeg62.dll
vendored
Normal file
Binary file not shown.
BIN
thirdparty/libheif/Release/lib/x86_64/libde265.dll
vendored
Normal file
BIN
thirdparty/libheif/Release/lib/x86_64/libde265.dll
vendored
Normal file
Binary file not shown.
BIN
thirdparty/libheif/Release/lib/x86_64/libx265.dll
vendored
Normal file
BIN
thirdparty/libheif/Release/lib/x86_64/libx265.dll
vendored
Normal file
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user