├── .gitignore ├── .idea ├── misc.xml └── runConfigurations.xml ├── README.md ├── app ├── build.gradle └── src │ └── main │ ├── AndroidManifest.xml │ ├── assets │ ├── yolov8n-seg-sim-opt-fp16.bin │ ├── yolov8n-seg-sim-opt-fp16.param │ ├── yolov8s-seg-sim-opt-fp16.bin │ └── yolov8s-seg-sim-opt-fp16.param │ ├── java │ └── com │ │ └── tencent │ │ └── yolov8ncnn │ │ ├── MainActivity.java │ │ └── Yolov8Ncnn.java │ ├── jni │ ├── CMakeLists.txt │ ├── ncnn-20221128-android-vulkan │ │ ├── arm64-v8a │ │ │ ├── include │ │ │ │ ├── glslang │ │ │ │ │ ├── Include │ │ │ │ │ │ ├── BaseTypes.h │ │ │ │ │ │ ├── Common.h │ │ │ │ │ │ ├── ConstantUnion.h │ │ │ │ │ │ ├── InfoSink.h │ │ │ │ │ │ ├── InitializeGlobals.h │ │ │ │ │ │ ├── PoolAlloc.h │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShHandle.h │ │ │ │ │ │ ├── SpirvIntrinsics.h │ │ │ │ │ │ ├── Types.h │ │ │ │ │ │ ├── arrays.h │ │ │ │ │ │ ├── glslang_c_interface.h │ │ │ │ │ │ ├── glslang_c_shader_types.h │ │ │ │ │ │ └── intermediate.h │ │ │ │ │ ├── MachineIndependent │ │ │ │ │ │ ├── Initialize.h │ │ │ │ │ │ ├── LiveTraverser.h │ │ │ │ │ │ ├── ParseHelper.h │ │ │ │ │ │ ├── RemoveTree.h │ │ │ │ │ │ ├── Scan.h │ │ │ │ │ │ ├── ScanContext.h │ │ │ │ │ │ ├── SymbolTable.h │ │ │ │ │ │ ├── Versions.h │ │ │ │ │ │ ├── attribute.h │ │ │ │ │ │ ├── gl_types.h │ │ │ │ │ │ ├── glslang_tab.cpp.h │ │ │ │ │ │ ├── iomapper.h │ │ │ │ │ │ ├── localintermediate.h │ │ │ │ │ │ ├── parseVersions.h │ │ │ │ │ │ ├── preprocessor │ │ │ │ │ │ │ ├── PpContext.h │ │ │ │ │ │ │ └── PpTokens.h │ │ │ │ │ │ ├── propagateNoContraction.h │ │ │ │ │ │ └── reflection.h │ │ │ │ │ ├── Public │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShaderLang.h │ │ │ │ │ │ └── resource_limits_c.h │ │ │ │ │ ├── SPIRV │ │ │ │ │ │ ├── GLSL.ext.AMD.h │ │ │ │ │ │ ├── GLSL.ext.EXT.h │ │ │ │ │ │ ├── GLSL.ext.KHR.h │ │ │ │ │ │ ├── GLSL.ext.NV.h │ │ │ │ │ │ ├── GLSL.std.450.h │ │ │ │ │ │ ├── GlslangToSpv.h │ │ │ │ │ │ ├── Logger.h │ │ │ │ │ │ ├── NonSemanticDebugPrintf.h │ │ │ │ │ │ ├── NonSemanticShaderDebugInfo100.h │ │ │ │ │ │ ├── SPVRemapper.h │ │ │ │ │ │ ├── SpvBuilder.h │ │ │ │ │ │ ├── SpvTools.h │ │ │ │ │ │ ├── bitutils.h │ │ │ │ │ │ ├── disassemble.h │ │ │ │ │ │ ├── doc.h │ │ │ │ │ │ ├── hex_float.h │ │ │ │ │ │ ├── spirv.hpp │ │ │ │ │ │ └── spvIR.h │ │ │ │ │ └── build_info.h │ │ │ │ └── ncnn │ │ │ │ │ ├── allocator.h │ │ │ │ │ ├── benchmark.h │ │ │ │ │ ├── blob.h │ │ │ │ │ ├── c_api.h │ │ │ │ │ ├── command.h │ │ │ │ │ ├── cpu.h │ │ │ │ │ ├── datareader.h │ │ │ │ │ ├── gpu.h │ │ │ │ │ ├── layer.h │ │ │ │ │ ├── layer_shader_type.h │ │ │ │ │ ├── layer_shader_type_enum.h │ │ │ │ │ ├── layer_type.h │ │ │ │ │ ├── layer_type_enum.h │ │ │ │ │ ├── mat.h │ │ │ │ │ ├── modelbin.h │ │ │ │ │ ├── ncnn_export.h │ │ │ │ │ ├── net.h │ │ │ │ │ ├── option.h │ │ │ │ │ ├── paramdict.h │ │ │ │ │ ├── pipeline.h │ │ │ │ │ ├── pipelinecache.h │ │ │ │ │ ├── platform.h │ │ │ │ │ ├── simpleocv.h │ │ │ │ │ ├── simpleomp.h │ │ │ │ │ ├── simplestl.h │ │ │ │ │ └── vulkan_header_fix.h │ │ │ └── lib │ │ │ │ ├── cmake │ │ │ │ ├── OGLCompilerTargets.cmake │ │ │ │ ├── OSDependentTargets.cmake │ │ │ │ ├── SPIRVTargets.cmake │ │ │ │ ├── glslang │ │ │ │ │ ├── glslang-config-version.cmake │ │ │ │ │ ├── glslang-config.cmake │ │ │ │ │ ├── glslang-targets-release.cmake │ │ │ │ │ └── glslang-targets.cmake │ │ │ │ ├── glslangTargets.cmake │ │ │ │ └── ncnn │ │ │ │ │ ├── ncnn-release.cmake │ │ │ │ │ ├── ncnn.cmake │ │ │ │ │ └── ncnnConfig.cmake │ │ │ │ ├── libGenericCodeGen.a │ │ │ │ ├── libMachineIndependent.a │ │ │ │ ├── libOGLCompiler.a │ │ │ │ ├── libOSDependent.a │ │ │ │ ├── libSPIRV.a │ │ │ │ ├── libglslang.a │ │ │ │ ├── libncnn.a │ │ │ │ └── pkgconfig │ │ │ │ └── ncnn.pc │ │ ├── armeabi-v7a │ │ │ ├── include │ │ │ │ ├── glslang │ │ │ │ │ ├── Include │ │ │ │ │ │ ├── BaseTypes.h │ │ │ │ │ │ ├── Common.h │ │ │ │ │ │ ├── ConstantUnion.h │ │ │ │ │ │ ├── InfoSink.h │ │ │ │ │ │ ├── InitializeGlobals.h │ │ │ │ │ │ ├── PoolAlloc.h │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShHandle.h │ │ │ │ │ │ ├── SpirvIntrinsics.h │ │ │ │ │ │ ├── Types.h │ │ │ │ │ │ ├── arrays.h │ │ │ │ │ │ ├── glslang_c_interface.h │ │ │ │ │ │ ├── glslang_c_shader_types.h │ │ │ │ │ │ └── intermediate.h │ │ │ │ │ ├── MachineIndependent │ │ │ │ │ │ ├── Initialize.h │ │ │ │ │ │ ├── LiveTraverser.h │ │ │ │ │ │ ├── ParseHelper.h │ │ │ │ │ │ ├── RemoveTree.h │ │ │ │ │ │ ├── Scan.h │ │ │ │ │ │ ├── ScanContext.h │ │ │ │ │ │ ├── SymbolTable.h │ │ │ │ │ │ ├── Versions.h │ │ │ │ │ │ ├── attribute.h │ │ │ │ │ │ ├── gl_types.h │ │ │ │ │ │ ├── glslang_tab.cpp.h │ │ │ │ │ │ ├── iomapper.h │ │ │ │ │ │ ├── localintermediate.h │ │ │ │ │ │ ├── parseVersions.h │ │ │ │ │ │ ├── preprocessor │ │ │ │ │ │ │ ├── PpContext.h │ │ │ │ │ │ │ └── PpTokens.h │ │ │ │ │ │ ├── propagateNoContraction.h │ │ │ │ │ │ └── reflection.h │ │ │ │ │ ├── Public │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShaderLang.h │ │ │ │ │ │ └── resource_limits_c.h │ │ │ │ │ ├── SPIRV │ │ │ │ │ │ ├── GLSL.ext.AMD.h │ │ │ │ │ │ ├── GLSL.ext.EXT.h │ │ │ │ │ │ ├── GLSL.ext.KHR.h │ │ │ │ │ │ ├── GLSL.ext.NV.h │ │ │ │ │ │ ├── GLSL.std.450.h │ │ │ │ │ │ ├── GlslangToSpv.h │ │ │ │ │ │ ├── Logger.h │ │ │ │ │ │ ├── NonSemanticDebugPrintf.h │ │ │ │ │ │ ├── NonSemanticShaderDebugInfo100.h │ │ │ │ │ │ ├── SPVRemapper.h │ │ │ │ │ │ ├── SpvBuilder.h │ │ │ │ │ │ ├── SpvTools.h │ │ │ │ │ │ ├── bitutils.h │ │ │ │ │ │ ├── disassemble.h │ │ │ │ │ │ ├── doc.h │ │ │ │ │ │ ├── hex_float.h │ │ │ │ │ │ ├── spirv.hpp │ │ │ │ │ │ └── spvIR.h │ │ │ │ │ └── build_info.h │ │ │ │ └── ncnn │ │ │ │ │ ├── allocator.h │ │ │ │ │ ├── benchmark.h │ │ │ │ │ ├── blob.h │ │ │ │ │ ├── c_api.h │ │ │ │ │ ├── command.h │ │ │ │ │ ├── cpu.h │ │ │ │ │ ├── datareader.h │ │ │ │ │ ├── gpu.h │ │ │ │ │ ├── layer.h │ │ │ │ │ ├── layer_shader_type.h │ │ │ │ │ ├── layer_shader_type_enum.h │ │ │ │ │ ├── layer_type.h │ │ │ │ │ ├── layer_type_enum.h │ │ │ │ │ ├── mat.h │ │ │ │ │ ├── modelbin.h │ │ │ │ │ ├── ncnn_export.h │ │ │ │ │ ├── net.h │ │ │ │ │ ├── option.h │ │ │ │ │ ├── paramdict.h │ │ │ │ │ ├── pipeline.h │ │ │ │ │ ├── pipelinecache.h │ │ │ │ │ ├── platform.h │ │ │ │ │ ├── simpleocv.h │ │ │ │ │ ├── simpleomp.h │ │ │ │ │ ├── simplestl.h │ │ │ │ │ └── vulkan_header_fix.h │ │ │ └── lib │ │ │ │ ├── cmake │ │ │ │ ├── OGLCompilerTargets.cmake │ │ │ │ ├── OSDependentTargets.cmake │ │ │ │ ├── SPIRVTargets.cmake │ │ │ │ ├── glslang │ │ │ │ │ ├── glslang-config-version.cmake │ │ │ │ │ ├── glslang-config.cmake │ │ │ │ │ ├── glslang-targets-release.cmake │ │ │ │ │ └── glslang-targets.cmake │ │ │ │ ├── glslangTargets.cmake │ │ │ │ └── ncnn │ │ │ │ │ ├── ncnn-release.cmake │ │ │ │ │ ├── ncnn.cmake │ │ │ │ │ └── ncnnConfig.cmake │ │ │ │ ├── libGenericCodeGen.a │ │ │ │ ├── libMachineIndependent.a │ │ │ │ ├── libOGLCompiler.a │ │ │ │ ├── libOSDependent.a │ │ │ │ ├── libSPIRV.a │ │ │ │ ├── libglslang.a │ │ │ │ ├── libncnn.a │ │ │ │ └── pkgconfig │ │ │ │ └── ncnn.pc │ │ ├── x86 │ │ │ ├── include │ │ │ │ ├── glslang │ │ │ │ │ ├── Include │ │ │ │ │ │ ├── BaseTypes.h │ │ │ │ │ │ ├── Common.h │ │ │ │ │ │ ├── ConstantUnion.h │ │ │ │ │ │ ├── InfoSink.h │ │ │ │ │ │ ├── InitializeGlobals.h │ │ │ │ │ │ ├── PoolAlloc.h │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShHandle.h │ │ │ │ │ │ ├── SpirvIntrinsics.h │ │ │ │ │ │ ├── Types.h │ │ │ │ │ │ ├── arrays.h │ │ │ │ │ │ ├── glslang_c_interface.h │ │ │ │ │ │ ├── glslang_c_shader_types.h │ │ │ │ │ │ └── intermediate.h │ │ │ │ │ ├── MachineIndependent │ │ │ │ │ │ ├── Initialize.h │ │ │ │ │ │ ├── LiveTraverser.h │ │ │ │ │ │ ├── ParseHelper.h │ │ │ │ │ │ ├── RemoveTree.h │ │ │ │ │ │ ├── Scan.h │ │ │ │ │ │ ├── ScanContext.h │ │ │ │ │ │ ├── SymbolTable.h │ │ │ │ │ │ ├── Versions.h │ │ │ │ │ │ ├── attribute.h │ │ │ │ │ │ ├── gl_types.h │ │ │ │ │ │ ├── glslang_tab.cpp.h │ │ │ │ │ │ ├── iomapper.h │ │ │ │ │ │ ├── localintermediate.h │ │ │ │ │ │ ├── parseVersions.h │ │ │ │ │ │ ├── preprocessor │ │ │ │ │ │ │ ├── PpContext.h │ │ │ │ │ │ │ └── PpTokens.h │ │ │ │ │ │ ├── propagateNoContraction.h │ │ │ │ │ │ └── reflection.h │ │ │ │ │ ├── Public │ │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ │ ├── ShaderLang.h │ │ │ │ │ │ └── resource_limits_c.h │ │ │ │ │ ├── SPIRV │ │ │ │ │ │ ├── GLSL.ext.AMD.h │ │ │ │ │ │ ├── GLSL.ext.EXT.h │ │ │ │ │ │ ├── GLSL.ext.KHR.h │ │ │ │ │ │ ├── GLSL.ext.NV.h │ │ │ │ │ │ ├── GLSL.std.450.h │ │ │ │ │ │ ├── GlslangToSpv.h │ │ │ │ │ │ ├── Logger.h │ │ │ │ │ │ ├── NonSemanticDebugPrintf.h │ │ │ │ │ │ ├── NonSemanticShaderDebugInfo100.h │ │ │ │ │ │ ├── SPVRemapper.h │ │ │ │ │ │ ├── SpvBuilder.h │ │ │ │ │ │ ├── SpvTools.h │ │ │ │ │ │ ├── bitutils.h │ │ │ │ │ │ ├── disassemble.h │ │ │ │ │ │ ├── doc.h │ │ │ │ │ │ ├── hex_float.h │ │ │ │ │ │ ├── spirv.hpp │ │ │ │ │ │ └── spvIR.h │ │ │ │ │ └── build_info.h │ │ │ │ └── ncnn │ │ │ │ │ ├── allocator.h │ │ │ │ │ ├── benchmark.h │ │ │ │ │ ├── blob.h │ │ │ │ │ ├── c_api.h │ │ │ │ │ ├── command.h │ │ │ │ │ ├── cpu.h │ │ │ │ │ ├── datareader.h │ │ │ │ │ ├── gpu.h │ │ │ │ │ ├── layer.h │ │ │ │ │ ├── layer_shader_type.h │ │ │ │ │ ├── layer_shader_type_enum.h │ │ │ │ │ ├── layer_type.h │ │ │ │ │ ├── layer_type_enum.h │ │ │ │ │ ├── mat.h │ │ │ │ │ ├── modelbin.h │ │ │ │ │ ├── ncnn_export.h │ │ │ │ │ ├── net.h │ │ │ │ │ ├── option.h │ │ │ │ │ ├── paramdict.h │ │ │ │ │ ├── pipeline.h │ │ │ │ │ ├── pipelinecache.h │ │ │ │ │ ├── platform.h │ │ │ │ │ ├── simpleocv.h │ │ │ │ │ ├── simpleomp.h │ │ │ │ │ ├── simplestl.h │ │ │ │ │ └── vulkan_header_fix.h │ │ │ └── lib │ │ │ │ ├── cmake │ │ │ │ ├── OGLCompilerTargets.cmake │ │ │ │ ├── OSDependentTargets.cmake │ │ │ │ ├── SPIRVTargets.cmake │ │ │ │ ├── glslang │ │ │ │ │ ├── glslang-config-version.cmake │ │ │ │ │ ├── glslang-config.cmake │ │ │ │ │ ├── glslang-targets-release.cmake │ │ │ │ │ └── glslang-targets.cmake │ │ │ │ ├── glslangTargets.cmake │ │ │ │ └── ncnn │ │ │ │ │ ├── ncnn-release.cmake │ │ │ │ │ ├── ncnn.cmake │ │ │ │ │ └── ncnnConfig.cmake │ │ │ │ ├── libGenericCodeGen.a │ │ │ │ ├── libMachineIndependent.a │ │ │ │ ├── libOGLCompiler.a │ │ │ │ ├── libOSDependent.a │ │ │ │ ├── libSPIRV.a │ │ │ │ ├── libglslang.a │ │ │ │ ├── libncnn.a │ │ │ │ └── pkgconfig │ │ │ │ └── ncnn.pc │ │ └── x86_64 │ │ │ ├── include │ │ │ ├── glslang │ │ │ │ ├── Include │ │ │ │ │ ├── BaseTypes.h │ │ │ │ │ ├── Common.h │ │ │ │ │ ├── ConstantUnion.h │ │ │ │ │ ├── InfoSink.h │ │ │ │ │ ├── InitializeGlobals.h │ │ │ │ │ ├── PoolAlloc.h │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ ├── ShHandle.h │ │ │ │ │ ├── SpirvIntrinsics.h │ │ │ │ │ ├── Types.h │ │ │ │ │ ├── arrays.h │ │ │ │ │ ├── glslang_c_interface.h │ │ │ │ │ ├── glslang_c_shader_types.h │ │ │ │ │ └── intermediate.h │ │ │ │ ├── MachineIndependent │ │ │ │ │ ├── Initialize.h │ │ │ │ │ ├── LiveTraverser.h │ │ │ │ │ ├── ParseHelper.h │ │ │ │ │ ├── RemoveTree.h │ │ │ │ │ ├── Scan.h │ │ │ │ │ ├── ScanContext.h │ │ │ │ │ ├── SymbolTable.h │ │ │ │ │ ├── Versions.h │ │ │ │ │ ├── attribute.h │ │ │ │ │ ├── gl_types.h │ │ │ │ │ ├── glslang_tab.cpp.h │ │ │ │ │ ├── iomapper.h │ │ │ │ │ ├── localintermediate.h │ │ │ │ │ ├── parseVersions.h │ │ │ │ │ ├── preprocessor │ │ │ │ │ │ ├── PpContext.h │ │ │ │ │ │ └── PpTokens.h │ │ │ │ │ ├── propagateNoContraction.h │ │ │ │ │ └── reflection.h │ │ │ │ ├── Public │ │ │ │ │ ├── ResourceLimits.h │ │ │ │ │ ├── ShaderLang.h │ │ │ │ │ └── resource_limits_c.h │ │ │ │ ├── SPIRV │ │ │ │ │ ├── GLSL.ext.AMD.h │ │ │ │ │ ├── GLSL.ext.EXT.h │ │ │ │ │ ├── GLSL.ext.KHR.h │ │ │ │ │ ├── GLSL.ext.NV.h │ │ │ │ │ ├── GLSL.std.450.h │ │ │ │ │ ├── GlslangToSpv.h │ │ │ │ │ ├── Logger.h │ │ │ │ │ ├── NonSemanticDebugPrintf.h │ │ │ │ │ ├── NonSemanticShaderDebugInfo100.h │ │ │ │ │ ├── SPVRemapper.h │ │ │ │ │ ├── SpvBuilder.h │ │ │ │ │ ├── SpvTools.h │ │ │ │ │ ├── bitutils.h │ │ │ │ │ ├── disassemble.h │ │ │ │ │ ├── doc.h │ │ │ │ │ ├── hex_float.h │ │ │ │ │ ├── spirv.hpp │ │ │ │ │ └── spvIR.h │ │ │ │ └── build_info.h │ │ │ └── ncnn │ │ │ │ ├── allocator.h │ │ │ │ ├── benchmark.h │ │ │ │ ├── blob.h │ │ │ │ ├── c_api.h │ │ │ │ ├── command.h │ │ │ │ ├── cpu.h │ │ │ │ ├── datareader.h │ │ │ │ ├── gpu.h │ │ │ │ ├── layer.h │ │ │ │ ├── layer_shader_type.h │ │ │ │ ├── layer_shader_type_enum.h │ │ │ │ ├── layer_type.h │ │ │ │ ├── layer_type_enum.h │ │ │ │ ├── mat.h │ │ │ │ ├── modelbin.h │ │ │ │ ├── ncnn_export.h │ │ │ │ ├── net.h │ │ │ │ ├── option.h │ │ │ │ ├── paramdict.h │ │ │ │ ├── pipeline.h │ │ │ │ ├── pipelinecache.h │ │ │ │ ├── platform.h │ │ │ │ ├── simpleocv.h │ │ │ │ ├── simpleomp.h │ │ │ │ ├── simplestl.h │ │ │ │ └── vulkan_header_fix.h │ │ │ └── lib │ │ │ ├── cmake │ │ │ ├── OGLCompilerTargets.cmake │ │ │ ├── OSDependentTargets.cmake │ │ │ ├── SPIRVTargets.cmake │ │ │ ├── glslang │ │ │ │ ├── glslang-config-version.cmake │ │ │ │ ├── glslang-config.cmake │ │ │ │ ├── glslang-targets-release.cmake │ │ │ │ └── glslang-targets.cmake │ │ │ ├── glslangTargets.cmake │ │ │ └── ncnn │ │ │ │ ├── ncnn-release.cmake │ │ │ │ ├── ncnn.cmake │ │ │ │ └── ncnnConfig.cmake │ │ │ ├── libGenericCodeGen.a │ │ │ ├── libMachineIndependent.a │ │ │ ├── libOGLCompiler.a │ │ │ ├── libOSDependent.a │ │ │ ├── libSPIRV.a │ │ │ ├── libglslang.a │ │ │ ├── libncnn.a │ │ │ └── pkgconfig │ │ │ └── ncnn.pc │ ├── ndkcamera.cpp │ ├── ndkcamera.h │ ├── opencv-mobile-4.6.0-android │ │ ├── LICENSE │ │ ├── README.android │ │ └── sdk │ │ │ └── native │ │ │ ├── jni │ │ │ ├── OpenCVConfig-version.cmake │ │ │ ├── OpenCVConfig.cmake │ │ │ ├── abi-arm64-v8a │ │ │ │ ├── OpenCVConfig-version.cmake │ │ │ │ ├── OpenCVConfig.cmake │ │ │ │ ├── OpenCVModules-release.cmake │ │ │ │ └── OpenCVModules.cmake │ │ │ ├── abi-armeabi-v7a │ │ │ │ ├── OpenCVConfig-version.cmake │ │ │ │ ├── OpenCVConfig.cmake │ │ │ │ ├── OpenCVModules-release.cmake │ │ │ │ └── OpenCVModules.cmake │ │ │ ├── abi-x86 │ │ │ │ ├── OpenCVConfig-version.cmake │ │ │ │ ├── OpenCVConfig.cmake │ │ │ │ ├── OpenCVModules-release.cmake │ │ │ │ └── OpenCVModules.cmake │ │ │ ├── abi-x86_64 │ │ │ │ ├── OpenCVConfig-version.cmake │ │ │ │ ├── OpenCVConfig.cmake │ │ │ │ ├── OpenCVModules-release.cmake │ │ │ │ └── OpenCVModules.cmake │ │ │ └── include │ │ │ │ └── opencv2 │ │ │ │ ├── core.hpp │ │ │ │ ├── core │ │ │ │ ├── affine.hpp │ │ │ │ ├── async.hpp │ │ │ │ ├── base.hpp │ │ │ │ ├── bindings_utils.hpp │ │ │ │ ├── bufferpool.hpp │ │ │ │ ├── check.hpp │ │ │ │ ├── core.hpp │ │ │ │ ├── core_c.h │ │ │ │ ├── cuda.hpp │ │ │ │ ├── cuda.inl.hpp │ │ │ │ ├── cuda │ │ │ │ │ ├── block.hpp │ │ │ │ │ ├── border_interpolate.hpp │ │ │ │ │ ├── color.hpp │ │ │ │ │ ├── common.hpp │ │ │ │ │ ├── datamov_utils.hpp │ │ │ │ │ ├── detail │ │ │ │ │ │ ├── color_detail.hpp │ │ │ │ │ │ ├── reduce.hpp │ │ │ │ │ │ ├── reduce_key_val.hpp │ │ │ │ │ │ ├── transform_detail.hpp │ │ │ │ │ │ ├── type_traits_detail.hpp │ │ │ │ │ │ └── vec_distance_detail.hpp │ │ │ │ │ ├── dynamic_smem.hpp │ │ │ │ │ ├── emulation.hpp │ │ │ │ │ ├── filters.hpp │ │ │ │ │ ├── funcattrib.hpp │ │ │ │ │ ├── functional.hpp │ │ │ │ │ ├── limits.hpp │ │ │ │ │ ├── reduce.hpp │ │ │ │ │ ├── saturate_cast.hpp │ │ │ │ │ ├── scan.hpp │ │ │ │ │ ├── simd_functions.hpp │ │ │ │ │ ├── transform.hpp │ │ │ │ │ ├── type_traits.hpp │ │ │ │ │ ├── utility.hpp │ │ │ │ │ ├── vec_distance.hpp │ │ │ │ │ ├── vec_math.hpp │ │ │ │ │ ├── vec_traits.hpp │ │ │ │ │ ├── warp.hpp │ │ │ │ │ ├── warp_reduce.hpp │ │ │ │ │ └── warp_shuffle.hpp │ │ │ │ ├── cuda_stream_accessor.hpp │ │ │ │ ├── cuda_types.hpp │ │ │ │ ├── cv_cpu_dispatch.h │ │ │ │ ├── cv_cpu_helper.h │ │ │ │ ├── cvdef.h │ │ │ │ ├── cvstd.hpp │ │ │ │ ├── cvstd.inl.hpp │ │ │ │ ├── cvstd_wrapper.hpp │ │ │ │ ├── detail │ │ │ │ │ ├── async_promise.hpp │ │ │ │ │ ├── dispatch_helper.impl.hpp │ │ │ │ │ └── exception_ptr.hpp │ │ │ │ ├── directx.hpp │ │ │ │ ├── dualquaternion.hpp │ │ │ │ ├── dualquaternion.inl.hpp │ │ │ │ ├── eigen.hpp │ │ │ │ ├── fast_math.hpp │ │ │ │ ├── hal │ │ │ │ │ ├── hal.hpp │ │ │ │ │ ├── interface.h │ │ │ │ │ ├── intrin.hpp │ │ │ │ │ ├── intrin_avx.hpp │ │ │ │ │ ├── intrin_avx512.hpp │ │ │ │ │ ├── intrin_cpp.hpp │ │ │ │ │ ├── intrin_forward.hpp │ │ │ │ │ ├── intrin_msa.hpp │ │ │ │ │ ├── intrin_neon.hpp │ │ │ │ │ ├── intrin_rvv.hpp │ │ │ │ │ ├── intrin_rvv071.hpp │ │ │ │ │ ├── intrin_sse.hpp │ │ │ │ │ ├── intrin_sse_em.hpp │ │ │ │ │ ├── intrin_vsx.hpp │ │ │ │ │ ├── intrin_wasm.hpp │ │ │ │ │ ├── msa_macros.h │ │ │ │ │ └── simd_utils.impl.hpp │ │ │ │ ├── mat.hpp │ │ │ │ ├── mat.inl.hpp │ │ │ │ ├── matx.hpp │ │ │ │ ├── neon_utils.hpp │ │ │ │ ├── ocl.hpp │ │ │ │ ├── ocl_genbase.hpp │ │ │ │ ├── opencl │ │ │ │ │ ├── ocl_defs.hpp │ │ │ │ │ ├── opencl_info.hpp │ │ │ │ │ ├── opencl_svm.hpp │ │ │ │ │ └── runtime │ │ │ │ │ │ ├── autogenerated │ │ │ │ │ │ ├── opencl_clblas.hpp │ │ │ │ │ │ ├── opencl_clfft.hpp │ │ │ │ │ │ ├── opencl_core.hpp │ │ │ │ │ │ ├── opencl_core_wrappers.hpp │ │ │ │ │ │ ├── opencl_gl.hpp │ │ │ │ │ │ └── opencl_gl_wrappers.hpp │ │ │ │ │ │ ├── opencl_clblas.hpp │ │ │ │ │ │ ├── opencl_clfft.hpp │ │ │ │ │ │ ├── opencl_core.hpp │ │ │ │ │ │ ├── opencl_core_wrappers.hpp │ │ │ │ │ │ ├── opencl_gl.hpp │ │ │ │ │ │ ├── opencl_gl_wrappers.hpp │ │ │ │ │ │ ├── opencl_svm_20.hpp │ │ │ │ │ │ ├── opencl_svm_definitions.hpp │ │ │ │ │ │ └── opencl_svm_hsa_extension.hpp │ │ │ │ ├── opengl.hpp │ │ │ │ ├── operations.hpp │ │ │ │ ├── optim.hpp │ │ │ │ ├── ovx.hpp │ │ │ │ ├── parallel │ │ │ │ │ ├── backend │ │ │ │ │ │ ├── parallel_for.openmp.hpp │ │ │ │ │ │ └── parallel_for.tbb.hpp │ │ │ │ │ └── parallel_backend.hpp │ │ │ │ ├── persistence.hpp │ │ │ │ ├── quaternion.hpp │ │ │ │ ├── quaternion.inl.hpp │ │ │ │ ├── saturate.hpp │ │ │ │ ├── simd_intrinsics.hpp │ │ │ │ ├── softfloat.hpp │ │ │ │ ├── sse_utils.hpp │ │ │ │ ├── traits.hpp │ │ │ │ ├── types.hpp │ │ │ │ ├── types_c.h │ │ │ │ ├── utility.hpp │ │ │ │ ├── utils │ │ │ │ │ ├── allocator_stats.hpp │ │ │ │ │ ├── allocator_stats.impl.hpp │ │ │ │ │ ├── filesystem.hpp │ │ │ │ │ ├── fp_control_utils.hpp │ │ │ │ │ ├── instrumentation.hpp │ │ │ │ │ ├── logger.defines.hpp │ │ │ │ │ ├── logger.hpp │ │ │ │ │ ├── logtag.hpp │ │ │ │ │ ├── tls.hpp │ │ │ │ │ └── trace.hpp │ │ │ │ ├── va_intel.hpp │ │ │ │ ├── version.hpp │ │ │ │ └── vsx_utils.hpp │ │ │ │ ├── cvconfig.h │ │ │ │ ├── features2d.hpp │ │ │ │ ├── features2d │ │ │ │ ├── features2d.hpp │ │ │ │ └── hal │ │ │ │ │ └── interface.h │ │ │ │ ├── highgui.hpp │ │ │ │ ├── highgui │ │ │ │ └── highgui.hpp │ │ │ │ ├── imgproc.hpp │ │ │ │ ├── imgproc │ │ │ │ ├── bindings.hpp │ │ │ │ ├── detail │ │ │ │ │ └── gcgraph.hpp │ │ │ │ ├── hal │ │ │ │ │ ├── hal.hpp │ │ │ │ │ └── interface.h │ │ │ │ ├── imgproc.hpp │ │ │ │ ├── imgproc_c.h │ │ │ │ ├── segmentation.hpp │ │ │ │ └── types_c.h │ │ │ │ ├── opencv.hpp │ │ │ │ ├── opencv_modules.hpp │ │ │ │ ├── photo.hpp │ │ │ │ ├── photo │ │ │ │ ├── cuda.hpp │ │ │ │ ├── legacy │ │ │ │ │ └── constants_c.h │ │ │ │ └── photo.hpp │ │ │ │ ├── video.hpp │ │ │ │ └── video │ │ │ │ ├── background_segm.hpp │ │ │ │ ├── detail │ │ │ │ └── tracking.detail.hpp │ │ │ │ ├── legacy │ │ │ │ └── constants_c.h │ │ │ │ ├── tracking.hpp │ │ │ │ └── video.hpp │ │ │ └── staticlibs │ │ │ ├── arm64-v8a │ │ │ ├── libopencv_core.a │ │ │ ├── libopencv_features2d.a │ │ │ ├── libopencv_highgui.a │ │ │ ├── libopencv_imgproc.a │ │ │ ├── libopencv_photo.a │ │ │ └── libopencv_video.a │ │ │ ├── armeabi-v7a │ │ │ ├── libopencv_core.a │ │ │ ├── libopencv_features2d.a │ │ │ ├── libopencv_highgui.a │ │ │ ├── libopencv_imgproc.a │ │ │ ├── libopencv_photo.a │ │ │ └── libopencv_video.a │ │ │ ├── x86 │ │ │ ├── libopencv_core.a │ │ │ ├── libopencv_features2d.a │ │ │ ├── libopencv_highgui.a │ │ │ ├── libopencv_imgproc.a │ │ │ ├── libopencv_photo.a │ │ │ └── libopencv_video.a │ │ │ └── x86_64 │ │ │ ├── libopencv_core.a │ │ │ ├── libopencv_features2d.a │ │ │ ├── libopencv_highgui.a │ │ │ ├── libopencv_imgproc.a │ │ │ ├── libopencv_photo.a │ │ │ └── libopencv_video.a │ ├── yolo.cpp │ ├── yolo.h │ ├── yolo.zip │ └── yolov8ncnn.cpp │ └── res │ ├── layout │ └── main.xml │ └── values │ └── strings.xml ├── build.gradle ├── doc └── 20230209114529.jpg ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle /.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.aar 4 | *.ap_ 5 | *.aab 6 | 7 | # Files for the ART/Dalvik VM 8 | *.dex 9 | 10 | # Java class files 11 | *.class 12 | 13 | # Generated files 14 | bin/ 15 | gen/ 16 | out/ 17 | # Uncomment the following line in case you need and you don't have the release build type files in your app 18 | # release/ 19 | 20 | # Gradle files 21 | .gradle/ 22 | build/ 23 | 24 | # Local configuration file (sdk path, etc) 25 | local.properties 26 | 27 | # Proguard folder generated by Eclipse 28 | proguard/ 29 | 30 | # Log Files 31 | *.log 32 | 33 | # Android Studio Navigation editor temp files 34 | .navigation/ 35 | 36 | # Android Studio captures folder 37 | captures/ 38 | 39 | # IntelliJ 40 | *.iml 41 | .idea/workspace.xml 42 | .idea/tasks.xml 43 | .idea/gradle.xml 44 | .idea/assetWizardSettings.xml 45 | .idea/dictionaries 46 | .idea/libraries 47 | # Android Studio 3 in .gitignore file. 48 | .idea/caches 49 | .idea/modules.xml 50 | # Comment next line if keeping position of elements in Navigation Editor is relevant for you 51 | .idea/navEditor.xml 52 | 53 | # Keystore files 54 | # Uncomment the following lines if you do not want to check your keystore files in. 55 | #*.jks 56 | #*.keystore 57 | 58 | # External native build folder generated in Android Studio 2.2 and later 59 | .externalNativeBuild 60 | .cxx/ 61 | 62 | # Google Services (e.g. APIs or Firebase) 63 | # google-services.json 64 | 65 | # Freeline 66 | freeline.py 67 | freeline/ 68 | freeline_project_description.json 69 | 70 | # fastlane 71 | fastlane/report.xml 72 | fastlane/Preview.html 73 | fastlane/screenshots 74 | fastlane/test_output 75 | fastlane/readme.md 76 | 77 | # Version control 78 | vcs.xml 79 | 80 | # lint 81 | lint/intermediates/ 82 | lint/generated/ 83 | lint/outputs/ 84 | lint/tmp/ 85 | # lint/reports/ 86 | 87 | # Android Profiling 88 | *.hprof 89 | -------------------------------------------------------------------------------- /.idea/misc.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 16 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /.idea/runConfigurations.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 11 | 12 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # ncnn-yolov8-seg 2 | 3 | 4 | This is a sample ncnn yolov8 object segment android project, it depends on **ncnn** library and **opencv**. 5 | 6 | Method 1 7 | 8 | - [How to convert yolov8 model to ncnn model?](https://github.com/Digital2Slave/ncnn-android-yolov8-seg/wiki/Convert-yolov8-model-to-ncnn-model) 9 | 10 | Method 2 11 | 12 | - [Convert yolov8‐seg to ncnn model step by step](https://github.com/Digital2Slave/ncnn-android-yolov8-seg/wiki/Convert-yolov8%E2%80%90seg-to-ncnn-model-step-by-step) 13 | 14 | Method 3 15 | 16 | - ~~`ultralytics 8.0.129` add YOLOv8 Tencent NCNN export #3529 https://github.com/ultralytics/ultralytics/pull/3529~~ 17 | 18 | 19 | ## 1 How to build and run 20 | 21 | ### 1.1 Configure ncnn 22 | 23 | * Download [ncnn-YYYYMMDD-android-vulkan.zip](https://github.com/Tencent/ncnn/releases). 24 | * Extract **ncnn-YYYYMMDD-android-vulkan.zip** into **app/src/main/jni** folder and change the **ncnn_DIR** path to yours in **app/src/main/jni/CMakeLists.txt**. 25 | 26 | > For example:`ncnn-20221128-android-vulkan` 27 | 28 | ### 1.2 Configure OpenCV 29 | 30 | * Download [opencv-mobile-XYZ-android.zip](https://github.com/nihui/opencv-mobile) 31 | * Extract **opencv-mobile-XYZ-android.zip** into **app/src/main/jni** and change the **OpenCV_DIR** path to yours in **app/src/main/jni/CMakeLists.txt**. 32 | 33 | > For example:`opencv-mobile-4.6.0-android` 34 | 35 | ### 1.3 Build and Install ncnn-yolov8-seg app 36 | 37 | * Open this project with Android Studio, build it and enjoy! 38 | 39 | ## 2 Some notes 40 | 41 | * Android ndk camera is used for best efficiency. 42 | * Crash may happen on very old devices for lacking HAL3 camera interface. 43 | * All models are manually modified to accept dynamic input shape. 44 | * Most small models run slower on GPU than on CPU, this is common. 45 | * FPS may be lower in dark environment because of longer camera exposure time. 46 | 47 | ## 3 Screenshot 48 | 49 | ![](./doc/20230209114529.jpg) 50 | 51 | ## 4 Reference 52 | 53 | - https://github.com/ultralytics/ultralytics 54 | - https://github.com/Tencent/ncnn 55 | - https://github.com/nihui/opencv-mobile 56 | - https://github.com/nihui/ncnn-android-nanodet 57 | - https://github.com/FeiGeChuanShu/ncnn-android-yolov8 58 | -------------------------------------------------------------------------------- /app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 27 5 | // buildToolsVersion "29.0.2" 6 | 7 | defaultConfig { 8 | applicationId "com.tencent.yolov8ncnn" 9 | archivesBaseName = "$applicationId" 10 | 11 | minSdkVersion 24 12 | 13 | testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 14 | // 添加abiFilters 15 | externalNativeBuild { 16 | cmake { 17 | cppFlags "-std=c++11 -frtti -fexceptions" 18 | abiFilters 'arm64-v8a' 19 | //arguments "-DANDROID_STL=c++_shared" 20 | } 21 | } 22 | // 添加abiFilters 23 | ndk { 24 | abiFilters 'arm64-v8a' 25 | } 26 | } 27 | 28 | // 设置jniLibs 29 | // sourceSets { 30 | // main { 31 | // jniLibs.srcDirs = ['src/main/jniLibs'] 32 | // } 33 | // } 34 | 35 | externalNativeBuild { 36 | cmake { 37 | version "3.10.2" 38 | path file('src/main/jni/CMakeLists.txt') 39 | } 40 | } 41 | 42 | dependencies { 43 | implementation 'com.android.support:support-v4:24.0.0' 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 8 | 9 | 10 | 13 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | -------------------------------------------------------------------------------- /app/src/main/assets/yolov8n-seg-sim-opt-fp16.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/assets/yolov8n-seg-sim-opt-fp16.bin -------------------------------------------------------------------------------- /app/src/main/assets/yolov8s-seg-sim-opt-fp16.bin: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/assets/yolov8s-seg-sim-opt-fp16.bin -------------------------------------------------------------------------------- /app/src/main/java/com/tencent/yolov8ncnn/Yolov8Ncnn.java: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | package com.tencent.yolov8ncnn; 16 | 17 | import android.content.res.AssetManager; 18 | import android.view.Surface; 19 | 20 | public class Yolov8Ncnn 21 | { 22 | public native boolean loadModel(AssetManager mgr, int modelid, int cpugpu); 23 | public native boolean openCamera(int facing); 24 | public native boolean closeCamera(); 25 | public native boolean setOutputWindow(Surface surface); 26 | 27 | static { 28 | System.loadLibrary("yolov8ncnn"); 29 | } 30 | } 31 | -------------------------------------------------------------------------------- /app/src/main/jni/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | project(yolov8ncnn) 2 | 3 | cmake_minimum_required(VERSION 3.10) 4 | 5 | set(OpenCV_DIR ${CMAKE_SOURCE_DIR}/opencv-mobile-4.6.0-android/sdk/native/jni) 6 | #find_package(OpenCV REQUIRED) 7 | find_package(OpenCV REQUIRED core imgproc) 8 | 9 | set(ncnn_DIR ${CMAKE_SOURCE_DIR}/ncnn-20221128-android-vulkan/${ANDROID_ABI}/lib/cmake/ncnn) 10 | find_package(ncnn REQUIRED) 11 | 12 | add_library(yolov8ncnn SHARED yolov8ncnn.cpp yolo.cpp ndkcamera.cpp) 13 | 14 | target_link_libraries(yolov8ncnn ncnn ${OpenCV_LIBS} camera2ndk mediandk) 15 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/glslang/Include/InitializeGlobals.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #ifndef __INITIALIZE_GLOBALS_INCLUDED_ 36 | #define __INITIALIZE_GLOBALS_INCLUDED_ 37 | 38 | namespace glslang { 39 | 40 | bool InitializePoolIndex(); 41 | 42 | } // end namespace glslang 43 | 44 | #endif // __INITIALIZE_GLOBALS_INCLUDED_ 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/glslang/MachineIndependent/RemoveTree.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #pragma once 36 | 37 | namespace glslang { 38 | 39 | void RemoveAllTreeNodes(TIntermNode*); 40 | 41 | } // end namespace glslang 42 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/glslang/Public/resource_limits_c.h: -------------------------------------------------------------------------------- 1 | /** 2 | BSD 2-Clause License 3 | 4 | Copyright (c) 2020, Travis Fort 5 | All rights reserved. 6 | 7 | Redistribution and use in source and binary forms, with or without 8 | modification, are permitted provided that the following conditions are met: 9 | 10 | 1. Redistributions of source code must retain the above copyright notice, this 11 | list of conditions and the following disclaimer. 12 | 13 | 2. Redistributions in binary form must reproduce the above copyright notice, 14 | this list of conditions and the following disclaimer in the documentation 15 | and/or other materials provided with the distribution. 16 | 17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 20 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 21 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 23 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 24 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 26 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | **/ 28 | 29 | #ifndef _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 30 | #define _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 31 | 32 | #include "../Include/glslang_c_interface.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif 37 | 38 | // Returns a struct that can be use to create custom resource values. 39 | glslang_resource_t* glslang_resource(void); 40 | 41 | // These are the default resources for TBuiltInResources, used for both 42 | // - parsing this string for the case where the user didn't supply one, 43 | // - dumping out a template for user construction of a config file. 44 | const glslang_resource_t* glslang_default_resource(void); 45 | 46 | // Returns the DefaultTBuiltInResource as a human-readable string. 47 | // NOTE: User is responsible for freeing this string. 48 | const char* glslang_default_resource_string(); 49 | 50 | // Decodes the resource limits from |config| to |resources|. 51 | void glslang_decode_resource_limits(glslang_resource_t* resources, char* config); 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif 56 | 57 | #endif // _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 58 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/glslang/SPIRV/NonSemanticDebugPrintf.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2020 The Khronos Group Inc. 2 | // 3 | // Permission is hereby granted, free of charge, to any person obtaining a 4 | // copy of this software and/or associated documentation files (the 5 | // "Materials"), to deal in the Materials without restriction, including 6 | // without limitation the rights to use, copy, modify, merge, publish, 7 | // distribute, sublicense, and/or sell copies of the Materials, and to 8 | // permit persons to whom the Materials are furnished to do so, subject to 9 | // the following conditions: 10 | // 11 | // The above copyright notice and this permission notice shall be included 12 | // in all copies or substantial portions of the Materials. 13 | // 14 | // MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS 15 | // KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS 16 | // SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT 17 | // https://www.khronos.org/registry/ 18 | // 19 | // THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 20 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 21 | // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 22 | // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 23 | // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 24 | // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 25 | // MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. 26 | // 27 | 28 | #ifndef SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 29 | #define SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | 35 | enum { 36 | NonSemanticDebugPrintfRevision = 1, 37 | NonSemanticDebugPrintfRevision_BitWidthPadding = 0x7fffffff 38 | }; 39 | 40 | enum NonSemanticDebugPrintfInstructions { 41 | NonSemanticDebugPrintfDebugPrintf = 1, 42 | NonSemanticDebugPrintfInstructionsMax = 0x7fffffff 43 | }; 44 | 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif // SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 51 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/glslang/SPIRV/disassemble.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2014-2015 LunarG, Inc. 3 | // 4 | // All rights reserved. 5 | // 6 | // Redistribution and use in source and binary forms, with or without 7 | // modification, are permitted provided that the following conditions 8 | // are met: 9 | // 10 | // Redistributions of source code must retain the above copyright 11 | // notice, this list of conditions and the following disclaimer. 12 | // 13 | // Redistributions in binary form must reproduce the above 14 | // copyright notice, this list of conditions and the following 15 | // disclaimer in the documentation and/or other materials provided 16 | // with the distribution. 17 | // 18 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 19 | // contributors may be used to endorse or promote products derived 20 | // from this software without specific prior written permission. 21 | // 22 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 23 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 24 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 25 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 26 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 27 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 28 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 29 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 30 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 32 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 33 | // POSSIBILITY OF SUCH DAMAGE. 34 | 35 | // 36 | // Disassembler for SPIR-V. 37 | // 38 | 39 | #pragma once 40 | #ifndef disassembler_H 41 | #define disassembler_H 42 | 43 | #include 44 | #include 45 | 46 | namespace spv { 47 | 48 | // disassemble with glslang custom disassembler 49 | void Disassemble(std::ostream& out, const std::vector&); 50 | 51 | } // end namespace spv 52 | 53 | #endif // disassembler_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/benchmark.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BENCHMARK_H 16 | #define NCNN_BENCHMARK_H 17 | 18 | #include "layer.h" 19 | #include "mat.h" 20 | #include "platform.h" 21 | 22 | namespace ncnn { 23 | 24 | // get now timestamp in ms 25 | NCNN_EXPORT double get_current_time(); 26 | 27 | #if NCNN_BENCHMARK 28 | 29 | NCNN_EXPORT void benchmark(const Layer* layer, double start, double end); 30 | NCNN_EXPORT void benchmark(const Layer* layer, const Mat& bottom_blob, Mat& top_blob, double start, double end); 31 | 32 | #endif // NCNN_BENCHMARK 33 | 34 | } // namespace ncnn 35 | 36 | #endif // NCNN_BENCHMARK_H 37 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/blob.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BLOB_H 16 | #define NCNN_BLOB_H 17 | 18 | #include "mat.h" 19 | #include "platform.h" 20 | 21 | namespace ncnn { 22 | 23 | class NCNN_EXPORT Blob 24 | { 25 | public: 26 | // empty 27 | Blob(); 28 | 29 | public: 30 | #if NCNN_STRING 31 | // blob name 32 | std::string name; 33 | #endif // NCNN_STRING 34 | // layer index which produce this blob as output 35 | int producer; 36 | // layer index which need this blob as input 37 | int consumer; 38 | // shape hint 39 | Mat shape; 40 | }; 41 | 42 | } // namespace ncnn 43 | 44 | #endif // NCNN_BLOB_H 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/layer_shader_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_SHADER_TYPE_H 16 | #define NCNN_LAYER_SHADER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerShaderType { 21 | enum LayerShaderType 22 | { 23 | #include "layer_shader_type_enum.h" 24 | }; 25 | } // namespace LayerShaderType 26 | 27 | } // namespace ncnn 28 | 29 | #endif // NCNN_LAYER_SHADER_TYPE_H 30 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/layer_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_TYPE_H 16 | #define NCNN_LAYER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerType { 21 | enum LayerType 22 | { 23 | #include "layer_type_enum.h" 24 | CustomBit = (1 << 8), 25 | }; 26 | } // namespace LayerType 27 | 28 | } // namespace ncnn 29 | 30 | #endif // NCNN_LAYER_TYPE_H 31 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/layer_type_enum.h: -------------------------------------------------------------------------------- 1 | // Layer Type Enum header 2 | // 3 | // This file is auto-generated by cmake, don't edit it. 4 | 5 | AbsVal = 0, 6 | ArgMax = 1, 7 | BatchNorm = 2, 8 | Bias = 3, 9 | BNLL = 4, 10 | Concat = 5, 11 | Convolution = 6, 12 | Crop = 7, 13 | Deconvolution = 8, 14 | Dropout = 9, 15 | Eltwise = 10, 16 | ELU = 11, 17 | Embed = 12, 18 | Exp = 13, 19 | Flatten = 14, 20 | InnerProduct = 15, 21 | Input = 16, 22 | Log = 17, 23 | LRN = 18, 24 | MemoryData = 19, 25 | MVN = 20, 26 | Pooling = 21, 27 | Power = 22, 28 | PReLU = 23, 29 | Proposal = 24, 30 | Reduction = 25, 31 | ReLU = 26, 32 | Reshape = 27, 33 | ROIPooling = 28, 34 | Scale = 29, 35 | Sigmoid = 30, 36 | Slice = 31, 37 | Softmax = 32, 38 | Split = 33, 39 | SPP = 34, 40 | TanH = 35, 41 | Threshold = 36, 42 | Tile = 37, 43 | RNN = 38, 44 | LSTM = 39, 45 | BinaryOp = 40, 46 | UnaryOp = 41, 47 | ConvolutionDepthWise = 42, 48 | Padding = 43, 49 | Squeeze = 44, 50 | ExpandDims = 45, 51 | Normalize = 46, 52 | Permute = 47, 53 | PriorBox = 48, 54 | DetectionOutput = 49, 55 | Interp = 50, 56 | DeconvolutionDepthWise = 51, 57 | ShuffleChannel = 52, 58 | InstanceNorm = 53, 59 | Clip = 54, 60 | Reorg = 55, 61 | YoloDetectionOutput = 56, 62 | Quantize = 57, 63 | Dequantize = 58, 64 | Yolov3DetectionOutput = 59, 65 | PSROIPooling = 60, 66 | ROIAlign = 61, 67 | Packing = 62, 68 | Requantize = 63, 69 | Cast = 64, 70 | HardSigmoid = 65, 71 | SELU = 66, 72 | HardSwish = 67, 73 | Noop = 68, 74 | PixelShuffle = 69, 75 | DeepCopy = 70, 76 | Mish = 71, 77 | StatisticsPooling = 72, 78 | Swish = 73, 79 | Gemm = 74, 80 | GroupNorm = 75, 81 | LayerNorm = 76, 82 | Softplus = 77, 83 | GRU = 78, 84 | MultiHeadAttention = 79, 85 | GELU = 80, 86 | Convolution1D = 81, 87 | Pooling1D = 82, 88 | ConvolutionDepthWise1D = 83, 89 | Convolution3D = 84, 90 | ConvolutionDepthWise3D = 85, 91 | Pooling3D = 86, 92 | MatMul = 87, 93 | Deconvolution1D = 88, 94 | DeconvolutionDepthWise1D = 89, 95 | Deconvolution3D = 90, 96 | DeconvolutionDepthWise3D = 91, 97 | Einsum = 92, 98 | DeformableConv2D = 93, 99 | GLU = 94, 100 | Fold = 95, 101 | Unfold = 96, 102 | GridSample = 97, 103 | 104 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/modelbin.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_MODELBIN_H 16 | #define NCNN_MODELBIN_H 17 | 18 | #include "mat.h" 19 | 20 | namespace ncnn { 21 | 22 | class DataReader; 23 | class NCNN_EXPORT ModelBin 24 | { 25 | public: 26 | ModelBin(); 27 | virtual ~ModelBin(); 28 | // element type 29 | // 0 = auto 30 | // 1 = float32 31 | // 2 = float16 32 | // 3 = int8 33 | // load vec 34 | virtual Mat load(int w, int type) const = 0; 35 | // load image 36 | virtual Mat load(int w, int h, int type) const; 37 | // load dim 38 | virtual Mat load(int w, int h, int c, int type) const; 39 | // load cube 40 | virtual Mat load(int w, int h, int d, int c, int type) const; 41 | }; 42 | 43 | class ModelBinFromDataReaderPrivate; 44 | class NCNN_EXPORT ModelBinFromDataReader : public ModelBin 45 | { 46 | public: 47 | explicit ModelBinFromDataReader(const DataReader& dr); 48 | virtual ~ModelBinFromDataReader(); 49 | 50 | virtual Mat load(int w, int type) const; 51 | 52 | private: 53 | ModelBinFromDataReader(const ModelBinFromDataReader&); 54 | ModelBinFromDataReader& operator=(const ModelBinFromDataReader&); 55 | 56 | private: 57 | ModelBinFromDataReaderPrivate* const d; 58 | }; 59 | 60 | class ModelBinFromMatArrayPrivate; 61 | class NCNN_EXPORT ModelBinFromMatArray : public ModelBin 62 | { 63 | public: 64 | // construct from weight blob array 65 | explicit ModelBinFromMatArray(const Mat* weights); 66 | virtual ~ModelBinFromMatArray(); 67 | 68 | virtual Mat load(int w, int type) const; 69 | 70 | private: 71 | ModelBinFromMatArray(const ModelBinFromMatArray&); 72 | ModelBinFromMatArray& operator=(const ModelBinFromMatArray&); 73 | 74 | private: 75 | ModelBinFromMatArrayPrivate* const d; 76 | }; 77 | 78 | } // namespace ncnn 79 | 80 | #endif // NCNN_MODELBIN_H 81 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/ncnn_export.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef NCNN_EXPORT_H 3 | #define NCNN_EXPORT_H 4 | 5 | #ifdef NCNN_STATIC_DEFINE 6 | # define NCNN_EXPORT 7 | # define NCNN_NO_EXPORT 8 | #else 9 | # ifndef NCNN_EXPORT 10 | # ifdef ncnn_EXPORTS 11 | /* We are building this library */ 12 | # define NCNN_EXPORT 13 | # else 14 | /* We are using this library */ 15 | # define NCNN_EXPORT 16 | # endif 17 | # endif 18 | 19 | # ifndef NCNN_NO_EXPORT 20 | # define NCNN_NO_EXPORT 21 | # endif 22 | #endif 23 | 24 | #ifndef NCNN_DEPRECATED 25 | # define NCNN_DEPRECATED __attribute__ ((__deprecated__)) 26 | #endif 27 | 28 | #ifndef NCNN_DEPRECATED_EXPORT 29 | # define NCNN_DEPRECATED_EXPORT NCNN_EXPORT NCNN_DEPRECATED 30 | #endif 31 | 32 | #ifndef NCNN_DEPRECATED_NO_EXPORT 33 | # define NCNN_DEPRECATED_NO_EXPORT NCNN_NO_EXPORT NCNN_DEPRECATED 34 | #endif 35 | 36 | #if 0 /* DEFINE_NO_DEPRECATED */ 37 | # ifndef NCNN_NO_DEPRECATED 38 | # define NCNN_NO_DEPRECATED 39 | # endif 40 | #endif 41 | 42 | #endif /* NCNN_EXPORT_H */ 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/paramdict.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_PARAMDICT_H 16 | #define NCNN_PARAMDICT_H 17 | 18 | #include "mat.h" 19 | 20 | // at most 32 parameters 21 | #define NCNN_MAX_PARAM_COUNT 32 22 | 23 | namespace ncnn { 24 | 25 | class DataReader; 26 | class Net; 27 | class ParamDictPrivate; 28 | class NCNN_EXPORT ParamDict 29 | { 30 | public: 31 | // empty 32 | ParamDict(); 33 | 34 | virtual ~ParamDict(); 35 | 36 | // copy 37 | ParamDict(const ParamDict&); 38 | 39 | // assign 40 | ParamDict& operator=(const ParamDict&); 41 | 42 | // get type 43 | int type(int id) const; 44 | 45 | // get int 46 | int get(int id, int def) const; 47 | // get float 48 | float get(int id, float def) const; 49 | // get array 50 | Mat get(int id, const Mat& def) const; 51 | 52 | // set int 53 | void set(int id, int i); 54 | // set float 55 | void set(int id, float f); 56 | // set array 57 | void set(int id, const Mat& v); 58 | 59 | protected: 60 | friend class Net; 61 | 62 | void clear(); 63 | 64 | int load_param(const DataReader& dr); 65 | int load_param_bin(const DataReader& dr); 66 | 67 | private: 68 | ParamDictPrivate* const d; 69 | }; 70 | 71 | } // namespace ncnn 72 | 73 | #endif // NCNN_PARAMDICT_H 74 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/include/ncnn/simpleomp.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_SIMPLEOMP_H 16 | #define NCNN_SIMPLEOMP_H 17 | 18 | #include "platform.h" 19 | 20 | #if NCNN_SIMPLEOMP 21 | 22 | #include 23 | 24 | // This minimal openmp runtime implementation only supports the llvm openmp abi 25 | // and only supports #pragma omp parallel for num_threads(X) 26 | 27 | #ifdef __cplusplus 28 | extern "C" { 29 | #endif 30 | 31 | NCNN_EXPORT int omp_get_max_threads(); 32 | 33 | NCNN_EXPORT void omp_set_num_threads(int num_threads); 34 | 35 | NCNN_EXPORT int omp_get_dynamic(); 36 | 37 | NCNN_EXPORT void omp_set_dynamic(int dynamic); 38 | 39 | NCNN_EXPORT int omp_get_num_threads(); 40 | 41 | NCNN_EXPORT int omp_get_thread_num(); 42 | 43 | NCNN_EXPORT int kmp_get_blocktime(); 44 | 45 | NCNN_EXPORT void kmp_set_blocktime(int blocktime); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif // NCNN_SIMPLEOMP 52 | 53 | #endif // NCNN_SIMPLEOMP_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/OGLCompilerTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OGLCompilerTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OGLCompiler) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OGLCompiler ALIAS glslang::OGLCompiler) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/OSDependentTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OSDependentTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OSDependent) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OSDependent ALIAS glslang::OSDependent) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/SPIRVTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `SPIRVTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::SPIRV) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(SPIRV ALIAS glslang::SPIRV) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/glslang/glslang-config.cmake: -------------------------------------------------------------------------------- 1 | 2 | ####### Expanded from @PACKAGE_INIT@ by configure_package_config_file() ####### 3 | ####### Any changes to this file will be overwritten by the next CMake run #### 4 | ####### The input file was glslang-config.cmake.in ######## 5 | 6 | get_filename_component(PACKAGE_PREFIX_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE) 7 | 8 | macro(set_and_check _var _file) 9 | set(${_var} "${_file}") 10 | if(NOT EXISTS "${_file}") 11 | message(FATAL_ERROR "File or directory ${_file} referenced by variable ${_var} does not exist !") 12 | endif() 13 | endmacro() 14 | 15 | macro(check_required_components _NAME) 16 | foreach(comp ${${_NAME}_FIND_COMPONENTS}) 17 | if(NOT ${_NAME}_${comp}_FOUND) 18 | if(${_NAME}_FIND_REQUIRED_${comp}) 19 | set(${_NAME}_FOUND FALSE) 20 | endif() 21 | endif() 22 | endforeach() 23 | endmacro() 24 | 25 | #################################################################################### 26 | include("${PACKAGE_PREFIX_DIR}/lib/cmake/glslang/glslang-targets.cmake") 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/glslangTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `glslangTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::glslang) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | if(OFF) 9 | add_library(glslang ALIAS glslang::glslang) 10 | else() 11 | add_library(glslang ALIAS glslang::glslang) 12 | add_library(MachineIndependent ALIAS glslang::MachineIndependent) 13 | add_library(GenericCodeGen ALIAS glslang::GenericCodeGen) 14 | endif() 15 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/ncnn/ncnn-release.cmake: -------------------------------------------------------------------------------- 1 | #---------------------------------------------------------------- 2 | # Generated CMake target import file for configuration "Release". 3 | #---------------------------------------------------------------- 4 | 5 | # Commands may need to know the format version. 6 | set(CMAKE_IMPORT_FILE_VERSION 1) 7 | 8 | # Import target "ncnn" for configuration "Release" 9 | set_property(TARGET ncnn APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE) 10 | set_target_properties(ncnn PROPERTIES 11 | IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE "CXX" 12 | IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/libncnn.a" 13 | ) 14 | 15 | list(APPEND _cmake_import_check_targets ncnn ) 16 | list(APPEND _cmake_import_check_files_for_ncnn "${_IMPORT_PREFIX}/lib/libncnn.a" ) 17 | 18 | # Commands beyond this point should not need to know the version. 19 | set(CMAKE_IMPORT_FILE_VERSION) 20 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/cmake/ncnn/ncnnConfig.cmake: -------------------------------------------------------------------------------- 1 | set(NCNN_OPENMP ON) 2 | set(NCNN_THREADS ON) 3 | set(NCNN_VULKAN ON) 4 | set(NCNN_SHARED_LIB OFF) 5 | set(NCNN_SYSTEM_GLSLANG OFF) 6 | 7 | if(NCNN_OPENMP) 8 | find_package(OpenMP) 9 | endif() 10 | 11 | if(NCNN_THREADS) 12 | set(CMAKE_THREAD_PREFER_PTHREAD TRUE) 13 | set(THREADS_PREFER_PTHREAD_FLAG TRUE) 14 | find_package(Threads REQUIRED) 15 | endif() 16 | 17 | if(NCNN_VULKAN) 18 | find_package(Vulkan REQUIRED) 19 | 20 | if(NOT NCNN_SHARED_LIB) 21 | if(NCNN_SYSTEM_GLSLANG) 22 | find_package(glslang QUIET) 23 | if(NOT glslang_FOUND) 24 | set(GLSLANG_TARGET_DIR "") 25 | include(${GLSLANG_TARGET_DIR}/OSDependentTargets.cmake) 26 | include(${GLSLANG_TARGET_DIR}/OGLCompilerTargets.cmake) 27 | if(EXISTS "${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 28 | # hlsl support can be optional 29 | include("${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 30 | endif() 31 | include(${GLSLANG_TARGET_DIR}/glslangTargets.cmake) 32 | include(${GLSLANG_TARGET_DIR}/SPIRVTargets.cmake) 33 | endif() 34 | else() 35 | set(glslang_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../lib/cmake/glslang") 36 | find_package(glslang QUIET) 37 | endif() 38 | 39 | endif() 40 | endif() 41 | 42 | include(${CMAKE_CURRENT_LIST_DIR}/ncnn.cmake) 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libGenericCodeGen.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libGenericCodeGen.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libMachineIndependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libMachineIndependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libOGLCompiler.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libOGLCompiler.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libOSDependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libOSDependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libSPIRV.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libSPIRV.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libglslang.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libglslang.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libncnn.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/libncnn.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/arm64-v8a/lib/pkgconfig/ncnn.pc: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | librarydir=${prefix}/lib 3 | includedir=${prefix}/include 4 | 5 | Name: ncnn 6 | Description: high-performance neural network inference framework optimized for the mobile platform 7 | Version: 1.0.20221128 8 | URL: https://github.com/Tencent/ncnn 9 | Libs: -L"${librarydir}" -lncnn 10 | Cflags: -I"${includedir}" 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/glslang/Include/InitializeGlobals.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #ifndef __INITIALIZE_GLOBALS_INCLUDED_ 36 | #define __INITIALIZE_GLOBALS_INCLUDED_ 37 | 38 | namespace glslang { 39 | 40 | bool InitializePoolIndex(); 41 | 42 | } // end namespace glslang 43 | 44 | #endif // __INITIALIZE_GLOBALS_INCLUDED_ 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/glslang/MachineIndependent/RemoveTree.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #pragma once 36 | 37 | namespace glslang { 38 | 39 | void RemoveAllTreeNodes(TIntermNode*); 40 | 41 | } // end namespace glslang 42 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/glslang/Public/resource_limits_c.h: -------------------------------------------------------------------------------- 1 | /** 2 | BSD 2-Clause License 3 | 4 | Copyright (c) 2020, Travis Fort 5 | All rights reserved. 6 | 7 | Redistribution and use in source and binary forms, with or without 8 | modification, are permitted provided that the following conditions are met: 9 | 10 | 1. Redistributions of source code must retain the above copyright notice, this 11 | list of conditions and the following disclaimer. 12 | 13 | 2. Redistributions in binary form must reproduce the above copyright notice, 14 | this list of conditions and the following disclaimer in the documentation 15 | and/or other materials provided with the distribution. 16 | 17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 20 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 21 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 23 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 24 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 26 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | **/ 28 | 29 | #ifndef _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 30 | #define _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 31 | 32 | #include "../Include/glslang_c_interface.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif 37 | 38 | // Returns a struct that can be use to create custom resource values. 39 | glslang_resource_t* glslang_resource(void); 40 | 41 | // These are the default resources for TBuiltInResources, used for both 42 | // - parsing this string for the case where the user didn't supply one, 43 | // - dumping out a template for user construction of a config file. 44 | const glslang_resource_t* glslang_default_resource(void); 45 | 46 | // Returns the DefaultTBuiltInResource as a human-readable string. 47 | // NOTE: User is responsible for freeing this string. 48 | const char* glslang_default_resource_string(); 49 | 50 | // Decodes the resource limits from |config| to |resources|. 51 | void glslang_decode_resource_limits(glslang_resource_t* resources, char* config); 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif 56 | 57 | #endif // _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 58 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/glslang/SPIRV/NonSemanticDebugPrintf.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2020 The Khronos Group Inc. 2 | // 3 | // Permission is hereby granted, free of charge, to any person obtaining a 4 | // copy of this software and/or associated documentation files (the 5 | // "Materials"), to deal in the Materials without restriction, including 6 | // without limitation the rights to use, copy, modify, merge, publish, 7 | // distribute, sublicense, and/or sell copies of the Materials, and to 8 | // permit persons to whom the Materials are furnished to do so, subject to 9 | // the following conditions: 10 | // 11 | // The above copyright notice and this permission notice shall be included 12 | // in all copies or substantial portions of the Materials. 13 | // 14 | // MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS 15 | // KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS 16 | // SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT 17 | // https://www.khronos.org/registry/ 18 | // 19 | // THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 20 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 21 | // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 22 | // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 23 | // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 24 | // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 25 | // MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. 26 | // 27 | 28 | #ifndef SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 29 | #define SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | 35 | enum { 36 | NonSemanticDebugPrintfRevision = 1, 37 | NonSemanticDebugPrintfRevision_BitWidthPadding = 0x7fffffff 38 | }; 39 | 40 | enum NonSemanticDebugPrintfInstructions { 41 | NonSemanticDebugPrintfDebugPrintf = 1, 42 | NonSemanticDebugPrintfInstructionsMax = 0x7fffffff 43 | }; 44 | 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif // SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 51 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/glslang/SPIRV/disassemble.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2014-2015 LunarG, Inc. 3 | // 4 | // All rights reserved. 5 | // 6 | // Redistribution and use in source and binary forms, with or without 7 | // modification, are permitted provided that the following conditions 8 | // are met: 9 | // 10 | // Redistributions of source code must retain the above copyright 11 | // notice, this list of conditions and the following disclaimer. 12 | // 13 | // Redistributions in binary form must reproduce the above 14 | // copyright notice, this list of conditions and the following 15 | // disclaimer in the documentation and/or other materials provided 16 | // with the distribution. 17 | // 18 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 19 | // contributors may be used to endorse or promote products derived 20 | // from this software without specific prior written permission. 21 | // 22 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 23 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 24 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 25 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 26 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 27 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 28 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 29 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 30 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 32 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 33 | // POSSIBILITY OF SUCH DAMAGE. 34 | 35 | // 36 | // Disassembler for SPIR-V. 37 | // 38 | 39 | #pragma once 40 | #ifndef disassembler_H 41 | #define disassembler_H 42 | 43 | #include 44 | #include 45 | 46 | namespace spv { 47 | 48 | // disassemble with glslang custom disassembler 49 | void Disassemble(std::ostream& out, const std::vector&); 50 | 51 | } // end namespace spv 52 | 53 | #endif // disassembler_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/benchmark.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BENCHMARK_H 16 | #define NCNN_BENCHMARK_H 17 | 18 | #include "layer.h" 19 | #include "mat.h" 20 | #include "platform.h" 21 | 22 | namespace ncnn { 23 | 24 | // get now timestamp in ms 25 | NCNN_EXPORT double get_current_time(); 26 | 27 | #if NCNN_BENCHMARK 28 | 29 | NCNN_EXPORT void benchmark(const Layer* layer, double start, double end); 30 | NCNN_EXPORT void benchmark(const Layer* layer, const Mat& bottom_blob, Mat& top_blob, double start, double end); 31 | 32 | #endif // NCNN_BENCHMARK 33 | 34 | } // namespace ncnn 35 | 36 | #endif // NCNN_BENCHMARK_H 37 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/blob.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BLOB_H 16 | #define NCNN_BLOB_H 17 | 18 | #include "mat.h" 19 | #include "platform.h" 20 | 21 | namespace ncnn { 22 | 23 | class NCNN_EXPORT Blob 24 | { 25 | public: 26 | // empty 27 | Blob(); 28 | 29 | public: 30 | #if NCNN_STRING 31 | // blob name 32 | std::string name; 33 | #endif // NCNN_STRING 34 | // layer index which produce this blob as output 35 | int producer; 36 | // layer index which need this blob as input 37 | int consumer; 38 | // shape hint 39 | Mat shape; 40 | }; 41 | 42 | } // namespace ncnn 43 | 44 | #endif // NCNN_BLOB_H 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/layer_shader_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_SHADER_TYPE_H 16 | #define NCNN_LAYER_SHADER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerShaderType { 21 | enum LayerShaderType 22 | { 23 | #include "layer_shader_type_enum.h" 24 | }; 25 | } // namespace LayerShaderType 26 | 27 | } // namespace ncnn 28 | 29 | #endif // NCNN_LAYER_SHADER_TYPE_H 30 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/layer_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_TYPE_H 16 | #define NCNN_LAYER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerType { 21 | enum LayerType 22 | { 23 | #include "layer_type_enum.h" 24 | CustomBit = (1 << 8), 25 | }; 26 | } // namespace LayerType 27 | 28 | } // namespace ncnn 29 | 30 | #endif // NCNN_LAYER_TYPE_H 31 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/layer_type_enum.h: -------------------------------------------------------------------------------- 1 | // Layer Type Enum header 2 | // 3 | // This file is auto-generated by cmake, don't edit it. 4 | 5 | AbsVal = 0, 6 | ArgMax = 1, 7 | BatchNorm = 2, 8 | Bias = 3, 9 | BNLL = 4, 10 | Concat = 5, 11 | Convolution = 6, 12 | Crop = 7, 13 | Deconvolution = 8, 14 | Dropout = 9, 15 | Eltwise = 10, 16 | ELU = 11, 17 | Embed = 12, 18 | Exp = 13, 19 | Flatten = 14, 20 | InnerProduct = 15, 21 | Input = 16, 22 | Log = 17, 23 | LRN = 18, 24 | MemoryData = 19, 25 | MVN = 20, 26 | Pooling = 21, 27 | Power = 22, 28 | PReLU = 23, 29 | Proposal = 24, 30 | Reduction = 25, 31 | ReLU = 26, 32 | Reshape = 27, 33 | ROIPooling = 28, 34 | Scale = 29, 35 | Sigmoid = 30, 36 | Slice = 31, 37 | Softmax = 32, 38 | Split = 33, 39 | SPP = 34, 40 | TanH = 35, 41 | Threshold = 36, 42 | Tile = 37, 43 | RNN = 38, 44 | LSTM = 39, 45 | BinaryOp = 40, 46 | UnaryOp = 41, 47 | ConvolutionDepthWise = 42, 48 | Padding = 43, 49 | Squeeze = 44, 50 | ExpandDims = 45, 51 | Normalize = 46, 52 | Permute = 47, 53 | PriorBox = 48, 54 | DetectionOutput = 49, 55 | Interp = 50, 56 | DeconvolutionDepthWise = 51, 57 | ShuffleChannel = 52, 58 | InstanceNorm = 53, 59 | Clip = 54, 60 | Reorg = 55, 61 | YoloDetectionOutput = 56, 62 | Quantize = 57, 63 | Dequantize = 58, 64 | Yolov3DetectionOutput = 59, 65 | PSROIPooling = 60, 66 | ROIAlign = 61, 67 | Packing = 62, 68 | Requantize = 63, 69 | Cast = 64, 70 | HardSigmoid = 65, 71 | SELU = 66, 72 | HardSwish = 67, 73 | Noop = 68, 74 | PixelShuffle = 69, 75 | DeepCopy = 70, 76 | Mish = 71, 77 | StatisticsPooling = 72, 78 | Swish = 73, 79 | Gemm = 74, 80 | GroupNorm = 75, 81 | LayerNorm = 76, 82 | Softplus = 77, 83 | GRU = 78, 84 | MultiHeadAttention = 79, 85 | GELU = 80, 86 | Convolution1D = 81, 87 | Pooling1D = 82, 88 | ConvolutionDepthWise1D = 83, 89 | Convolution3D = 84, 90 | ConvolutionDepthWise3D = 85, 91 | Pooling3D = 86, 92 | MatMul = 87, 93 | Deconvolution1D = 88, 94 | DeconvolutionDepthWise1D = 89, 95 | Deconvolution3D = 90, 96 | DeconvolutionDepthWise3D = 91, 97 | Einsum = 92, 98 | DeformableConv2D = 93, 99 | GLU = 94, 100 | Fold = 95, 101 | Unfold = 96, 102 | GridSample = 97, 103 | 104 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/ncnn_export.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef NCNN_EXPORT_H 3 | #define NCNN_EXPORT_H 4 | 5 | #ifdef NCNN_STATIC_DEFINE 6 | # define NCNN_EXPORT 7 | # define NCNN_NO_EXPORT 8 | #else 9 | # ifndef NCNN_EXPORT 10 | # ifdef ncnn_EXPORTS 11 | /* We are building this library */ 12 | # define NCNN_EXPORT 13 | # else 14 | /* We are using this library */ 15 | # define NCNN_EXPORT 16 | # endif 17 | # endif 18 | 19 | # ifndef NCNN_NO_EXPORT 20 | # define NCNN_NO_EXPORT 21 | # endif 22 | #endif 23 | 24 | #ifndef NCNN_DEPRECATED 25 | # define NCNN_DEPRECATED __attribute__ ((__deprecated__)) 26 | #endif 27 | 28 | #ifndef NCNN_DEPRECATED_EXPORT 29 | # define NCNN_DEPRECATED_EXPORT NCNN_EXPORT NCNN_DEPRECATED 30 | #endif 31 | 32 | #ifndef NCNN_DEPRECATED_NO_EXPORT 33 | # define NCNN_DEPRECATED_NO_EXPORT NCNN_NO_EXPORT NCNN_DEPRECATED 34 | #endif 35 | 36 | #if 0 /* DEFINE_NO_DEPRECATED */ 37 | # ifndef NCNN_NO_DEPRECATED 38 | # define NCNN_NO_DEPRECATED 39 | # endif 40 | #endif 41 | 42 | #endif /* NCNN_EXPORT_H */ 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/paramdict.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_PARAMDICT_H 16 | #define NCNN_PARAMDICT_H 17 | 18 | #include "mat.h" 19 | 20 | // at most 32 parameters 21 | #define NCNN_MAX_PARAM_COUNT 32 22 | 23 | namespace ncnn { 24 | 25 | class DataReader; 26 | class Net; 27 | class ParamDictPrivate; 28 | class NCNN_EXPORT ParamDict 29 | { 30 | public: 31 | // empty 32 | ParamDict(); 33 | 34 | virtual ~ParamDict(); 35 | 36 | // copy 37 | ParamDict(const ParamDict&); 38 | 39 | // assign 40 | ParamDict& operator=(const ParamDict&); 41 | 42 | // get type 43 | int type(int id) const; 44 | 45 | // get int 46 | int get(int id, int def) const; 47 | // get float 48 | float get(int id, float def) const; 49 | // get array 50 | Mat get(int id, const Mat& def) const; 51 | 52 | // set int 53 | void set(int id, int i); 54 | // set float 55 | void set(int id, float f); 56 | // set array 57 | void set(int id, const Mat& v); 58 | 59 | protected: 60 | friend class Net; 61 | 62 | void clear(); 63 | 64 | int load_param(const DataReader& dr); 65 | int load_param_bin(const DataReader& dr); 66 | 67 | private: 68 | ParamDictPrivate* const d; 69 | }; 70 | 71 | } // namespace ncnn 72 | 73 | #endif // NCNN_PARAMDICT_H 74 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/include/ncnn/simpleomp.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_SIMPLEOMP_H 16 | #define NCNN_SIMPLEOMP_H 17 | 18 | #include "platform.h" 19 | 20 | #if NCNN_SIMPLEOMP 21 | 22 | #include 23 | 24 | // This minimal openmp runtime implementation only supports the llvm openmp abi 25 | // and only supports #pragma omp parallel for num_threads(X) 26 | 27 | #ifdef __cplusplus 28 | extern "C" { 29 | #endif 30 | 31 | NCNN_EXPORT int omp_get_max_threads(); 32 | 33 | NCNN_EXPORT void omp_set_num_threads(int num_threads); 34 | 35 | NCNN_EXPORT int omp_get_dynamic(); 36 | 37 | NCNN_EXPORT void omp_set_dynamic(int dynamic); 38 | 39 | NCNN_EXPORT int omp_get_num_threads(); 40 | 41 | NCNN_EXPORT int omp_get_thread_num(); 42 | 43 | NCNN_EXPORT int kmp_get_blocktime(); 44 | 45 | NCNN_EXPORT void kmp_set_blocktime(int blocktime); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif // NCNN_SIMPLEOMP 52 | 53 | #endif // NCNN_SIMPLEOMP_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/OGLCompilerTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OGLCompilerTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OGLCompiler) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OGLCompiler ALIAS glslang::OGLCompiler) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/OSDependentTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OSDependentTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OSDependent) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OSDependent ALIAS glslang::OSDependent) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/SPIRVTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `SPIRVTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::SPIRV) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(SPIRV ALIAS glslang::SPIRV) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/glslang/glslang-config.cmake: -------------------------------------------------------------------------------- 1 | 2 | ####### Expanded from @PACKAGE_INIT@ by configure_package_config_file() ####### 3 | ####### Any changes to this file will be overwritten by the next CMake run #### 4 | ####### The input file was glslang-config.cmake.in ######## 5 | 6 | get_filename_component(PACKAGE_PREFIX_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE) 7 | 8 | macro(set_and_check _var _file) 9 | set(${_var} "${_file}") 10 | if(NOT EXISTS "${_file}") 11 | message(FATAL_ERROR "File or directory ${_file} referenced by variable ${_var} does not exist !") 12 | endif() 13 | endmacro() 14 | 15 | macro(check_required_components _NAME) 16 | foreach(comp ${${_NAME}_FIND_COMPONENTS}) 17 | if(NOT ${_NAME}_${comp}_FOUND) 18 | if(${_NAME}_FIND_REQUIRED_${comp}) 19 | set(${_NAME}_FOUND FALSE) 20 | endif() 21 | endif() 22 | endforeach() 23 | endmacro() 24 | 25 | #################################################################################### 26 | include("${PACKAGE_PREFIX_DIR}/lib/cmake/glslang/glslang-targets.cmake") 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/glslangTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `glslangTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::glslang) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | if(OFF) 9 | add_library(glslang ALIAS glslang::glslang) 10 | else() 11 | add_library(glslang ALIAS glslang::glslang) 12 | add_library(MachineIndependent ALIAS glslang::MachineIndependent) 13 | add_library(GenericCodeGen ALIAS glslang::GenericCodeGen) 14 | endif() 15 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/ncnn/ncnn-release.cmake: -------------------------------------------------------------------------------- 1 | #---------------------------------------------------------------- 2 | # Generated CMake target import file for configuration "Release". 3 | #---------------------------------------------------------------- 4 | 5 | # Commands may need to know the format version. 6 | set(CMAKE_IMPORT_FILE_VERSION 1) 7 | 8 | # Import target "ncnn" for configuration "Release" 9 | set_property(TARGET ncnn APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE) 10 | set_target_properties(ncnn PROPERTIES 11 | IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE "CXX" 12 | IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/libncnn.a" 13 | ) 14 | 15 | list(APPEND _cmake_import_check_targets ncnn ) 16 | list(APPEND _cmake_import_check_files_for_ncnn "${_IMPORT_PREFIX}/lib/libncnn.a" ) 17 | 18 | # Commands beyond this point should not need to know the version. 19 | set(CMAKE_IMPORT_FILE_VERSION) 20 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/cmake/ncnn/ncnnConfig.cmake: -------------------------------------------------------------------------------- 1 | set(NCNN_OPENMP ON) 2 | set(NCNN_THREADS ON) 3 | set(NCNN_VULKAN ON) 4 | set(NCNN_SHARED_LIB OFF) 5 | set(NCNN_SYSTEM_GLSLANG OFF) 6 | 7 | if(NCNN_OPENMP) 8 | find_package(OpenMP) 9 | endif() 10 | 11 | if(NCNN_THREADS) 12 | set(CMAKE_THREAD_PREFER_PTHREAD TRUE) 13 | set(THREADS_PREFER_PTHREAD_FLAG TRUE) 14 | find_package(Threads REQUIRED) 15 | endif() 16 | 17 | if(NCNN_VULKAN) 18 | find_package(Vulkan REQUIRED) 19 | 20 | if(NOT NCNN_SHARED_LIB) 21 | if(NCNN_SYSTEM_GLSLANG) 22 | find_package(glslang QUIET) 23 | if(NOT glslang_FOUND) 24 | set(GLSLANG_TARGET_DIR "") 25 | include(${GLSLANG_TARGET_DIR}/OSDependentTargets.cmake) 26 | include(${GLSLANG_TARGET_DIR}/OGLCompilerTargets.cmake) 27 | if(EXISTS "${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 28 | # hlsl support can be optional 29 | include("${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 30 | endif() 31 | include(${GLSLANG_TARGET_DIR}/glslangTargets.cmake) 32 | include(${GLSLANG_TARGET_DIR}/SPIRVTargets.cmake) 33 | endif() 34 | else() 35 | set(glslang_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../lib/cmake/glslang") 36 | find_package(glslang QUIET) 37 | endif() 38 | 39 | endif() 40 | endif() 41 | 42 | include(${CMAKE_CURRENT_LIST_DIR}/ncnn.cmake) 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libGenericCodeGen.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libGenericCodeGen.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libMachineIndependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libMachineIndependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libOGLCompiler.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libOGLCompiler.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libOSDependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libOSDependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libSPIRV.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libSPIRV.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libglslang.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libglslang.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libncnn.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/libncnn.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/armeabi-v7a/lib/pkgconfig/ncnn.pc: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | librarydir=${prefix}/lib 3 | includedir=${prefix}/include 4 | 5 | Name: ncnn 6 | Description: high-performance neural network inference framework optimized for the mobile platform 7 | Version: 1.0.20221128 8 | URL: https://github.com/Tencent/ncnn 9 | Libs: -L"${librarydir}" -lncnn 10 | Cflags: -I"${includedir}" 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/glslang/Include/InitializeGlobals.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #ifndef __INITIALIZE_GLOBALS_INCLUDED_ 36 | #define __INITIALIZE_GLOBALS_INCLUDED_ 37 | 38 | namespace glslang { 39 | 40 | bool InitializePoolIndex(); 41 | 42 | } // end namespace glslang 43 | 44 | #endif // __INITIALIZE_GLOBALS_INCLUDED_ 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/glslang/MachineIndependent/RemoveTree.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #pragma once 36 | 37 | namespace glslang { 38 | 39 | void RemoveAllTreeNodes(TIntermNode*); 40 | 41 | } // end namespace glslang 42 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/glslang/Public/resource_limits_c.h: -------------------------------------------------------------------------------- 1 | /** 2 | BSD 2-Clause License 3 | 4 | Copyright (c) 2020, Travis Fort 5 | All rights reserved. 6 | 7 | Redistribution and use in source and binary forms, with or without 8 | modification, are permitted provided that the following conditions are met: 9 | 10 | 1. Redistributions of source code must retain the above copyright notice, this 11 | list of conditions and the following disclaimer. 12 | 13 | 2. Redistributions in binary form must reproduce the above copyright notice, 14 | this list of conditions and the following disclaimer in the documentation 15 | and/or other materials provided with the distribution. 16 | 17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 20 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 21 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 23 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 24 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 26 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | **/ 28 | 29 | #ifndef _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 30 | #define _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 31 | 32 | #include "../Include/glslang_c_interface.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif 37 | 38 | // Returns a struct that can be use to create custom resource values. 39 | glslang_resource_t* glslang_resource(void); 40 | 41 | // These are the default resources for TBuiltInResources, used for both 42 | // - parsing this string for the case where the user didn't supply one, 43 | // - dumping out a template for user construction of a config file. 44 | const glslang_resource_t* glslang_default_resource(void); 45 | 46 | // Returns the DefaultTBuiltInResource as a human-readable string. 47 | // NOTE: User is responsible for freeing this string. 48 | const char* glslang_default_resource_string(); 49 | 50 | // Decodes the resource limits from |config| to |resources|. 51 | void glslang_decode_resource_limits(glslang_resource_t* resources, char* config); 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif 56 | 57 | #endif // _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 58 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/glslang/SPIRV/NonSemanticDebugPrintf.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2020 The Khronos Group Inc. 2 | // 3 | // Permission is hereby granted, free of charge, to any person obtaining a 4 | // copy of this software and/or associated documentation files (the 5 | // "Materials"), to deal in the Materials without restriction, including 6 | // without limitation the rights to use, copy, modify, merge, publish, 7 | // distribute, sublicense, and/or sell copies of the Materials, and to 8 | // permit persons to whom the Materials are furnished to do so, subject to 9 | // the following conditions: 10 | // 11 | // The above copyright notice and this permission notice shall be included 12 | // in all copies or substantial portions of the Materials. 13 | // 14 | // MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS 15 | // KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS 16 | // SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT 17 | // https://www.khronos.org/registry/ 18 | // 19 | // THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 20 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 21 | // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 22 | // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 23 | // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 24 | // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 25 | // MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. 26 | // 27 | 28 | #ifndef SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 29 | #define SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | 35 | enum { 36 | NonSemanticDebugPrintfRevision = 1, 37 | NonSemanticDebugPrintfRevision_BitWidthPadding = 0x7fffffff 38 | }; 39 | 40 | enum NonSemanticDebugPrintfInstructions { 41 | NonSemanticDebugPrintfDebugPrintf = 1, 42 | NonSemanticDebugPrintfInstructionsMax = 0x7fffffff 43 | }; 44 | 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif // SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 51 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/glslang/SPIRV/disassemble.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2014-2015 LunarG, Inc. 3 | // 4 | // All rights reserved. 5 | // 6 | // Redistribution and use in source and binary forms, with or without 7 | // modification, are permitted provided that the following conditions 8 | // are met: 9 | // 10 | // Redistributions of source code must retain the above copyright 11 | // notice, this list of conditions and the following disclaimer. 12 | // 13 | // Redistributions in binary form must reproduce the above 14 | // copyright notice, this list of conditions and the following 15 | // disclaimer in the documentation and/or other materials provided 16 | // with the distribution. 17 | // 18 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 19 | // contributors may be used to endorse or promote products derived 20 | // from this software without specific prior written permission. 21 | // 22 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 23 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 24 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 25 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 26 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 27 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 28 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 29 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 30 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 32 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 33 | // POSSIBILITY OF SUCH DAMAGE. 34 | 35 | // 36 | // Disassembler for SPIR-V. 37 | // 38 | 39 | #pragma once 40 | #ifndef disassembler_H 41 | #define disassembler_H 42 | 43 | #include 44 | #include 45 | 46 | namespace spv { 47 | 48 | // disassemble with glslang custom disassembler 49 | void Disassemble(std::ostream& out, const std::vector&); 50 | 51 | } // end namespace spv 52 | 53 | #endif // disassembler_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/benchmark.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BENCHMARK_H 16 | #define NCNN_BENCHMARK_H 17 | 18 | #include "layer.h" 19 | #include "mat.h" 20 | #include "platform.h" 21 | 22 | namespace ncnn { 23 | 24 | // get now timestamp in ms 25 | NCNN_EXPORT double get_current_time(); 26 | 27 | #if NCNN_BENCHMARK 28 | 29 | NCNN_EXPORT void benchmark(const Layer* layer, double start, double end); 30 | NCNN_EXPORT void benchmark(const Layer* layer, const Mat& bottom_blob, Mat& top_blob, double start, double end); 31 | 32 | #endif // NCNN_BENCHMARK 33 | 34 | } // namespace ncnn 35 | 36 | #endif // NCNN_BENCHMARK_H 37 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/blob.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BLOB_H 16 | #define NCNN_BLOB_H 17 | 18 | #include "mat.h" 19 | #include "platform.h" 20 | 21 | namespace ncnn { 22 | 23 | class NCNN_EXPORT Blob 24 | { 25 | public: 26 | // empty 27 | Blob(); 28 | 29 | public: 30 | #if NCNN_STRING 31 | // blob name 32 | std::string name; 33 | #endif // NCNN_STRING 34 | // layer index which produce this blob as output 35 | int producer; 36 | // layer index which need this blob as input 37 | int consumer; 38 | // shape hint 39 | Mat shape; 40 | }; 41 | 42 | } // namespace ncnn 43 | 44 | #endif // NCNN_BLOB_H 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/layer_shader_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_SHADER_TYPE_H 16 | #define NCNN_LAYER_SHADER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerShaderType { 21 | enum LayerShaderType 22 | { 23 | #include "layer_shader_type_enum.h" 24 | }; 25 | } // namespace LayerShaderType 26 | 27 | } // namespace ncnn 28 | 29 | #endif // NCNN_LAYER_SHADER_TYPE_H 30 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/layer_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_TYPE_H 16 | #define NCNN_LAYER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerType { 21 | enum LayerType 22 | { 23 | #include "layer_type_enum.h" 24 | CustomBit = (1 << 8), 25 | }; 26 | } // namespace LayerType 27 | 28 | } // namespace ncnn 29 | 30 | #endif // NCNN_LAYER_TYPE_H 31 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/layer_type_enum.h: -------------------------------------------------------------------------------- 1 | // Layer Type Enum header 2 | // 3 | // This file is auto-generated by cmake, don't edit it. 4 | 5 | AbsVal = 0, 6 | ArgMax = 1, 7 | BatchNorm = 2, 8 | Bias = 3, 9 | BNLL = 4, 10 | Concat = 5, 11 | Convolution = 6, 12 | Crop = 7, 13 | Deconvolution = 8, 14 | Dropout = 9, 15 | Eltwise = 10, 16 | ELU = 11, 17 | Embed = 12, 18 | Exp = 13, 19 | Flatten = 14, 20 | InnerProduct = 15, 21 | Input = 16, 22 | Log = 17, 23 | LRN = 18, 24 | MemoryData = 19, 25 | MVN = 20, 26 | Pooling = 21, 27 | Power = 22, 28 | PReLU = 23, 29 | Proposal = 24, 30 | Reduction = 25, 31 | ReLU = 26, 32 | Reshape = 27, 33 | ROIPooling = 28, 34 | Scale = 29, 35 | Sigmoid = 30, 36 | Slice = 31, 37 | Softmax = 32, 38 | Split = 33, 39 | SPP = 34, 40 | TanH = 35, 41 | Threshold = 36, 42 | Tile = 37, 43 | RNN = 38, 44 | LSTM = 39, 45 | BinaryOp = 40, 46 | UnaryOp = 41, 47 | ConvolutionDepthWise = 42, 48 | Padding = 43, 49 | Squeeze = 44, 50 | ExpandDims = 45, 51 | Normalize = 46, 52 | Permute = 47, 53 | PriorBox = 48, 54 | DetectionOutput = 49, 55 | Interp = 50, 56 | DeconvolutionDepthWise = 51, 57 | ShuffleChannel = 52, 58 | InstanceNorm = 53, 59 | Clip = 54, 60 | Reorg = 55, 61 | YoloDetectionOutput = 56, 62 | Quantize = 57, 63 | Dequantize = 58, 64 | Yolov3DetectionOutput = 59, 65 | PSROIPooling = 60, 66 | ROIAlign = 61, 67 | Packing = 62, 68 | Requantize = 63, 69 | Cast = 64, 70 | HardSigmoid = 65, 71 | SELU = 66, 72 | HardSwish = 67, 73 | Noop = 68, 74 | PixelShuffle = 69, 75 | DeepCopy = 70, 76 | Mish = 71, 77 | StatisticsPooling = 72, 78 | Swish = 73, 79 | Gemm = 74, 80 | GroupNorm = 75, 81 | LayerNorm = 76, 82 | Softplus = 77, 83 | GRU = 78, 84 | MultiHeadAttention = 79, 85 | GELU = 80, 86 | Convolution1D = 81, 87 | Pooling1D = 82, 88 | ConvolutionDepthWise1D = 83, 89 | Convolution3D = 84, 90 | ConvolutionDepthWise3D = 85, 91 | Pooling3D = 86, 92 | MatMul = 87, 93 | Deconvolution1D = 88, 94 | DeconvolutionDepthWise1D = 89, 95 | Deconvolution3D = 90, 96 | DeconvolutionDepthWise3D = 91, 97 | Einsum = 92, 98 | DeformableConv2D = 93, 99 | GLU = 94, 100 | Fold = 95, 101 | Unfold = 96, 102 | GridSample = 97, 103 | 104 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/modelbin.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_MODELBIN_H 16 | #define NCNN_MODELBIN_H 17 | 18 | #include "mat.h" 19 | 20 | namespace ncnn { 21 | 22 | class DataReader; 23 | class NCNN_EXPORT ModelBin 24 | { 25 | public: 26 | ModelBin(); 27 | virtual ~ModelBin(); 28 | // element type 29 | // 0 = auto 30 | // 1 = float32 31 | // 2 = float16 32 | // 3 = int8 33 | // load vec 34 | virtual Mat load(int w, int type) const = 0; 35 | // load image 36 | virtual Mat load(int w, int h, int type) const; 37 | // load dim 38 | virtual Mat load(int w, int h, int c, int type) const; 39 | // load cube 40 | virtual Mat load(int w, int h, int d, int c, int type) const; 41 | }; 42 | 43 | class ModelBinFromDataReaderPrivate; 44 | class NCNN_EXPORT ModelBinFromDataReader : public ModelBin 45 | { 46 | public: 47 | explicit ModelBinFromDataReader(const DataReader& dr); 48 | virtual ~ModelBinFromDataReader(); 49 | 50 | virtual Mat load(int w, int type) const; 51 | 52 | private: 53 | ModelBinFromDataReader(const ModelBinFromDataReader&); 54 | ModelBinFromDataReader& operator=(const ModelBinFromDataReader&); 55 | 56 | private: 57 | ModelBinFromDataReaderPrivate* const d; 58 | }; 59 | 60 | class ModelBinFromMatArrayPrivate; 61 | class NCNN_EXPORT ModelBinFromMatArray : public ModelBin 62 | { 63 | public: 64 | // construct from weight blob array 65 | explicit ModelBinFromMatArray(const Mat* weights); 66 | virtual ~ModelBinFromMatArray(); 67 | 68 | virtual Mat load(int w, int type) const; 69 | 70 | private: 71 | ModelBinFromMatArray(const ModelBinFromMatArray&); 72 | ModelBinFromMatArray& operator=(const ModelBinFromMatArray&); 73 | 74 | private: 75 | ModelBinFromMatArrayPrivate* const d; 76 | }; 77 | 78 | } // namespace ncnn 79 | 80 | #endif // NCNN_MODELBIN_H 81 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/ncnn_export.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef NCNN_EXPORT_H 3 | #define NCNN_EXPORT_H 4 | 5 | #ifdef NCNN_STATIC_DEFINE 6 | # define NCNN_EXPORT 7 | # define NCNN_NO_EXPORT 8 | #else 9 | # ifndef NCNN_EXPORT 10 | # ifdef ncnn_EXPORTS 11 | /* We are building this library */ 12 | # define NCNN_EXPORT 13 | # else 14 | /* We are using this library */ 15 | # define NCNN_EXPORT 16 | # endif 17 | # endif 18 | 19 | # ifndef NCNN_NO_EXPORT 20 | # define NCNN_NO_EXPORT 21 | # endif 22 | #endif 23 | 24 | #ifndef NCNN_DEPRECATED 25 | # define NCNN_DEPRECATED __attribute__ ((__deprecated__)) 26 | #endif 27 | 28 | #ifndef NCNN_DEPRECATED_EXPORT 29 | # define NCNN_DEPRECATED_EXPORT NCNN_EXPORT NCNN_DEPRECATED 30 | #endif 31 | 32 | #ifndef NCNN_DEPRECATED_NO_EXPORT 33 | # define NCNN_DEPRECATED_NO_EXPORT NCNN_NO_EXPORT NCNN_DEPRECATED 34 | #endif 35 | 36 | #if 0 /* DEFINE_NO_DEPRECATED */ 37 | # ifndef NCNN_NO_DEPRECATED 38 | # define NCNN_NO_DEPRECATED 39 | # endif 40 | #endif 41 | 42 | #endif /* NCNN_EXPORT_H */ 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/paramdict.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_PARAMDICT_H 16 | #define NCNN_PARAMDICT_H 17 | 18 | #include "mat.h" 19 | 20 | // at most 32 parameters 21 | #define NCNN_MAX_PARAM_COUNT 32 22 | 23 | namespace ncnn { 24 | 25 | class DataReader; 26 | class Net; 27 | class ParamDictPrivate; 28 | class NCNN_EXPORT ParamDict 29 | { 30 | public: 31 | // empty 32 | ParamDict(); 33 | 34 | virtual ~ParamDict(); 35 | 36 | // copy 37 | ParamDict(const ParamDict&); 38 | 39 | // assign 40 | ParamDict& operator=(const ParamDict&); 41 | 42 | // get type 43 | int type(int id) const; 44 | 45 | // get int 46 | int get(int id, int def) const; 47 | // get float 48 | float get(int id, float def) const; 49 | // get array 50 | Mat get(int id, const Mat& def) const; 51 | 52 | // set int 53 | void set(int id, int i); 54 | // set float 55 | void set(int id, float f); 56 | // set array 57 | void set(int id, const Mat& v); 58 | 59 | protected: 60 | friend class Net; 61 | 62 | void clear(); 63 | 64 | int load_param(const DataReader& dr); 65 | int load_param_bin(const DataReader& dr); 66 | 67 | private: 68 | ParamDictPrivate* const d; 69 | }; 70 | 71 | } // namespace ncnn 72 | 73 | #endif // NCNN_PARAMDICT_H 74 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/include/ncnn/simpleomp.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_SIMPLEOMP_H 16 | #define NCNN_SIMPLEOMP_H 17 | 18 | #include "platform.h" 19 | 20 | #if NCNN_SIMPLEOMP 21 | 22 | #include 23 | 24 | // This minimal openmp runtime implementation only supports the llvm openmp abi 25 | // and only supports #pragma omp parallel for num_threads(X) 26 | 27 | #ifdef __cplusplus 28 | extern "C" { 29 | #endif 30 | 31 | NCNN_EXPORT int omp_get_max_threads(); 32 | 33 | NCNN_EXPORT void omp_set_num_threads(int num_threads); 34 | 35 | NCNN_EXPORT int omp_get_dynamic(); 36 | 37 | NCNN_EXPORT void omp_set_dynamic(int dynamic); 38 | 39 | NCNN_EXPORT int omp_get_num_threads(); 40 | 41 | NCNN_EXPORT int omp_get_thread_num(); 42 | 43 | NCNN_EXPORT int kmp_get_blocktime(); 44 | 45 | NCNN_EXPORT void kmp_set_blocktime(int blocktime); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif // NCNN_SIMPLEOMP 52 | 53 | #endif // NCNN_SIMPLEOMP_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/OGLCompilerTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OGLCompilerTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OGLCompiler) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OGLCompiler ALIAS glslang::OGLCompiler) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/OSDependentTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OSDependentTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OSDependent) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OSDependent ALIAS glslang::OSDependent) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/SPIRVTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `SPIRVTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::SPIRV) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(SPIRV ALIAS glslang::SPIRV) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/glslang/glslang-config.cmake: -------------------------------------------------------------------------------- 1 | 2 | ####### Expanded from @PACKAGE_INIT@ by configure_package_config_file() ####### 3 | ####### Any changes to this file will be overwritten by the next CMake run #### 4 | ####### The input file was glslang-config.cmake.in ######## 5 | 6 | get_filename_component(PACKAGE_PREFIX_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE) 7 | 8 | macro(set_and_check _var _file) 9 | set(${_var} "${_file}") 10 | if(NOT EXISTS "${_file}") 11 | message(FATAL_ERROR "File or directory ${_file} referenced by variable ${_var} does not exist !") 12 | endif() 13 | endmacro() 14 | 15 | macro(check_required_components _NAME) 16 | foreach(comp ${${_NAME}_FIND_COMPONENTS}) 17 | if(NOT ${_NAME}_${comp}_FOUND) 18 | if(${_NAME}_FIND_REQUIRED_${comp}) 19 | set(${_NAME}_FOUND FALSE) 20 | endif() 21 | endif() 22 | endforeach() 23 | endmacro() 24 | 25 | #################################################################################### 26 | include("${PACKAGE_PREFIX_DIR}/lib/cmake/glslang/glslang-targets.cmake") 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/glslangTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `glslangTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::glslang) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | if(OFF) 9 | add_library(glslang ALIAS glslang::glslang) 10 | else() 11 | add_library(glslang ALIAS glslang::glslang) 12 | add_library(MachineIndependent ALIAS glslang::MachineIndependent) 13 | add_library(GenericCodeGen ALIAS glslang::GenericCodeGen) 14 | endif() 15 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/ncnn/ncnn-release.cmake: -------------------------------------------------------------------------------- 1 | #---------------------------------------------------------------- 2 | # Generated CMake target import file for configuration "Release". 3 | #---------------------------------------------------------------- 4 | 5 | # Commands may need to know the format version. 6 | set(CMAKE_IMPORT_FILE_VERSION 1) 7 | 8 | # Import target "ncnn" for configuration "Release" 9 | set_property(TARGET ncnn APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE) 10 | set_target_properties(ncnn PROPERTIES 11 | IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE "CXX" 12 | IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/libncnn.a" 13 | ) 14 | 15 | list(APPEND _cmake_import_check_targets ncnn ) 16 | list(APPEND _cmake_import_check_files_for_ncnn "${_IMPORT_PREFIX}/lib/libncnn.a" ) 17 | 18 | # Commands beyond this point should not need to know the version. 19 | set(CMAKE_IMPORT_FILE_VERSION) 20 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/cmake/ncnn/ncnnConfig.cmake: -------------------------------------------------------------------------------- 1 | set(NCNN_OPENMP ON) 2 | set(NCNN_THREADS ON) 3 | set(NCNN_VULKAN ON) 4 | set(NCNN_SHARED_LIB OFF) 5 | set(NCNN_SYSTEM_GLSLANG OFF) 6 | 7 | if(NCNN_OPENMP) 8 | find_package(OpenMP) 9 | endif() 10 | 11 | if(NCNN_THREADS) 12 | set(CMAKE_THREAD_PREFER_PTHREAD TRUE) 13 | set(THREADS_PREFER_PTHREAD_FLAG TRUE) 14 | find_package(Threads REQUIRED) 15 | endif() 16 | 17 | if(NCNN_VULKAN) 18 | find_package(Vulkan REQUIRED) 19 | 20 | if(NOT NCNN_SHARED_LIB) 21 | if(NCNN_SYSTEM_GLSLANG) 22 | find_package(glslang QUIET) 23 | if(NOT glslang_FOUND) 24 | set(GLSLANG_TARGET_DIR "") 25 | include(${GLSLANG_TARGET_DIR}/OSDependentTargets.cmake) 26 | include(${GLSLANG_TARGET_DIR}/OGLCompilerTargets.cmake) 27 | if(EXISTS "${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 28 | # hlsl support can be optional 29 | include("${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 30 | endif() 31 | include(${GLSLANG_TARGET_DIR}/glslangTargets.cmake) 32 | include(${GLSLANG_TARGET_DIR}/SPIRVTargets.cmake) 33 | endif() 34 | else() 35 | set(glslang_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../lib/cmake/glslang") 36 | find_package(glslang QUIET) 37 | endif() 38 | 39 | endif() 40 | endif() 41 | 42 | include(${CMAKE_CURRENT_LIST_DIR}/ncnn.cmake) 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libGenericCodeGen.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libGenericCodeGen.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libMachineIndependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libMachineIndependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libOGLCompiler.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libOGLCompiler.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libOSDependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libOSDependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libSPIRV.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libSPIRV.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libglslang.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libglslang.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libncnn.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/libncnn.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86/lib/pkgconfig/ncnn.pc: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | librarydir=${prefix}/lib 3 | includedir=${prefix}/include 4 | 5 | Name: ncnn 6 | Description: high-performance neural network inference framework optimized for the mobile platform 7 | Version: 1.0.20221128 8 | URL: https://github.com/Tencent/ncnn 9 | Libs: -L"${librarydir}" -lncnn 10 | Cflags: -I"${includedir}" 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/glslang/Include/InitializeGlobals.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #ifndef __INITIALIZE_GLOBALS_INCLUDED_ 36 | #define __INITIALIZE_GLOBALS_INCLUDED_ 37 | 38 | namespace glslang { 39 | 40 | bool InitializePoolIndex(); 41 | 42 | } // end namespace glslang 43 | 44 | #endif // __INITIALIZE_GLOBALS_INCLUDED_ 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/glslang/MachineIndependent/RemoveTree.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2002-2005 3Dlabs Inc. Ltd. 3 | // All rights reserved. 4 | // 5 | // Redistribution and use in source and binary forms, with or without 6 | // modification, are permitted provided that the following conditions 7 | // are met: 8 | // 9 | // Redistributions of source code must retain the above copyright 10 | // notice, this list of conditions and the following disclaimer. 11 | // 12 | // Redistributions in binary form must reproduce the above 13 | // copyright notice, this list of conditions and the following 14 | // disclaimer in the documentation and/or other materials provided 15 | // with the distribution. 16 | // 17 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 18 | // contributors may be used to endorse or promote products derived 19 | // from this software without specific prior written permission. 20 | // 21 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 22 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 23 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 24 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 25 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 26 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 27 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 28 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 29 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 30 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 31 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 32 | // POSSIBILITY OF SUCH DAMAGE. 33 | // 34 | 35 | #pragma once 36 | 37 | namespace glslang { 38 | 39 | void RemoveAllTreeNodes(TIntermNode*); 40 | 41 | } // end namespace glslang 42 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/glslang/Public/resource_limits_c.h: -------------------------------------------------------------------------------- 1 | /** 2 | BSD 2-Clause License 3 | 4 | Copyright (c) 2020, Travis Fort 5 | All rights reserved. 6 | 7 | Redistribution and use in source and binary forms, with or without 8 | modification, are permitted provided that the following conditions are met: 9 | 10 | 1. Redistributions of source code must retain the above copyright notice, this 11 | list of conditions and the following disclaimer. 12 | 13 | 2. Redistributions in binary form must reproduce the above copyright notice, 14 | this list of conditions and the following disclaimer in the documentation 15 | and/or other materials provided with the distribution. 16 | 17 | THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 18 | AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 19 | IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE 20 | DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE 21 | FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 | DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 23 | SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 24 | CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, 25 | OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE 26 | OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 27 | **/ 28 | 29 | #ifndef _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 30 | #define _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 31 | 32 | #include "../Include/glslang_c_interface.h" 33 | 34 | #ifdef __cplusplus 35 | extern "C" { 36 | #endif 37 | 38 | // Returns a struct that can be use to create custom resource values. 39 | glslang_resource_t* glslang_resource(void); 40 | 41 | // These are the default resources for TBuiltInResources, used for both 42 | // - parsing this string for the case where the user didn't supply one, 43 | // - dumping out a template for user construction of a config file. 44 | const glslang_resource_t* glslang_default_resource(void); 45 | 46 | // Returns the DefaultTBuiltInResource as a human-readable string. 47 | // NOTE: User is responsible for freeing this string. 48 | const char* glslang_default_resource_string(); 49 | 50 | // Decodes the resource limits from |config| to |resources|. 51 | void glslang_decode_resource_limits(glslang_resource_t* resources, char* config); 52 | 53 | #ifdef __cplusplus 54 | } 55 | #endif 56 | 57 | #endif // _STAND_ALONE_RESOURCE_LIMITS_C_INCLUDED_ 58 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/glslang/SPIRV/NonSemanticDebugPrintf.h: -------------------------------------------------------------------------------- 1 | // Copyright (c) 2020 The Khronos Group Inc. 2 | // 3 | // Permission is hereby granted, free of charge, to any person obtaining a 4 | // copy of this software and/or associated documentation files (the 5 | // "Materials"), to deal in the Materials without restriction, including 6 | // without limitation the rights to use, copy, modify, merge, publish, 7 | // distribute, sublicense, and/or sell copies of the Materials, and to 8 | // permit persons to whom the Materials are furnished to do so, subject to 9 | // the following conditions: 10 | // 11 | // The above copyright notice and this permission notice shall be included 12 | // in all copies or substantial portions of the Materials. 13 | // 14 | // MODIFICATIONS TO THIS FILE MAY MEAN IT NO LONGER ACCURATELY REFLECTS 15 | // KHRONOS STANDARDS. THE UNMODIFIED, NORMATIVE VERSIONS OF KHRONOS 16 | // SPECIFICATIONS AND HEADER INFORMATION ARE LOCATED AT 17 | // https://www.khronos.org/registry/ 18 | // 19 | // THE MATERIALS ARE PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, 20 | // EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF 21 | // MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. 22 | // IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY 23 | // CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, 24 | // TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE 25 | // MATERIALS OR THE USE OR OTHER DEALINGS IN THE MATERIALS. 26 | // 27 | 28 | #ifndef SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 29 | #define SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 30 | 31 | #ifdef __cplusplus 32 | extern "C" { 33 | #endif 34 | 35 | enum { 36 | NonSemanticDebugPrintfRevision = 1, 37 | NonSemanticDebugPrintfRevision_BitWidthPadding = 0x7fffffff 38 | }; 39 | 40 | enum NonSemanticDebugPrintfInstructions { 41 | NonSemanticDebugPrintfDebugPrintf = 1, 42 | NonSemanticDebugPrintfInstructionsMax = 0x7fffffff 43 | }; 44 | 45 | 46 | #ifdef __cplusplus 47 | } 48 | #endif 49 | 50 | #endif // SPIRV_UNIFIED1_NonSemanticDebugPrintf_H_ 51 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/glslang/SPIRV/disassemble.h: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2014-2015 LunarG, Inc. 3 | // 4 | // All rights reserved. 5 | // 6 | // Redistribution and use in source and binary forms, with or without 7 | // modification, are permitted provided that the following conditions 8 | // are met: 9 | // 10 | // Redistributions of source code must retain the above copyright 11 | // notice, this list of conditions and the following disclaimer. 12 | // 13 | // Redistributions in binary form must reproduce the above 14 | // copyright notice, this list of conditions and the following 15 | // disclaimer in the documentation and/or other materials provided 16 | // with the distribution. 17 | // 18 | // Neither the name of 3Dlabs Inc. Ltd. nor the names of its 19 | // contributors may be used to endorse or promote products derived 20 | // from this software without specific prior written permission. 21 | // 22 | // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS 23 | // "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT 24 | // LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS 25 | // FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE 26 | // COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, 27 | // INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, 28 | // BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; 29 | // LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 30 | // CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 31 | // LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN 32 | // ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE 33 | // POSSIBILITY OF SUCH DAMAGE. 34 | 35 | // 36 | // Disassembler for SPIR-V. 37 | // 38 | 39 | #pragma once 40 | #ifndef disassembler_H 41 | #define disassembler_H 42 | 43 | #include 44 | #include 45 | 46 | namespace spv { 47 | 48 | // disassemble with glslang custom disassembler 49 | void Disassemble(std::ostream& out, const std::vector&); 50 | 51 | } // end namespace spv 52 | 53 | #endif // disassembler_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/benchmark.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BENCHMARK_H 16 | #define NCNN_BENCHMARK_H 17 | 18 | #include "layer.h" 19 | #include "mat.h" 20 | #include "platform.h" 21 | 22 | namespace ncnn { 23 | 24 | // get now timestamp in ms 25 | NCNN_EXPORT double get_current_time(); 26 | 27 | #if NCNN_BENCHMARK 28 | 29 | NCNN_EXPORT void benchmark(const Layer* layer, double start, double end); 30 | NCNN_EXPORT void benchmark(const Layer* layer, const Mat& bottom_blob, Mat& top_blob, double start, double end); 31 | 32 | #endif // NCNN_BENCHMARK 33 | 34 | } // namespace ncnn 35 | 36 | #endif // NCNN_BENCHMARK_H 37 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/blob.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_BLOB_H 16 | #define NCNN_BLOB_H 17 | 18 | #include "mat.h" 19 | #include "platform.h" 20 | 21 | namespace ncnn { 22 | 23 | class NCNN_EXPORT Blob 24 | { 25 | public: 26 | // empty 27 | Blob(); 28 | 29 | public: 30 | #if NCNN_STRING 31 | // blob name 32 | std::string name; 33 | #endif // NCNN_STRING 34 | // layer index which produce this blob as output 35 | int producer; 36 | // layer index which need this blob as input 37 | int consumer; 38 | // shape hint 39 | Mat shape; 40 | }; 41 | 42 | } // namespace ncnn 43 | 44 | #endif // NCNN_BLOB_H 45 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/layer_shader_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_SHADER_TYPE_H 16 | #define NCNN_LAYER_SHADER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerShaderType { 21 | enum LayerShaderType 22 | { 23 | #include "layer_shader_type_enum.h" 24 | }; 25 | } // namespace LayerShaderType 26 | 27 | } // namespace ncnn 28 | 29 | #endif // NCNN_LAYER_SHADER_TYPE_H 30 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/layer_type.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_LAYER_TYPE_H 16 | #define NCNN_LAYER_TYPE_H 17 | 18 | namespace ncnn { 19 | 20 | namespace LayerType { 21 | enum LayerType 22 | { 23 | #include "layer_type_enum.h" 24 | CustomBit = (1 << 8), 25 | }; 26 | } // namespace LayerType 27 | 28 | } // namespace ncnn 29 | 30 | #endif // NCNN_LAYER_TYPE_H 31 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/layer_type_enum.h: -------------------------------------------------------------------------------- 1 | // Layer Type Enum header 2 | // 3 | // This file is auto-generated by cmake, don't edit it. 4 | 5 | AbsVal = 0, 6 | ArgMax = 1, 7 | BatchNorm = 2, 8 | Bias = 3, 9 | BNLL = 4, 10 | Concat = 5, 11 | Convolution = 6, 12 | Crop = 7, 13 | Deconvolution = 8, 14 | Dropout = 9, 15 | Eltwise = 10, 16 | ELU = 11, 17 | Embed = 12, 18 | Exp = 13, 19 | Flatten = 14, 20 | InnerProduct = 15, 21 | Input = 16, 22 | Log = 17, 23 | LRN = 18, 24 | MemoryData = 19, 25 | MVN = 20, 26 | Pooling = 21, 27 | Power = 22, 28 | PReLU = 23, 29 | Proposal = 24, 30 | Reduction = 25, 31 | ReLU = 26, 32 | Reshape = 27, 33 | ROIPooling = 28, 34 | Scale = 29, 35 | Sigmoid = 30, 36 | Slice = 31, 37 | Softmax = 32, 38 | Split = 33, 39 | SPP = 34, 40 | TanH = 35, 41 | Threshold = 36, 42 | Tile = 37, 43 | RNN = 38, 44 | LSTM = 39, 45 | BinaryOp = 40, 46 | UnaryOp = 41, 47 | ConvolutionDepthWise = 42, 48 | Padding = 43, 49 | Squeeze = 44, 50 | ExpandDims = 45, 51 | Normalize = 46, 52 | Permute = 47, 53 | PriorBox = 48, 54 | DetectionOutput = 49, 55 | Interp = 50, 56 | DeconvolutionDepthWise = 51, 57 | ShuffleChannel = 52, 58 | InstanceNorm = 53, 59 | Clip = 54, 60 | Reorg = 55, 61 | YoloDetectionOutput = 56, 62 | Quantize = 57, 63 | Dequantize = 58, 64 | Yolov3DetectionOutput = 59, 65 | PSROIPooling = 60, 66 | ROIAlign = 61, 67 | Packing = 62, 68 | Requantize = 63, 69 | Cast = 64, 70 | HardSigmoid = 65, 71 | SELU = 66, 72 | HardSwish = 67, 73 | Noop = 68, 74 | PixelShuffle = 69, 75 | DeepCopy = 70, 76 | Mish = 71, 77 | StatisticsPooling = 72, 78 | Swish = 73, 79 | Gemm = 74, 80 | GroupNorm = 75, 81 | LayerNorm = 76, 82 | Softplus = 77, 83 | GRU = 78, 84 | MultiHeadAttention = 79, 85 | GELU = 80, 86 | Convolution1D = 81, 87 | Pooling1D = 82, 88 | ConvolutionDepthWise1D = 83, 89 | Convolution3D = 84, 90 | ConvolutionDepthWise3D = 85, 91 | Pooling3D = 86, 92 | MatMul = 87, 93 | Deconvolution1D = 88, 94 | DeconvolutionDepthWise1D = 89, 95 | Deconvolution3D = 90, 96 | DeconvolutionDepthWise3D = 91, 97 | Einsum = 92, 98 | DeformableConv2D = 93, 99 | GLU = 94, 100 | Fold = 95, 101 | Unfold = 96, 102 | GridSample = 97, 103 | 104 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/modelbin.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_MODELBIN_H 16 | #define NCNN_MODELBIN_H 17 | 18 | #include "mat.h" 19 | 20 | namespace ncnn { 21 | 22 | class DataReader; 23 | class NCNN_EXPORT ModelBin 24 | { 25 | public: 26 | ModelBin(); 27 | virtual ~ModelBin(); 28 | // element type 29 | // 0 = auto 30 | // 1 = float32 31 | // 2 = float16 32 | // 3 = int8 33 | // load vec 34 | virtual Mat load(int w, int type) const = 0; 35 | // load image 36 | virtual Mat load(int w, int h, int type) const; 37 | // load dim 38 | virtual Mat load(int w, int h, int c, int type) const; 39 | // load cube 40 | virtual Mat load(int w, int h, int d, int c, int type) const; 41 | }; 42 | 43 | class ModelBinFromDataReaderPrivate; 44 | class NCNN_EXPORT ModelBinFromDataReader : public ModelBin 45 | { 46 | public: 47 | explicit ModelBinFromDataReader(const DataReader& dr); 48 | virtual ~ModelBinFromDataReader(); 49 | 50 | virtual Mat load(int w, int type) const; 51 | 52 | private: 53 | ModelBinFromDataReader(const ModelBinFromDataReader&); 54 | ModelBinFromDataReader& operator=(const ModelBinFromDataReader&); 55 | 56 | private: 57 | ModelBinFromDataReaderPrivate* const d; 58 | }; 59 | 60 | class ModelBinFromMatArrayPrivate; 61 | class NCNN_EXPORT ModelBinFromMatArray : public ModelBin 62 | { 63 | public: 64 | // construct from weight blob array 65 | explicit ModelBinFromMatArray(const Mat* weights); 66 | virtual ~ModelBinFromMatArray(); 67 | 68 | virtual Mat load(int w, int type) const; 69 | 70 | private: 71 | ModelBinFromMatArray(const ModelBinFromMatArray&); 72 | ModelBinFromMatArray& operator=(const ModelBinFromMatArray&); 73 | 74 | private: 75 | ModelBinFromMatArrayPrivate* const d; 76 | }; 77 | 78 | } // namespace ncnn 79 | 80 | #endif // NCNN_MODELBIN_H 81 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/ncnn_export.h: -------------------------------------------------------------------------------- 1 | 2 | #ifndef NCNN_EXPORT_H 3 | #define NCNN_EXPORT_H 4 | 5 | #ifdef NCNN_STATIC_DEFINE 6 | # define NCNN_EXPORT 7 | # define NCNN_NO_EXPORT 8 | #else 9 | # ifndef NCNN_EXPORT 10 | # ifdef ncnn_EXPORTS 11 | /* We are building this library */ 12 | # define NCNN_EXPORT 13 | # else 14 | /* We are using this library */ 15 | # define NCNN_EXPORT 16 | # endif 17 | # endif 18 | 19 | # ifndef NCNN_NO_EXPORT 20 | # define NCNN_NO_EXPORT 21 | # endif 22 | #endif 23 | 24 | #ifndef NCNN_DEPRECATED 25 | # define NCNN_DEPRECATED __attribute__ ((__deprecated__)) 26 | #endif 27 | 28 | #ifndef NCNN_DEPRECATED_EXPORT 29 | # define NCNN_DEPRECATED_EXPORT NCNN_EXPORT NCNN_DEPRECATED 30 | #endif 31 | 32 | #ifndef NCNN_DEPRECATED_NO_EXPORT 33 | # define NCNN_DEPRECATED_NO_EXPORT NCNN_NO_EXPORT NCNN_DEPRECATED 34 | #endif 35 | 36 | #if 0 /* DEFINE_NO_DEPRECATED */ 37 | # ifndef NCNN_NO_DEPRECATED 38 | # define NCNN_NO_DEPRECATED 39 | # endif 40 | #endif 41 | 42 | #endif /* NCNN_EXPORT_H */ 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/paramdict.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2017 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_PARAMDICT_H 16 | #define NCNN_PARAMDICT_H 17 | 18 | #include "mat.h" 19 | 20 | // at most 32 parameters 21 | #define NCNN_MAX_PARAM_COUNT 32 22 | 23 | namespace ncnn { 24 | 25 | class DataReader; 26 | class Net; 27 | class ParamDictPrivate; 28 | class NCNN_EXPORT ParamDict 29 | { 30 | public: 31 | // empty 32 | ParamDict(); 33 | 34 | virtual ~ParamDict(); 35 | 36 | // copy 37 | ParamDict(const ParamDict&); 38 | 39 | // assign 40 | ParamDict& operator=(const ParamDict&); 41 | 42 | // get type 43 | int type(int id) const; 44 | 45 | // get int 46 | int get(int id, int def) const; 47 | // get float 48 | float get(int id, float def) const; 49 | // get array 50 | Mat get(int id, const Mat& def) const; 51 | 52 | // set int 53 | void set(int id, int i); 54 | // set float 55 | void set(int id, float f); 56 | // set array 57 | void set(int id, const Mat& v); 58 | 59 | protected: 60 | friend class Net; 61 | 62 | void clear(); 63 | 64 | int load_param(const DataReader& dr); 65 | int load_param_bin(const DataReader& dr); 66 | 67 | private: 68 | ParamDictPrivate* const d; 69 | }; 70 | 71 | } // namespace ncnn 72 | 73 | #endif // NCNN_PARAMDICT_H 74 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/include/ncnn/simpleomp.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2020 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef NCNN_SIMPLEOMP_H 16 | #define NCNN_SIMPLEOMP_H 17 | 18 | #include "platform.h" 19 | 20 | #if NCNN_SIMPLEOMP 21 | 22 | #include 23 | 24 | // This minimal openmp runtime implementation only supports the llvm openmp abi 25 | // and only supports #pragma omp parallel for num_threads(X) 26 | 27 | #ifdef __cplusplus 28 | extern "C" { 29 | #endif 30 | 31 | NCNN_EXPORT int omp_get_max_threads(); 32 | 33 | NCNN_EXPORT void omp_set_num_threads(int num_threads); 34 | 35 | NCNN_EXPORT int omp_get_dynamic(); 36 | 37 | NCNN_EXPORT void omp_set_dynamic(int dynamic); 38 | 39 | NCNN_EXPORT int omp_get_num_threads(); 40 | 41 | NCNN_EXPORT int omp_get_thread_num(); 42 | 43 | NCNN_EXPORT int kmp_get_blocktime(); 44 | 45 | NCNN_EXPORT void kmp_set_blocktime(int blocktime); 46 | 47 | #ifdef __cplusplus 48 | } 49 | #endif 50 | 51 | #endif // NCNN_SIMPLEOMP 52 | 53 | #endif // NCNN_SIMPLEOMP_H 54 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/OGLCompilerTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OGLCompilerTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OGLCompiler) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OGLCompiler ALIAS glslang::OGLCompiler) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/OSDependentTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `OSDependentTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::OSDependent) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(OSDependent ALIAS glslang::OSDependent) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/SPIRVTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `SPIRVTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::SPIRV) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | add_library(SPIRV ALIAS glslang::SPIRV) 9 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/glslang/glslang-config.cmake: -------------------------------------------------------------------------------- 1 | 2 | ####### Expanded from @PACKAGE_INIT@ by configure_package_config_file() ####### 3 | ####### Any changes to this file will be overwritten by the next CMake run #### 4 | ####### The input file was glslang-config.cmake.in ######## 5 | 6 | get_filename_component(PACKAGE_PREFIX_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../" ABSOLUTE) 7 | 8 | macro(set_and_check _var _file) 9 | set(${_var} "${_file}") 10 | if(NOT EXISTS "${_file}") 11 | message(FATAL_ERROR "File or directory ${_file} referenced by variable ${_var} does not exist !") 12 | endif() 13 | endmacro() 14 | 15 | macro(check_required_components _NAME) 16 | foreach(comp ${${_NAME}_FIND_COMPONENTS}) 17 | if(NOT ${_NAME}_${comp}_FOUND) 18 | if(${_NAME}_FIND_REQUIRED_${comp}) 19 | set(${_NAME}_FOUND FALSE) 20 | endif() 21 | endif() 22 | endforeach() 23 | endmacro() 24 | 25 | #################################################################################### 26 | include("${PACKAGE_PREFIX_DIR}/lib/cmake/glslang/glslang-targets.cmake") 27 | 28 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/glslangTargets.cmake: -------------------------------------------------------------------------------- 1 | 2 | message(WARNING "Using `glslangTargets.cmake` is deprecated: use `find_package(glslang)` to find glslang CMake targets.") 3 | 4 | if (NOT TARGET glslang::glslang) 5 | include("${CMAKE_CURRENT_LIST_DIR}/../../lib/cmake/glslang/glslang-targets.cmake") 6 | endif() 7 | 8 | if(OFF) 9 | add_library(glslang ALIAS glslang::glslang) 10 | else() 11 | add_library(glslang ALIAS glslang::glslang) 12 | add_library(MachineIndependent ALIAS glslang::MachineIndependent) 13 | add_library(GenericCodeGen ALIAS glslang::GenericCodeGen) 14 | endif() 15 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/ncnn/ncnn-release.cmake: -------------------------------------------------------------------------------- 1 | #---------------------------------------------------------------- 2 | # Generated CMake target import file for configuration "Release". 3 | #---------------------------------------------------------------- 4 | 5 | # Commands may need to know the format version. 6 | set(CMAKE_IMPORT_FILE_VERSION 1) 7 | 8 | # Import target "ncnn" for configuration "Release" 9 | set_property(TARGET ncnn APPEND PROPERTY IMPORTED_CONFIGURATIONS RELEASE) 10 | set_target_properties(ncnn PROPERTIES 11 | IMPORTED_LINK_INTERFACE_LANGUAGES_RELEASE "CXX" 12 | IMPORTED_LOCATION_RELEASE "${_IMPORT_PREFIX}/lib/libncnn.a" 13 | ) 14 | 15 | list(APPEND _cmake_import_check_targets ncnn ) 16 | list(APPEND _cmake_import_check_files_for_ncnn "${_IMPORT_PREFIX}/lib/libncnn.a" ) 17 | 18 | # Commands beyond this point should not need to know the version. 19 | set(CMAKE_IMPORT_FILE_VERSION) 20 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/cmake/ncnn/ncnnConfig.cmake: -------------------------------------------------------------------------------- 1 | set(NCNN_OPENMP ON) 2 | set(NCNN_THREADS ON) 3 | set(NCNN_VULKAN ON) 4 | set(NCNN_SHARED_LIB OFF) 5 | set(NCNN_SYSTEM_GLSLANG OFF) 6 | 7 | if(NCNN_OPENMP) 8 | find_package(OpenMP) 9 | endif() 10 | 11 | if(NCNN_THREADS) 12 | set(CMAKE_THREAD_PREFER_PTHREAD TRUE) 13 | set(THREADS_PREFER_PTHREAD_FLAG TRUE) 14 | find_package(Threads REQUIRED) 15 | endif() 16 | 17 | if(NCNN_VULKAN) 18 | find_package(Vulkan REQUIRED) 19 | 20 | if(NOT NCNN_SHARED_LIB) 21 | if(NCNN_SYSTEM_GLSLANG) 22 | find_package(glslang QUIET) 23 | if(NOT glslang_FOUND) 24 | set(GLSLANG_TARGET_DIR "") 25 | include(${GLSLANG_TARGET_DIR}/OSDependentTargets.cmake) 26 | include(${GLSLANG_TARGET_DIR}/OGLCompilerTargets.cmake) 27 | if(EXISTS "${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 28 | # hlsl support can be optional 29 | include("${GLSLANG_TARGET_DIR}/HLSLTargets.cmake") 30 | endif() 31 | include(${GLSLANG_TARGET_DIR}/glslangTargets.cmake) 32 | include(${GLSLANG_TARGET_DIR}/SPIRVTargets.cmake) 33 | endif() 34 | else() 35 | set(glslang_DIR "${CMAKE_CURRENT_LIST_DIR}/../../../lib/cmake/glslang") 36 | find_package(glslang QUIET) 37 | endif() 38 | 39 | endif() 40 | endif() 41 | 42 | include(${CMAKE_CURRENT_LIST_DIR}/ncnn.cmake) 43 | -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libGenericCodeGen.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libGenericCodeGen.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libMachineIndependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libMachineIndependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libOGLCompiler.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libOGLCompiler.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libOSDependent.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libOSDependent.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libSPIRV.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libSPIRV.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libglslang.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libglslang.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libncnn.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/libncnn.a -------------------------------------------------------------------------------- /app/src/main/jni/ncnn-20221128-android-vulkan/x86_64/lib/pkgconfig/ncnn.pc: -------------------------------------------------------------------------------- 1 | prefix=${pcfiledir}/../.. 2 | librarydir=${prefix}/lib 3 | includedir=${prefix}/include 4 | 5 | Name: ncnn 6 | Description: high-performance neural network inference framework optimized for the mobile platform 7 | Version: 1.0.20221128 8 | URL: https://github.com/Tencent/ncnn 9 | Libs: -L"${librarydir}" -lncnn 10 | Cflags: -I"${includedir}" 11 | 12 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/README.android: -------------------------------------------------------------------------------- 1 | See http://opencv.org/platforms/android 2 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/OpenCVConfig-version.cmake: -------------------------------------------------------------------------------- 1 | set(OpenCV_VERSION 4.6.0) 2 | set(PACKAGE_VERSION ${OpenCV_VERSION}) 3 | 4 | set(PACKAGE_VERSION_EXACT False) 5 | set(PACKAGE_VERSION_COMPATIBLE False) 6 | 7 | if(PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 8 | set(PACKAGE_VERSION_EXACT True) 9 | set(PACKAGE_VERSION_COMPATIBLE True) 10 | endif() 11 | 12 | if(PACKAGE_FIND_VERSION_MAJOR EQUAL 4 13 | AND PACKAGE_FIND_VERSION VERSION_LESS PACKAGE_VERSION) 14 | set(PACKAGE_VERSION_COMPATIBLE True) 15 | endif() 16 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/OpenCVConfig.cmake: -------------------------------------------------------------------------------- 1 | # =================================================================================== 2 | # The OpenCV CMake configuration file 3 | # 4 | # ** File generated automatically, do not modify ** 5 | # 6 | # Usage from an external project: 7 | # In your CMakeLists.txt, add these lines: 8 | # 9 | # find_package(OpenCV REQUIRED) 10 | # include_directories(${OpenCV_INCLUDE_DIRS}) # Not needed for CMake >= 2.8.11 11 | # target_link_libraries(MY_TARGET_NAME ${OpenCV_LIBS}) 12 | # 13 | # Or you can search for specific OpenCV modules: 14 | # 15 | # find_package(OpenCV REQUIRED core videoio) 16 | # 17 | # If the module is found then OPENCV__FOUND is set to TRUE. 18 | # 19 | # This file will define the following variables: 20 | # - OpenCV_LIBS : The list of all imported targets for OpenCV modules. 21 | # - OpenCV_INCLUDE_DIRS : The OpenCV include directories. 22 | # - OpenCV_ANDROID_NATIVE_API_LEVEL : Minimum required level of Android API. 23 | # - OpenCV_VERSION : The version of this OpenCV build: "4.6.0" 24 | # - OpenCV_VERSION_MAJOR : Major version part of OpenCV_VERSION: "4" 25 | # - OpenCV_VERSION_MINOR : Minor version part of OpenCV_VERSION: "6" 26 | # - OpenCV_VERSION_PATCH : Patch version part of OpenCV_VERSION: "0" 27 | # - OpenCV_VERSION_STATUS : Development status of this build: "" 28 | # 29 | # =================================================================================== 30 | 31 | # Extract directory name from full path of the file currently being processed. 32 | # Note that CMake 2.8.3 introduced CMAKE_CURRENT_LIST_DIR. We reimplement it 33 | # for older versions of CMake to support these as well. 34 | if(CMAKE_VERSION VERSION_LESS "2.8.3") 35 | get_filename_component(CMAKE_CURRENT_LIST_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH) 36 | endif() 37 | 38 | if(NOT DEFINED OpenCV_CONFIG_SUBDIR) 39 | set(OpenCV_CONFIG_SUBDIR "/abi-${ANDROID_NDK_ABI_NAME}") 40 | endif() 41 | 42 | set(OpenCV_CONFIG_PATH "${CMAKE_CURRENT_LIST_DIR}${OpenCV_CONFIG_SUBDIR}") 43 | if(EXISTS "${OpenCV_CONFIG_PATH}/OpenCVConfig.cmake") 44 | include("${OpenCV_CONFIG_PATH}/OpenCVConfig.cmake") 45 | else() 46 | if(NOT OpenCV_FIND_QUIETLY) 47 | message(WARNING "Found OpenCV Android Pack but it has no binaries compatible with your ABI (can't find: ${OpenCV_CONFIG_SUBDIR})") 48 | endif() 49 | set(OpenCV_FOUND FALSE) 50 | endif() 51 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/abi-arm64-v8a/OpenCVConfig-version.cmake: -------------------------------------------------------------------------------- 1 | set(OpenCV_VERSION 4.6.0) 2 | set(PACKAGE_VERSION ${OpenCV_VERSION}) 3 | 4 | set(PACKAGE_VERSION_EXACT False) 5 | set(PACKAGE_VERSION_COMPATIBLE False) 6 | 7 | if(PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 8 | set(PACKAGE_VERSION_EXACT True) 9 | set(PACKAGE_VERSION_COMPATIBLE True) 10 | endif() 11 | 12 | if(PACKAGE_FIND_VERSION_MAJOR EQUAL 4 13 | AND PACKAGE_FIND_VERSION VERSION_LESS PACKAGE_VERSION) 14 | set(PACKAGE_VERSION_COMPATIBLE True) 15 | endif() 16 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/abi-armeabi-v7a/OpenCVConfig-version.cmake: -------------------------------------------------------------------------------- 1 | set(OpenCV_VERSION 4.6.0) 2 | set(PACKAGE_VERSION ${OpenCV_VERSION}) 3 | 4 | set(PACKAGE_VERSION_EXACT False) 5 | set(PACKAGE_VERSION_COMPATIBLE False) 6 | 7 | if(PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 8 | set(PACKAGE_VERSION_EXACT True) 9 | set(PACKAGE_VERSION_COMPATIBLE True) 10 | endif() 11 | 12 | if(PACKAGE_FIND_VERSION_MAJOR EQUAL 4 13 | AND PACKAGE_FIND_VERSION VERSION_LESS PACKAGE_VERSION) 14 | set(PACKAGE_VERSION_COMPATIBLE True) 15 | endif() 16 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/abi-x86/OpenCVConfig-version.cmake: -------------------------------------------------------------------------------- 1 | set(OpenCV_VERSION 4.6.0) 2 | set(PACKAGE_VERSION ${OpenCV_VERSION}) 3 | 4 | set(PACKAGE_VERSION_EXACT False) 5 | set(PACKAGE_VERSION_COMPATIBLE False) 6 | 7 | if(PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 8 | set(PACKAGE_VERSION_EXACT True) 9 | set(PACKAGE_VERSION_COMPATIBLE True) 10 | endif() 11 | 12 | if(PACKAGE_FIND_VERSION_MAJOR EQUAL 4 13 | AND PACKAGE_FIND_VERSION VERSION_LESS PACKAGE_VERSION) 14 | set(PACKAGE_VERSION_COMPATIBLE True) 15 | endif() 16 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/abi-x86_64/OpenCVConfig-version.cmake: -------------------------------------------------------------------------------- 1 | set(OpenCV_VERSION 4.6.0) 2 | set(PACKAGE_VERSION ${OpenCV_VERSION}) 3 | 4 | set(PACKAGE_VERSION_EXACT False) 5 | set(PACKAGE_VERSION_COMPATIBLE False) 6 | 7 | if(PACKAGE_FIND_VERSION VERSION_EQUAL PACKAGE_VERSION) 8 | set(PACKAGE_VERSION_EXACT True) 9 | set(PACKAGE_VERSION_COMPATIBLE True) 10 | endif() 11 | 12 | if(PACKAGE_FIND_VERSION_MAJOR EQUAL 4 13 | AND PACKAGE_FIND_VERSION VERSION_LESS PACKAGE_VERSION) 14 | set(PACKAGE_VERSION_COMPATIBLE True) 15 | endif() 16 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/bufferpool.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | // 5 | // Copyright (C) 2014, Advanced Micro Devices, Inc., all rights reserved. 6 | 7 | #ifndef OPENCV_CORE_BUFFER_POOL_HPP 8 | #define OPENCV_CORE_BUFFER_POOL_HPP 9 | 10 | #ifdef _MSC_VER 11 | #pragma warning(push) 12 | #pragma warning(disable: 4265) 13 | #endif 14 | 15 | namespace cv 16 | { 17 | 18 | //! @addtogroup core 19 | //! @{ 20 | 21 | class BufferPoolController 22 | { 23 | protected: 24 | ~BufferPoolController() { } 25 | public: 26 | virtual size_t getReservedSize() const = 0; 27 | virtual size_t getMaxReservedSize() const = 0; 28 | virtual void setMaxReservedSize(size_t size) = 0; 29 | virtual void freeAllReservedBuffers() = 0; 30 | }; 31 | 32 | //! @} 33 | 34 | } 35 | 36 | #ifdef _MSC_VER 37 | #pragma warning(pop) 38 | #endif 39 | 40 | #endif // OPENCV_CORE_BUFFER_POOL_HPP 41 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/core.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 14 | // Copyright (C) 2009, Willow Garage Inc., all rights reserved. 15 | // Copyright (C) 2013, OpenCV Foundation, all rights reserved. 16 | // Third party copyrights are property of their respective owners. 17 | // 18 | // Redistribution and use in source and binary forms, with or without modification, 19 | // are permitted provided that the following conditions are met: 20 | // 21 | // * Redistribution's of source code must retain the above copyright notice, 22 | // this list of conditions and the following disclaimer. 23 | // 24 | // * Redistribution's in binary form must reproduce the above copyright notice, 25 | // this list of conditions and the following disclaimer in the documentation 26 | // and/or other materials provided with the distribution. 27 | // 28 | // * The name of the copyright holders may not be used to endorse or promote products 29 | // derived from this software without specific prior written permission. 30 | // 31 | // This software is provided by the copyright holders and contributors "as is" and 32 | // any express or implied warranties, including, but not limited to, the implied 33 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 34 | // In no event shall the Intel Corporation or contributors be liable for any direct, 35 | // indirect, incidental, special, exemplary, or consequential damages 36 | // (including, but not limited to, procurement of substitute goods or services; 37 | // loss of use, data, or profits; or business interruption) however caused 38 | // and on any theory of liability, whether in contract, strict liability, 39 | // or tort (including negligence or otherwise) arising in any way out of 40 | // the use of this software, even if advised of the possibility of such damage. 41 | // 42 | //M*/ 43 | 44 | #ifdef __OPENCV_BUILD 45 | #error this is a compatibility header which should not be used inside the OpenCV library 46 | #endif 47 | 48 | #include "opencv2/core.hpp" 49 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/detail/async_promise.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_ASYNC_PROMISE_HPP 6 | #define OPENCV_CORE_ASYNC_PROMISE_HPP 7 | 8 | #include "../async.hpp" 9 | 10 | #include "exception_ptr.hpp" 11 | 12 | namespace cv { 13 | 14 | /** @addtogroup core_async 15 | @{ 16 | */ 17 | 18 | 19 | /** @brief Provides result of asynchronous operations 20 | 21 | */ 22 | class CV_EXPORTS AsyncPromise 23 | { 24 | public: 25 | ~AsyncPromise() CV_NOEXCEPT; 26 | AsyncPromise() CV_NOEXCEPT; 27 | explicit AsyncPromise(const AsyncPromise& o) CV_NOEXCEPT; 28 | AsyncPromise& operator=(const AsyncPromise& o) CV_NOEXCEPT; 29 | void release() CV_NOEXCEPT; 30 | 31 | /** Returns associated AsyncArray 32 | @note Can be called once 33 | */ 34 | AsyncArray getArrayResult(); 35 | 36 | /** Stores asynchronous result. 37 | @param[in] value result 38 | */ 39 | void setValue(InputArray value); 40 | 41 | // TODO "move" setters 42 | 43 | #if CV__EXCEPTION_PTR 44 | /** Stores exception. 45 | @param[in] exception exception to be raised in AsyncArray 46 | */ 47 | void setException(std::exception_ptr exception); 48 | #endif 49 | 50 | /** Stores exception. 51 | @param[in] exception exception to be raised in AsyncArray 52 | */ 53 | void setException(const cv::Exception& exception); 54 | 55 | #ifdef CV_CXX11 56 | explicit AsyncPromise(AsyncPromise&& o) { p = o.p; o.p = NULL; } 57 | AsyncPromise& operator=(AsyncPromise&& o) CV_NOEXCEPT { std::swap(p, o.p); return *this; } 58 | #endif 59 | 60 | 61 | // PImpl 62 | typedef struct AsyncArray::Impl Impl; friend struct AsyncArray::Impl; 63 | inline void* _getImpl() const CV_NOEXCEPT { return p; } 64 | protected: 65 | Impl* p; 66 | }; 67 | 68 | 69 | //! @} 70 | } // namespace 71 | #endif // OPENCV_CORE_ASYNC_PROMISE_HPP 72 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/detail/dispatch_helper.impl.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_DETAIL_DISPATCH_HELPER_IMPL_HPP 6 | #define OPENCV_CORE_DETAIL_DISPATCH_HELPER_IMPL_HPP 7 | 8 | //! @cond IGNORED 9 | 10 | namespace cv { 11 | namespace detail { 12 | 13 | template class Functor, typename... Args> 14 | static inline void depthDispatch(const int depth, Args&&... args) 15 | { 16 | switch (depth) 17 | { 18 | case CV_8U: 19 | Functor{}(std::forward(args)...); 20 | break; 21 | case CV_8S: 22 | Functor{}(std::forward(args)...); 23 | break; 24 | case CV_16U: 25 | Functor{}(std::forward(args)...); 26 | break; 27 | case CV_16S: 28 | Functor{}(std::forward(args)...); 29 | break; 30 | case CV_32S: 31 | Functor{}(std::forward(args)...); 32 | break; 33 | case CV_32F: 34 | Functor{}(std::forward(args)...); 35 | break; 36 | case CV_64F: 37 | Functor{}(std::forward(args)...); 38 | break; 39 | case CV_16F: 40 | default: 41 | CV_Error(cv::Error::BadDepth, "Unsupported matrix type."); 42 | }; 43 | } 44 | 45 | }} 46 | 47 | //! @endcond 48 | 49 | #endif //OPENCV_CORE_DETAIL_DISPATCH_HELPER_IMPL_HPP 50 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/detail/exception_ptr.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_DETAILS_EXCEPTION_PTR_H 6 | #define OPENCV_CORE_DETAILS_EXCEPTION_PTR_H 7 | 8 | #ifndef CV__EXCEPTION_PTR 9 | # if defined(__ANDROID__) && defined(ATOMIC_INT_LOCK_FREE) && ATOMIC_INT_LOCK_FREE < 2 10 | # define CV__EXCEPTION_PTR 0 // Not supported, details: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58938 11 | # elif defined(CV_CXX11) 12 | # define CV__EXCEPTION_PTR 1 13 | # elif defined(_MSC_VER) 14 | # define CV__EXCEPTION_PTR (_MSC_VER >= 1600) 15 | # elif defined(__clang__) 16 | # define CV__EXCEPTION_PTR 0 // C++11 only (see above) 17 | # elif defined(__GNUC__) && defined(__GXX_EXPERIMENTAL_CXX0X__) 18 | # define CV__EXCEPTION_PTR (__GXX_EXPERIMENTAL_CXX0X__ > 0) 19 | # endif 20 | #endif 21 | #ifndef CV__EXCEPTION_PTR 22 | # define CV__EXCEPTION_PTR 0 23 | #elif CV__EXCEPTION_PTR 24 | # include // std::exception_ptr 25 | #endif 26 | 27 | #endif // OPENCV_CORE_DETAILS_EXCEPTION_PTR_H 28 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/opencl/runtime/opencl_core_wrappers.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2010-2013, Advanced Micro Devices, Inc., all rights reserved. 14 | // Third party copyrights are property of their respective owners. 15 | // 16 | // Redistribution and use in source and binary forms, with or without modification, 17 | // are permitted provided that the following conditions are met: 18 | // 19 | // * Redistribution's of source code must retain the above copyright notice, 20 | // this list of conditions and the following disclaimer. 21 | // 22 | // * Redistribution's in binary form must reproduce the above copyright notice, 23 | // this list of conditions and the following disclaimer in the documentation 24 | // and/or other materials provided with the distribution. 25 | // 26 | // * The name of the copyright holders may not be used to endorse or promote products 27 | // derived from this software without specific prior written permission. 28 | // 29 | // This software is provided by the copyright holders and contributors "as is" and 30 | // any express or implied warranties, including, but not limited to, the implied 31 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 32 | // In no event shall the OpenCV Foundation or contributors be liable for any direct, 33 | // indirect, incidental, special, exemplary, or consequential damages 34 | // (including, but not limited to, procurement of substitute goods or services; 35 | // loss of use, data, or profits; or business interruption) however caused 36 | // and on any theory of liability, whether in contract, strict liability, 37 | // or tort (including negligence or otherwise) arising in any way out of 38 | // the use of this software, even if advised of the possibility of such damage. 39 | // 40 | //M*/ 41 | 42 | #ifndef OPENCV_CORE_OCL_RUNTIME_OPENCL_WRAPPERS_HPP 43 | #define OPENCV_CORE_OCL_RUNTIME_OPENCL_WRAPPERS_HPP 44 | 45 | #include "autogenerated/opencl_core_wrappers.hpp" 46 | 47 | #endif // OPENCV_CORE_OCL_RUNTIME_OPENCL_WRAPPERS_HPP 48 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/opencl/runtime/opencl_gl_wrappers.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2010-2013, Advanced Micro Devices, Inc., all rights reserved. 14 | // Third party copyrights are property of their respective owners. 15 | // 16 | // Redistribution and use in source and binary forms, with or without modification, 17 | // are permitted provided that the following conditions are met: 18 | // 19 | // * Redistribution's of source code must retain the above copyright notice, 20 | // this list of conditions and the following disclaimer. 21 | // 22 | // * Redistribution's in binary form must reproduce the above copyright notice, 23 | // this list of conditions and the following disclaimer in the documentation 24 | // and/or other materials provided with the distribution. 25 | // 26 | // * The name of the copyright holders may not be used to endorse or promote products 27 | // derived from this software without specific prior written permission. 28 | // 29 | // This software is provided by the copyright holders and contributors "as is" and 30 | // any express or implied warranties, including, but not limited to, the implied 31 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 32 | // In no event shall the OpenCV Foundation or contributors be liable for any direct, 33 | // indirect, incidental, special, exemplary, or consequential damages 34 | // (including, but not limited to, procurement of substitute goods or services; 35 | // loss of use, data, or profits; or business interruption) however caused 36 | // and on any theory of liability, whether in contract, strict liability, 37 | // or tort (including negligence or otherwise) arising in any way out of 38 | // the use of this software, even if advised of the possibility of such damage. 39 | // 40 | //M*/ 41 | 42 | #ifndef OPENCV_CORE_OCL_RUNTIME_OPENCL_GL_WRAPPERS_HPP 43 | #define OPENCV_CORE_OCL_RUNTIME_OPENCL_GL_WRAPPERS_HPP 44 | 45 | #include "autogenerated/opencl_gl_wrappers.hpp" 46 | 47 | #endif // OPENCV_CORE_OCL_RUNTIME_OPENCL_GL_WRAPPERS_HPP 48 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/opencl/runtime/opencl_svm_definitions.hpp: -------------------------------------------------------------------------------- 1 | /* See LICENSE file in the root OpenCV directory */ 2 | 3 | #ifndef OPENCV_CORE_OCL_RUNTIME_OPENCL_SVM_DEFINITIONS_HPP 4 | #define OPENCV_CORE_OCL_RUNTIME_OPENCL_SVM_DEFINITIONS_HPP 5 | 6 | #if defined(HAVE_OPENCL_SVM) 7 | #if defined(CL_VERSION_2_0) 8 | 9 | // OpenCL 2.0 contains SVM definitions 10 | 11 | #else 12 | 13 | typedef cl_bitfield cl_device_svm_capabilities; 14 | typedef cl_bitfield cl_svm_mem_flags; 15 | typedef cl_uint cl_kernel_exec_info; 16 | 17 | // 18 | // TODO Add real values after OpenCL 2.0 release 19 | // 20 | 21 | #ifndef CL_DEVICE_SVM_CAPABILITIES 22 | #define CL_DEVICE_SVM_CAPABILITIES 0x1053 23 | 24 | #define CL_DEVICE_SVM_COARSE_GRAIN_BUFFER (1 << 0) 25 | #define CL_DEVICE_SVM_FINE_GRAIN_BUFFER (1 << 1) 26 | #define CL_DEVICE_SVM_FINE_GRAIN_SYSTEM (1 << 2) 27 | #define CL_DEVICE_SVM_ATOMICS (1 << 3) 28 | #endif 29 | 30 | #ifndef CL_MEM_SVM_FINE_GRAIN_BUFFER 31 | #define CL_MEM_SVM_FINE_GRAIN_BUFFER (1 << 10) 32 | #endif 33 | 34 | #ifndef CL_MEM_SVM_ATOMICS 35 | #define CL_MEM_SVM_ATOMICS (1 << 11) 36 | #endif 37 | 38 | 39 | #endif // CL_VERSION_2_0 40 | #endif // HAVE_OPENCL_SVM 41 | 42 | #endif // OPENCV_CORE_OCL_RUNTIME_OPENCL_SVM_DEFINITIONS_HPP 43 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/ovx.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | // Copyright (C) 2016, Intel Corporation, all rights reserved. 6 | // Third party copyrights are property of their respective owners. 7 | 8 | // OpenVX related definitions and declarations 9 | 10 | #pragma once 11 | #ifndef OPENCV_OVX_HPP 12 | #define OPENCV_OVX_HPP 13 | 14 | #include "cvdef.h" 15 | 16 | namespace cv 17 | { 18 | /// Check if use of OpenVX is possible 19 | CV_EXPORTS_W bool haveOpenVX(); 20 | 21 | /// Check if use of OpenVX is enabled 22 | CV_EXPORTS_W bool useOpenVX(); 23 | 24 | /// Enable/disable use of OpenVX 25 | CV_EXPORTS_W void setUseOpenVX(bool flag); 26 | } // namespace cv 27 | 28 | #endif // OPENCV_OVX_HPP 29 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/parallel/backend/parallel_for.openmp.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_PARALLEL_FOR_OPENMP_HPP 6 | #define OPENCV_CORE_PARALLEL_FOR_OPENMP_HPP 7 | 8 | #include "opencv2/core/parallel/parallel_backend.hpp" 9 | 10 | #if !defined(_OPENMP) && !defined(OPENCV_SKIP_OPENMP_PRESENSE_CHECK) 11 | #error "This file must be compiled with enabled OpenMP" 12 | #endif 13 | 14 | #include 15 | 16 | namespace cv { namespace parallel { namespace openmp { 17 | 18 | /** OpenMP parallel_for API implementation 19 | * 20 | * @sa setParallelForBackend 21 | * @ingroup core_parallel_backend 22 | */ 23 | class ParallelForBackend : public ParallelForAPI 24 | { 25 | protected: 26 | int numThreads; 27 | int numThreadsMax; 28 | public: 29 | ParallelForBackend() 30 | { 31 | numThreads = 0; 32 | numThreadsMax = omp_get_max_threads(); 33 | } 34 | 35 | virtual ~ParallelForBackend() {} 36 | 37 | virtual void parallel_for(int tasks, FN_parallel_for_body_cb_t body_callback, void* callback_data) CV_OVERRIDE 38 | { 39 | #pragma omp parallel for schedule(dynamic) num_threads(numThreads > 0 ? numThreads : numThreadsMax) 40 | for (int i = 0; i < tasks; ++i) 41 | body_callback(i, i + 1, callback_data); 42 | } 43 | 44 | virtual int getThreadNum() const CV_OVERRIDE 45 | { 46 | return omp_get_thread_num(); 47 | } 48 | 49 | virtual int getNumThreads() const CV_OVERRIDE 50 | { 51 | return numThreads > 0 52 | ? numThreads 53 | : numThreadsMax; 54 | } 55 | 56 | virtual int setNumThreads(int nThreads) CV_OVERRIDE 57 | { 58 | int oldNumThreads = numThreads; 59 | numThreads = nThreads; 60 | // nothing needed as numThreads is used in #pragma omp parallel for directly 61 | return oldNumThreads; 62 | } 63 | 64 | const char* getName() const CV_OVERRIDE 65 | { 66 | return "openmp"; 67 | } 68 | }; 69 | 70 | }}} // namespace 71 | 72 | #endif // OPENCV_CORE_PARALLEL_FOR_OPENMP_HPP 73 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/utils/allocator_stats.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_ALLOCATOR_STATS_HPP 6 | #define OPENCV_CORE_ALLOCATOR_STATS_HPP 7 | 8 | #include "../cvdef.h" 9 | 10 | namespace cv { namespace utils { 11 | 12 | class AllocatorStatisticsInterface 13 | { 14 | protected: 15 | AllocatorStatisticsInterface() {} 16 | virtual ~AllocatorStatisticsInterface() {} 17 | public: 18 | virtual uint64_t getCurrentUsage() const = 0; 19 | virtual uint64_t getTotalUsage() const = 0; 20 | virtual uint64_t getNumberOfAllocations() const = 0; 21 | virtual uint64_t getPeakUsage() const = 0; 22 | 23 | /** set peak usage = current usage */ 24 | virtual void resetPeakUsage() = 0; 25 | }; 26 | 27 | }} // namespace 28 | 29 | #endif // OPENCV_CORE_ALLOCATOR_STATS_HPP 30 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/utils/fp_control_utils.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_FP_CONTROL_UTILS_HPP 6 | #define OPENCV_CORE_FP_CONTROL_UTILS_HPP 7 | 8 | namespace cv { 9 | 10 | namespace details { 11 | 12 | struct FPDenormalsModeState 13 | { 14 | uint32_t reserved[16]; // 64-bytes 15 | }; // FPDenormalsModeState 16 | 17 | CV_EXPORTS void setFPDenormalsIgnoreHint(bool ignore, CV_OUT FPDenormalsModeState& state); 18 | CV_EXPORTS int saveFPDenormalsState(CV_OUT FPDenormalsModeState& state); 19 | CV_EXPORTS bool restoreFPDenormalsState(const FPDenormalsModeState& state); 20 | 21 | class FPDenormalsIgnoreHintScope 22 | { 23 | public: 24 | inline explicit FPDenormalsIgnoreHintScope(bool ignore = true) 25 | { 26 | details::setFPDenormalsIgnoreHint(ignore, saved_state); 27 | } 28 | 29 | inline explicit FPDenormalsIgnoreHintScope(const FPDenormalsModeState& state) 30 | { 31 | details::saveFPDenormalsState(saved_state); 32 | details::restoreFPDenormalsState(state); 33 | } 34 | 35 | inline ~FPDenormalsIgnoreHintScope() 36 | { 37 | details::restoreFPDenormalsState(saved_state); 38 | } 39 | 40 | protected: 41 | FPDenormalsModeState saved_state; 42 | }; // FPDenormalsIgnoreHintScope 43 | 44 | class FPDenormalsIgnoreHintScopeNOOP 45 | { 46 | public: 47 | inline FPDenormalsIgnoreHintScopeNOOP(bool ignore = true) { CV_UNUSED(ignore); } 48 | inline FPDenormalsIgnoreHintScopeNOOP(const FPDenormalsModeState& state) { CV_UNUSED(state); } 49 | inline ~FPDenormalsIgnoreHintScopeNOOP() { } 50 | }; // FPDenormalsIgnoreHintScopeNOOP 51 | 52 | } // namespace details 53 | 54 | 55 | // Should depend on target compilation architecture only 56 | // Note: previously added archs should NOT be removed to preserve ABI compatibility 57 | #if defined(OPENCV_SUPPORTS_FP_DENORMALS_HINT) 58 | // preserve configuration overloading through ports 59 | #elif defined(__i386__) || defined(__x86_64__) || defined(_M_X64) || defined(_X86_) 60 | typedef details::FPDenormalsIgnoreHintScope FPDenormalsIgnoreHintScope; 61 | #define OPENCV_SUPPORTS_FP_DENORMALS_HINT 1 62 | #else 63 | #define OPENCV_SUPPORTS_FP_DENORMALS_HINT 0 64 | typedef details::FPDenormalsIgnoreHintScopeNOOP FPDenormalsIgnoreHintScope; 65 | #endif 66 | 67 | } // namespace cv 68 | 69 | #endif // OPENCV_CORE_FP_CONTROL_UTILS_HPP 70 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/utils/logger.defines.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_LOGGER_DEFINES_HPP 6 | #define OPENCV_LOGGER_DEFINES_HPP 7 | 8 | //! @addtogroup core_logging 9 | //! @{ 10 | 11 | // Supported logging levels and their semantic 12 | #define CV_LOG_LEVEL_SILENT 0 //!< for using in setLogLevel() call 13 | #define CV_LOG_LEVEL_FATAL 1 //!< Fatal (critical) error (unrecoverable internal error) 14 | #define CV_LOG_LEVEL_ERROR 2 //!< Error message 15 | #define CV_LOG_LEVEL_WARN 3 //!< Warning message 16 | #define CV_LOG_LEVEL_INFO 4 //!< Info message 17 | #define CV_LOG_LEVEL_DEBUG 5 //!< Debug message. Disabled in the "Release" build. 18 | #define CV_LOG_LEVEL_VERBOSE 6 //!< Verbose (trace) messages. Requires verbosity level. Disabled in the "Release" build. 19 | 20 | namespace cv { 21 | namespace utils { 22 | namespace logging { 23 | 24 | //! Supported logging levels and their semantic 25 | enum LogLevel { 26 | LOG_LEVEL_SILENT = 0, //!< for using in setLogVevel() call 27 | LOG_LEVEL_FATAL = 1, //!< Fatal (critical) error (unrecoverable internal error) 28 | LOG_LEVEL_ERROR = 2, //!< Error message 29 | LOG_LEVEL_WARNING = 3, //!< Warning message 30 | LOG_LEVEL_INFO = 4, //!< Info message 31 | LOG_LEVEL_DEBUG = 5, //!< Debug message. Disabled in the "Release" build. 32 | LOG_LEVEL_VERBOSE = 6, //!< Verbose (trace) messages. Requires verbosity level. Disabled in the "Release" build. 33 | #ifndef CV_DOXYGEN 34 | ENUM_LOG_LEVEL_FORCE_INT = INT_MAX 35 | #endif 36 | }; 37 | 38 | }}} // namespace 39 | 40 | //! @} 41 | 42 | #endif // OPENCV_LOGGER_DEFINES_HPP 43 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/utils/logtag.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_CORE_LOGTAG_HPP 6 | #define OPENCV_CORE_LOGTAG_HPP 7 | 8 | #include "opencv2/core/cvstd.hpp" 9 | #include "logger.defines.hpp" 10 | 11 | namespace cv { 12 | namespace utils { 13 | namespace logging { 14 | 15 | struct LogTag 16 | { 17 | const char* name; 18 | LogLevel level; 19 | 20 | inline LogTag(const char* _name, LogLevel _level) 21 | : name(_name) 22 | , level(_level) 23 | {} 24 | }; 25 | 26 | }}} 27 | 28 | #endif 29 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/core/version.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_VERSION_HPP 6 | #define OPENCV_VERSION_HPP 7 | 8 | #define CV_VERSION_MAJOR 4 9 | #define CV_VERSION_MINOR 6 10 | #define CV_VERSION_REVISION 0 11 | #define CV_VERSION_STATUS "" 12 | 13 | #define CVAUX_STR_EXP(__A) #__A 14 | #define CVAUX_STR(__A) CVAUX_STR_EXP(__A) 15 | 16 | #define CVAUX_STRW_EXP(__A) L ## #__A 17 | #define CVAUX_STRW(__A) CVAUX_STRW_EXP(__A) 18 | 19 | #define CV_VERSION CVAUX_STR(CV_VERSION_MAJOR) "." CVAUX_STR(CV_VERSION_MINOR) "." CVAUX_STR(CV_VERSION_REVISION) CV_VERSION_STATUS 20 | 21 | /* old style version constants*/ 22 | #define CV_MAJOR_VERSION CV_VERSION_MAJOR 23 | #define CV_MINOR_VERSION CV_VERSION_MINOR 24 | #define CV_SUBMINOR_VERSION CV_VERSION_REVISION 25 | 26 | #endif // OPENCV_VERSION_HPP 27 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/features2d/features2d.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 14 | // Copyright (C) 2009, Willow Garage Inc., all rights reserved. 15 | // Copyright (C) 2013, OpenCV Foundation, all rights reserved. 16 | // Third party copyrights are property of their respective owners. 17 | // 18 | // Redistribution and use in source and binary forms, with or without modification, 19 | // are permitted provided that the following conditions are met: 20 | // 21 | // * Redistribution's of source code must retain the above copyright notice, 22 | // this list of conditions and the following disclaimer. 23 | // 24 | // * Redistribution's in binary form must reproduce the above copyright notice, 25 | // this list of conditions and the following disclaimer in the documentation 26 | // and/or other materials provided with the distribution. 27 | // 28 | // * The name of the copyright holders may not be used to endorse or promote products 29 | // derived from this software without specific prior written permission. 30 | // 31 | // This software is provided by the copyright holders and contributors "as is" and 32 | // any express or implied warranties, including, but not limited to, the implied 33 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 34 | // In no event shall the Intel Corporation or contributors be liable for any direct, 35 | // indirect, incidental, special, exemplary, or consequential damages 36 | // (including, but not limited to, procurement of substitute goods or services; 37 | // loss of use, data, or profits; or business interruption) however caused 38 | // and on any theory of liability, whether in contract, strict liability, 39 | // or tort (including negligence or otherwise) arising in any way out of 40 | // the use of this software, even if advised of the possibility of such damage. 41 | // 42 | //M*/ 43 | 44 | #ifdef __OPENCV_BUILD 45 | #error this is a compatibility header which should not be used inside the OpenCV library 46 | #endif 47 | 48 | #include "opencv2/features2d.hpp" 49 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/features2d/hal/interface.h: -------------------------------------------------------------------------------- 1 | #ifndef OPENCV_FEATURE2D_HAL_INTERFACE_H 2 | #define OPENCV_FEATURE2D_HAL_INTERFACE_H 3 | 4 | #include "opencv2/core/cvdef.h" 5 | //! @addtogroup features2d_hal_interface 6 | //! @{ 7 | 8 | //! @name Fast feature detector types 9 | //! @sa cv::FastFeatureDetector 10 | //! @{ 11 | #define CV_HAL_TYPE_5_8 0 12 | #define CV_HAL_TYPE_7_12 1 13 | #define CV_HAL_TYPE_9_16 2 14 | //! @} 15 | 16 | //! @name Key point 17 | //! @sa cv::KeyPoint 18 | //! @{ 19 | struct CV_EXPORTS cvhalKeyPoint 20 | { 21 | float x; 22 | float y; 23 | float size; 24 | float angle; 25 | float response; 26 | int octave; 27 | int class_id; 28 | }; 29 | //! @} 30 | 31 | //! @} 32 | 33 | #endif 34 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/highgui.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2021 nihui 3 | // 4 | // Licensed under the Apache License, Version 2.0 (the "License"); 5 | // you may not use this file except in compliance with the License. 6 | // You may obtain a copy of the License at 7 | // 8 | // http://www.apache.org/licenses/LICENSE-2.0 9 | // 10 | // Unless required by applicable law or agreed to in writing, software 11 | // distributed under the License is distributed on an "AS IS" BASIS, 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | // See the License for the specific language governing permissions and 14 | // limitations under the License. 15 | // 16 | 17 | #include "opencv2/highgui/highgui.hpp" 18 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/highgui/highgui.hpp: -------------------------------------------------------------------------------- 1 | // 2 | // Copyright (C) 2021 nihui 3 | // 4 | // Licensed under the Apache License, Version 2.0 (the "License"); 5 | // you may not use this file except in compliance with the License. 6 | // You may obtain a copy of the License at 7 | // 8 | // http://www.apache.org/licenses/LICENSE-2.0 9 | // 10 | // Unless required by applicable law or agreed to in writing, software 11 | // distributed under the License is distributed on an "AS IS" BASIS, 12 | // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 | // See the License for the specific language governing permissions and 14 | // limitations under the License. 15 | // 16 | 17 | #ifndef OPENCV_HIGHGUI_HPP 18 | #define OPENCV_HIGHGUI_HPP 19 | 20 | #include "opencv2/core.hpp" 21 | 22 | enum 23 | { 24 | CV_LOAD_IMAGE_UNCHANGED = -1, 25 | CV_LOAD_IMAGE_GRAYSCALE = 0, 26 | CV_LOAD_IMAGE_COLOR = 1, 27 | }; 28 | 29 | enum 30 | { 31 | CV_IMWRITE_JPEG_QUALITY = 1 32 | }; 33 | 34 | namespace cv { 35 | 36 | enum ImreadModes 37 | { 38 | IMREAD_UNCHANGED = -1, 39 | IMREAD_GRAYSCALE = 0, 40 | IMREAD_COLOR = 1 41 | }; 42 | 43 | enum ImwriteFlags 44 | { 45 | IMWRITE_JPEG_QUALITY = 1 46 | }; 47 | 48 | CV_EXPORTS_W Mat imread(const String& filename, int flags = IMREAD_COLOR); 49 | 50 | CV_EXPORTS_W bool imwrite(const String& filename, InputArray img, const std::vector& params = std::vector()); 51 | 52 | CV_EXPORTS_W Mat imdecode(InputArray buf, int flags); 53 | 54 | CV_EXPORTS_W bool imencode(const String& ext, InputArray img, CV_OUT std::vector& buf, const std::vector& params = std::vector()); 55 | 56 | CV_EXPORTS_W void imshow(const String& winname, InputArray mat); 57 | 58 | CV_EXPORTS_W int waitKey(int delay = 0); 59 | 60 | } // namespace cv 61 | 62 | #endif // OPENCV_HIGHGUI_HPP 63 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/imgproc/bindings.hpp: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_IMGPROC_BINDINGS_HPP 6 | #define OPENCV_IMGPROC_BINDINGS_HPP 7 | 8 | // This file contains special overloads for OpenCV bindings 9 | // No need to use these functions in C++ code. 10 | 11 | namespace cv { 12 | 13 | /** @brief Finds lines in a binary image using the standard Hough transform and get accumulator. 14 | * 15 | * @note This function is for bindings use only. Use original function in C++ code 16 | * 17 | * @sa HoughLines 18 | */ 19 | CV_WRAP static inline 20 | void HoughLinesWithAccumulator( 21 | InputArray image, OutputArray lines, 22 | double rho, double theta, int threshold, 23 | double srn = 0, double stn = 0, 24 | double min_theta = 0, double max_theta = CV_PI 25 | ) 26 | { 27 | std::vector lines_acc; 28 | HoughLines(image, lines_acc, rho, theta, threshold, srn, stn, min_theta, max_theta); 29 | Mat(lines_acc).copyTo(lines); 30 | } 31 | 32 | } // namespace 33 | 34 | #endif // OPENCV_IMGPROC_BINDINGS_HPP 35 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/imgproc/hal/interface.h: -------------------------------------------------------------------------------- 1 | #ifndef OPENCV_IMGPROC_HAL_INTERFACE_H 2 | #define OPENCV_IMGPROC_HAL_INTERFACE_H 3 | 4 | //! @addtogroup imgproc_hal_interface 5 | //! @{ 6 | 7 | //! @name Interpolation modes 8 | //! @sa cv::InterpolationFlags 9 | //! @{ 10 | #define CV_HAL_INTER_NEAREST 0 11 | #define CV_HAL_INTER_LINEAR 1 12 | #define CV_HAL_INTER_CUBIC 2 13 | #define CV_HAL_INTER_AREA 3 14 | #define CV_HAL_INTER_LANCZOS4 4 15 | //! @} 16 | 17 | //! @name Morphology operations 18 | //! @sa cv::MorphTypes 19 | //! @{ 20 | #define CV_HAL_MORPH_ERODE 0 21 | #define CV_HAL_MORPH_DILATE 1 22 | //! @} 23 | 24 | //! @name Threshold types 25 | //! @sa cv::ThresholdTypes 26 | //! @{ 27 | #define CV_HAL_THRESH_BINARY 0 28 | #define CV_HAL_THRESH_BINARY_INV 1 29 | #define CV_HAL_THRESH_TRUNC 2 30 | #define CV_HAL_THRESH_TOZERO 3 31 | #define CV_HAL_THRESH_TOZERO_INV 4 32 | #define CV_HAL_THRESH_MASK 7 33 | #define CV_HAL_THRESH_OTSU 8 34 | #define CV_HAL_THRESH_TRIANGLE 16 35 | //! @} 36 | 37 | //! @name Adaptive threshold algorithm 38 | //! @sa cv::AdaptiveThresholdTypes 39 | //! @{ 40 | #define CV_HAL_ADAPTIVE_THRESH_MEAN_C 0 41 | #define CV_HAL_ADAPTIVE_THRESH_GAUSSIAN_C 1 42 | //! @} 43 | 44 | //! @} 45 | 46 | #endif 47 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/imgproc/imgproc.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 14 | // Copyright (C) 2009, Willow Garage Inc., all rights reserved. 15 | // Copyright (C) 2013, OpenCV Foundation, all rights reserved. 16 | // Third party copyrights are property of their respective owners. 17 | // 18 | // Redistribution and use in source and binary forms, with or without modification, 19 | // are permitted provided that the following conditions are met: 20 | // 21 | // * Redistribution's of source code must retain the above copyright notice, 22 | // this list of conditions and the following disclaimer. 23 | // 24 | // * Redistribution's in binary form must reproduce the above copyright notice, 25 | // this list of conditions and the following disclaimer in the documentation 26 | // and/or other materials provided with the distribution. 27 | // 28 | // * The name of the copyright holders may not be used to endorse or promote products 29 | // derived from this software without specific prior written permission. 30 | // 31 | // This software is provided by the copyright holders and contributors "as is" and 32 | // any express or implied warranties, including, but not limited to, the implied 33 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 34 | // In no event shall the Intel Corporation or contributors be liable for any direct, 35 | // indirect, incidental, special, exemplary, or consequential damages 36 | // (including, but not limited to, procurement of substitute goods or services; 37 | // loss of use, data, or profits; or business interruption) however caused 38 | // and on any theory of liability, whether in contract, strict liability, 39 | // or tort (including negligence or otherwise) arising in any way out of 40 | // the use of this software, even if advised of the possibility of such damage. 41 | // 42 | //M*/ 43 | 44 | #ifdef __OPENCV_BUILD 45 | #error this is a compatibility header which should not be used inside the OpenCV library 46 | #endif 47 | 48 | #include "opencv2/imgproc.hpp" 49 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/opencv_modules.hpp: -------------------------------------------------------------------------------- 1 | /* 2 | * ** File generated automatically, do not modify ** 3 | * 4 | * This file defines the list of modules available in current build configuration 5 | * 6 | * 7 | */ 8 | 9 | // This definition means that OpenCV is built with enabled non-free code. 10 | // For example, patented algorithms for non-profit/non-commercial use only. 11 | /* #undef OPENCV_ENABLE_NONFREE */ 12 | 13 | #define HAVE_OPENCV_CORE 14 | #define HAVE_OPENCV_FEATURES2D 15 | #define HAVE_OPENCV_HIGHGUI 16 | #define HAVE_OPENCV_IMGPROC 17 | #define HAVE_OPENCV_PHOTO 18 | #define HAVE_OPENCV_VIDEO 19 | 20 | 21 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/photo/legacy/constants_c.h: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_PHOTO_LEGACY_CONSTANTS_H 6 | #define OPENCV_PHOTO_LEGACY_CONSTANTS_H 7 | 8 | enum InpaintingModes 9 | { 10 | CV_INPAINT_NS =0, 11 | CV_INPAINT_TELEA =1 12 | }; 13 | 14 | #endif // OPENCV_PHOTO_LEGACY_CONSTANTS_H 15 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/photo/photo.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 14 | // Copyright (C) 2009, Willow Garage Inc., all rights reserved. 15 | // Copyright (C) 2013, OpenCV Foundation, all rights reserved. 16 | // Third party copyrights are property of their respective owners. 17 | // 18 | // Redistribution and use in source and binary forms, with or without modification, 19 | // are permitted provided that the following conditions are met: 20 | // 21 | // * Redistribution's of source code must retain the above copyright notice, 22 | // this list of conditions and the following disclaimer. 23 | // 24 | // * Redistribution's in binary form must reproduce the above copyright notice, 25 | // this list of conditions and the following disclaimer in the documentation 26 | // and/or other materials provided with the distribution. 27 | // 28 | // * The name of the copyright holders may not be used to endorse or promote products 29 | // derived from this software without specific prior written permission. 30 | // 31 | // This software is provided by the copyright holders and contributors "as is" and 32 | // any express or implied warranties, including, but not limited to, the implied 33 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 34 | // In no event shall the Intel Corporation or contributors be liable for any direct, 35 | // indirect, incidental, special, exemplary, or consequential damages 36 | // (including, but not limited to, procurement of substitute goods or services; 37 | // loss of use, data, or profits; or business interruption) however caused 38 | // and on any theory of liability, whether in contract, strict liability, 39 | // or tort (including negligence or otherwise) arising in any way out of 40 | // the use of this software, even if advised of the possibility of such damage. 41 | // 42 | //M*/ 43 | 44 | #ifdef __OPENCV_BUILD 45 | #error this is a compatibility header which should not be used inside the OpenCV library 46 | #endif 47 | 48 | #include "opencv2/photo.hpp" 49 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/video/legacy/constants_c.h: -------------------------------------------------------------------------------- 1 | // This file is part of OpenCV project. 2 | // It is subject to the license terms in the LICENSE file found in the top-level directory 3 | // of this distribution and at http://opencv.org/license.html. 4 | 5 | #ifndef OPENCV_VIDEO_LEGACY_CONSTANTS_H 6 | #define OPENCV_VIDEO_LEGACY_CONSTANTS_H 7 | 8 | enum 9 | { 10 | CV_LKFLOW_PYR_A_READY = 1, 11 | CV_LKFLOW_PYR_B_READY = 2, 12 | CV_LKFLOW_INITIAL_GUESSES = 4, 13 | CV_LKFLOW_GET_MIN_EIGENVALS = 8 14 | }; 15 | 16 | #endif // OPENCV_VIDEO_LEGACY_CONSTANTS_H 17 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/jni/include/opencv2/video/video.hpp: -------------------------------------------------------------------------------- 1 | /*M/////////////////////////////////////////////////////////////////////////////////////// 2 | // 3 | // IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING. 4 | // 5 | // By downloading, copying, installing or using the software you agree to this license. 6 | // If you do not agree to this license, do not download, install, 7 | // copy or use the software. 8 | // 9 | // 10 | // License Agreement 11 | // For Open Source Computer Vision Library 12 | // 13 | // Copyright (C) 2000-2008, Intel Corporation, all rights reserved. 14 | // Copyright (C) 2009, Willow Garage Inc., all rights reserved. 15 | // Copyright (C) 2013, OpenCV Foundation, all rights reserved. 16 | // Third party copyrights are property of their respective owners. 17 | // 18 | // Redistribution and use in source and binary forms, with or without modification, 19 | // are permitted provided that the following conditions are met: 20 | // 21 | // * Redistribution's of source code must retain the above copyright notice, 22 | // this list of conditions and the following disclaimer. 23 | // 24 | // * Redistribution's in binary form must reproduce the above copyright notice, 25 | // this list of conditions and the following disclaimer in the documentation 26 | // and/or other materials provided with the distribution. 27 | // 28 | // * The name of the copyright holders may not be used to endorse or promote products 29 | // derived from this software without specific prior written permission. 30 | // 31 | // This software is provided by the copyright holders and contributors "as is" and 32 | // any express or implied warranties, including, but not limited to, the implied 33 | // warranties of merchantability and fitness for a particular purpose are disclaimed. 34 | // In no event shall the Intel Corporation or contributors be liable for any direct, 35 | // indirect, incidental, special, exemplary, or consequential damages 36 | // (including, but not limited to, procurement of substitute goods or services; 37 | // loss of use, data, or profits; or business interruption) however caused 38 | // and on any theory of liability, whether in contract, strict liability, 39 | // or tort (including negligence or otherwise) arising in any way out of 40 | // the use of this software, even if advised of the possibility of such damage. 41 | // 42 | //M*/ 43 | 44 | #ifdef __OPENCV_BUILD 45 | #error this is a compatibility header which should not be used inside the OpenCV library 46 | #endif 47 | 48 | #include "opencv2/video.hpp" 49 | -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_core.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_core.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_features2d.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_features2d.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_highgui.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_highgui.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_imgproc.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_imgproc.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_photo.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_photo.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_video.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/arm64-v8a/libopencv_video.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_core.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_core.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_features2d.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_features2d.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_highgui.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_highgui.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_imgproc.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_imgproc.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_photo.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_photo.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_video.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/armeabi-v7a/libopencv_video.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_core.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_core.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_features2d.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_features2d.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_highgui.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_highgui.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_imgproc.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_imgproc.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_photo.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_photo.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_video.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86/libopencv_video.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_core.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_core.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_features2d.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_features2d.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_highgui.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_highgui.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_imgproc.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_imgproc.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_photo.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_photo.a -------------------------------------------------------------------------------- /app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_video.a: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/opencv-mobile-4.6.0-android/sdk/native/staticlibs/x86_64/libopencv_video.a -------------------------------------------------------------------------------- /app/src/main/jni/yolo.h: -------------------------------------------------------------------------------- 1 | // Tencent is pleased to support the open source community by making ncnn available. 2 | // 3 | // Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved. 4 | // 5 | // Licensed under the BSD 3-Clause License (the "License"); you may not use this file except 6 | // in compliance with the License. You may obtain a copy of the License at 7 | // 8 | // https://opensource.org/licenses/BSD-3-Clause 9 | // 10 | // Unless required by applicable law or agreed to in writing, software distributed 11 | // under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR 12 | // CONDITIONS OF ANY KIND, either express or implied. See the License for the 13 | // specific language governing permissions and limitations under the License. 14 | 15 | #ifndef YOLOV8_SEG_H 16 | #define YOLOV8_SEG_H 17 | 18 | #include 19 | 20 | #include 21 | 22 | struct Object 23 | { 24 | cv::Rect_ rect; 25 | int label; 26 | float prob; 27 | cv::Mat mask; 28 | std::vector mask_feat; 29 | }; 30 | struct GridAndStride 31 | { 32 | int grid0; 33 | int grid1; 34 | int stride; 35 | }; 36 | class Yolo 37 | { 38 | public: 39 | Yolo(); 40 | 41 | int load(const char* modeltype, int target_size, const float* mean_vals, const float* norm_vals, bool use_gpu = false); 42 | 43 | int load(AAssetManager* mgr, const char* modeltype, int target_size, const float* mean_vals, const float* norm_vals, bool use_gpu = false); 44 | 45 | int detect(const cv::Mat& rgb, std::vector& objects, float prob_threshold = 0.4f, float nms_threshold = 0.5f); 46 | 47 | int draw(cv::Mat& rgb, const std::vector& objects); 48 | 49 | private: 50 | ncnn::Net yolo; 51 | 52 | int target_size; 53 | float mean_vals[3]; 54 | float norm_vals[3]; 55 | int image_w; 56 | int image_h; 57 | int in_w; 58 | int in_h; 59 | 60 | ncnn::UnlockedPoolAllocator blob_pool_allocator; 61 | ncnn::PoolAllocator workspace_pool_allocator; 62 | }; 63 | 64 | #endif // YOLOV8_SEG_H 65 | -------------------------------------------------------------------------------- /app/src/main/jni/yolo.zip: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Digital2Slave/ncnn-android-yolov8-seg/635645712f319c11ac9e6ca6ec7b7a0616db67d4/app/src/main/jni/yolo.zip -------------------------------------------------------------------------------- /app/src/main/res/layout/main.xml: -------------------------------------------------------------------------------- 1 | 2 | 6 | 7 | 11 | 12 |