Oh darn,
Hey Agi in what lever are you in school know, you are making the guru that write paper look like idiots.
A few year ago the people that did this stuff where writing paper, and books, now you can do it by simple using a physic engine and your intelligence.
If I did not see those images I would not believe it.
This is using a general purpose ray cast function, this is tell me that if the function is optimized for rendering, plus the using the newer GPU or multicourse CPUs, a ray trace is perfectly possible and probably much more superior to raster graphics.
agi_shi wrote:Here's a 4096x4096 (scaled again) render that took a few hours (single-threaded):
Loads of reflections and shadows. 500 spheres and 1 box for the ground.
Is it safe to call NewtonWorldRayCast() from several threads? Would speed up the thing linearly...
Yes all of the collision and reay cast funstion can be call for separate threads. they are all re entrant in 2.0
what SDK do you have now?
Hey I have an idea how about exposing the multithreading function of the engine,
Something like
NewtonSumitTask (Newton, TaskCallback, Data)
NetwonSinck (Newton)You use it like this:
devided the job into batches of more of lest equal load. For example if you have a dual core you have two threads, the you assign use the upper haft of the image to one thread and the lower half to the other
- Code: Select all
For (I = 0; I < thread count; I ++) {
NewtonSumitTask (Newton, TaskCallback, &Data[I] )
}
NetwonSinck (Newton)
It should reduce the time to haft more of less, with more cores it is even better.
Would you like to try that?