4 ms·
Are there some easy-to-understand samples? I looked in the samples directory and only saw how to do bokeh blur. I was looking for something a little simpler...
by CyanLite2 6y ago
Are there some easy-to-understand samples? I looked in the samples directory and only saw how to do bokeh blur.
I was looking for something a little simpler... I have two large arrays and I want to do simple mathematical operations on them.
- Sergio0694 6y agoI have some more samples in the other folders, and I will also include some snippets in the updated docs (need to finish writing them and include them in the dev branch). Here's a couple examples: Super simple, complete examples of a shader that just multiplies all items in a buffer by 2: https://github.com/Sergio0694/ComputeSharp/blob/dev/samples/ComputeSharp.Sample.Shared/Program.cs https://github.com/Sergio0694/ComputeSharp/blob/dev/samples/... Simple naive matrix-multiply-add shader: https://github.com/Sergio0694/ComputeSharp/blob/ada133aacd29882ede43d201e178a9c3eb92d611/samples/ComputeSharp.Benchmark/Blas/BlasHelpers.cs#L84 https://github.com/Sergio0694/ComputeSharp/blob/ada133aacd29... Let me know if those help, and feel free to ping me on GitHub or in the C# Discord server if you have any issues!