Wes xx mediapipe integration

This commit is contained in:
Jelle De Geest
2023-03-12 20:34:16 +00:00
parent 8349b5f149
commit b11eeb465c
975 changed files with 192230 additions and 0 deletions

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 06f197b48df268a4c854e0a995ccfb26
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,22 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool absl_Status__ok(IntPtr status);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int absl_Status__raw_code(IntPtr status);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: da8fc54cee1027e99b8906eb2bf52fe9
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,23 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode absl_Status__i_PKc(int code, string message, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void absl_Status__delete(IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode absl_Status__ToString(IntPtr status, out IntPtr str);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 155484db76e5b33b9abb229007a71250
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,49 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode google_InitGoogleLogging__PKc(string name);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode google_ShutdownGoogleLogging();
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_FLAGS_logtostderr([MarshalAs(UnmanagedType.I1)] bool value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_FLAGS_stderrthreshold(int threshold);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_FLAGS_minloglevel(int level);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_FLAGS_log_dir(string dir);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_FLAGS_v(int v);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_LOG_INFO__PKc(string str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_LOG_WARNING__PKc(string str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_LOG_ERROR__PKc(string str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void glog_LOG_FATAL__PKc(string str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void google_FlushLogFiles(Glog.Severity severity);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 5746b8714205e5f4c9b283abb157f283
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,74 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode google_protobuf__SetLogHandler__PF(
[MarshalAs(UnmanagedType.FunctionPtr)] Protobuf.LogHandler logHandler);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode google_protobuf__ResetLogHandler();
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_api_SerializedProtoArray__delete(IntPtr serializedProtoVectorData, int size);
#region MessageProto
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetClassificationList(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetClassificationListVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetDetection(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetDetectionVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFaceGeometry(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFaceGeometryVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFrameAnnotation(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetLandmarkList(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetLandmarkListVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetNormalizedLandmarkList(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetNormalizedLandmarkListVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetNormalizedRect(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetNormalizedRectVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetRect(IntPtr packet, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetRectVector(IntPtr packet, out SerializedProtoVector serializedProtoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetTimedModelMatrixProtoList(IntPtr packet, out SerializedProto serializedProto);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: d2824e1ee33b214b5931f71e3476d099
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,19 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_StatusOrString__ok(IntPtr statusOrString);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 4387fa8ccc9d34346989f3157763325c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,45 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void delete_array__PKc(IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void delete_array__Pf(IntPtr str);
#region String
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void std_string__delete(IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode std_string__PKc_i(byte[] bytes, int size, out IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void std_string__swap__Rstr(IntPtr src, IntPtr dst);
#endregion
#region StatusOrString
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_StatusOrString__delete(IntPtr statusOrString);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrString__status(IntPtr statusOrString, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrString__value(IntPtr statusOrString, out IntPtr value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrString__bytearray(IntPtr statusOrString, out IntPtr value, out int size);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 8145b1567167432dda87798d70f47019
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 0b05ef67a7940b44e9c78e9845c84aa8
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,35 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_CalculatorGraph__HasError(IntPtr graph);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_CalculatorGraph__HasInputStream__PKc(IntPtr graph, string name);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_CalculatorGraph__GraphInputStreamsClosed(IntPtr graph);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_CalculatorGraph__IsNodeThrottled__i(IntPtr graph, int nodeId);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_CalculatorGraph__UnthrottleSources(IntPtr graph);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 4151a04c25074315f99f586059854ebe
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,77 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__(out IntPtr graph);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__PKc_i(byte[] serializedConfig, int size, out IntPtr graph);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_CalculatorGraph__delete(IntPtr graph);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__Initialize__PKc_i(IntPtr graph, byte[] serializedConfig, int size, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__Initialize__PKc_i_Rsp(
IntPtr graph, byte[] serializedConfig, int size, IntPtr sidePackets, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__Config(IntPtr graph, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__ObserveOutputStream__PKc_PF_b(IntPtr graph, string streamName, int streamId,
[MarshalAs(UnmanagedType.FunctionPtr)] CalculatorGraph.NativePacketCallback packetCallback, [MarshalAs(UnmanagedType.I1)] bool observeTimestampBounds, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__AddOutputStreamPoller__PKc_b(IntPtr graph, string streamName, [MarshalAs(UnmanagedType.I1)] bool observeTimestampBounds, out IntPtr statusOrPoller);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__Run__Rsp(IntPtr graph, IntPtr sidePackets, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__StartRun__Rsp(IntPtr graph, IntPtr sidePackets, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__WaitUntilIdle(IntPtr graph, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__WaitUntilDone(IntPtr graph, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__AddPacketToInputStream__PKc_Ppacket(
IntPtr graph, string streamName, IntPtr packet, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__SetInputStreamMaxQueueSize__PKc_i(
IntPtr graph, string streamName, int maxQueueSize, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__CloseInputStream__PKc(IntPtr graph, string streamName, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__CloseAllPacketSources(IntPtr graph, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__Cancel(IntPtr graph);
#region GPU
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__GetGpuResources(IntPtr graph, out IntPtr gpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_CalculatorGraph__SetGpuResources__SPgpu(IntPtr graph, IntPtr gpuResources, out IntPtr status);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 9f798d37c18934402bf7aa85c095fa32
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,17 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_api__ConvertFromCalculatorGraphConfigTextFormat(string configText, out SerializedProto serializedProto);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3c7f419d9297b69f7bd4259432b3a846
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 49d82fd23aaa04643b39b7aa9f461010
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,48 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_ImageFrame__IsEmpty(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_ImageFrame__IsContiguous(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__IsAligned__ui(
IntPtr imageFrame, uint alignmentBoundary, [MarshalAs(UnmanagedType.I1)] out bool value);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern ImageFormat.Types.Format mp_ImageFrame__Format(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ImageFrame__Width(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ImageFrame__Height(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ImageFrame__WidthStep(IntPtr imageFrame);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_ImageFrame__MutablePixelData(IntPtr imageFrame);
#region StatusOr
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_StatusOrImageFrame__ok(IntPtr statusOrImageFrame);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 99e8da896b508c97fbfe30b3c8d1c0d9
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,72 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__(out IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__ui_i_i_ui(
ImageFormat.Types.Format format, int width, int height, uint alignmentBoundary, out IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__ui_i_i_i_Pui8_PF(
ImageFormat.Types.Format format, int width, int height, int widthStep, IntPtr pixelData,
[MarshalAs(UnmanagedType.FunctionPtr)] ImageFrame.Deleter deleter, out IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_ImageFrame__delete(IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__SetToZero(IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__SetAlignmentPaddingAreas(IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__CopyToBuffer__Pui8_i(IntPtr imageFrame, IntPtr buffer, int bufferSize);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__CopyToBuffer__Pui16_i(IntPtr imageFrame, IntPtr buffer, int bufferSize);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ImageFrame__CopyToBuffer__Pf_i(IntPtr imageFrame, IntPtr buffer, int bufferSize);
#region StatusOr
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_StatusOrImageFrame__delete(IntPtr statusOrImageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrImageFrame__status(IntPtr statusOrImageFrame, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrImageFrame__value(IntPtr statusOrImageFrame, out IntPtr imageFrame);
#endregion
#region Packet
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeImageFramePacket__Pif(IntPtr imageFrame, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeImageFramePacket_At__Pif_Rt(IntPtr imageFrame, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ConsumeImageFrame(IntPtr packet, out IntPtr statusOrImageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetImageFrame(IntPtr packet, out IntPtr imageFrame);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsImageFrame(IntPtr packet, out IntPtr status);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 2f1912965dccdf052aba3a477883eb98
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,29 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#region Packet
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeMatrixPacket__PKc_i(byte[] serializedMatrixData, int size, out IntPtr packet_out);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeMatrixPacket_At__PKc_i_Rt(byte[] serializedMatrixData, int size, IntPtr timestamp, out IntPtr packet_out);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsMatrix(IntPtr packet, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetMatrix(IntPtr packet, out SerializedProto serializedProto);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: fc5345171757d2049a546634b03b8c5e
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,19 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_StatusOrPoller__ok(IntPtr statusOrPoller);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 089b00baa4837fc45b59e49b3fd89708
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,42 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#region OutputStreamPoller
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_OutputStreamPoller__delete(IntPtr poller);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_OutputStreamPoller__Reset(IntPtr poller);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_OutputStreamPoller__Next_Ppacket(IntPtr poller, IntPtr packet, out bool result);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_OutputStreamPoller__SetMaxQueueSize(IntPtr poller, int queueSize);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_OutputStreamPoller__QueueSize(IntPtr poller, out int queueSize);
#endregion
#region StatusOrPoller
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_StatusOrPoller__delete(IntPtr statusOrPoller);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrPoller__status(IntPtr statusOrPoller, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrPoller__value(IntPtr statusOrPoller, out IntPtr poller);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 5c8eb1e2420bbdbd79777f61fa67daa5
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,25 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_Packet__IsEmpty(IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SidePacket__clear(IntPtr sidePacket);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_SidePacket__size(IntPtr sidePacket);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: aa23fae0b90d981ac997812e8d7541fc
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,153 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#region common
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__(out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_Packet__delete(IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__At__Rt(IntPtr packet, IntPtr timestamp, out IntPtr newPacket);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsProtoMessageLite(IntPtr packet, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__Timestamp(IntPtr packet, out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__DebugString(IntPtr packet, out IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__RegisteredTypeName(IntPtr packet, out IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__DebugTypeName(IntPtr packet, out IntPtr str);
#endregion
#region Bool
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeBoolPacket__b([MarshalAs(UnmanagedType.I1)] bool value, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeBoolPacket_At__b_Rt([MarshalAs(UnmanagedType.I1)] bool value, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetBool(IntPtr packet, [MarshalAs(UnmanagedType.I1)] out bool value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsBool(IntPtr packet, out IntPtr status);
#endregion
#region Float
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatPacket__f(float value, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatPacket_At__f_Rt(float value, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFloat(IntPtr packet, out float value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsFloat(IntPtr packet, out IntPtr status);
#endregion
#region Int
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeIntPacket__i(int value, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeIntPacket_At__i_Rt(int value, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetInt(IntPtr packet, out int value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsInt(IntPtr packet, out IntPtr status);
#endregion
#region FloatArray
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatArrayPacket__Pf_i(float[] value, int size, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatArrayPacket_At__Pf_i_Rt(float[] value, int size, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFloatArray_i(IntPtr packet, int size, out IntPtr value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsFloatArray(IntPtr packet, out IntPtr status);
#endregion
#region FloatVector
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatVectorPacket__Pf_i(float[] value, int size, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeFloatVectorPacket_At__Pf_i_Rt(float[] value, int size, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetFloatVector(IntPtr packet, out FloatVector value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsFloatVector(IntPtr packet, out IntPtr status);
#endregion
#region String
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeStringPacket__PKc(string value, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeStringPacket_At__PKc_Rt(string value, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeStringPacket__PKc_i(byte[] bytes, int size, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeStringPacket_At__PKc_i_Rt(byte[] bytes, int size, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetString(IntPtr packet, out IntPtr value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetByteString(IntPtr packet, out IntPtr value, out int size);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ConsumeString(IntPtr packet, out IntPtr statusOrValue);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsString(IntPtr packet, out IntPtr status);
#endregion
#region SidePacket
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_SidePacket__(out IntPtr sidePacket);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SidePacket__delete(IntPtr sidePacket);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_SidePacket__emplace__PKc_Rp(IntPtr sidePacket, string key, IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_SidePacket__at__PKc(IntPtr sidePacket, string key, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_SidePacket__erase__PKc(IntPtr sidePacket, string key, out int count);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 2f45c37386d4ecb8abb6f74475d29dc6
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,36 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern long mp_Timestamp__Value(IntPtr timestamp);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern double mp_Timestamp__Seconds(IntPtr timestamp);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern long mp_Timestamp__Microseconds(IntPtr timestamp);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_Timestamp__IsSpecialValue(IntPtr timestamp);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_Timestamp__IsRangeValue(IntPtr timestamp);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_Timestamp__IsAllowedInStream(IntPtr timestamp);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: cd82a3be1540e60c9ab398f1d488758c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,56 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp__l(long value, out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_Timestamp__delete(IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp__DebugString(IntPtr timestamp, out IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp__NextAllowedInStream(IntPtr timestamp, out IntPtr nextTimestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp__PreviousAllowedInStream(IntPtr timestamp, out IntPtr prevTimestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_FromSeconds__d(double seconds, out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_Unset(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_Unstarted(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_PreStream(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_Min(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_Max(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_PostStream(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_OneOverPostStream(out IntPtr timestamp);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Timestamp_Done(out IntPtr timestamp);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3552112fccbfde24b80dbe41bf72a806
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,36 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_ValidatedGraphConfig__Initialized(IntPtr config);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ValidatedGraphConfig__OutputStreamIndex__PKc(IntPtr config, string name);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ValidatedGraphConfig__OutputSidePacketIndex__PKc(IntPtr config, string name);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_ValidatedGraphConfig__OutputStreamToNode__PKc(IntPtr config, string name);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_ValidatedGraphConfig_IsReservedExecutorName(string name);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_ValidatedGraphConfig__IsExternalSidePacket__PKc(IntPtr config, string name);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: c73850dfbc5a5d0bc9c02651552efc2c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,56 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__(out IntPtr config);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_ValidatedGraphConfig__delete(IntPtr config);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__Initialize__Rcgc(IntPtr config, byte[] serializedConfig, int size, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__Initialize__PKc(IntPtr config, string graphType, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__ValidateRequiredSidePackets__Rsp(IntPtr config, IntPtr sidePackets, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__Config(IntPtr config, out SerializedProto serializedProto);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__InputStreamInfos(IntPtr config, out EdgeInfoVector edgeInfoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__OutputStreamInfos(IntPtr config, out EdgeInfoVector edgeInfoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__InputSidePacketInfos(IntPtr config, out EdgeInfoVector edgeInfoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__OutputSidePacketInfos(IntPtr config, out EdgeInfoVector edgeInfoVector);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__RegisteredSidePacketTypeName(IntPtr config, string name, out IntPtr statusOrString);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__RegisteredStreamTypeName(IntPtr config, string name, out IntPtr statusOrString);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_ValidatedGraphConfig__Package(IntPtr config, out IntPtr str);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_api_EdgeInfoArray__delete(IntPtr data, int size);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 3178003154386ee09ae63eb0a48f386b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 06552cb1942286044a1ae8ad31c92246
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,25 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern uint mp_GlCalculatorHelper__framebuffer(IntPtr glCalculatorHelper);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlCalculatorHelper__GetGlContext(IntPtr glCalculatorHelper);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_GlCalculatorHelper__Initialized(IntPtr glCalculatorHelper);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: e564c364aa8fc108c952c34bd5708e49
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,52 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__(out IntPtr glCalculatorHelper);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_GlCalculatorHelper__delete(IntPtr glCalculatorHelper);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__InitializeForTest__Pgr(IntPtr glCalculatorHelper, IntPtr gpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__RunInGlContext__PF(
IntPtr glCalculatorHelper, [MarshalAs(UnmanagedType.FunctionPtr)] GlCalculatorHelper.NativeGlStatusFunction glFunc, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__CreateSourceTexture__Rif(
IntPtr glCalculatorHelper, IntPtr imageFrame, out IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__CreateSourceTexture__Rgb(
IntPtr glCalculatorHelper, IntPtr gpuBuffer, out IntPtr glTexture);
#if UNITY_IOS
[DllImport (MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__CreateSourceTexture__Rgb_i(
IntPtr glCalculatorHelper, IntPtr gpuBuffer, int plane, out IntPtr glTexture);
#endif
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__CreateDestinationTexture__i_i_ui(
IntPtr glCalculatorHelper, int outputWidth, int outputHeight, GpuBufferFormat formatCode, out IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__CreateDestinationTexture__Rgb(
IntPtr glCalculatorHelper, IntPtr gpuBuffer, out IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlCalculatorHelper__BindFrameBuffer__Rtexture(IntPtr glCalculatorHelper, IntPtr glTexture);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 82da240322adcf754810db201ec3bb6d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,60 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
#region GlContext
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_SharedGlContext__get(IntPtr sharedGlContext);
#if UNITY_EDITOR_LINUX || UNITY_STANDALONE_LINUX || UNITY_ANDROID
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__egl_display(IntPtr glContext);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__egl_config(IntPtr glContext);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__egl_context(IntPtr glContext);
#endif
#if UNITY_IOS
[Pure, DllImport (MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__eagl_context(IntPtr glContext);
#elif UNITY_STANDALONE_OSX
[Pure, DllImport (MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__nsgl_context(IntPtr glContext);
[Pure, DllImport (MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlContext__nsgl_pixel_format(IntPtr glContext);
#endif
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_GlContext__IsCurrent(IntPtr glContext);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlContext__gl_major_version(IntPtr glContext);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlContext__gl_minor_version(IntPtr glContext);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern long mp_GlContext__gl_finish_count(IntPtr glContext);
#endregion
#region GlSyncToken
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlSyncToken__get(IntPtr glSyncToken);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: d6d0d1aa759d4722881c31504ff7f2b7
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,62 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#region GlContext
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGlContext__delete(IntPtr sharedGlContext);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGlContext__reset(IntPtr sharedGlContext);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlContext_GetCurrent(out IntPtr sharedGlContext);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlContext_Create__P_b([MarshalAs(UnmanagedType.I1)] bool createThread, out IntPtr statusOrSharedGlContext);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlContext_Create__Rgc_b(
IntPtr shareContext, [MarshalAs(UnmanagedType.I1)] bool createThread, out IntPtr statusOrSharedGlContext);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlContext_Create__ui_b(
uint shareContext, [MarshalAs(UnmanagedType.I1)] bool createThread, out IntPtr statusOrSharedGlContext);
#if UNITY_IOS
[DllImport (MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlContext_Create__Pes_b(
IntPtr sharegroup, [MarshalAs(UnmanagedType.I1)]bool createThread, out IntPtr statusOrSharedGlContext);
#endif
#endregion
#region GlSyncToken
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_GlSyncToken__delete(IntPtr glSyncToken);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_GlSyncToken__reset(IntPtr glSyncToken);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlSyncPoint__Wait(IntPtr glSyncPoint);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlSyncPoint__WaitOnGpu(IntPtr glSyncPoint);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlSyncPoint__IsReady(IntPtr glSyncPoint, out bool value);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlSyncPoint__GetContext(IntPtr glSyncPoint, out IntPtr sharedGlContext);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 07ecf4eb645a5867f8fd99c199334778
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,40 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
#region GlTextureBuffer
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern uint mp_GlTextureBuffer__name(IntPtr glTextureBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern uint mp_GlTextureBuffer__target(IntPtr glTextureBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlTextureBuffer__width(IntPtr glTextureBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlTextureBuffer__height(IntPtr glTextureBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern GpuBufferFormat mp_GlTextureBuffer__format(IntPtr glTextureBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_GlTextureBuffer__GetProducerContext(IntPtr glTextureBuffer);
#endregion
#region SharedGlTextureBuffer
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_SharedGlTextureBuffer__get(IntPtr glTextureBuffer);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 94158874b636c7c1c86afcec7fca108e
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,51 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#region GlTextureBuffer
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__WaitUntilComplete(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__WaitOnGpu(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__Reuse(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__Updated__Pgst(IntPtr glTextureBuffer, IntPtr prodToken);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__DidRead__Pgst(IntPtr glTextureBuffer, IntPtr consToken);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__WaitForConsumers(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTextureBuffer__WaitForConsumersOnGpu(IntPtr glTextureBuffer);
#endregion
#region SharedGlTextureBuffer
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGlTextureBuffer__delete(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGlTextureBuffer__reset(IntPtr glTextureBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_SharedGlTextureBuffer__ui_ui_i_i_ui_PF_PSgc(
uint target, uint name, int width, int height, GpuBufferFormat format,
[MarshalAs(UnmanagedType.FunctionPtr)] GlTextureBuffer.DeletionCallback deletionCallback,
IntPtr producerContext, out IntPtr sharedGlTextureBuffer);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 7aaa60de75bee921e82d0d1a754b3544
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,27 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlTexture__width(IntPtr glTexture);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GlTexture__height(IntPtr glTexture);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern uint mp_GlTexture__target(IntPtr glTexture);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern uint mp_GlTexture__name(IntPtr glTexture);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: c8844f009f7a785ec8bcfdd8b60c7f3a
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,26 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTexture__(out IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_GlTexture__delete(IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTexture__Release(IntPtr glTexture);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GlTexture__GetGpuBufferFrame(IntPtr glTexture, out IntPtr gpuBuffer);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 1bc45e10b1b9589dc88a57aa1b1dc97b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,20 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
#if UNITY_STANDALONE_LINUX || UNITY_ANDROID
[Pure, DllImport(MediaPipeLibrary)]
public static extern IntPtr eglGetCurrentContext();
#endif
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 240d79bdaffc8e1beb14793ddfa70635
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,20 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary)]
public static extern void glFlush();
[DllImport(MediaPipeLibrary)]
public static extern void glReadPixels(int x, int y, int width, int height, uint glFormat, uint glType, IntPtr pixels);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: cdb6820be7e5d26ab959e3787392835b
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,20 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern ImageFormat.Types.Format mp__ImageFormatForGpuBufferFormat__ui(GpuBufferFormat format);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern ImageFormat.Types.Format mp__GpuBufferFormatForImageFormat__ui(ImageFormat.Types.Format format);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 0f824754e827bdc1282d0352454e46dd
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,17 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__GlTextureInfoForGpuBufferFormat__ui_i_ui(
GpuBufferFormat format, int plane, GlVersion glVersion, out GlTextureInfo glTextureInfo);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 0a463b93a1e2b3efd915a3d5ae85687a
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,30 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GpuBuffer__width(IntPtr gpuBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern int mp_GpuBuffer__height(IntPtr gpuBuffer);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern GpuBufferFormat mp_GpuBuffer__format(IntPtr gpuBuffer);
#region StatusOr
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_StatusOrGpuBuffer__ok(IntPtr statusOrGpuBuffer);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 8ed78dc9779f9f974a01a9e5ce6e2b78
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,50 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
#if UNITY_EDITOR_LINUX || UNITY_STANDALONE_LINUX || UNITY_ANDROID
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GpuBuffer__PSgtb(IntPtr glTextureBuffer, out IntPtr gpuBuffer);
#endif
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_GpuBuffer__delete(IntPtr gpuBuffer);
#region StatusOr
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_StatusOrGpuBuffer__delete(IntPtr statusOrGpuBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrGpuBuffer__status(IntPtr statusOrGpuBuffer, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrGpuBuffer__value(IntPtr statusOrGpuBuffer, out IntPtr gpuBuffer);
#endregion
#region Packet
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeGpuBufferPacket__Rgb(IntPtr gpuBuffer, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeGpuBufferPacket_At__Rgb_Rts(IntPtr gpuBuffer, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ConsumeGpuBuffer(IntPtr packet, out IntPtr statusOrGpuBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetGpuBuffer(IntPtr packet, out IntPtr gpuBuffer);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__ValidateAsGpuBuffer(IntPtr packet, out IntPtr status);
#endregion
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: fccfad8d2e49e5e6db0b9c0ee0fac50f
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,22 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Diagnostics.Contracts;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern IntPtr mp_SharedGpuResources__get(IntPtr gpuResources);
[Pure, DllImport(MediaPipeLibrary, ExactSpelling = true)]
[return: MarshalAs(UnmanagedType.I1)]
public static extern bool mp_StatusOrGpuResources__ok(IntPtr statusOrGpuResources);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: dfa309ee6a68a6599898f97bb6266a3c
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,35 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGpuResources__delete(IntPtr gpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_SharedGpuResources__reset(IntPtr gpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GpuResources_Create(out IntPtr statusOrGpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_GpuResources_Create__Pv(IntPtr externalContext, out IntPtr statusOrGpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_StatusOrGpuResources__delete(IntPtr statusOrGpuResources);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrGpuResources__status(IntPtr statusOrGpuResources, out IntPtr status);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_StatusOrGpuResources__value(IntPtr statusOrGpuResources, out IntPtr gpuResources);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 03fee8ca1b3101d6b9e0a862b958fc6d
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: 758c9122bbda91842afa6a5246b5bb6f
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,26 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System;
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class UnsafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeAnchor3dVectorPacket__PA_i(Anchor3d[] value, int size, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp__MakeAnchor3dVectorPacket_At__PA_i_Rt(Anchor3d[] value, int size, IntPtr timestamp, out IntPtr packet);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp_Anchor3dArray__delete(IntPtr anchorVectorData);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern MpReturnCode mp_Packet__GetAnchor3dVector(IntPtr packet, out Anchor3dVector anchorVector);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 7d4da3790f601856f9eb91cc8a09f14a
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,8 @@
fileFormatVersion: 2
guid: f0c107b877d7bc04484e971776be6563
folderAsset: yes
DefaultImporter:
externalObjects: {}
userData:
assetBundleName:
assetBundleVariant:

View File

@@ -0,0 +1,21 @@
// Copyright (c) 2021 homuler
//
// Use of this source code is governed by an MIT-style
// license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
using System.Runtime.InteropServices;
namespace Mediapipe
{
internal static partial class SafeNativeMethods
{
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp__SetCustomGlobalResourceProvider__P(
[MarshalAs(UnmanagedType.FunctionPtr)] ResourceManager.NativeResourceProvider provider);
[DllImport(MediaPipeLibrary, ExactSpelling = true)]
public static extern void mp__SetCustomGlobalPathResolver__P(
[MarshalAs(UnmanagedType.FunctionPtr)] ResourceManager.PathResolver resolver);
}
}

View File

@@ -0,0 +1,11 @@
fileFormatVersion: 2
guid: 6b34d2d2f3864709d8d61b85b4210662
MonoImporter:
externalObjects: {}
serializedVersion: 2
defaultReferences: []
executionOrder: 0
icon: {instanceID: 0}
userData:
assetBundleName:
assetBundleVariant: