Quantcast
Channel: Visual C# forum
Viewing all articles
Browse latest Browse all 31927

C# AND GPU Programming

$
0
0

Hello everyone!

Ok, so I've built many C# application in the past few years. The most recent project involves pixel operations. I'm taking a screenshot of an image, and then scanning that image for all of the black pixels, and then copying just those black pixels to a new image. I've got everything to work using a loop with Get/Set Pixel. The problem is that it's too slow. I've read a lot about parallel programming with the GPU, and would like to take this route. So far I've downloaded and installed CUDAFY.net and linked the DLL to my project, but that's as far as I've gotten. I imported the dll and can see all of it's functions, but nothing seems to look like what I need. In the case that the GPU is way out of my mindset, I would like to try unsafe pixel operations. I've also read that it is much faster than Get/Set pixel. Not really looking for code, just looking to be pointed in the right direction; GPU or unsafe code or anything else you can think of.


Viewing all articles
Browse latest Browse all 31927

Latest Images

Trending Articles



Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>