Код: Выделить всё
using System;
using Emgu.CV.Cuda;
using Emgu.CV;
namespace OpenCV_Test
{
internal class Program
{
static void Main(string[] args)
{
if (!CudaInvoke.HasCuda)
{
Console.WriteLine("CUDA is not available on this machine.");
return;
}
// I want to upload this data to the gpu / Create some sort of buffer
Matrix matrix = new Matrix(10000, 5);
// Then run some calculations on the data using some sort of Cuda-Code/HLSL Shader code
// Preferably on each row
// Return different data using another buffer
}
}
}
Заранее спасибо!
Хотя я видел, что у меня должна быть возможность создать какое-то собственное ядро для моего варианта использования, но мне совершенно неясно, как применить эти знания.
Как запустить собственное ядро OpenCL в OpenCV (3.0.0) OCL?
Как определить ядро для filter2d в EMGU CV
Как запустить собственное ядро OpenCL в OpenCV (3.0.0) OCL?
Подробнее здесь: https://stackoverflow.com/questions/786 ... return-the