Excel Ray Tracing with Help from C
It isn’t news that [s0lly] likes to do ray tracing using Microsoft Excel. However, he recently updated his set up to use functions in a C XLL — a DLL, really — to accelerate the Excel rendering. Even if ray tracing isn’t your thing, the technique of creating custom high-performance Excel functions might do you some good somewhere else.
We’ve seen [s0lly’s] efforts before, and you can certainly see that the new technique speeds things up and produces a better result, which isn’t especially surprising. In addition to being faster, the new routines produce more detail.
The Microsoft documentation on doing this is pretty clear if you want to give it a go. One of the things you can do in your C code is to take advantage of things like threads to get better performance, which [s0lly] shows in his example.
Of course, you could argue that you don’t need Excel here, but what fun would that be? Besides, then you’d need to handle all the data input and output which would be a pain in its own right.
via Blog – Hackaday https://hackaday.com
September 28, 2021 at 07:20PM