POV-Ray : Newsgroups : povray.pov4.discussion.general : GPU usage : Re: GPU usage Server Time
14 May 2024 11:45:13 EDT (-0400)
  Re: GPU usage  
From: scott
Date: 5 Mar 2009 06:11:43
Message: <49afb36f$1@news.povray.org>
>  The GPU can only be used to your advantage if you can give it a big
> bunch of calculations to perform, let it crunch the numbers for several
> seconds (or minutes) and then retrieve the results.

The main problem for raytracing is that GPUs don't handle recursion very 
well, GPUs work by running set code on a group of data points, you cannot 
arbitrarily create new data points or even write to several different data 
points in your code.

All GPU code must essentially be structured like this:

For every element I of an array A:
- Read some elements a,b,c,... from other arrays (not array A)
- Do some processing based on a,b,c,...
- Write a single result to element I

As you can see it is totally geared for calculating pixel colours for your 
screen from texture arrays and bump maps etc.

Of course you can chain together blocks like that to do more complicated 
things in clever ways, but a complete raytracer does not fit in to that 
scheme at all really.


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.