diff --git a/CHANGELOG.md b/CHANGELOG.md index f91b9116406..25adf454818 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ * Map C++ JIT classes and functions of TorchScript in presets for PyTorch ([issue #1068](https://github.com/bytedeco/javacpp-presets/issues/1068)) * Synchronize `cachePackage()` and prevent repeated package caching in all presets ([pull #1071](https://github.com/bytedeco/javacpp-presets/pull/1071)) * Build FFmpeg with VA-API enabled and bundle its libraries to avoid loading issues ([issue bytedeco/javacv#1188](https://github.com/bytedeco/javacv/issues/1188)) - * Upgrade presets for OpenCV 4.5.5, FFmpeg 4.4.1, librealsense2 2.50.0, Arrow 6.0.1, MKL 2022.0, DNNL 2.5.1, OpenBLAS 0.3.19, FFTW 3.3.10, CPython 3.10.1, NumPy 1.22.0, SciPy 1.8.0, Gym 0.21.0, LLVM 13.0.0, libpostal 1.1, Leptonica 1.82.0, Tesseract 5.0.0, CUDA 11.4.2, cuDNN 8.2.4, NCCL 2.11.4, MXNet 1.9.0, PyTorch 1.10.1, TensorFlow Lite 2.7.0, ALE 0.7.3, DepthAI 2.13.3, ONNX 1.10.2, ONNX Runtime 1.10.0, TVM 0.8.0, ModSecurity 3.0.6, and their dependencies + * Upgrade presets for OpenCV 4.5.5, FFmpeg 4.4.1, librealsense2 2.50.0, Arrow 6.0.1, MKL 2022.0, DNNL 2.5.1, OpenBLAS 0.3.19, FFTW 3.3.10, CPython 3.10.1, NumPy 1.22.0, SciPy 1.8.0, Gym 0.21.0, LLVM 13.0.0, libpostal 1.1, Leptonica 1.82.0, Tesseract 5.0.1, CUDA 11.4.2, cuDNN 8.2.4, NCCL 2.11.4, MXNet 1.9.0, PyTorch 1.10.1, TensorFlow Lite 2.7.0, ALE 0.7.3, DepthAI 2.14.0, ONNX 1.10.2, ONNX Runtime 1.10.0, TVM 0.8.0, ModSecurity 3.0.6, and their dependencies ### August 2, 2021 version 1.5.6 * Change `opencv_core.Mat` constructors to create column vectors out of arrays for consistency ([issue #1064](https://github.com/bytedeco/javacpp-presets/issues/1064)) diff --git a/README.md b/README.md index cd66a3191c0..636397e3783 100644 --- a/README.md +++ b/README.md @@ -204,14 +204,14 @@ Each child module in turn relies by default on the included [`cppbuild.sh` scrip * libffi 3.4.x https://github.com/libffi/libffi * libpostal 1.1 https://github.com/openvenues/libpostal * Leptonica 1.82.x http://www.leptonica.org/download.html - * Tesseract 5.0.0 https://github.com/tesseract-ocr/tesseract + * Tesseract 5.0.x https://github.com/tesseract-ocr/tesseract * Caffe 1.0 https://github.com/BVLC/caffe * OpenPose 1.7.0 https://github.com/CMU-Perceptual-Computing-Lab/openpose * CUDA 11.4.x https://developer.nvidia.com/cuda-downloads * cuDNN 8.2.x https://developer.nvidia.com/cudnn * NCCL 2.11.x https://developer.nvidia.com/nccl * NVIDIA Video Codec SDK 11.1.x https://developer.nvidia.com/nvidia-video-codec-sdk - * OpenCL 3.0 https://github.com/KhronosGroup/OpenCL-ICD-Loader + * OpenCL 3.0.x https://github.com/KhronosGroup/OpenCL-ICD-Loader * MXNet 1.9.0 https://github.com/apache/incubator-mxnet * PyTorch 1.10.x https://github.com/pytorch/pytorch * TensorFlow 1.15.x https://github.com/tensorflow/tensorflow @@ -219,7 +219,7 @@ Each child module in turn relies by default on the included [`cppbuild.sh` scrip * TensorRT 8.x https://developer.nvidia.com/tensorrt * Triton Inference Server 2.17.x https://developer.nvidia.com/nvidia-triton-inference-server * The Arcade Learning Environment 0.7.x https://github.com/mgbellemare/Arcade-Learning-Environment - * DepthAI 2.13.x https://github.com/luxonis/depthai-core + * DepthAI 2.14.x https://github.com/luxonis/depthai-core * ONNX 1.10.x https://github.com/onnx/onnx * nGraph 0.26.0 https://github.com/NervanaSystems/ngraph * ONNX Runtime 1.10.x https://github.com/microsoft/onnxruntime diff --git a/depthai/README.md b/depthai/README.md index d59fa69eaa9..b77e16e258d 100644 --- a/depthai/README.md +++ b/depthai/README.md @@ -9,7 +9,7 @@ Introduction ------------ This directory contains the JavaCPP Presets module for: - * DepthAI 2.13.3 https://luxonis.com/depthai + * DepthAI 2.14.0 https://luxonis.com/depthai Please refer to the parent README.md file for more detailed information about the JavaCPP Presets. @@ -46,7 +46,7 @@ We can use [Maven 3](http://maven.apache.org/) to download and install automatic org.bytedeco depthai-platform - 2.13.3-1.5.7-SNAPSHOT + 2.14.0-1.5.7-SNAPSHOT org.bytedeco diff --git a/depthai/cppbuild.sh b/depthai/cppbuild.sh index a839690478e..dee4eb1d344 100755 --- a/depthai/cppbuild.sh +++ b/depthai/cppbuild.sh @@ -7,7 +7,7 @@ if [[ -z "$PLATFORM" ]]; then exit fi -DEPTHAI_VERSION=2.13.3 +DEPTHAI_VERSION=2.14.0 LIBUSB_VERSION=1.0.22 download https://github.com/luxonis/depthai-core/releases/download/v$DEPTHAI_VERSION/depthai-core-v$DEPTHAI_VERSION.tar.gz depthai-core-v$DEPTHAI_VERSION.tar.gz download http://sourceforge.net/projects/libusb/files/libusb-1.0/libusb-$LIBUSB_VERSION/libusb-$LIBUSB_VERSION.tar.bz2/download libusb-$LIBUSB_VERSION.tar.bz2 diff --git a/depthai/platform/pom.xml b/depthai/platform/pom.xml index 3b1c9fffd6c..775e3553c32 100644 --- a/depthai/platform/pom.xml +++ b/depthai/platform/pom.xml @@ -12,7 +12,7 @@ org.bytedeco depthai-platform - 2.13.3-${project.parent.version} + 2.14.0-${project.parent.version} JavaCPP Presets Platform for DepthAI diff --git a/depthai/pom.xml b/depthai/pom.xml index 50bed053ffc..9a04254e15f 100644 --- a/depthai/pom.xml +++ b/depthai/pom.xml @@ -11,7 +11,7 @@ org.bytedeco depthai - 2.13.3-${project.parent.version} + 2.14.0-${project.parent.version} JavaCPP Presets for DepthAI diff --git a/depthai/samples/pom.xml b/depthai/samples/pom.xml index 7024a75f949..bc3fb6095a1 100644 --- a/depthai/samples/pom.xml +++ b/depthai/samples/pom.xml @@ -12,7 +12,7 @@ org.bytedeco depthai-platform - 2.13.3-1.5.7-SNAPSHOT + 2.14.0-1.5.7-SNAPSHOT org.bytedeco diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ColorCamera.java b/depthai/src/gen/java/org/bytedeco/depthai/ColorCamera.java index 280b2bd2f70..ddaca435202 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ColorCamera.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ColorCamera.java @@ -21,20 +21,24 @@ * \brief ColorCamera node. For use with color sensors. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ColorCamera extends Node { +public class ColorCamera extends ColorCameraPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public ColorCamera(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - - public native int getScaledSize(int input, int num, int denom); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); /** * Constructs ColorCamera node. */ public ColorCamera(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public ColorCamera(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ColorCameraProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ColorCameraProperties props); + + /** + * Computes the scaled size given numerator and denominator + */ + public native int getScaledSize(int input, int num, int denom); /** * Initial control options to apply to sensor @@ -42,7 +46,7 @@ public class ColorCamera extends Node { @MemberGetter public native @ByRef CameraControl initialControl(); /** - * Input for ImageManipConfig message, which can modify crop paremeters in runtime + * Input for ImageManipConfig message, which can modify crop parameters in runtime * * Default queue is non-blocking with size 8 */ @@ -255,13 +259,13 @@ public class ColorCamera extends Node { * before sending out a frame. * @param wait True to wait for inputConfig message, false otherwise */ - public native void setWaitForConfigInput(@Cast("bool") boolean _wait); + public native @Deprecated void setWaitForConfigInput(@Cast("bool") boolean _wait); /** * @see setWaitForConfigInput * @return True if wait for inputConfig message, false otherwise */ - public native @Cast("bool") boolean getWaitForConfigInput(); + public native @Cast("bool") @Deprecated boolean getWaitForConfigInput(); /** * Specifies whether preview output should preserve aspect ratio, diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraProperties.java index 1be2ee79b05..7e7daca97c2 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for ColorCamera such as camera ID, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ColorCameraProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ColorCameraProperties extends ColorCameraPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public ColorCameraProperties() { super((Pointer)null); allocate(); } @@ -160,11 +160,6 @@ public enum ColorOrder { BGR(0), RGB(1); public native float sensorCropX(); public native ColorCameraProperties sensorCropX(float setter); public native float sensorCropY(); public native ColorCameraProperties sensorCropY(float setter); - /** - * Whether to wait for config at 'inputConfig' io - */ - public native @Cast("bool") boolean inputConfigSync(); public native ColorCameraProperties inputConfigSync(boolean setter); - /** * Whether to keep aspect ratio of input (video size) or not */ diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesNode.java new file mode 100644 index 00000000000..67116089330 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ColorCameraPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ColorCameraPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef ColorCameraProperties properties(); public native ColorCameraPropertiesNode properties(ColorCameraProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesSerializable.java new file mode 100644 index 00000000000..831b0f26c70 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ColorCameraPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ColorCameraPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public ColorCameraPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public ColorCameraPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ColorCameraPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public ColorCameraPropertiesSerializable position(long position) { + return (ColorCameraPropertiesSerializable)super.position(position); + } + @Override public ColorCameraPropertiesSerializable getPointer(long i) { + return new ColorCameraPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DaiProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/DaiProperties.java new file mode 100644 index 00000000000..4c651b515a0 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/DaiProperties.java @@ -0,0 +1,31 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + + +/** Base Properties structure */ +@Name("dai::Properties") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class DaiProperties extends Pointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public DaiProperties(Pointer p) { super(p); } + + public native void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + public native @UniquePtr DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetwork.java index 0e3d21d8eb8..8c5c00db4d3 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetwork.java @@ -21,34 +21,27 @@ * \brief DetectionNetwork, base for different network specializations */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class DetectionNetwork extends NeuralNetwork { +public class DetectionNetwork extends DetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public DetectionNetwork(Pointer p) { super(p); } - - public native @StdString @Override BytePointer getName(); - /** - * Input message with data to be infered upon - * Default queue is blocking with size 5 - */ - @MemberGetter public native @ByRef Input input(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); /** * Outputs ImgDetections message that carries parsed detection results. + * Overrides NeuralNetwork 'out' with ImgDetections output message type. */ @MemberGetter public native @ByRef Output out(); - /** - * Passthrough message on which the inference was performed. - * - * Suitable for when input queue is set to non-blocking behavior. - */ - @MemberGetter public native @ByRef Output passthrough(); - /** * Specifies confidence threshold at which to filter the rest of the detections. * @param thresh Detection confidence must be greater than specified threshold to be added to the list */ public native void setConfidenceThreshold(float thresh); + + /** + * Retrieves threshold at which to filter the rest of the detections. + * @return Detection confidence + */ + public native float getConfidenceThreshold(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkProperties.java index b4b1924cf2a..53b90c684bd 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkProperties.java @@ -21,7 +21,7 @@ * Specify properties for DetectionNetwork */ @Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class DetectionNetworkProperties extends NeuralNetworkProperties { +public class DetectionNetworkProperties extends DetectionNetworkPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public DetectionNetworkProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..5025fe06162 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class DetectionNetworkPropertiesNode extends NeuralNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public DetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef DetectionNetworkProperties properties(); public native DetectionNetworkPropertiesNode properties(DetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesSerializable.java new file mode 100644 index 00000000000..a7e4e2a5b02 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/DetectionNetworkPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class DetectionNetworkPropertiesSerializable extends NeuralNetworkProperties { + static { Loader.load(); } + /** Default native constructor. */ + public DetectionNetworkPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public DetectionNetworkPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public DetectionNetworkPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public DetectionNetworkPropertiesSerializable position(long position) { + return (DetectionNetworkPropertiesSerializable)super.position(position); + } + @Override public DetectionNetworkPropertiesSerializable getPointer(long i) { + return new DetectionNetworkPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/Device.java b/depthai/src/gen/java/org/bytedeco/depthai/Device.java index b4b9feb90eb..481cf8916ce 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/Device.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/Device.java @@ -259,7 +259,7 @@ public class Device extends DeviceBase { public native @ByVal StringVector getQueueEvents(@StdString String queueName); /** - * Gets or waits until any any queue has received a message + * Gets or waits until any queue has received a message * * @param maxNumEvents Maximum number of events to remove from queue. Default is unlimited * @param timeout Timeout after which return regardless. If negative then wait is indefinite. Default is -1 diff --git a/depthai/src/gen/java/org/bytedeco/depthai/DeviceBase.java b/depthai/src/gen/java/org/bytedeco/depthai/DeviceBase.java index f02ad683e09..a26550662cd 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/DeviceBase.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/DeviceBase.java @@ -339,7 +339,7 @@ public static class Config extends Pointer { public native @Cast("bool") boolean startPipeline(@Const @ByRef Pipeline pipeline); /** - * Sets the devices logging severity level. This level affects which logs are transfered from device to host. + * Sets the devices logging severity level. This level affects which logs are transferred from device to host. * * @param level Logging severity */ diff --git a/depthai/src/gen/java/org/bytedeco/depthai/GlobalProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/GlobalProperties.java index 743918cf782..f0eeb409b65 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/GlobalProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/GlobalProperties.java @@ -20,8 +20,8 @@ /** * Specify properties which apply for whole pipeline */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class GlobalProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class GlobalProperties extends GlobalPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public GlobalProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/GlobalPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/GlobalPropertiesSerializable.java new file mode 100644 index 00000000000..9b566c0bf47 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/GlobalPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class GlobalPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public GlobalPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public GlobalPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public GlobalPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public GlobalPropertiesSerializable position(long position) { + return (GlobalPropertiesSerializable)super.position(position); + } + @Override public GlobalPropertiesSerializable getPointer(long i) { + return new GlobalPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/IMU.java b/depthai/src/gen/java/org/bytedeco/depthai/IMU.java index 6e4aabdb3fb..c345f5cacb0 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/IMU.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/IMU.java @@ -21,18 +21,20 @@ * \brief IMU node for BNO08X. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class IMU extends Node { +public class IMU extends IMUPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public IMU(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); /** * Constructs IMU node. */ public IMU(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public IMU(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr IMUProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr IMUProperties props); /** * Outputs IMUData message that carries IMU packets. diff --git a/depthai/src/gen/java/org/bytedeco/depthai/IMUPacket.java b/depthai/src/gen/java/org/bytedeco/depthai/IMUPacket.java index bf4d65229e4..6a2af28690f 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/IMUPacket.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/IMUPacket.java @@ -18,6 +18,7 @@ // #if 0 + // #endif /** diff --git a/depthai/src/gen/java/org/bytedeco/depthai/IMUProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/IMUProperties.java index c2d0e114851..75e34936071 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/IMUProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/IMUProperties.java @@ -17,8 +17,8 @@ import static org.bytedeco.depthai.global.depthai.*; -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class IMUProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class IMUProperties extends IMUPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public IMUProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesNode.java new file mode 100644 index 00000000000..dd444931406 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesNode.java @@ -0,0 +1,31 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + + +// Node CRTP class +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class IMUPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public IMUPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef IMUProperties properties(); public native IMUPropertiesNode properties(IMUProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesSerializable.java new file mode 100644 index 00000000000..6213530a3b1 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/IMUPropertiesSerializable.java @@ -0,0 +1,44 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + + +/** Serializable properties */ +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class IMUPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public IMUPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public IMUPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public IMUPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public IMUPropertiesSerializable position(long position) { + return (IMUPropertiesSerializable)super.position(position); + } + @Override public IMUPropertiesSerializable getPointer(long i) { + return new IMUPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ImageManip.java b/depthai/src/gen/java/org/bytedeco/depthai/ImageManip.java index aed814ff3ab..25785834c9c 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ImageManip.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ImageManip.java @@ -21,15 +21,16 @@ * \brief ImageManip node. Capability to crop, resize, warp, ... incoming image frames */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ImageManip extends Node { +public class ImageManip extends ImageManipPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public ImageManip(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public ImageManip(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public ImageManip(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ImageManipProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ImageManipProperties props); /** * Initial config to use when manipulating frames @@ -68,9 +69,15 @@ public class ImageManip extends Node { // Functions to set properties /** * Specify whether or not wait until configuration message arrives to inputConfig Input. - * @param wait True to wait for configuration message, false otherwise + * @param wait True to wait for configuration message, false otherwise. + */ + public native @Deprecated void setWaitForConfigInput(@Cast("bool") boolean _wait); + + /** + * @see setWaitForConfigInput + * @return True if wait for inputConfig message, false otherwise */ - public native void setWaitForConfigInput(@Cast("bool") boolean _wait); + public native @Cast("bool") @Deprecated boolean getWaitForConfigInput(); /** * Specify number of frames in pool. diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipConfig.java b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipConfig.java index 45d655d73ed..ff519609fd3 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipConfig.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipConfig.java @@ -84,7 +84,7 @@ public class ImageManipConfig extends Buffer { public native void setCenterCrop(float ratio); /** - * Specifies warp by suppling 4 points in either absolute or normalized coordinates + * Specifies warp by supplying 4 points in either absolute or normalized coordinates * @param pt 4 points specifying warp * @param normalizedCoords If true pt is interpreted as normalized, absolute otherwise */ @@ -129,14 +129,14 @@ public class ImageManipConfig extends Buffer { public native void setRotationRadians(float rad); /** - * Specifies output image size. After crop stage the image will be streched to fit. + * Specifies output image size. After crop stage the image will be stretched to fit. * @param w Width in pixels * @param h Height in pixels */ public native void setResize(int w, int h); /** - * Specifies output image size. After crop stage the image will be streched to fit. + * Specifies output image size. After crop stage the image will be stretched to fit. * @param size Size in pixels */ public native void setResize(@ByVal @Cast("std::tuple*") Pointer size); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipProperties.java index 978de6ab157..95e3863314d 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for ImageManip */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ImageManipProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ImageManipProperties extends ImageManipPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public ImageManipProperties() { super((Pointer)null); allocate(); } @@ -41,9 +41,6 @@ public class ImageManipProperties extends Pointer { /** Initial configuration for ImageManip node */ public native @ByRef RawImageManipConfig initialConfig(); public native ImageManipProperties initialConfig(RawImageManipConfig setter); - /** Whether to wait for config at 'inputConfig' IO */ - public native @Cast("bool") boolean inputConfigSync(); public native ImageManipProperties inputConfigSync(boolean setter); - /** Maximum output frame size in bytes (eg: 300x300 BGR image -> 300*300*3 bytes) */ public native int outputFrameSize(); public native ImageManipProperties outputFrameSize(int setter); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesNode.java new file mode 100644 index 00000000000..f1d5da48826 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ImageManipPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ImageManipPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef ImageManipProperties properties(); public native ImageManipPropertiesNode properties(ImageManipProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesSerializable.java new file mode 100644 index 00000000000..f4494ee6730 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ImageManipPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ImageManipPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public ImageManipPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public ImageManipPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ImageManipPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public ImageManipPropertiesSerializable position(long position) { + return (ImageManipPropertiesSerializable)super.position(position); + } + @Override public ImageManipPropertiesSerializable getPointer(long i) { + return new ImageManipPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetwork.java index a6e2f7869c3..3841c822fca 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetwork.java @@ -21,11 +21,13 @@ * \brief MobileNetDetectionNetwork node. Parses MobileNet results */ @Namespace("dai::node") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class MobileNetDetectionNetwork extends DetectionNetwork { +public class MobileNetDetectionNetwork extends MobileNetDetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public MobileNetDetectionNetwork(Pointer p) { super(p); } public MobileNetDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public MobileNetDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr DetectionNetworkProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr DetectionNetworkProperties props); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..fd6acea5e2f --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetDetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class MobileNetDetectionNetworkPropertiesNode extends DetectionNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public MobileNetDetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef DetectionNetworkProperties properties(); public native MobileNetDetectionNetworkPropertiesNode properties(DetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetwork.java index 0d3b66ff084..3f630a2795c 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetwork.java @@ -21,7 +21,7 @@ * MobileNetSpatialDetectionNetwork node. Mobilenet-SSD based network with spatial location data. */ @Namespace("dai::node") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class MobileNetSpatialDetectionNetwork extends SpatialDetectionNetwork { +public class MobileNetSpatialDetectionNetwork extends MobileNetSpatialDetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public MobileNetSpatialDetectionNetwork(Pointer p) { super(p); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..19ee763250a --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/MobileNetSpatialDetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class MobileNetSpatialDetectionNetworkPropertiesNode extends SpatialDetectionNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public MobileNetSpatialDetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SpatialDetectionNetworkProperties properties(); public native MobileNetSpatialDetectionNetworkPropertiesNode properties(SpatialDetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MonoCamera.java b/depthai/src/gen/java/org/bytedeco/depthai/MonoCamera.java index 9fc68b160b1..7b4c32f8063 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/MonoCamera.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/MonoCamera.java @@ -21,15 +21,16 @@ * \brief MonoCamera node. For use with grayscale sensors. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class MonoCamera extends Node { +public class MonoCamera extends ColorCameraPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public MonoCamera(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public MonoCamera(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public MonoCamera(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr MonoCameraProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr MonoCameraProperties props); /** * Initial control options to apply to sensor diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraProperties.java index 44fde45dbc9..7963a42d471 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for MonoCamera such as camera ID, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class MonoCameraProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class MonoCameraProperties extends MonoCameraPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public MonoCameraProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraPropertiesSerializable.java new file mode 100644 index 00000000000..c1fdb9cb3c5 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/MonoCameraPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class MonoCameraPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public MonoCameraPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public MonoCameraPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public MonoCameraPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public MonoCameraPropertiesSerializable position(long position) { + return (MonoCameraPropertiesSerializable)super.position(position); + } + @Override public MonoCameraPropertiesSerializable getPointer(long i) { + return new MonoCameraPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NNData.java b/depthai/src/gen/java/org/bytedeco/depthai/NNData.java index 41ac51c9180..c5c54e0d8fe 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NNData.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NNData.java @@ -58,7 +58,7 @@ public class NNData extends Buffer { public native void setLayer(@StdString String name, @Cast("std::uint8_t*") @StdVector byte[] data); /** - * Set a layer with datatype U8. Integers are casted to bytes. + * Set a layer with datatype U8. Integers are cast to bytes. * @param name Name of the layer * @param data Data to store */ @@ -108,7 +108,7 @@ public class NNData extends Buffer { /** * Retrieve layers tensor information * @param name Name of the layer - * @param tensor [out] Outputs tensor infromation of that layer + * @param tensor [out] Outputs tensor information of that layer * @return True if layer exists, false otherwise */ public native @Cast("bool") boolean getLayer(@StdString BytePointer name, @ByRef TensorInfo tensor); @@ -137,7 +137,7 @@ public class NNData extends Buffer { // uint8 /** - * Convinience function to retrieve U8 data from layer + * Convenience function to retrieve U8 data from layer * @param name Name of the layer * @return U8 binary data */ @@ -146,7 +146,7 @@ public class NNData extends Buffer { // fp16 /** - * Convinience function to retrieve float values from layers FP16 tensor + * Convenience function to retrieve float values from layers FP16 tensor * @param name Name of the layer * @return Float data */ @@ -155,7 +155,7 @@ public class NNData extends Buffer { // int32 /** - * Convinience function to retrieve INT32 values from layers tensor + * Convenience function to retrieve INT32 values from layers tensor * @param name Name of the layer * @return INT32 data */ @@ -164,19 +164,19 @@ public class NNData extends Buffer { // first layer /** - * Convinience function to retrieve U8 data from first layer + * Convenience function to retrieve U8 data from first layer * @return U8 binary data */ public native @Cast("std::uint8_t*") @StdVector BytePointer getFirstLayerUInt8(); /** - * Convinience function to retrieve float values from first layers FP16 tensor + * Convenience function to retrieve float values from first layers FP16 tensor * @return Float data */ public native @StdVector FloatPointer getFirstLayerFp16(); /** - * Convinience function to retrieve INT32 values from first layers tensor + * Convenience function to retrieve INT32 values from first layers tensor * @return INT32 data */ public native @Cast("std::int32_t*") @StdVector IntPointer getFirstLayerInt32(); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetwork.java index 612319245ac..14fe26c8190 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetwork.java @@ -21,18 +21,19 @@ * \brief NeuralNetwork node. Runs a neural inference on input data. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class NeuralNetwork extends Node { +public class NeuralNetwork extends NeuralNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public NeuralNetwork(Pointer p) { super(p); } - - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public NeuralNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public NeuralNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr NeuralNetworkProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr NeuralNetworkProperties props); /** - * Input message with data to be infered upon + * Input message with data to be inferred upon * Default queue is blocking with size 5 */ @MemberGetter public native @ByRef Input input(); @@ -49,6 +50,17 @@ public class NeuralNetwork extends Node { */ @MemberGetter public native @ByRef Output passthrough(); + /** + * Inputs mapped to network inputs. Useful for infering from separate data sources + * Default input is non-blocking with queue size 1 and waits for messages + */ + @MemberGetter public native @ByRef InputMap inputs(); + + /** + * Passthroughs which correspond to specified input + */ + @MemberGetter public native @ByRef OutputMap passthroughs(); + // Specify local filesystem path to load the blob (which gets loaded at loadAssets) /** * Load network blob into assets and use once pipeline is started. @@ -60,7 +72,7 @@ public class NeuralNetwork extends Node { public native void setBlobPath(@StdString String path); /** - * Specifies how many frames will be avilable in the pool + * Specifies how many frames will be available in the pool * @param numFrames How many frames will pool have */ public native void setNumPoolFrames(int numFrames); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkProperties.java index de6091adb2a..7258606c9d4 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for NeuralNetwork such as blob path, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class NeuralNetworkProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class NeuralNetworkProperties extends NeuralNetworkPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public NeuralNetworkProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesNode.java new file mode 100644 index 00000000000..0e2a1c8ac8a --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class NeuralNetworkPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public NeuralNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef NeuralNetworkProperties properties(); public native NeuralNetworkPropertiesNode properties(NeuralNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesSerializable.java new file mode 100644 index 00000000000..2cffcfc2a5a --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/NeuralNetworkPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class NeuralNetworkPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public NeuralNetworkPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public NeuralNetworkPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public NeuralNetworkPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public NeuralNetworkPropertiesSerializable position(long position) { + return (NeuralNetworkPropertiesSerializable)super.position(position); + } + @Override public NeuralNetworkPropertiesSerializable getPointer(long i) { + return new NeuralNetworkPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/Node.java b/depthai/src/gen/java/org/bytedeco/depthai/Node.java index 730b9dd0020..cbe6304b0ee 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/Node.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/Node.java @@ -30,11 +30,17 @@ public class Node extends Pointer { // fwd declare classes - @MemberGetter public native @Cast("dai::Node::Output**") @StdVector PointerPointer outputs(); - @MemberGetter public native @Cast("dai::Node::Input**") @StdVector PointerPointer inputs(); + @MemberGetter public native @ByRef StringNodeOutputMap outputRefs(); + @MemberGetter public native @ByRef StringNodeInputMap inputRefs(); - @MemberGetter public native @Cast("dai::Node::OutputMap**") @StdVector PointerPointer outputMaps(); - @MemberGetter public native @Cast("dai::Node::InputMap**") @StdVector PointerPointer inputMaps(); + @MemberGetter public native @ByRef StringNodeOutputMapMap outputMapRefs(); + @MemberGetter public native @ByRef StringNodeInputMapMap inputMapRefs(); + + // helpers for setting refs + public native void setOutputRefs(Output outRef); + public native void setInputRefs(Input inRef); + public native void setOutputMapRefs(OutputMap outMapRef); + public native void setInputMapRefs(InputMap inMapRef); @NoOffset public static class DatatypeHierarchy extends Pointer { static { Loader.load(); } @@ -62,6 +68,7 @@ public enum Type { MSender(0), SSender(1); public Type intern() { for (Type e : values()) if (e.value == value) return e; return this; } @Override public String toString() { return intern().name(); } } + @MemberGetter public native @StdString BytePointer group(); @MemberGetter public native @StdString BytePointer name(); @MemberGetter public native Type type(); // Which types and do descendants count as well? @@ -70,10 +77,23 @@ public enum Type { MSender(0), SSender(1); private native void allocate(@ByRef Node par, @StdString BytePointer n, Type t, @StdVector DatatypeHierarchy types); public Output(@ByRef Node par, @StdString String n, @Cast("dai::Node::Output::Type") int t, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, n, t, types); } private native void allocate(@ByRef Node par, @StdString String n, @Cast("dai::Node::Output::Type") int t, @StdVector DatatypeHierarchy types); - public native @Cast("bool") boolean isSamePipeline(@Const @ByRef Input in); + public Output(@ByRef Node par, @StdString BytePointer group, @StdString BytePointer n, Type t, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, group, n, t, types); } + private native void allocate(@ByRef Node par, @StdString BytePointer group, @StdString BytePointer n, Type t, @StdVector DatatypeHierarchy types); + public Output(@ByRef Node par, @StdString String group, @StdString String n, @Cast("dai::Node::Output::Type") int t, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, group, n, t, types); } + private native void allocate(@ByRef Node par, @StdString String group, @StdString String n, @Cast("dai::Node::Output::Type") int t, @StdVector DatatypeHierarchy types); public native @ByRef Node getParent(); + /** Output to string representation */ + public native @StdString String toString(); + + /** + * Check if this output and given input are on the same pipeline. + * @see canConnect for checking if connection is possible + * @return True if output and input are on the same pipeline + */ + public native @Cast("bool") boolean isSamePipeline(@Const @ByRef Input in); + /** * Check if connection is possible * @param in Input to connect to @@ -116,6 +136,11 @@ public enum Type { MSender(0), SSender(1); /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public OutputMap(Pointer p) { super(p); } + @MemberGetter public native @StdString BytePointer name(); + public OutputMap(@StdString BytePointer name, @ByVal Output defaultOutput) { super((Pointer)null); allocate(name, defaultOutput); } + private native void allocate(@StdString BytePointer name, @ByVal Output defaultOutput); + public OutputMap(@StdString String name, @ByVal Output defaultOutput) { super((Pointer)null); allocate(name, defaultOutput); } + private native void allocate(@StdString String name, @ByVal Output defaultOutput); public OutputMap(@ByVal Output defaultOutput) { super((Pointer)null); allocate(defaultOutput); } private native void allocate(@ByVal Output defaultOutput); /** Create or modify an input */ @@ -136,12 +161,16 @@ public enum Type { SReceiver(0), MReceiver(1); public Type intern() { for (Type e : values()) if (e.value == value) return e; return this; } @Override public String toString() { return intern().name(); } } + @MemberGetter public native @StdString BytePointer group(); @MemberGetter public native @StdString BytePointer name(); @MemberGetter public native Type type(); @MemberGetter public native @Cast("bool") boolean defaultBlocking(); @MemberGetter public native int defaultQueueSize(); @MemberGetter public native @ByRef BoolOptional blocking(); @MemberGetter public native @ByRef @Cast("tl::optional*") IntOptional queueSize(); + // Options - more information about the input + @MemberGetter public native @ByRef BoolOptional waitForMessage(); + @MemberGetter public native @Cast("bool") boolean defaultWaitForMessage(); @MemberGetter public native @StdVector DatatypeHierarchy possibleDatatypes(); /** Constructs Input with default blocking and queueSize options */ @@ -156,8 +185,23 @@ public enum Type { SReceiver(0), MReceiver(1); public Input(@ByRef Node par, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, n, t, blocking, queueSize, types); } private native void allocate(@ByRef Node par, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @StdVector DatatypeHierarchy types); + /** Constructs Input with specified blocking and queueSize as well as additional options */ + public Input(@ByRef Node par, @StdString BytePointer n, Type t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, n, t, blocking, queueSize, waitForMessage, types); } + private native void allocate(@ByRef Node par, @StdString BytePointer n, Type t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types); + public Input(@ByRef Node par, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, n, t, blocking, queueSize, waitForMessage, types); } + private native void allocate(@ByRef Node par, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types); + + /** Constructs Input with specified blocking and queueSize as well as additional options */ + public Input(@ByRef Node par, @StdString BytePointer group, @StdString BytePointer n, Type t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, group, n, t, blocking, queueSize, waitForMessage, types); } + private native void allocate(@ByRef Node par, @StdString BytePointer group, @StdString BytePointer n, Type t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types); + public Input(@ByRef Node par, @StdString String group, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types) { super((Pointer)null); allocate(par, group, n, t, blocking, queueSize, waitForMessage, types); } + private native void allocate(@ByRef Node par, @StdString String group, @StdString String n, @Cast("dai::Node::Input::Type") int t, @Cast("bool") boolean blocking, int queueSize, @Cast("bool") boolean waitForMessage, @StdVector DatatypeHierarchy types); + public native @ByRef Node getParent(); + /** Input to string representation */ + public native @StdString String toString(); + /** * Overrides default input queue behavior. * @param blocking True blocking, false overwriting @@ -182,6 +226,30 @@ public enum Type { SReceiver(0), MReceiver(1); * @return Maximum input queue size */ public native int getQueueSize(); + + /** + * Overrides default wait for message behavior. + * Applicable for nodes with multiple inputs. + * Specifies behavior whether to wait for this input when a Node processes certain data or not. + * @param waitForMessage Whether to wait for message to arrive to this input or not + */ + public native void setWaitForMessage(@Cast("bool") boolean waitForMessage); + + /** + * Get behavior whether to wait for this input when a Node processes certain data or not + * @return Whether to wait for message to arrive to this input or not + */ + public native @Cast("bool") boolean getWaitForMessage(); + + /** + * Equaivalent to setWaitForMessage but with inverted logic. + */ + public native void setReusePreviousMessage(@Cast("bool") boolean reusePreviousMessage); + + /** + * Equaivalent to getWaitForMessage but with inverted logic. + */ + public native @Cast("bool") boolean getReusePreviousMessage(); } /** @@ -193,27 +261,38 @@ public enum Type { SReceiver(0), MReceiver(1); /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public InputMap(Pointer p) { super(p); } + @MemberGetter public native @StdString BytePointer name(); public InputMap(@ByVal Input defaultInput) { super((Pointer)null); allocate(defaultInput); } private native void allocate(@ByVal Input defaultInput); + public InputMap(@StdString BytePointer name, @ByVal Input defaultInput) { super((Pointer)null); allocate(name, defaultInput); } + private native void allocate(@StdString BytePointer name, @ByVal Input defaultInput); + public InputMap(@StdString String name, @ByVal Input defaultInput) { super((Pointer)null); allocate(name, defaultInput); } + private native void allocate(@StdString String name, @ByVal Input defaultInput); /** Create or modify an input */ public native @ByRef @Name("operator []") Input get(@StdString BytePointer key); public native @ByRef @Name("operator []") Input get(@StdString String key); } // when Pipeline tries to serialize and construct on remote, it will check if all connected nodes are on same pipeline + /** Id of node */ + @MemberGetter public native @Cast("const dai::Node::Id") long id(); + @MemberGetter public native @ByRef AssetManager assetManager(); - public native @ByVal @Cast("nlohmann::json*") Pointer getProperties(); + public native @ByRef DaiProperties getProperties(); public native @ByVal VersionOptional getRequiredOpenVINOVersion(); - public native @SharedPtr @ByVal Node clone(); - /** Id of node */ - @MemberGetter public native @Cast("const dai::Node::Id") long id(); + @MemberGetter public native @ByRef @Cast("dai::copyable_unique_ptr*") Pointer propertiesHolder(); + // Underlying properties + @MemberGetter public native @ByRef DaiProperties properties(); // access public native @ByVal Pipeline getParentPipeline(); + /** Deep copy the node */ + public native @UniquePtr Node clone(); + /** Retrieves nodes name */ - public native @StdString BytePointer getName(); + public native @Cast("const char*") BytePointer getName(); /** Retrieves all nodes outputs */ public native @StdVector Output getOutputs(); @@ -241,8 +320,10 @@ public enum Type { SReceiver(0), MReceiver(1); private native void allocate(@ByVal Output out, @ByVal Input in); @MemberGetter public native @Cast("dai::Node::Id") long outputId(); @MemberGetter public native @StdString BytePointer outputName(); + @MemberGetter public native @StdString BytePointer outputGroup(); @MemberGetter public native @Cast("dai::Node::Id") long inputId(); @MemberGetter public native @StdString BytePointer inputName(); + @MemberGetter public native @StdString BytePointer inputGroup(); public native @Cast("bool") @Name("operator ==") boolean equals(@Const @ByRef Connection rhs); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NodeConnectionSchema.java b/depthai/src/gen/java/org/bytedeco/depthai/NodeConnectionSchema.java index 35be6d49cfa..1ccb7eb1b04 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NodeConnectionSchema.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NodeConnectionSchema.java @@ -39,7 +39,9 @@ public class NodeConnectionSchema extends Pointer { } public native @Cast("int64_t") long node1Id(); public native NodeConnectionSchema node1Id(long setter); + public native @StdString BytePointer node1OutputGroup(); public native NodeConnectionSchema node1OutputGroup(BytePointer setter); public native @StdString BytePointer node1Output(); public native NodeConnectionSchema node1Output(BytePointer setter); public native @Cast("int64_t") long node2Id(); public native NodeConnectionSchema node2Id(long setter); + public native @StdString BytePointer node2InputGroup(); public native NodeConnectionSchema node2InputGroup(BytePointer setter); public native @StdString BytePointer node2Input(); public native NodeConnectionSchema node2Input(BytePointer setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NodeIoInfo.java b/depthai/src/gen/java/org/bytedeco/depthai/NodeIoInfo.java index d338ba80166..3d3bcfadf02 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NodeIoInfo.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NodeIoInfo.java @@ -45,8 +45,10 @@ public enum Type { MSender(0), SSender(1), MReceiver(2), SReceiver(3); @Override public String toString() { return intern().name(); } } + public native @StdString BytePointer group(); public native NodeIoInfo group(BytePointer setter); public native @StdString BytePointer name(); public native NodeIoInfo name(BytePointer setter); public native Type type(); public native NodeIoInfo type(Type setter); public native @Cast("bool") boolean blocking(); public native NodeIoInfo blocking(boolean setter); public native int queueSize(); public native NodeIoInfo queueSize(int setter); + public native @Cast("bool") boolean waitForMessage(); public native NodeIoInfo waitForMessage(boolean setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/NodeObjInfo.java b/depthai/src/gen/java/org/bytedeco/depthai/NodeObjInfo.java index 507ad290016..d9b0750f0b4 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/NodeObjInfo.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/NodeObjInfo.java @@ -38,6 +38,27 @@ public class NodeObjInfo extends Pointer { public native @Cast("int64_t") long id(); public native NodeObjInfo id(long setter); public native @StdString BytePointer name(); public native NodeObjInfo name(BytePointer setter); - public native @ByRef @Cast("nlohmann::json*") Pointer properties(); public native NodeObjInfo properties(Pointer setter); - public native @ByRef StringNodeIoInfoMap ioInfo(); public native NodeObjInfo ioInfo(StringNodeIoInfoMap setter); + + public native @Cast("std::uint8_t*") @StdVector BytePointer properties(); public native NodeObjInfo properties(BytePointer setter); + + public static class IoInfoKey extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public IoInfoKey() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public IoInfoKey(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public IoInfoKey(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public IoInfoKey position(long position) { + return (IoInfoKey)super.position(position); + } + @Override public IoInfoKey getPointer(long i) { + return new IoInfoKey((Pointer)this).offsetAddress(i); + } + + public native @Cast("std::size_t") @Name("operator ()") long apply(@Const @ByRef StringStringTuple k); + } + public native @ByRef @Cast("std::unordered_map,dai::NodeIoInfo,dai::NodeObjInfo::IoInfoKey>*") Pointer ioInfo(); public native NodeObjInfo ioInfo(Pointer setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTracker.java b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTracker.java index e5391c9fb74..1927613a8e8 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTracker.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTracker.java @@ -21,15 +21,17 @@ * \brief ObjectTracker node. Performs object tracking using Kalman filter and hungarian algorithm. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ObjectTracker extends Node { +public class ObjectTracker extends ObjectTrackerPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public ObjectTracker(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public ObjectTracker(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public ObjectTracker(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ObjectTrackerProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr ObjectTrackerProperties props); /** * Input ImgFrame message on which tracking will be performed. RGBp, BGRp, NV12, YUV420p types are supported. @@ -67,7 +69,7 @@ public class ObjectTracker extends Node { @MemberGetter public native @ByRef Output passthroughDetectionFrame(); /** - * Passthrough image detections message from neural nework output. + * Passthrough image detections message from neural network output. * Suitable for when input queue is set to non-blocking behavior. */ @MemberGetter public native @ByRef Output passthroughDetections(); @@ -100,9 +102,9 @@ public class ObjectTracker extends Node { public native void setTrackerType(@Cast("dai::TrackerType") int type); /** - * Specify tracker ID assigment policy. - * @param type Tracker ID assigment policy. + * Specify tracker ID assignment policy. + * @param type Tracker ID assignment policy. */ - public native void setTrackerIdAssigmentPolicy(TrackerIdAssigmentPolicy type); - public native void setTrackerIdAssigmentPolicy(@Cast("dai::TrackerIdAssigmentPolicy") int type); + public native void setTrackerIdAssignmentPolicy(TrackerIdAssignmentPolicy type); + public native void setTrackerIdAssignmentPolicy(@Cast("dai::TrackerIdAssignmentPolicy") int type); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerProperties.java index f100b68511d..e21efb6dc08 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for ObjectTracker */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class ObjectTrackerProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ObjectTrackerProperties extends ObjectTrackerPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public ObjectTrackerProperties() { super((Pointer)null); allocate(); } @@ -38,9 +38,29 @@ public class ObjectTrackerProperties extends Pointer { return new ObjectTrackerProperties((Pointer)this).offsetAddress(i); } + /** + * Confidence threshold for tracklets. + * Above this threshold detections will be tracked. + * Default 0, all detections are tracked. + */ public native float trackerThreshold(); public native ObjectTrackerProperties trackerThreshold(float setter); + /** + * Maximum number of objects to track. + * Maximum 60 for SHORT_TERM_KCF, maximum 1000 for other tracking methods. + * Default 60. + */ public native @Cast("std::int32_t") int maxObjectsToTrack(); public native ObjectTrackerProperties maxObjectsToTrack(int setter); + /** + * Which detections labels to track. + * Default all labels are tracked. + */ public native @Cast("std::uint32_t*") @StdVector IntPointer detectionLabelsToTrack(); public native ObjectTrackerProperties detectionLabelsToTrack(IntPointer setter); + /** + * Tracking method. + */ public native TrackerType trackerType(); public native ObjectTrackerProperties trackerType(TrackerType setter); - public native TrackerIdAssigmentPolicy trackerIdAssigmentPolicy(); public native ObjectTrackerProperties trackerIdAssigmentPolicy(TrackerIdAssigmentPolicy setter); + /** + * New ID assignment policy. + */ + public native TrackerIdAssignmentPolicy trackerIdAssignmentPolicy(); public native ObjectTrackerProperties trackerIdAssignmentPolicy(TrackerIdAssignmentPolicy setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesNode.java new file mode 100644 index 00000000000..980f302522c --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ObjectTrackerPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ObjectTrackerPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef ObjectTrackerProperties properties(); public native ObjectTrackerPropertiesNode properties(ObjectTrackerProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesSerializable.java new file mode 100644 index 00000000000..26d25998720 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/ObjectTrackerPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class ObjectTrackerPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public ObjectTrackerPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public ObjectTrackerPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ObjectTrackerPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public ObjectTrackerPropertiesSerializable position(long position) { + return (ObjectTrackerPropertiesSerializable)super.position(position); + } + @Override public ObjectTrackerPropertiesSerializable getPointer(long i) { + return new ObjectTrackerPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/OpenVINO.java b/depthai/src/gen/java/org/bytedeco/depthai/OpenVINO.java index f6d4c087260..057d92950e6 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/OpenVINO.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/OpenVINO.java @@ -66,18 +66,18 @@ public class OpenVINO extends Pointer { public static native @Cast("dai::OpenVINO::Version") int parseVersionName(@StdString String versionString); /** - * Returns a list of potentionally supported versions for a specified blob major and minor versions. + * Returns a list of potentially supported versions for a specified blob major and minor versions. * @param majorVersion Major version from OpenVINO blob * @param minorVersion Minor version from OpenVINO blob - * @return Vector of potentionally supported versions + * @return Vector of potentially supported versions */ public static native @Cast("dai::OpenVINO::Version*") @StdVector IntPointer getBlobSupportedVersions(@Cast("std::uint32_t") int majorVersion, @Cast("std::uint32_t") int minorVersion); /** - * Returns latest potentionally supported version by a given blob version. + * Returns latest potentially supported version by a given blob version. * @param majorVersion Major version from OpenVINO blob * @param minorVersion Minor version from OpenVINO blob - * @return Latest potentionally supported version + * @return Latest potentially supported version */ public static native @Cast("dai::OpenVINO::Version") int getBlobLatestSupportedVersion(@Cast("std::uint32_t") int majorVersion, @Cast("std::uint32_t") int minorVersion); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/PrebootConfig.java b/depthai/src/gen/java/org/bytedeco/depthai/PrebootConfig.java index 642e865674b..99a817b155f 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/PrebootConfig.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/PrebootConfig.java @@ -62,4 +62,5 @@ public static class USB extends Pointer { public native @ByRef USB usb(); public native PrebootConfig usb(USB setter); public native @ByRef @Cast("tl::optional*") IntOptional watchdogTimeoutMs(); public native PrebootConfig watchdogTimeoutMs(IntOptional setter); + public native @ByRef @Cast("tl::optional*") IntOptional watchdogInitialDelayMs(); public native PrebootConfig watchdogInitialDelayMs(IntOptional setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/RawBuffer.java b/depthai/src/gen/java/org/bytedeco/depthai/RawBuffer.java index 76099ce0cae..b5d1a148bbe 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/RawBuffer.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/RawBuffer.java @@ -41,6 +41,4 @@ public class RawBuffer extends Pointer { public native void serialize(@Cast("std::uint8_t*") @StdVector BytePointer metadata, @ByRef @Cast("dai::DatatypeEnum*") IntPointer datatype); public native void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer metadata, @ByRef @Cast("dai::DatatypeEnum*") IntBuffer datatype); public native void serialize(@Cast("std::uint8_t*") @StdVector byte[] metadata, @ByRef @Cast("dai::DatatypeEnum*") int[] datatype); - - // NLOHMANN_DEFINE_TYPE_INTRUSIVE(RawBuffer); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/RawImageManipConfig.java b/depthai/src/gen/java/org/bytedeco/depthai/RawImageManipConfig.java index 196d6282de3..a8f6dc49eba 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/RawImageManipConfig.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/RawImageManipConfig.java @@ -168,7 +168,7 @@ public static class FormatConfig extends Pointer { public native @Cast("bool") boolean enableFormat(); public native RawImageManipConfig enableFormat(boolean setter); // Usable with runtime config only, - // when ImageManipProperties.inputConfigSync is set + // when ImageManipProperties.inputConfig.setWaitForMessage(true) is set public native @Cast("bool") boolean reusePreviousImage(); public native RawImageManipConfig reusePreviousImage(boolean setter); public native @Cast("bool") boolean skipCurrentImage(); public native RawImageManipConfig skipCurrentImage(boolean setter); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/RawStereoDepthConfig.java b/depthai/src/gen/java/org/bytedeco/depthai/RawStereoDepthConfig.java index 943247e7c98..3af7421ced2 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/RawStereoDepthConfig.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/RawStereoDepthConfig.java @@ -54,6 +54,23 @@ public static class AlgorithmControl extends Pointer { return new AlgorithmControl((Pointer)this).offsetAddress(i); } + /** + * Align the disparity/depth to the perspective of a rectified output, or center it + */ + public enum DepthAlign { RECTIFIED_RIGHT(0), RECTIFIED_LEFT(1), CENTER(2); + + public final int value; + private DepthAlign(int v) { this.value = v; } + private DepthAlign(DepthAlign e) { this.value = e.value; } + public DepthAlign intern() { for (DepthAlign e : values()) if (e.value == value) return e; return this; } + @Override public String toString() { return intern().name(); } + } + + /** + * Set the disparity/depth alignment to the perspective of a rectified output, or center it + */ + public native DepthAlign depthAlign(); public native AlgorithmControl depthAlign(DepthAlign setter); + /** * Computes and combines disparities in both L-R and R-L directions, and combine them. * For better occlusion handling @@ -79,19 +96,25 @@ public static class AlgorithmControl extends Pointer { public native @Cast("std::int32_t") int leftRightCheckThreshold(); public native AlgorithmControl leftRightCheckThreshold(int setter); /** - * Number of fractional bits for subpixel mode. - * Valid values: 3,4,5. - * Defines the number of fractional disparities: 2^x. - * Median filter postprocessing is supported only for 3 fractional bits. + * Number of fractional bits for subpixel mode + * + * Valid values: 3,4,5 + * + * Defines the number of fractional disparities: 2^x + * + * Median filter postprocessing is supported only for 3 fractional bits */ public native @Cast("std::int32_t") int subpixelFractionalBits(); public native AlgorithmControl subpixelFractionalBits(int setter); } /** - * Controls the flow of stereo algorithm: left-right check, subpixel etc. + * Controls the flow of stereo algorithm - left-right check, subpixel etc. */ public native @ByRef AlgorithmControl algorithmControl(); public native RawStereoDepthConfig algorithmControl(AlgorithmControl setter); + /** + * Post-processing filters, all the filters are applied in disparity domain. + */ public static class PostProcessing extends Pointer { static { Loader.load(); } /** Default native constructor. */ @@ -115,10 +138,278 @@ public static class PostProcessing extends Pointer { public native MedianFilter median(); public native PostProcessing median(MedianFilter setter); /** - * Sigma value for bilateral filter. 0 means disabled + * Sigma value for bilateral filter. 0 means disabled. * A larger value of the parameter means that farther colors within the pixel neighborhood will be mixed together. */ public native @Cast("std::int16_t") short bilateralSigmaValue(); public native PostProcessing bilateralSigmaValue(short setter); + + /** + * 1D edge-preserving spatial filter using high-order domain transform. + */ + public static class SpatialFilter extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public SpatialFilter() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SpatialFilter(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpatialFilter(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SpatialFilter position(long position) { + return (SpatialFilter)super.position(position); + } + @Override public SpatialFilter getPointer(long i) { + return new SpatialFilter((Pointer)this).offsetAddress(i); + } + + @MemberGetter public static native @Cast("const std::int32_t") int DEFAULT_DELTA_VALUE(); + public static final int DEFAULT_DELTA_VALUE = DEFAULT_DELTA_VALUE(); + + /** + * Whether to enable or disable the filter. + */ + public native @Cast("bool") boolean enable(); public native SpatialFilter enable(boolean setter); + + /** + * An in-place heuristic symmetric hole-filling mode applied horizontally during the filter passes. + * Intended to rectify minor artefacts with minimal performance impact. + * Search radius for hole filling. + */ + public native @Cast("std::uint8_t") byte holeFillingRadius(); public native SpatialFilter holeFillingRadius(byte setter); + + /** + * The Alpha factor in an exponential moving average with Alpha=1 - no filter. Alpha = 0 - infinite filter. + * Determines the amount of smoothing. + */ + public native float alpha(); public native SpatialFilter alpha(float setter); + + /** + * Step-size boundary. Establishes the threshold used to preserve "edges". + * If the disparity value between neighboring pixels exceed the disparity threshold set by this delta parameter, + * then filtering will be temporarily disabled. + * Default value 0 means auto: 3 disparity integer levels. + * In case of subpixel mode it's 3*number of subpixel levels. + */ + public native @Cast("std::int32_t") int delta(); public native SpatialFilter delta(int setter); + + /** + * Nubmer of iterations over the image in both horizontal and vertical direction. + */ + public native @Cast("std::int32_t") int numIterations(); public native SpatialFilter numIterations(int setter); + } + + /** + * Edge-preserving filtering: This type of filter will smooth the depth noise while attempting to preserve edges. + */ + public native @ByRef SpatialFilter spatialFilter(); public native PostProcessing spatialFilter(SpatialFilter setter); + + /** + * Temporal filtering with optional persistence. + * More details about the filter can be found here: + */ + public static class TemporalFilter extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public TemporalFilter() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public TemporalFilter(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public TemporalFilter(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public TemporalFilter position(long position) { + return (TemporalFilter)super.position(position); + } + @Override public TemporalFilter getPointer(long i) { + return new TemporalFilter((Pointer)this).offsetAddress(i); + } + + @MemberGetter public static native @Cast("const std::int32_t") int DEFAULT_DELTA_VALUE(); + public static final int DEFAULT_DELTA_VALUE = DEFAULT_DELTA_VALUE(); + + /** + * Whether to enable or disable the filter. + */ + public native @Cast("bool") boolean enable(); public native TemporalFilter enable(boolean setter); + + /** + * Persistency algorithm type. + */ + public enum PersistencyMode { + PERSISTENCY_OFF(0), + VALID_8_OUT_OF_8(1), + VALID_2_IN_LAST_3(2), + VALID_2_IN_LAST_4(3), + VALID_2_OUT_OF_8(4), + VALID_1_IN_LAST_2(5), + VALID_1_IN_LAST_5(6), + VALID_1_IN_LAST_8(7), + PERSISTENCY_INDEFINITELY(8); + + public final int value; + private PersistencyMode(int v) { this.value = v; } + private PersistencyMode(PersistencyMode e) { this.value = e.value; } + public PersistencyMode intern() { for (PersistencyMode e : values()) if (e.value == value) return e; return this; } + @Override public String toString() { return intern().name(); } + } + + /** + * Persistency mode. + * If the current disparity/depth value is invalid, it will be replaced by an older value, based on persistency mode. + */ + public native PersistencyMode persistencyMode(); public native TemporalFilter persistencyMode(PersistencyMode setter); + + /** + * The Alpha factor in an exponential moving average with Alpha=1 - no filter. Alpha = 0 - infinite filter. + * Determines the extent of the temporal history that should be averaged. + */ + public native float alpha(); public native TemporalFilter alpha(float setter); + + /** + * Step-size boundary. Establishes the threshold used to preserve surfaces (edges). + * If the disparity value between neighboring pixels exceed the disparity threshold set by this delta parameter, + * then filtering will be temporarily disabled. + * Default value 0 means auto: 3 disparity integer levels. + * In case of subpixel mode it's 3*number of subpixel levels. + */ + public native @Cast("std::int32_t") int delta(); public native TemporalFilter delta(int setter); + } + + /** + * Temporal filtering with optional persistence. + * More details about the filter can be found here: + */ + public native @ByRef TemporalFilter temporalFilter(); public native PostProcessing temporalFilter(TemporalFilter setter); + + /** + * Threshold filtering. + * Filters out distances outside of a given interval. + */ + public static class ThresholdFilter extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public ThresholdFilter() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public ThresholdFilter(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public ThresholdFilter(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public ThresholdFilter position(long position) { + return (ThresholdFilter)super.position(position); + } + @Override public ThresholdFilter getPointer(long i) { + return new ThresholdFilter((Pointer)this).offsetAddress(i); + } + + /** + * Minimum range in millimeters. + * Depth values under this value are invalidated. + */ + public native @Cast("std::int32_t") int minRange(); public native ThresholdFilter minRange(int setter); + /** + * Minimum range in millimeters. + * Depth values over this value are invalidated. + */ + public native @Cast("std::int32_t") int maxRange(); public native ThresholdFilter maxRange(int setter); + } + + /** + * Threshold filtering. + * Filters out distances outside of a given interval. + */ + public native @ByRef ThresholdFilter thresholdFilter(); public native PostProcessing thresholdFilter(ThresholdFilter setter); + + /** + * Speckle filtering. + * Removes speckle noise. + */ + public static class SpeckleFilter extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public SpeckleFilter() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SpeckleFilter(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpeckleFilter(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SpeckleFilter position(long position) { + return (SpeckleFilter)super.position(position); + } + @Override public SpeckleFilter getPointer(long i) { + return new SpeckleFilter((Pointer)this).offsetAddress(i); + } + + /** + * Whether to enable or disable the filter. + */ + public native @Cast("bool") boolean enable(); public native SpeckleFilter enable(boolean setter); + /** + * Speckle search range. + */ + public native @Cast("std::uint32_t") int speckleRange(); public native SpeckleFilter speckleRange(int setter); + } + + /** + * Speckle filtering. + * Removes speckle noise. + */ + public native @ByRef SpeckleFilter speckleFilter(); public native PostProcessing speckleFilter(SpeckleFilter setter); + + /** + * Decimation filter. + * Reduces the depth scene complexity. The filter runs on kernel sizes [2x2] to [8x8] pixels. + */ + public static class DecimationFilter extends Pointer { + static { Loader.load(); } + /** Default native constructor. */ + public DecimationFilter() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public DecimationFilter(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public DecimationFilter(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public DecimationFilter position(long position) { + return (DecimationFilter)super.position(position); + } + @Override public DecimationFilter getPointer(long i) { + return new DecimationFilter((Pointer)this).offsetAddress(i); + } + + /** + * Decimation factor. + * Valid values are 1,2,3,4. + * Disparity/depth map x/y resolution will be decimated with this value. + */ + public native @Cast("std::uint32_t") int decimationFactor(); public native DecimationFilter decimationFactor(int setter); + /** + * Decimation algorithm type. + */ + public enum DecimationMode { + PIXEL_SKIPPING(0), + NON_ZERO_MEDIAN(1), + NON_ZERO_MEAN(2); + + public final int value; + private DecimationMode(int v) { this.value = v; } + private DecimationMode(DecimationMode e) { this.value = e.value; } + public DecimationMode intern() { for (DecimationMode e : values()) if (e.value == value) return e; return this; } + @Override public String toString() { return intern().name(); } + } + /** + * Decimation algorithm type. + */ + public native DecimationMode decimationMode(); public native DecimationFilter decimationMode(DecimationMode setter); + } + + /** + * Decimation filter. + * Reduces disparity/depth map x/y complexity, reducing runtime complexity for other filters. + */ + public native @ByRef DecimationFilter decimationFilter(); public native PostProcessing decimationFilter(DecimationFilter setter); } /** @@ -179,7 +470,7 @@ public enum KernelSize { AUTO(-1), KERNEL_5x5(0), KERNEL_7x7(1), KERNEL_7x9(2); public native KernelSize kernelSize(); public native CensusTransform kernelSize(KernelSize setter); /** - * Census transform mask, default: auto, mask is set based on resolution and kernel size. + * Census transform mask, default - auto, mask is set based on resolution and kernel size. * Disabled for 400p input resolution. * Enabled for 720p. * 0XA82415 for 5x5 census transform kernel. @@ -195,7 +486,7 @@ public enum KernelSize { AUTO(-1), KERNEL_5x5(0), KERNEL_7x7(1), KERNEL_7x9(2); public native @Cast("bool") boolean enableMeanMode(); public native CensusTransform enableMeanMode(boolean setter); /** - * Census transform comparation treshold value. + * Census transform comparison threshold value. */ public native @Cast("uint32_t") int threshold(); public native CensusTransform threshold(int setter); } @@ -272,7 +563,7 @@ public enum DisparityWidth { DISPARITY_64(0), DISPARITY_96(1); * CLAMP(COMB_COST >> 5, threshold). * Where AD is the Absolute Difference between 2 pixels values. * CTC is the Census Transform Cost between 2 pixels, based on Hamming distance (xor). - * The α and β parameters are subject to fine fine tuning by the user. + * The α and β parameters are subject to fine tuning by the user. */ public static class LinearEquationParameters extends Pointer { static { Loader.load(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SPIOut.java b/depthai/src/gen/java/org/bytedeco/depthai/SPIOut.java index 3eb1d30d75a..e212c60204d 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SPIOut.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SPIOut.java @@ -21,18 +21,20 @@ * \brief SPIOut node. Sends messages over SPI. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SPIOut extends Node { +public class SPIOut extends SPIOutPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public SPIOut(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); + public SPIOut(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SPIOutProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SPIOutProperties props); public SPIOut(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); /** - * Input for any type of messages to be transfered over SPI stream + * Input for any type of messages to be transferred over SPI stream * * Default queue is blocking with size 8 */ diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SPIOutProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutProperties.java index bff7d0280d8..f10b0896fb3 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SPIOutProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for SPIOut node */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SPIOutProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SPIOutProperties extends SPIOutPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public SPIOutProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesNode.java new file mode 100644 index 00000000000..6b433f8f342 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SPIOutPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SPIOutPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SPIOutProperties properties(); public native SPIOutPropertiesNode properties(SPIOutProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesSerializable.java new file mode 100644 index 00000000000..328c08aec36 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SPIOutPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SPIOutPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public SPIOutPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SPIOutPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SPIOutPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SPIOutPropertiesSerializable position(long position) { + return (SPIOutPropertiesSerializable)super.position(position); + } + @Override public SPIOutPropertiesSerializable getPointer(long i) { + return new SPIOutPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetwork.java index 115af627079..d40786e3cb9 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetwork.java @@ -21,18 +21,14 @@ * \brief SpatialDetectionNetwork node. Runs a neural inference on input image and calculates spatial location data. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SpatialDetectionNetwork extends DetectionNetwork { +public class SpatialDetectionNetwork extends SpatialDetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public SpatialDetectionNetwork(Pointer p) { super(p); } - - public native @StdString @Override BytePointer getName(); - public SpatialDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } - private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); /** - * Input message with data to be infered upon + * Input message with data to be inferred upon * Default queue is blocking with size 5 */ @MemberGetter public native @ByRef Input input(); @@ -76,13 +72,13 @@ public class SpatialDetectionNetwork extends DetectionNetwork { public native void setBoundingBoxScaleFactor(float scaleFactor); /** - * Specifies lower threshold in milimeters for depth values which will used to calculate spatial data + * Specifies lower threshold in millimeters for depth values which will used to calculate spatial data * @param lowerThreshold LowerThreshold must be in the interval [0,upperThreshold] and less than upperThreshold. */ public native void setDepthLowerThreshold(@Cast("uint32_t") int lowerThreshold); /** - * Specifies upper threshold in milimeters for depth values which will used to calculate spatial data + * Specifies upper threshold in millimeters for depth values which will used to calculate spatial data * @param upperThreshold UpperThreshold must be in the interval (lowerThreshold,65535]. */ public native void setDepthUpperThreshold(@Cast("uint32_t") int upperThreshold); diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkProperties.java index c1eee7cb8b5..7523a036c5e 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkProperties.java @@ -21,7 +21,7 @@ * Specify properties for SpatialDetectionNetwork */ @Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SpatialDetectionNetworkProperties extends DetectionNetworkProperties { +public class SpatialDetectionNetworkProperties extends SpatialDetectionNetworkPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public SpatialDetectionNetworkProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..a7c65d38fa5 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SpatialDetectionNetworkPropertiesNode extends DetectionNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpatialDetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SpatialDetectionNetworkProperties properties(); public native SpatialDetectionNetworkPropertiesNode properties(SpatialDetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesSerializable.java new file mode 100644 index 00000000000..7045f397728 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialDetectionNetworkPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SpatialDetectionNetworkPropertiesSerializable extends DetectionNetworkProperties { + static { Loader.load(); } + /** Default native constructor. */ + public SpatialDetectionNetworkPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SpatialDetectionNetworkPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpatialDetectionNetworkPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SpatialDetectionNetworkPropertiesSerializable position(long position) { + return (SpatialDetectionNetworkPropertiesSerializable)super.position(position); + } + @Override public SpatialDetectionNetworkPropertiesSerializable getPointer(long i) { + return new SpatialDetectionNetworkPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculator.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculator.java index a41a31b8276..ba9f5c4b264 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculator.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculator.java @@ -21,15 +21,16 @@ * \brief SpatialLocationCalculator node. Calculates spatial location data on a set of ROIs on depth map. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SpatialLocationCalculator extends Node { +public class SpatialLocationCalculator extends SpatialLocationCalculatorPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public SpatialLocationCalculator(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public SpatialLocationCalculator(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public SpatialLocationCalculator(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SpatialLocationCalculatorProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SpatialLocationCalculatorProperties props); /** * Initial config to use when calculating spatial location data. @@ -63,5 +64,11 @@ public class SpatialLocationCalculator extends Node { * Specify whether or not wait until configuration message arrives to inputConfig Input. * @param wait True to wait for configuration message, false otherwise. */ - public native void setWaitForConfigInput(@Cast("bool") boolean _wait); + public native @Deprecated void setWaitForConfigInput(@Cast("bool") boolean _wait); + + /** + * @see setWaitForConfigInput + * @return True if wait for inputConfig message, false otherwise + */ + public native @Cast("bool") @Deprecated boolean getWaitForConfigInput(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorConfigData.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorConfigData.java index b25a56e5dc2..8faeba18585 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorConfigData.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorConfigData.java @@ -45,8 +45,8 @@ public class SpatialLocationCalculatorConfigData extends Pointer { */ public native @ByRef SpatialLocationCalculatorConfigThresholds depthThresholds(); public native SpatialLocationCalculatorConfigData depthThresholds(SpatialLocationCalculatorConfigThresholds setter); /** - * Calculation method used to obtain spatial locations. - * Average: the average of ROI is used for calculation. + * Calculation method used to obtain spatial locations + * Average - the average of ROI is used for calculation. * Min: the minimum value inside ROI is used for calculation. * Max: the maximum value inside ROI is used for calculation. * Default: average. diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorProperties.java index 72edb4f282f..f901847cea1 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for SpatialLocationCalculator */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SpatialLocationCalculatorProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SpatialLocationCalculatorProperties extends SpatialLocationCalculatorPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public SpatialLocationCalculatorProperties() { super((Pointer)null); allocate(); } @@ -39,7 +39,4 @@ public class SpatialLocationCalculatorProperties extends Pointer { } public native @ByRef RawSpatialLocationCalculatorConfig roiConfig(); public native SpatialLocationCalculatorProperties roiConfig(RawSpatialLocationCalculatorConfig setter); - - /** Whether to wait for config at 'inputConfig' IO */ - public native @Cast("bool") boolean inputConfigSync(); public native SpatialLocationCalculatorProperties inputConfigSync(boolean setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesNode.java new file mode 100644 index 00000000000..50b62e1c906 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SpatialLocationCalculatorPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpatialLocationCalculatorPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SpatialLocationCalculatorProperties properties(); public native SpatialLocationCalculatorPropertiesNode properties(SpatialLocationCalculatorProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesSerializable.java new file mode 100644 index 00000000000..cbb173c7699 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocationCalculatorPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SpatialLocationCalculatorPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public SpatialLocationCalculatorPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SpatialLocationCalculatorPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SpatialLocationCalculatorPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SpatialLocationCalculatorPropertiesSerializable position(long position) { + return (SpatialLocationCalculatorPropertiesSerializable)super.position(position); + } + @Override public SpatialLocationCalculatorPropertiesSerializable getPointer(long i) { + return new SpatialLocationCalculatorPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocations.java b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocations.java index 3d372d28621..d89a92063fd 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocations.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SpatialLocations.java @@ -63,7 +63,7 @@ public class SpatialLocations extends Pointer { */ public native @Cast("std::uint32_t") int depthAveragePixelCount(); public native SpatialLocations depthAveragePixelCount(int setter); /** - * Spatial coordinates: x,y,z; x,y are the relative positions of the center of ROI to the center of depth map + * Spatial coordinates - x,y,z; x,y are the relative positions of the center of ROI to the center of depth map */ public native @ByRef Point3f spatialCoordinates(); public native SpatialLocations spatialCoordinates(Point3f setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepth.java b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepth.java index 6012d418872..b1f9823df7f 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepth.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepth.java @@ -21,15 +21,28 @@ * \brief StereoDepth node. Compute stereo disparity and depth from left-right image pair. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class StereoDepth extends Node { +public class StereoDepth extends StereoDepthPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public StereoDepth(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); + /** + * Preset modes for stereo depth. + */ + public enum PresetMode { HIGH_ACCURACY(0), HIGH_DENSITY(1); + + public final int value; + private PresetMode(int v) { this.value = v; } + private PresetMode(PresetMode e) { this.value = e.value; } + public PresetMode intern() { for (PresetMode e : values()) if (e.value == value) return e; return this; } + @Override public String toString() { return intern().name(); } + } public StereoDepth(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public StereoDepth(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr StereoDepthProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr StereoDepthProperties props); /** * Initial config to use for StereoDepth. @@ -129,11 +142,11 @@ public class StereoDepth extends Node { /** * Outputs ImgFrame message that carries RAW8 confidence map. * Lower values means higher confidence of the calculated disparity value. - * RGB aligment, left-right check or any postproccessing (e.g. median filter) is not performed on confidence map. + * RGB alignment, left-right check or any postproccessing (e.g. median filter) is not performed on confidence map. */ @MemberGetter public native @ByRef Output confidenceMap(); -// #if 0 // will be enabled when confidence map RGB aligment/LR-check support will be added +// #if 0 // will be enabled when confidence map RGB alignment/LR-check support will be added // #endif /** @@ -223,7 +236,7 @@ public class StereoDepth extends Node { * @param align Set the disparity/depth alignment: centered (between the 'left' and 'right' inputs), * or from the perspective of a rectified output stream */ - public native void setDepthAlign(@ByVal StereoDepthProperties.DepthAlign align); + public native void setDepthAlign(RawStereoDepthConfig.AlgorithmControl.DepthAlign align); /** * @param camera Set the camera from whose perspective the disparity/depth will be aligned @@ -313,4 +326,19 @@ public class StereoDepth extends Node { * @return Maximum disparity value that the node can return */ public native @Deprecated float getMaxDisparity(); + + /** + * Specify allocated hardware resources for stereo depth. + * Suitable only to increase post processing runtime. + * @param numShaves Number of shaves. + * @param numMemorySlices Number of memory slices. + */ + public native void setPostProcessingHardwareResources(int numShaves, int numMemorySlices); + + /** + * Sets a default preset based on specified option. + * @param mode Stereo depth preset mode + */ + public native void setDefaultProfilePreset(PresetMode mode); + public native void setDefaultProfilePreset(@Cast("dai::node::StereoDepth::PresetMode") int mode); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthConfig.java b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthConfig.java index 37de5da86b8..6874fa16bcc 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthConfig.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthConfig.java @@ -35,6 +35,7 @@ public class StereoDepthConfig extends Buffer { return new StereoDepthConfig((Pointer)this).offsetAddress(i); } + /** * Construct StereoDepthConfig message. */ @@ -43,6 +44,12 @@ public class StereoDepthConfig extends Buffer { public StereoDepthConfig(@SharedPtr RawStereoDepthConfig ptr) { super((Pointer)null); allocate(ptr); } private native void allocate(@SharedPtr RawStereoDepthConfig ptr); + /** + * @param align Set the disparity/depth alignment: centered (between the 'left' and 'right' inputs), + * or from the perspective of a rectified output stream + */ + public native void setDepthAlign(RawStereoDepthConfig.AlgorithmControl.DepthAlign align); + /** * Confidence threshold for disparity calculation * @param confThr Confidence threshold value 0..255 diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthProperties.java index c91c81fe5a3..91ffcc87f87 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for StereoDepth */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class StereoDepthProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StereoDepthProperties extends StereoDepthPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public StereoDepthProperties() { super((Pointer)null); allocate(); } @@ -38,6 +38,9 @@ public class StereoDepthProperties extends Pointer { return new StereoDepthProperties((Pointer)this).offsetAddress(i); } + @MemberGetter public static native @Cast("const std::int32_t") int AUTO(); + public static final int AUTO = AUTO(); + public static class RectificationMesh extends Pointer { static { Loader.load(); } /** Default native constructor. */ @@ -80,25 +83,6 @@ public static class RectificationMesh extends Pointer { /** Initial stereo config */ public native @ByRef RawStereoDepthConfig initialConfig(); public native StereoDepthProperties initialConfig(RawStereoDepthConfig setter); - /** Whether to wait for config at 'inputConfig' IO */ - public native @Cast("bool") boolean inputConfigSync(); public native StereoDepthProperties inputConfigSync(boolean setter); - - /** - * Align the disparity/depth to the perspective of a rectified output, or center it - */ - public enum DepthAlign { RECTIFIED_RIGHT(0), RECTIFIED_LEFT(1), CENTER(2); - - public final int value; - private DepthAlign(int v) { this.value = v; } - private DepthAlign(DepthAlign e) { this.value = e.value; } - public DepthAlign intern() { for (DepthAlign e : values()) if (e.value == value) return e; return this; } - @Override public String toString() { return intern().name(); } - } - - /** - * Set the disparity/depth alignment to the perspective of a rectified output, or center it - */ - public native DepthAlign depthAlign(); public native StereoDepthProperties depthAlign(DepthAlign setter); /** * Which camera to align disparity/depth to. * When configured (not AUTO), takes precedence over 'depthAlign' @@ -108,7 +92,7 @@ public enum DepthAlign { RECTIFIED_RIGHT(0), RECTIFIED_LEFT(1), CENTER(2); public native @Cast("bool") boolean enableRectification(); public native StereoDepthProperties enableRectification(boolean setter); /** - * Fill color for missing data at frame edges: grayscale 0..255, or -1 to replicate pixels + * Fill color for missing data at frame edges - grayscale 0..255, or -1 to replicate pixels */ public native @Cast("std::int32_t") int rectifyEdgeFillColor(); public native StereoDepthProperties rectifyEdgeFillColor(int setter); /** @@ -149,4 +133,23 @@ public enum DepthAlign { RECTIFIED_RIGHT(0), RECTIFIED_LEFT(1), CENTER(2); /** Num frames in output pool */ public native int numFramesPool(); public native StereoDepthProperties numFramesPool(int setter); + + /** + * Number of shaves reserved for stereo depth post processing. + * Post processing can use multiple shaves to increase performance. + * -1 means auto, resources will be allocated based on enabled filters. + * 0 means that it will reuse the shave assigned for main stereo algorithm. + * For optimal performance it's recommended to allocate more than 0, + * so post processing will run in parallel with main stereo algorithm. + */ + public native @Cast("std::int32_t") int numPostProcessingShaves(); public native StereoDepthProperties numPostProcessingShaves(int setter); + + /** + * Number of memory slices reserved for stereo depth post processing. + * -1 means auto, memory will be allocated based on initial stereo settings and number of shaves. + * 0 means that it will reuse the memory slices assigned for main stereo algorithm. + * For optimal performance it's recommended to allocate more than 0, + * so post processing will run in parallel with main stereo algorithm. + */ + public native @Cast("std::int32_t") int numPostProcessingMemorySlices(); public native StereoDepthProperties numPostProcessingMemorySlices(int setter); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesNode.java new file mode 100644 index 00000000000..cd4a42878cc --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StereoDepthPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public StereoDepthPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef StereoDepthProperties properties(); public native StereoDepthPropertiesNode properties(StereoDepthProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesSerializable.java new file mode 100644 index 00000000000..9b9130141ff --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/StereoDepthPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StereoDepthPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public StereoDepthPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public StereoDepthPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public StereoDepthPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public StereoDepthPropertiesSerializable position(long position) { + return (StereoDepthPropertiesSerializable)super.position(position); + } + @Override public StereoDepthPropertiesSerializable getPointer(long i) { + return new StereoDepthPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMap.java b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMap.java index 7fadaa66b3d..592d07531de 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMap.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMap.java @@ -16,20 +16,22 @@ import static org.bytedeco.depthai.global.depthai.*; -@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) public class StringNodeInputMap extends Pointer { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public StringNodeInputMap(Pointer p) { super(p); } public StringNodeInputMap() { allocate(); } private native void allocate(); - + public native @Name("operator =") @ByRef StringNodeInputMap put(@ByRef StringNodeInputMap x); public boolean empty() { return size() == 0; } public native long size(); - @Index(function = "at") public native @ByRef Node.Input get(@StdString BytePointer i); + @Index public native Node.Input get(@StdString BytePointer i); + public native StringNodeInputMap put(@StdString BytePointer i, Node.Input value); + public native void erase(@ByVal Iterator pos); public native @ByVal Iterator begin(); public native @ByVal Iterator end(); @NoOffset @Name("iterator") public static class Iterator extends Pointer { @@ -39,7 +41,7 @@ public Iterator() { } public native @Name("operator ++") @ByRef Iterator increment(); public native @Name("operator ==") boolean equals(@ByRef Iterator it); public native @Name("operator *().first") @MemberGetter @StdString BytePointer first(); - public native @Name("operator *().second") @MemberGetter @ByRef @Const Node.Input second(); + public native @Name("operator *().second") @MemberGetter @Const Node.Input second(); } } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMapMap.java b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMapMap.java new file mode 100644 index 00000000000..1c2b86e1038 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeInputMapMap.java @@ -0,0 +1,47 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StringNodeInputMapMap extends Pointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public StringNodeInputMapMap(Pointer p) { super(p); } + public StringNodeInputMapMap() { allocate(); } + private native void allocate(); + public native @Name("operator =") @ByRef StringNodeInputMapMap put(@ByRef StringNodeInputMapMap x); + + public boolean empty() { return size() == 0; } + public native long size(); + + @Index public native Node.InputMap get(@StdString BytePointer i); + public native StringNodeInputMapMap put(@StdString BytePointer i, Node.InputMap value); + + public native void erase(@ByVal Iterator pos); + public native @ByVal Iterator begin(); + public native @ByVal Iterator end(); + @NoOffset @Name("iterator") public static class Iterator extends Pointer { + public Iterator(Pointer p) { super(p); } + public Iterator() { } + + public native @Name("operator ++") @ByRef Iterator increment(); + public native @Name("operator ==") boolean equals(@ByRef Iterator it); + public native @Name("operator *().first") @MemberGetter @StdString BytePointer first(); + public native @Name("operator *().second") @MemberGetter @Const Node.InputMap second(); + } +} + diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMap.java b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMap.java index 20b7cd736ee..44aba38641c 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMap.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMap.java @@ -16,20 +16,22 @@ import static org.bytedeco.depthai.global.depthai.*; -@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) public class StringNodeOutputMap extends Pointer { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public StringNodeOutputMap(Pointer p) { super(p); } public StringNodeOutputMap() { allocate(); } private native void allocate(); - + public native @Name("operator =") @ByRef StringNodeOutputMap put(@ByRef StringNodeOutputMap x); public boolean empty() { return size() == 0; } public native long size(); - @Index(function = "at") public native @ByRef Node.Output get(@StdString BytePointer i); + @Index public native Node.Output get(@StdString BytePointer i); + public native StringNodeOutputMap put(@StdString BytePointer i, Node.Output value); + public native void erase(@ByVal Iterator pos); public native @ByVal Iterator begin(); public native @ByVal Iterator end(); @NoOffset @Name("iterator") public static class Iterator extends Pointer { @@ -39,7 +41,7 @@ public Iterator() { } public native @Name("operator ++") @ByRef Iterator increment(); public native @Name("operator ==") boolean equals(@ByRef Iterator it); public native @Name("operator *().first") @MemberGetter @StdString BytePointer first(); - public native @Name("operator *().second") @MemberGetter @ByRef @Const Node.Output second(); + public native @Name("operator *().second") @MemberGetter @Const Node.Output second(); } } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMapMap.java b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMapMap.java new file mode 100644 index 00000000000..de063c45be9 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/StringNodeOutputMapMap.java @@ -0,0 +1,47 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("std::unordered_map") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StringNodeOutputMapMap extends Pointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public StringNodeOutputMapMap(Pointer p) { super(p); } + public StringNodeOutputMapMap() { allocate(); } + private native void allocate(); + public native @Name("operator =") @ByRef StringNodeOutputMapMap put(@ByRef StringNodeOutputMapMap x); + + public boolean empty() { return size() == 0; } + public native long size(); + + @Index public native Node.OutputMap get(@StdString BytePointer i); + public native StringNodeOutputMapMap put(@StdString BytePointer i, Node.OutputMap value); + + public native void erase(@ByVal Iterator pos); + public native @ByVal Iterator begin(); + public native @ByVal Iterator end(); + @NoOffset @Name("iterator") public static class Iterator extends Pointer { + public Iterator(Pointer p) { super(p); } + public Iterator() { } + + public native @Name("operator ++") @ByRef Iterator increment(); + public native @Name("operator ==") boolean equals(@ByRef Iterator it); + public native @Name("operator *().first") @MemberGetter @StdString BytePointer first(); + public native @Name("operator *().second") @MemberGetter @Const Node.OutputMap second(); + } +} + diff --git a/depthai/src/gen/java/org/bytedeco/depthai/StringStringTuple.java b/depthai/src/gen/java/org/bytedeco/depthai/StringStringTuple.java new file mode 100644 index 00000000000..deca651bc31 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/StringStringTuple.java @@ -0,0 +1,35 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@NoOffset @Name("std::tuple") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class StringStringTuple extends Pointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public StringStringTuple(Pointer p) { super(p); } + public StringStringTuple(@StdString BytePointer value0, @StdString BytePointer value1) { allocate(value0, value1); } + private native void allocate(@StdString BytePointer value0, @StdString BytePointer value1); + public StringStringTuple() { allocate(); } + private native void allocate(); + public native @Name("operator =") @ByRef StringStringTuple put(@ByRef StringStringTuple x); + + public @StdString BytePointer get0() { return get0(this); } + @Namespace @Name("std::get<0>") public static native @StdString BytePointer get0(@ByRef StringStringTuple container); + public @StdString BytePointer get1() { return get1(this); } + @Namespace @Name("std::get<1>") public static native @StdString BytePointer get1(@ByRef StringStringTuple container); +} + diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SystemLogger.java b/depthai/src/gen/java/org/bytedeco/depthai/SystemLogger.java index 821b39f4c59..816c0f00c9b 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SystemLogger.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SystemLogger.java @@ -21,15 +21,17 @@ * \brief SystemLogger node. Send system information periodically. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SystemLogger extends Node { +public class SystemLogger extends SystemLoggerPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public SystemLogger(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public SystemLogger(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public SystemLogger(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SystemLoggerProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr SystemLoggerProperties props); /** * Outputs SystemInformation message that carries various system information @@ -38,8 +40,13 @@ public class SystemLogger extends Node { @MemberGetter public native @ByRef Output out(); /** - * Specify logging rate, at which messages will be sent to out output + * Specify logging rate, at which messages will be sent out * @param hz Sending rate in hertz (messages per second) */ public native void setRate(float hz); + + /** + * Gets logging rate, at which messages will be sent out + */ + public native float getRate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerProperties.java index c61be33fa26..42c2438e410 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerProperties.java @@ -20,8 +20,8 @@ /** * SystemLoggerProperties structure */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class SystemLoggerProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SystemLoggerProperties extends SystemLoggerPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public SystemLoggerProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesNode.java new file mode 100644 index 00000000000..106b63eb7bc --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SystemLoggerPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SystemLoggerPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SystemLoggerProperties properties(); public native SystemLoggerPropertiesNode properties(SystemLoggerProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesSerializable.java new file mode 100644 index 00000000000..78d61cece62 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/SystemLoggerPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class SystemLoggerPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public SystemLoggerPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public SystemLoggerPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public SystemLoggerPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public SystemLoggerPropertiesSerializable position(long position) { + return (SystemLoggerPropertiesSerializable)super.position(position); + } + @Override public SystemLoggerPropertiesSerializable getPointer(long i) { + return new SystemLoggerPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/VectorWriter.java b/depthai/src/gen/java/org/bytedeco/depthai/VectorWriter.java new file mode 100644 index 00000000000..f2a027f9b2a --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/VectorWriter.java @@ -0,0 +1,63 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + + +// // Json-Msgpack serialization +// template +// inline void serialize(const T& obj, std::vector& data){ +// nlohmann::json j = obj; +// data = nlohmann::json::to_msgpack(j); +// } +// template +// inline std::vector serialize(const T& obj){ +// std::vector data; +// serialize(obj, data); +// return data; +// } +// +// // Json-Msgpack deserialization +// template +// inline void deserialize(const std::uint8_t* data, std::size_t size, T& obj){ +// nlohmann::from_json(nlohmann::json::from_msgpack(data, data + size), obj); +// } +// template +// inline void deserialize(const std::vector& data, T& obj){ +// deserialize(data.data(), data.size(), obj); +// } + +@Namespace("dai::utility") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class VectorWriter extends Pointer { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public VectorWriter(Pointer p) { super(p); } + + public VectorWriter(@Const @ByRef VectorWriter arg0) { super((Pointer)null); allocate(arg0); } + private native void allocate(@Const @ByRef VectorWriter arg0); + public native @ByRef @Name("operator =") VectorWriter put(@Const @ByRef VectorWriter arg0); + + public native @ByVal @Cast("nop::Status*") Pointer Prepare(@Cast("std::size_t") long arg0); + + public native @ByVal @Cast("nop::Status*") Pointer Write(@Cast("std::uint8_t") byte _byte); + + public native @ByVal @Cast("nop::Status*") Pointer Write(@Const Pointer begin, @Const Pointer end); + + public native @ByVal @Cast("nop::Status*") Pointer Skip(@Cast("std::size_t") long padding_bytes, @Cast("std::uint8_t") byte padding_value/*=0x00*/); + public native @ByVal @Cast("nop::Status*") Pointer Skip(@Cast("std::size_t") long padding_bytes); + public native @Cast("std::uint8_t*") @StdVector BytePointer ref(); + public native @Cast("std::uint8_t*") @StdVector BytePointer take(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoder.java b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoder.java index f30d03ee6ba..82fa016c1f9 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoder.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoder.java @@ -21,15 +21,17 @@ * \brief VideoEncoder node. Encodes frames into MJPEG, H264 or H265. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class VideoEncoder extends Node { +public class VideoEncoder extends VideoEncoderPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public VideoEncoder(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public VideoEncoder(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public VideoEncoder(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr VideoEncoderProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr VideoEncoderProperties props); /** * Input for NV12 ImgFrame to be encoded diff --git a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderProperties.java index 751dbf1e688..1ff2b4ac413 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for VideoEncoder such as profile, bitrate, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class VideoEncoderProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class VideoEncoderProperties extends VideoEncoderPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public VideoEncoderProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesNode.java new file mode 100644 index 00000000000..e68be5785a5 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class VideoEncoderPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public VideoEncoderPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef VideoEncoderProperties properties(); public native VideoEncoderPropertiesNode properties(VideoEncoderProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesSerializable.java new file mode 100644 index 00000000000..ce83e7b6f4c --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/VideoEncoderPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class VideoEncoderPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public VideoEncoderPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public VideoEncoderPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public VideoEncoderPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public VideoEncoderPropertiesSerializable position(long position) { + return (VideoEncoderPropertiesSerializable)super.position(position); + } + @Override public VideoEncoderPropertiesSerializable getPointer(long i) { + return new VideoEncoderPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkIn.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkIn.java index 474e9098ee3..b44a42896e7 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/XLinkIn.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkIn.java @@ -21,15 +21,16 @@ * \brief XLinkIn node. Receives messages over XLink. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class XLinkIn extends Node { +public class XLinkIn extends XLinkInPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public XLinkIn(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public XLinkIn(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public XLinkIn(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr XLinkInProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr XLinkInProperties props); /** * Outputs message of same type as send from host. diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkInProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInProperties.java index c630af73d4b..44fecdbdde5 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/XLinkInProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for XLinkIn such as stream name, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class XLinkInProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkInProperties extends XLinkInPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public XLinkInProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesNode.java new file mode 100644 index 00000000000..89bf149df74 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkInPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public XLinkInPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef XLinkInProperties properties(); public native XLinkInPropertiesNode properties(XLinkInProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesSerializable.java new file mode 100644 index 00000000000..0b22459bbb5 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkInPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkInPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public XLinkInPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public XLinkInPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public XLinkInPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public XLinkInPropertiesSerializable position(long position) { + return (XLinkInPropertiesSerializable)super.position(position); + } + @Override public XLinkInPropertiesSerializable getPointer(long i) { + return new XLinkInPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOut.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOut.java index 19c4e969a06..e6c523d3759 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOut.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOut.java @@ -21,18 +21,19 @@ * \brief XLinkOut node. Sends messages over XLink. */ @Namespace("dai::node") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class XLinkOut extends Node { +public class XLinkOut extends XLinkOutPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public XLinkOut(Pointer p) { super(p); } - public native @StdString @Override BytePointer getName(); - + @MemberGetter public static native @Cast("const char*") BytePointer NAME(); public XLinkOut(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public XLinkOut(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr XLinkOutProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr XLinkOutProperties props); /** - * Input for any type of messages to be transfered over XLink stream + * Input for any type of messages to be transferred over XLink stream * * Default queue is blocking with size 8 */ diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutProperties.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutProperties.java index d7aa25783f3..0ef9cbc3e21 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutProperties.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutProperties.java @@ -20,8 +20,8 @@ /** * Specify properties for XLinkOut such as stream name, ... */ -@Namespace("dai") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class XLinkOutProperties extends Pointer { +@Namespace("dai") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkOutProperties extends XLinkOutPropertiesSerializable { static { Loader.load(); } /** Default native constructor. */ public XLinkOutProperties() { super((Pointer)null); allocate(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesNode.java new file mode 100644 index 00000000000..2b347c34d57 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkOutPropertiesNode extends Node { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public XLinkOutPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef XLinkOutProperties properties(); public native XLinkOutPropertiesNode properties(XLinkOutProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesSerializable.java b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesSerializable.java new file mode 100644 index 00000000000..3e54e2efe9b --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/XLinkOutPropertiesSerializable.java @@ -0,0 +1,42 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::PropertiesSerializable") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class XLinkOutPropertiesSerializable extends DaiProperties { + static { Loader.load(); } + /** Default native constructor. */ + public XLinkOutPropertiesSerializable() { super((Pointer)null); allocate(); } + /** Native array allocator. Access with {@link Pointer#position(long)}. */ + public XLinkOutPropertiesSerializable(long size) { super((Pointer)null); allocateArray(size); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public XLinkOutPropertiesSerializable(Pointer p) { super(p); } + private native void allocate(); + private native void allocateArray(long size); + @Override public XLinkOutPropertiesSerializable position(long position) { + return (XLinkOutPropertiesSerializable)super.position(position); + } + @Override public XLinkOutPropertiesSerializable getPointer(long i) { + return new XLinkOutPropertiesSerializable((Pointer)this).offsetAddress(i); + } + + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector BytePointer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector ByteBuffer data); + public native @Override void serialize(@Cast("std::uint8_t*") @StdVector byte[] data); + + public native @UniquePtr @Override DaiProperties clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetwork.java index f03af1e9b6a..eb47a8f5e1e 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetwork.java @@ -21,13 +21,15 @@ * \brief YoloDetectionNetwork node. Parses Yolo results */ @Namespace("dai::node") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class YoloDetectionNetwork extends DetectionNetwork { +public class YoloDetectionNetwork extends YoloDetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public YoloDetectionNetwork(Pointer p) { super(p); } public YoloDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + public YoloDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr DetectionNetworkProperties props) { super((Pointer)null); allocate(par, nodeId, props); } + private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId, @UniquePtr DetectionNetworkProperties props); /** Set num classes */ public native void setNumClasses(int numClasses); @@ -41,4 +43,15 @@ public class YoloDetectionNetwork extends DetectionNetwork { public native void setAnchorMasks(@ByVal StringIntVectorMap anchorMasks); /** Set Iou threshold */ public native void setIouThreshold(float thresh); + + /** Get num classes */ + public native int getNumClasses(); + /** Get coordianate size */ + public native int getCoordinateSize(); + /** Get anchors */ + public native @StdVector FloatPointer getAnchors(); + /** Get anchor masks */ + public native @ByVal StringIntVectorMap getAnchorMasks(); + /** Get Iou threshold */ + public native float getIouThreshold(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..7249847929d --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/YoloDetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class YoloDetectionNetworkPropertiesNode extends DetectionNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public YoloDetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef DetectionNetworkProperties properties(); public native YoloDetectionNetworkPropertiesNode properties(DetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetwork.java b/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetwork.java index 0a28221998c..5c3bd4042a1 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetwork.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetwork.java @@ -21,13 +21,14 @@ * YoloSpatialDetectionNetwork node. (tiny)Yolov3/v4 based network with spatial location data. */ @Namespace("dai::node") @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) -public class YoloSpatialDetectionNetwork extends SpatialDetectionNetwork { +public class YoloSpatialDetectionNetwork extends YoloSpatialDetectionNetworkPropertiesNode { static { Loader.load(); } /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ public YoloSpatialDetectionNetwork(Pointer p) { super(p); } public YoloSpatialDetectionNetwork(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId) { super((Pointer)null); allocate(par, nodeId); } private native void allocate(@SharedPtr PipelineImpl par, @Cast("int64_t") long nodeId); + /** Set num classes */ public native void setNumClasses(int numClasses); /** Set coordianate size */ @@ -40,4 +41,15 @@ public class YoloSpatialDetectionNetwork extends SpatialDetectionNetwork { public native void setAnchorMasks(@ByVal StringIntVectorMap anchorMasks); /** Set Iou threshold */ public native void setIouThreshold(float thresh); + + /** Get num classes */ + public native int getNumClasses(); + /** Get coordianate size */ + public native int getCoordinateSize(); + /** Get anchors */ + public native @StdVector FloatPointer getAnchors(); + /** Get anchor masks */ + public native @ByVal StringIntVectorMap getAnchorMasks(); + /** Get Iou threshold */ + public native float getIouThreshold(); } diff --git a/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetworkPropertiesNode.java b/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetworkPropertiesNode.java new file mode 100644 index 00000000000..b699e0482f7 --- /dev/null +++ b/depthai/src/gen/java/org/bytedeco/depthai/YoloSpatialDetectionNetworkPropertiesNode.java @@ -0,0 +1,29 @@ +// Targeted by JavaCPP version 1.5.7-SNAPSHOT: DO NOT EDIT THIS FILE + +package org.bytedeco.depthai; + +import java.nio.*; +import org.bytedeco.javacpp.*; +import org.bytedeco.javacpp.annotation.*; + +import static org.bytedeco.javacpp.presets.javacpp.*; +import static org.bytedeco.openblas.global.openblas_nolapack.*; +import static org.bytedeco.openblas.global.openblas.*; +import org.bytedeco.opencv.opencv_core.*; +import static org.bytedeco.opencv.global.opencv_core.*; +import org.bytedeco.opencv.opencv_imgproc.*; +import static org.bytedeco.opencv.global.opencv_imgproc.*; + +import static org.bytedeco.depthai.global.depthai.*; + +@Name("dai::NodeCRTP") @NoOffset @Properties(inherit = org.bytedeco.depthai.presets.depthai.class) +public class YoloSpatialDetectionNetworkPropertiesNode extends SpatialDetectionNetwork { + static { Loader.load(); } + /** Pointer cast constructor. Invokes {@link Pointer#Pointer(Pointer)}. */ + public YoloSpatialDetectionNetworkPropertiesNode(Pointer p) { super(p); } + + /** Underlying properties */ + public native @Cast("dai::NodeCRTP::Properties*") @ByRef SpatialDetectionNetworkProperties properties(); public native YoloSpatialDetectionNetworkPropertiesNode properties(SpatialDetectionNetworkProperties setter); + public native @Override @Cast("const char*") BytePointer getName(); + public native @UniquePtr @Override Node clone(); +} diff --git a/depthai/src/gen/java/org/bytedeco/depthai/global/depthai.java b/depthai/src/gen/java/org/bytedeco/depthai/global/depthai.java index 65b54ca0804..33e5cefec24 100644 --- a/depthai/src/gen/java/org/bytedeco/depthai/global/depthai.java +++ b/depthai/src/gen/java/org/bytedeco/depthai/global/depthai.java @@ -55,6 +55,9 @@ public class depthai extends org.bytedeco.depthai.presets.depthai { // Targeting ../NodeVector.java +// Targeting ../StringStringTuple.java + + // Targeting ../FloatVectorVectorIntIntTuple.java @@ -82,6 +85,18 @@ public class depthai extends org.bytedeco.depthai.presets.depthai { // Targeting ../StringNodeIoInfoMap.java +// Targeting ../StringNodeInputMap.java + + +// Targeting ../StringNodeOutputMap.java + + +// Targeting ../StringNodeInputMapMap.java + + +// Targeting ../StringNodeOutputMapMap.java + + // Targeting ../ConnectionSet.java @@ -289,11 +304,66 @@ public class depthai extends org.bytedeco.depthai.presets.depthai { // namespace dai -// Parsed from depthai-shared/common/CameraBoardSocket.hpp +// Parsed from depthai-shared/utility/Serialization.hpp // #pragma once +// std +// #include +// #include +// #include + +// libraries +// #include +// #include +// #include +// #include + // #include + +// To not require exceptions for embedded usecases. +// #ifndef __has_feature // Optional of course. +// #define __has_feature(x) 0 // Compatibility with non-clang compilers. +// #endif +// #if __has_feature(cxx_exceptions) || defined(__cpp_exceptions) || (defined(_MSC_VER) && defined(_CPPUNWIND)) || defined(__EXCEPTIONS) +// #define DEPTHAI_EXCEPTIONS +// #endif +// Targeting ../VectorWriter.java + + + +// libnop serialization +// If exceptions are available it throws in error cases +// Otherwise return value can be checked + +// libnop deserialization + + // namespace utility + +// // In dai scope +// template +// struct Serializable : Base { +// virtual void serialize(std::vector& data) { +// utility::serialize(static_cast(*this), data); +// } +// }; + + // namespace dai + +// Macros +// #define DEPTHAI_SERIALIZE_EXT(...) +// NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE(__VA_ARGS__) +// NOP_EXTERNAL_STRUCTURE(__VA_ARGS__) + +// #define DEPTHAI_SERIALIZE(...) +// NLOHMANN_DEFINE_TYPE_INTRUSIVE(__VA_ARGS__) +// NOP_STRUCTURE(__VA_ARGS__) + + +// Parsed from depthai-shared/common/CameraBoardSocket.hpp + +// #pragma once +// #include /** * Which Camera socket to use. * @@ -314,8 +384,7 @@ public class depthai extends org.bytedeco.depthai.presets.depthai { // Parsed from depthai-shared/common/CameraImageOrientation.hpp // #pragma once - -// #include +// #include /** * Camera sensor image orientation / pixel readout. * This exposes direct sensor settings. 90 or 270 degrees rotation is not available. @@ -338,22 +407,26 @@ public class depthai extends org.bytedeco.depthai.presets.depthai { // #pragma once -// #include +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../ChipTemperature.java + + // namespace dai // Parsed from depthai-shared/common/CpuUsage.hpp // #pragma once -// #include +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../CpuUsage.java + + // namespace dai // Parsed from depthai-shared/common/DetectionNetworkType.hpp @@ -376,11 +449,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../MemoryInfo.java + + // namespace dai // Parsed from depthai-shared/common/Point2f.hpp @@ -390,12 +465,14 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include "nlohmann/json.hpp" +// project +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Point2f.java + + // namespace dai @@ -406,12 +483,14 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include "nlohmann/json.hpp" +// project +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Point3f.java + + // namespace dai @@ -422,12 +501,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include "nlohmann/json.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Size2f.java + + // namespace dai @@ -440,11 +520,12 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/Point2f.hpp" // #include "depthai-shared/common/Size2f.hpp" -// #include "nlohmann/json.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Rect.java + // namespace dai // Parsed from depthai-shared/common/RotatedRect.hpp @@ -454,16 +535,16 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include "nlohmann/json.hpp" - // shared // #include "depthai-shared/common/Point2f.hpp" // #include "depthai-shared/common/Size2f.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RotatedRect.java + + // namespace dai @@ -475,6 +556,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/CameraBoardSocket.hpp" // #include "depthai-shared/common/Point3f.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Extrinsics.java @@ -485,7 +567,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include /** * Which CameraModel to initialize the calibration with. */ @@ -506,6 +588,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/CameraModel.hpp" // #include "depthai-shared/common/Extrinsics.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../CameraInfo.java @@ -519,10 +602,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include // #include "depthai-shared/common/CameraBoardSocket.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../StereoRectification.java + + // namespace dai @@ -538,9 +624,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/Extrinsics.hpp" // #include "depthai-shared/common/Point3f.hpp" // #include "depthai-shared/common/StereoRectification.hpp" - -// libraries -// #include "nlohmann/json.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../EepromData.java @@ -553,16 +637,16 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // std -// #include - -// libraries // #include +// #include -// #include "nlohmann/json.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Timestamp.java + + // namespace dai @@ -629,10 +713,10 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RawBuffer.java @@ -647,24 +731,32 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "RawBuffer.hpp" // #include "depthai-shared/common/Point3f.hpp" // #include "depthai-shared/common/Timestamp.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../IMUReport.java + // Targeting ../IMUReportAccelerometer.java + // Targeting ../IMUReportGyroscope.java + // Targeting ../IMUReportMagneticField.java + // Targeting ../IMUReportRotationVectorWAcc.java + // Targeting ../IMUPacket.java + + // Targeting ../RawIMUData.java @@ -676,11 +768,11 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" // #include "RawBuffer.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RawCameraControl.java @@ -696,6 +788,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "RawBuffer.hpp" // #include "depthai-shared/common/Timestamp.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RawImgFrame.java @@ -709,9 +802,12 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "RawBuffer.hpp" // #include "depthai-shared/common/Point3f.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../ImgDetection.java + + // Targeting ../RawImgDetections.java @@ -723,7 +819,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" @@ -734,6 +829,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/Point2f.hpp" // #include "depthai-shared/common/RotatedRect.hpp" // #include "depthai-shared/common/Size2f.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RawImageManipConfig.java @@ -746,6 +842,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include "RawBuffer.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../TensorInfo.java @@ -763,9 +860,12 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "RawBuffer.hpp" // #include "RawImgDetections.hpp" // #include "depthai-shared/common/Point3f.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../SpatialImgDetection.java + + // Targeting ../RawSpatialImgDetections.java @@ -777,17 +877,18 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" // #include "RawBuffer.hpp" // #include "RawImgFrame.hpp" // #include "depthai-shared/common/Rect.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../SpatialLocationCalculatorConfigThresholds.java + @Namespace("dai") public enum SpatialLocationCalculatorAlgorithm { AVERAGE(0), MIN(1), MAX(2); public final int value; @@ -799,6 +900,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // Targeting ../SpatialLocationCalculatorConfigData.java + // Targeting ../RawSpatialLocationCalculatorConfig.java @@ -810,7 +912,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" @@ -818,9 +919,11 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "RawSpatialLocationCalculatorConfig.hpp" // #include "depthai-shared/common/Point3f.hpp" // #include "depthai-shared/common/Rect.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../SpatialLocations.java + // Targeting ../RawSpatialLocations.java @@ -833,11 +936,11 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include // #include -// #include // #include // #include "DatatypeEnum.hpp" // #include "RawBuffer.hpp" +// #include "depthai-shared/utility/Serialization.hpp" /** * Median filter config for disparity post-processing @@ -861,7 +964,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include // #include // #include "DatatypeEnum.hpp" @@ -869,6 +971,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/ChipTemperature.hpp" // #include "depthai-shared/common/CpuUsage.hpp" // #include "depthai-shared/common/MemoryInfo.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../RawSystemInformation.java @@ -886,6 +989,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "depthai-shared/common/Point3f.hpp" // #include "depthai-shared/common/Rect.hpp" // #include "depthai-shared/datatype/RawImgDetections.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../Tracklet.java @@ -906,6 +1010,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // project // #include "depthai-shared/common/UsbSpeed.hpp" // #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // #include "depthai-shared/xlink/XLinkConstants.hpp" @Namespace("dai") @MemberGetter public static native @Cast("const uint32_t") int PREBOOT_CONFIG_MAGIC1(); @@ -916,6 +1021,9 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); + + + // namespace dai @@ -926,8 +1034,8 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include +// project +// #include "depthai-shared/utility/Serialization.hpp" // Follows spdlog levels @Namespace("dai") public enum LogLevel { TRACE(0), DEBUG(1), INFO(2), WARN(3), ERR(4), CRITICAL(5), OFF(6); @@ -949,16 +1057,16 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include - // project // #include "LogLevel.hpp" // #include "depthai-shared/common/Timestamp.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../LogMessage.java + + // namespace dai @@ -983,16 +1091,79 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // Watchdog timeout @Namespace("dai::device") @MemberGetter public static native @ByRef @Cast("const std::chrono::milliseconds*") Pointer XLINK_WATCHDOG_TIMEOUT(); +// Maximum metadata size +@Namespace("dai::device") @MemberGetter public static native int XLINK_MESSAGE_METADATA_MAX_SIZE(); +public static final int XLINK_MESSAGE_METADATA_MAX_SIZE = XLINK_MESSAGE_METADATA_MAX_SIZE(); + // namespace device // namespace dai +// Parsed from depthai-shared/properties/Properties.hpp + +// #pragma once + +// #include "depthai-shared/utility/Serialization.hpp" +// Targeting ../DaiProperties.java + + +// Targeting ../IMUPropertiesSerializable.java + + +// Targeting ../ColorCameraPropertiesSerializable.java + + +// Targeting ../MonoCameraPropertiesSerializable.java + + +// Targeting ../ImageManipPropertiesSerializable.java + + +// Targeting ../GlobalPropertiesSerializable.java + + +// Targeting ../NeuralNetworkPropertiesSerializable.java + + +// Targeting ../DetectionNetworkPropertiesSerializable.java + + +// Targeting ../ObjectTrackerPropertiesSerializable.java + + +// Targeting ../SPIOutPropertiesSerializable.java + + +// Targeting ../SpatialDetectionNetworkPropertiesSerializable.java + + +// Targeting ../SpatialLocationCalculatorPropertiesSerializable.java + + +// Targeting ../StereoDepthPropertiesSerializable.java + + +// Targeting ../SystemLoggerPropertiesSerializable.java + + +// Targeting ../VideoEncoderPropertiesSerializable.java + + +// Targeting ../XLinkInPropertiesSerializable.java + + +// Targeting ../XLinkOutPropertiesSerializable.java + + + + // namespace dai + // Parsed from depthai-shared/properties/IMUProperties.hpp // #pragma once -// #include -// #include +// #include "depthai-shared/datatype/RawIMUData.hpp" +// #include "depthai-shared/properties/Properties.hpp" /** * Available IMU sensors. @@ -1133,10 +1304,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // Targeting ../IMUSensorConfig.java + // Targeting ../IMUProperties.java + + // namespace dai @@ -1144,14 +1318,15 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include - // #include "depthai-shared/common/EepromData.hpp" +// #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../GlobalProperties.java + + // namespace dai @@ -1159,15 +1334,16 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include - // #include "depthai-shared/common/CameraBoardSocket.hpp" // #include "depthai-shared/common/CameraImageOrientation.hpp" +// #include "depthai-shared/datatype/RawCameraControl.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../ColorCameraProperties.java + + // namespace dai @@ -1175,13 +1351,15 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include -// #include +// #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/datatype/RawImageManipConfig.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../ImageManipProperties.java + + // namespace dai @@ -1189,15 +1367,16 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include - // #include "depthai-shared/common/CameraBoardSocket.hpp" // #include "depthai-shared/common/CameraImageOrientation.hpp" +// #include "depthai-shared/datatype/RawCameraControl.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../MonoCameraProperties.java + + // namespace dai @@ -1205,12 +1384,14 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include +// #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../NeuralNetworkProperties.java + + // namespace dai @@ -1221,9 +1402,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include - // project // #include "NeuralNetworkProperties.hpp" // #include "depthai-shared/common/DetectionNetworkType.hpp" @@ -1232,6 +1410,8 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); + + // namespace dai @@ -1242,12 +1422,9 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // std // #include -// libraries -// #include - // project - // #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/properties/Properties.hpp" @Namespace("dai") public enum TrackerType { /** Kernelized Correlation Filter tracking */ @@ -1266,22 +1443,24 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); @Override public String toString() { return intern().name(); } } -@Namespace("dai") public enum TrackerIdAssigmentPolicy { +@Namespace("dai") public enum TrackerIdAssignmentPolicy { /** Always take a new, unique ID */ UNIQUE_ID(0), /** Take the smallest available ID */ SMALLEST_ID(1); public final int value; - private TrackerIdAssigmentPolicy(int v) { this.value = v; } - private TrackerIdAssigmentPolicy(TrackerIdAssigmentPolicy e) { this.value = e.value; } - public TrackerIdAssigmentPolicy intern() { for (TrackerIdAssigmentPolicy e : values()) if (e.value == value) return e; return this; } + private TrackerIdAssignmentPolicy(int v) { this.value = v; } + private TrackerIdAssignmentPolicy(TrackerIdAssignmentPolicy e) { this.value = e.value; } + public TrackerIdAssignmentPolicy intern() { for (TrackerIdAssignmentPolicy e : values()) if (e.value == value) return e; return this; } @Override public String toString() { return intern().name(); } } // Targeting ../ObjectTrackerProperties.java + + // namespace dai @@ -1289,11 +1468,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../SPIOutProperties.java + + // namespace dai @@ -1305,7 +1486,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include // libraries -// #include // project // #include "DetectionNetworkProperties.hpp" @@ -1316,6 +1496,8 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); + + // namespace dai @@ -1323,14 +1505,17 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include -// #include // #include + +// #include "depthai-shared/common/optional.hpp" +// #include "depthai-shared/datatype/RawSpatialLocationCalculatorConfig.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../SpatialLocationCalculatorProperties.java + + // namespace dai @@ -1338,16 +1523,17 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include -// #include - // #include "depthai-shared/common/CameraBoardSocket.hpp" +// #include "depthai-shared/common/EepromData.hpp" +// #include "depthai-shared/common/optional.hpp" // #include "depthai-shared/datatype/RawStereoDepthConfig.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../StereoDepthProperties.java + + // namespace dai @@ -1355,14 +1541,15 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include - // #include "depthai-shared/common/CameraBoardSocket.hpp" // #include "depthai-shared/common/CameraImageOrientation.hpp" +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../SystemLoggerProperties.java + + // namespace dai @@ -1371,11 +1558,14 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include -// #include + +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../VideoEncoderProperties.java + + // namespace dai @@ -1383,13 +1573,14 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include - +// #include "depthai-shared/properties/Properties.hpp" // #include "depthai-shared/xlink/XLinkConstants.hpp" // Targeting ../XLinkInProperties.java + + // namespace dai @@ -1397,11 +1588,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include "depthai-shared/properties/Properties.hpp" // Targeting ../XLinkOutProperties.java + + // namespace dai @@ -1414,8 +1607,8 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include // #include -// libraries -// #include +// project +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../AssetView.java @@ -1430,11 +1623,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../NodeConnectionSchema.java + + // namespace dai @@ -1442,11 +1637,13 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../NodeIoInfo.java + + // namespace dai @@ -1454,39 +1651,33 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once -// #include -// #include +// #include // #include "NodeIoInfo.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../NodeObjInfo.java + + // namespace dai // Parsed from depthai-shared/pipeline/PipelineSchema.hpp -// To parse this JSON data, first install -// -// Boost http://www.boost.org -// json.hpp https://github.com/nlohmann/json -// -// Then include this file, and then do -// -// PipelineSchema.hpp data = nlohmann::json::parse(jsonString); - // #pragma once -// #include - // #include "NodeConnectionSchema.hpp" // #include "NodeObjInfo.hpp" // #include "depthai-shared/properties/GlobalProperties.hpp" +// #include "depthai-shared/utility/Serialization.hpp" // Targeting ../PipelineSchema.java + + // namespace dai @@ -1801,6 +1992,7 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #pragma once // #include +// #include // #include // #include // #include @@ -1808,17 +2000,72 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // project // #include "depthai/openvino/OpenVINO.hpp" // #include "depthai/pipeline/AssetManager.hpp" +// #include "depthai/utility/copyable_unique_ptr.hpp" // depthai-shared // #include "depthai-shared/datatype/DatatypeEnum.hpp" +// #include "depthai-shared/properties/Properties.hpp" // libraries -// #include "nlohmann/json.hpp" // #include "tl/optional.hpp" // fwd declare Pipeline // Targeting ../Node.java +// Targeting ../IMUPropertiesNode.java + + +// Targeting ../ColorCameraPropertiesNode.java + + +// Targeting ../ImageManipPropertiesNode.java + + +// Targeting ../NeuralNetworkPropertiesNode.java + + +// Targeting ../DetectionNetworkPropertiesNode.java + + +// Targeting ../MobileNetDetectionNetworkPropertiesNode.java + + +// Targeting ../YoloDetectionNetworkPropertiesNode.java + + +// Targeting ../ObjectTrackerPropertiesNode.java + + +// Targeting ../SPIOutPropertiesNode.java + + +// Targeting ../SpatialDetectionNetworkPropertiesNode.java + + +// Targeting ../MobileNetSpatialDetectionNetworkPropertiesNode.java + + +// Targeting ../YoloSpatialDetectionNetworkPropertiesNode.java + + +// Targeting ../SpatialLocationCalculatorPropertiesNode.java + + +// Targeting ../StereoDepthPropertiesNode.java + + +// Targeting ../SystemLoggerPropertiesNode.java + + +// Targeting ../VideoEncoderPropertiesNode.java + + +// Targeting ../XLinkInPropertiesNode.java + + +// Targeting ../XLinkOutPropertiesNode.java + + // Targeting ../ConnectionHash.java @@ -1871,7 +2118,6 @@ public enum DetectionNetworkType { YOLO(0), MOBILENET(1); // #include "node/IMU.hpp" // #include "node/ImageManip.hpp" // #include "node/MonoCamera.hpp" -// #include "node/MyProducer.hpp" // #include "node/NeuralNetwork.hpp" // #include "node/ObjectTracker.hpp" // #include "node/SPIIn.hpp" diff --git a/depthai/src/main/java/org/bytedeco/depthai/presets/depthai.java b/depthai/src/main/java/org/bytedeco/depthai/presets/depthai.java index 5056128463a..05554be6684 100644 --- a/depthai/src/main/java/org/bytedeco/depthai/presets/depthai.java +++ b/depthai/src/main/java/org/bytedeco/depthai/presets/depthai.java @@ -1,5 +1,5 @@ /* - * Copyright (C) 2021 Samuel Audet + * Copyright (C) 2021-2022 Samuel Audet * * Licensed either under the Apache License, Version 2.0, or (at your option) * under the terms of the GNU General Public License as published by @@ -46,7 +46,7 @@ @Platform( value = {"linux-arm", "linux-x86", "macosx-x86"}, compiler = "cpp14", - define = {"SHARED_PTR_NAMESPACE std", "XLINK_USE_MX_ID_NAME ON"}, + define = {"SHARED_PTR_NAMESPACE std", "UNIQUE_PTR_NAMESPACE std", "XLINK_USE_MX_ID_NAME ON"}, include = { "XLink/XLinkPublicDefines.h", "depthai/depthai.hpp", @@ -54,6 +54,7 @@ "depthai/utility/Initialization.hpp", "depthai/utility/LockingQueue.hpp", "depthai/utility/Pimpl.hpp", + "depthai-shared/utility/Serialization.hpp", "depthai-shared/common/CameraBoardSocket.hpp", "depthai-shared/common/CameraImageOrientation.hpp", "depthai-shared/common/ChipTemperature.hpp", @@ -90,6 +91,7 @@ "depthai-shared/log/LogLevel.hpp", "depthai-shared/log/LogMessage.hpp", "depthai-shared/xlink/XLinkConstants.hpp", + "depthai-shared/properties/Properties.hpp", "depthai-shared/properties/IMUProperties.hpp", "depthai-shared/properties/GlobalProperties.hpp", "depthai-shared/properties/ColorCameraProperties.hpp", @@ -174,7 +176,7 @@ public class depthai implements InfoMapper { public void map(InfoMap infoMap) { infoMap.put(new Info().enumerate()) .put(new Info("DEPTHAI_HAVE_OPENCV_SUPPORT").define(true)) - .put(new Info("NLOHMANN_DEFINE_TYPE_INTRUSIVE", "NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE").cppTypes().annotations()) + .put(new Info("NLOHMANN_DEFINE_TYPE_INTRUSIVE", "NLOHMANN_DEFINE_TYPE_NON_INTRUSIVE", "NOP_STRUCTURE").cppTypes().annotations()) .put(new Info("std::uint8_t").cast().valueTypes("byte").pointerTypes("BytePointer", "ByteBuffer", "byte[]")) .put(new Info("std::int16_t", "std::uint16_t").cast().valueTypes("short").pointerTypes("ShortPointer", "ShortBuffer", "short[]")) @@ -194,7 +196,9 @@ public void map(InfoMap infoMap) { "std::chrono::time_point", "std::tuple", "std::tuple", "std::tuple", "std::tuple", "std::tuple", "std::tuple", "tl::optional >", - "std::array", "std::array", "std::array", "nlohmann::json").cast().pointerTypes("Pointer")) + "std::array", "std::array", "std::array", "nlohmann::json", + "std::unordered_map,dai::NodeIoInfo,dai::NodeObjInfo::IoInfoKey>", + "dai::copyable_unique_ptr", "nop::Status").cast().pointerTypes("Pointer")) .put(new Info("std::hash").pointerTypes("ConnectionHash")) .put(new Info("std::shared_ptr").annotations("@SharedPtr").pointerTypes("Asset")) .put(new Info("std::shared_ptr").annotations("@SharedPtr").pointerTypes("ADatatype")) @@ -214,6 +218,10 @@ public void map(InfoMap infoMap) { .put(new Info("std::unordered_map >").pointerTypes("NodeIdNodeMap").define()) .put(new Info("std::unordered_map").pointerTypes("LongNodeObjInfoMap").define()) .put(new Info("std::unordered_map").pointerTypes("StringNodeIoInfoMap").define()) + .put(new Info("std::unordered_map").pointerTypes("StringNodeInputMap").define()) + .put(new Info("std::unordered_map").pointerTypes("StringNodeOutputMap").define()) + .put(new Info("std::unordered_map").pointerTypes("StringNodeInputMapMap").define()) + .put(new Info("std::unordered_map").pointerTypes("StringNodeOutputMapMap").define()) .put(new Info("const std::unordered_map", "std::unordered_map").pointerTypes("StringNodeInputMap").define()) .put(new Info("const std::unordered_map", @@ -224,22 +232,100 @@ public void map(InfoMap infoMap) { .put(new Info("tl::optional").pointerTypes("VersionOptional").define()) .put(new Info("tl::optional").pointerTypes("StringOptional").define()) .put(new Info("tl::optional").pointerTypes("EepromDataOptional").define()) + .put(new Info("std::tuple").pointerTypes("StringStringTuple").define()) .put(new Info("std::tuple >,int,int>").pointerTypes("FloatVectorVectorIntIntTuple").define()) .put(new Info("dai::Node").immutable().purify()) .put(new Info("dai::Node::Connection").pointerTypes("Node.Connection")) .put(new Info("dai::Node::Input").pointerTypes("Node.Input")) .put(new Info("dai::Node::Output").pointerTypes("Node.Output")) + .put(new Info("dai::Node::InputMap").pointerTypes("Node.InputMap")) + .put(new Info("dai::Node::OutputMap").pointerTypes("Node.OutputMap")) + .put(new Info("dai::Properties").pointerTypes("DaiProperties")) .put(new Info("dai::node::IMU", "dai::node::ColorCamera", "dai::node::ImageManip", "dai::node::MonoCamera", "dai::node::NeuralNetwork", "dai::node::DetectionNetwork", "dai::node::ObjectTracker", "dai::node::SPIOut", "dai::node::SpatialDetectionNetwork", "dai::node::SpatialLocationCalculator", "dai::node::StereoDepth", "dai::node::SystemLogger", "dai::node::VideoEncoder", "dai::node::XLinkIn", "dai::node::XLinkOut").immutable()) + .put(new Info("dai::node::IMU::Properties").pointerTypes("IMUProperties")) + .put(new Info("dai::node::ColorCamera::Properties").pointerTypes("ColorCameraProperties")) + .put(new Info("dai::node::MonoCamera::Properties").pointerTypes("MonoCameraProperties")) + .put(new Info("dai::node::ImageManip::Properties").pointerTypes("ImageManipProperties")) + .put(new Info("dai::node::NeuralNetwork::Properties").pointerTypes("NeuralNetworkProperties")) + .put(new Info("dai::node::DetectionNetwork::Properties", + "dai::node::MobileNetDetectionNetwork::Properties", + "dai::node::YoloDetectionNetwork::Properties").pointerTypes("DetectionNetworkProperties")) + .put(new Info("dai::node::ObjectTracker::Properties").pointerTypes("ObjectTrackerProperties")) + .put(new Info("dai::node::SPIOut::Properties").pointerTypes("SPIOutProperties")) + .put(new Info("dai::node::SpatialDetectionNetwork::Properties").pointerTypes("SpatialDetectionNetworkProperties")) + .put(new Info("dai::node::SpatialLocationCalculator::Properties").pointerTypes("SpatialLocationCalculatorProperties")) + .put(new Info("dai::node::StereoDepth::Properties").pointerTypes("StereoDepthProperties")) + .put(new Info("dai::node::SystemLogger::Properties").pointerTypes("SystemLoggerProperties")) + .put(new Info("dai::node::VideoEncoder::Properties").pointerTypes("VideoEncoderProperties")) + .put(new Info("dai::node::XLinkIn::Properties").pointerTypes("XLinkInProperties")) + .put(new Info("dai::node::XLinkOut::Properties").pointerTypes("XLinkOutProperties")) .put(new Info("dai::node::ColorCamera::Properties::SensorResolution").pointerTypes("ColorCameraProperties.SensorResolution")) .put(new Info("dai::node::MonoCamera::Properties::SensorResolution").pointerTypes("MonoCameraProperties.SensorResolution")) - .put(new Info("dai::node::StereoDepth::Properties::DepthAlign").pointerTypes("StereoDepthProperties.DepthAlign")) - .put(new Info("dai::node::StereoDepth::Properties::MedianFilter").pointerTypes("StereoDepthProperties.MedianFilter")) +// .put(new Info("dai::node::StereoDepth::Properties::DepthAlign").pointerTypes("StereoDepthProperties.DepthAlign")) +// .put(new Info("dai::node::StereoDepth::Properties::MedianFilter").pointerTypes("StereoDepthProperties.MedianFilter")) .put(new Info("dai::node::VideoEncoder::Properties::Profile").pointerTypes("VideoEncoderProperties.Profile")) .put(new Info("dai::node::VideoEncoder::Properties::RateControlMode").pointerTypes("VideoEncoderProperties.RateControlMode")) + .put(new Info("dai::RawStereoDepthConfig::AlgorithmControl::DepthAlign", + "Properties::DepthAlign", "AlgorithmControl::DepthAlign").enumerate().pointerTypes("RawStereoDepthConfig.AlgorithmControl.DepthAlign")) + .put(new Info("dai::NodeCRTP").pointerTypes("IMUPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("ColorCameraPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("ColorCameraPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("ImageManipPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("NeuralNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("DetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP", + "dai::NodeCRTP").pointerTypes("MobileNetDetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP", + "dai::NodeCRTP").pointerTypes("YoloDetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("ObjectTrackerPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("SPIOutPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("SpatialDetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP", + "dai::NodeCRTP").pointerTypes("MobileNetSpatialDetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP", + "dai::NodeCRTP").pointerTypes("YoloSpatialDetectionNetworkPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("SpatialLocationCalculatorPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("StereoDepthPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("SystemLoggerPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("VideoEncoderPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("XLinkInPropertiesNode")) + .put(new Info("dai::NodeCRTP").pointerTypes("XLinkOutPropertiesNode")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("IMUPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("ColorCameraPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("MonoCameraPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("ImageManipPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("GlobalPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("NeuralNetworkPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("DetectionNetworkPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("ObjectTrackerPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("SPIOutPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("SpatialDetectionNetworkPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("SpatialLocationCalculatorPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("StereoDepthPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("SystemLoggerPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("VideoEncoderPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("XLinkInPropertiesSerializable")) + .put(new Info("dai::PropertiesSerializable", + "dai::PropertiesSerializable").pointerTypes("XLinkOutPropertiesSerializable")) .put(new Info("dai::IMUReport::accuracy").javaNames("reportAccuracy")) .put(new Info("dai::DataInputQueue::send(const std::shared_ptr&)", @@ -316,7 +402,7 @@ public void map(InfoMap infoMap) { + "public native @Name(\"front\") @SharedPtr SpatialLocationCalculatorData frontSpatialLocationCalculatorData();\n" + "public native @Name(\"front\") @SharedPtr StereoDepthConfig frontStereoDepthConfig();\n" + "public native @Name(\"front\") @SharedPtr SystemInformation frontSystemInformation();\n")) - .put(new Info("dai::DeviceBootloader::Version::toString").javaText("public native @StdString String toString();")) + .put(new Info("dai::DeviceBootloader::Version::toString", "dai::Node::toString").javaText("public native @StdString String toString();")) .put(new Info("std::function(std::shared_ptr)>").valueTypes("RawBufferCallback")) .put(new Info("std::function").valueTypes("LogCallback")) diff --git a/platform/pom.xml b/platform/pom.xml index bd5581025cd..bf770d6d6dc 100644 --- a/platform/pom.xml +++ b/platform/pom.xml @@ -249,7 +249,7 @@ org.bytedeco tesseract-platform - 5.0.0-${project.version} + 5.0.1-${project.version} org.bytedeco @@ -314,7 +314,7 @@ org.bytedeco depthai-platform - 2.13.3-${project.version} + 2.14.0-${project.version} org.bytedeco diff --git a/tesseract/README.md b/tesseract/README.md index 62439819586..a1e83abe276 100644 --- a/tesseract/README.md +++ b/tesseract/README.md @@ -9,7 +9,7 @@ Introduction ------------ This directory contains the JavaCPP Presets module for: - * Tesseract 5.0.0 https://github.com/tesseract-ocr + * Tesseract 5.0.1 https://github.com/tesseract-ocr Please refer to the parent README.md file for more detailed information about the JavaCPP Presets. @@ -47,7 +47,7 @@ We can use [Maven 3](http://maven.apache.org/) to download and install automatic org.bytedeco tesseract-platform - 5.0.0-1.5.7-SNAPSHOT + 5.0.1-1.5.7-SNAPSHOT diff --git a/tesseract/cppbuild.sh b/tesseract/cppbuild.sh index 817f9cca5d4..7b85e5f2560 100755 --- a/tesseract/cppbuild.sh +++ b/tesseract/cppbuild.sh @@ -7,7 +7,7 @@ if [[ -z "$PLATFORM" ]]; then exit fi -TESSERACT_VERSION=5.0.0 +TESSERACT_VERSION=5.0.1 download https://github.com/tesseract-ocr/tesseract/archive/$TESSERACT_VERSION.tar.gz tesseract-$TESSERACT_VERSION.tar.gz mkdir -p $PLATFORM diff --git a/tesseract/platform/pom.xml b/tesseract/platform/pom.xml index 5cc075fdf16..67189bfd543 100644 --- a/tesseract/platform/pom.xml +++ b/tesseract/platform/pom.xml @@ -12,7 +12,7 @@ org.bytedeco tesseract-platform - 5.0.0-${project.parent.version} + 5.0.1-${project.parent.version} JavaCPP Presets Platform for Tesseract diff --git a/tesseract/pom.xml b/tesseract/pom.xml index 48c20354bb4..3d7c9b8c2be 100644 --- a/tesseract/pom.xml +++ b/tesseract/pom.xml @@ -11,7 +11,7 @@ org.bytedeco tesseract - 5.0.0-${project.parent.version} + 5.0.1-${project.parent.version} JavaCPP Presets for Tesseract diff --git a/tesseract/samples/pom.xml b/tesseract/samples/pom.xml index 0e88e0c6bb8..d865ef22b7d 100644 --- a/tesseract/samples/pom.xml +++ b/tesseract/samples/pom.xml @@ -12,7 +12,7 @@ org.bytedeco tesseract-platform - 5.0.0-1.5.7-SNAPSHOT + 5.0.1-1.5.7-SNAPSHOT diff --git a/tesseract/src/gen/java/org/bytedeco/tesseract/UNICHAR.java b/tesseract/src/gen/java/org/bytedeco/tesseract/UNICHAR.java index 726707cba55..81e8f2a17c5 100644 --- a/tesseract/src/gen/java/org/bytedeco/tesseract/UNICHAR.java +++ b/tesseract/src/gen/java/org/bytedeco/tesseract/UNICHAR.java @@ -65,10 +65,10 @@ public class UNICHAR extends Pointer { // for (UNICHAR::const_iterator it = UNICHAR::begin(str, str_len); // it != UNICHAR::end(str, len); // ++it) { - // tprintf("UCS-4 symbol code = %d\n", *it); + // printf("UCS-4 symbol code = %d\n", *it); // char buf[5]; // int char_len = it.get_utf8(buf); buf[char_len] = '\0'; - // tprintf("Char = %s\n", buf); + // printf("Char = %s\n", buf); // } @NoOffset public static class const_iterator extends Pointer { static { Loader.load(); } diff --git a/tesseract/src/gen/java/org/bytedeco/tesseract/global/tesseract.java b/tesseract/src/gen/java/org/bytedeco/tesseract/global/tesseract.java index 2c011777fb0..3473aaef987 100644 --- a/tesseract/src/gen/java/org/bytedeco/tesseract/global/tesseract.java +++ b/tesseract/src/gen/java/org/bytedeco/tesseract/global/tesseract.java @@ -26,7 +26,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/export.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: export.h // Description: Place holder // @@ -40,8 +40,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_PLATFORM_H_ // #define TESSERACT_PLATFORM_H_ @@ -69,7 +67,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/osdetect.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: osdetect.h // Description: Orientation and script detection. // Author: Samuel Charron @@ -85,8 +83,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCMAIN_OSDETECT_H_ // #define TESSERACT_CCMAIN_OSDETECT_H_ @@ -161,7 +157,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/unichar.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: unichar.h // Description: Unicode character/ligature class. // Author: Ray Smith @@ -176,8 +172,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCUTIL_UNICHAR_H_ // #define TESSERACT_CCUTIL_UNICHAR_H_ @@ -220,7 +214,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/version.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: version.h // Description: Version information // @@ -234,8 +228,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_API_VERSION_H_ // #define TESSERACT_API_VERSION_H_ @@ -244,14 +236,14 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { public static final int TESSERACT_MAJOR_VERSION = 5; public static final int TESSERACT_MINOR_VERSION = 0; -public static final int TESSERACT_MICRO_VERSION = 0; +public static final int TESSERACT_MICRO_VERSION = 1; public static final int TESSERACT_VERSION = (TESSERACT_MAJOR_VERSION << 16 | TESSERACT_MINOR_VERSION << 8 | TESSERACT_MICRO_VERSION); -public static final String TESSERACT_VERSION_STR = "5.0.0"; +public static final String TESSERACT_VERSION_STR = "5.0.1"; // clang-format on @@ -260,7 +252,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/publictypes.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: publictypes.h // Description: Types used in both the API and internally // Author: Ray Smith @@ -275,8 +267,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCSTRUCT_PUBLICTYPES_H_ // #define TESSERACT_CCSTRUCT_PUBLICTYPES_H_ @@ -532,7 +522,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/pageiterator.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: pageiterator.h // Description: Iterator for tesseract page structure that avoids using // tesseract internal data structures. @@ -548,8 +538,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCMAIN_PAGEITERATOR_H_ // #define TESSERACT_CCMAIN_PAGEITERATOR_H_ @@ -582,6 +570,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/ocrclass.h +// SPDX-License-Identifier: Apache-2.0 /********************************************************************** * File: ocrclass.h * Description: Class definitions and constants for the OCR API. @@ -635,7 +624,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/ltrresultiterator.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: ltrresultiterator.h // Description: Iterator for tesseract results in strict left-to-right // order that avoids using tesseract internal data structures. @@ -651,8 +640,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCMAIN_LTR_RESULT_ITERATOR_H_ // #define TESSERACT_CCMAIN_LTR_RESULT_ITERATOR_H_ @@ -681,7 +668,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/renderer.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: renderer.h // Description: Rendering interface to inject into TessBaseAPI // @@ -695,8 +682,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_API_RENDERER_H_ // #define TESSERACT_API_RENDERER_H_ @@ -751,7 +736,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/resultiterator.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: resultiterator.h // Description: Iterator for tesseract results that is capable of // iterating in proper reading order over Bi Directional @@ -768,8 +753,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_CCMAIN_RESULT_ITERATOR_H_ // #define TESSERACT_CCMAIN_RESULT_ITERATOR_H_ @@ -792,7 +775,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/baseapi.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: baseapi.h // Description: Simple API for calling tesseract. // Author: Ray Smith @@ -807,8 +790,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef TESSERACT_API_BASEAPI_H_ // #define TESSERACT_API_BASEAPI_H_ @@ -872,7 +853,7 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // Parsed from tesseract/capi.h -/////////////////////////////////////////////////////////////////////// +// SPDX-License-Identifier: Apache-2.0 // File: capi.h // Description: C-API TessBaseAPI // @@ -886,8 +867,6 @@ public class tesseract extends org.bytedeco.tesseract.presets.tesseract { // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. -// -/////////////////////////////////////////////////////////////////////// // #ifndef API_CAPI_H_ // #define API_CAPI_H_