forked from amkovkov/GranuSightSoftware2
15 lines
358 B
C#
15 lines
358 B
C#
using OpenCvSharp;
|
|
|
|
namespace GSS2.Core.Extensions;
|
|
|
|
public static class MatExtensions
|
|
{
|
|
public static void ImWrite(this Mat mat, string path)
|
|
{
|
|
var directory = Path.GetDirectoryName(path);
|
|
if (directory is not null && !Directory.Exists(directory))
|
|
Directory.CreateDirectory(directory);
|
|
mat.ImWrite(path);
|
|
}
|
|
}
|