![](/i/fill.gif) |
![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
This isn't POV-Ray. I just wanted to share an image I'm proud of. This is a
screenshot from a level editor for a game I'm working on, showing off my own
implementation of radiosity. Lighting is calculated per-vertex.
Only one iteration has been done, and it took 10 or 15 minutes to run, so I
have some work to do to make it more efficient...
Time for bed.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
Attachments:
Download 'myfirstradiosity.jpg' (79 KB)
Preview of image 'myfirstradiosity.jpg'
![myfirstradiosity.jpg](/povray.binaries.images/attachment/%3C4361ffbf%40news.povray.org%3E/myfirstradiosity.jpg?ttop=443866&toff=4950&preview=1)
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
> This isn't POV-Ray. I just wanted to share an image I'm proud of.
And you surely can be proud of it! Looks great and smooth! I'd be interested
to see an image of the 2nd and 3rd iterations, if thats possible yet.
What kind of game is it, and will it be available somewhere, sometime? :-)
Regards,
Tim
--
aka "Tim Nikias v2.0"
Homepage: <http://www.nolights.de>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
Very impressive.
By sheer coincedence we've been having some problems with our radiosity at
the games company I work at (Naughty Dog), so I'd be really interested in
knowing some technical details: How many vertices are in the scene? What
radiosity method are you using? It looks too smooth to just be gathering
photons. Have you applied any filters to the result to make it so smooth?
Cheers,
Tek
http://evilsuperbrain.com
"Slime" <fak### [at] email address> wrote in message
news:4361ffbf@news.povray.org...
> This isn't POV-Ray. I just wanted to share an image I'm proud of. This is
> a
> screenshot from a level editor for a game I'm working on, showing off my
> own
> implementation of radiosity. Lighting is calculated per-vertex.
>
> Only one iteration has been done, and it took 10 or 15 minutes to run, so
> I
> have some work to do to make it more efficient...
>
> Time for bed.
>
> - Slime
> [ http://www.slimeland.com/ ]
>
>
>
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
> And you surely can be proud of it! Looks great and smooth! I'd be
interested
> to see an image of the 2nd and 3rd iterations, if thats possible yet.
OK, I'll post another image when I get to that point.
> What kind of game is it, and will it be available somewhere, sometime? :-)
Probably a "sort of" FPS deathmatch game. I'm trying to strike a balance
between making it good and actually finishing it someday. =) It's kind of a
big project, and although I have a small amount of the gameplay programmed,
mostly I've just done probably about 75% of the level editor.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
> Very impressive.
Thanks =)
> By sheer coincedence we've been having some problems with our radiosity at
> the games company I work at (Naughty Dog), so I'd be really interested in
> knowing some technical details: How many vertices are in the scene?
15106, so it seems to be doing a little over 1000 a minute (ow).
> What
> radiosity method are you using? It looks too smooth to just be gathering
> photons.
Pretty much exactly what's described here:
http://freespace.virgin.net/hugo.elias/radiosity/radiosity.htm only without
light maps or the memory address trick they talk about at the end (so no
possibility for HDR lighting).
The two major bottlenecks in my implementation are the rendering of the
scene itself (there's no visibility algorithms yet so the entire object is
drawn for every vertex, and needs more optimization) and the retrieval of
the render to calculate the (weighted) average color (I'm using glReadBuffer
which appears to be extremely slow). I'm hoping to find a way to do the
latter part with OpenGL itself so I don't have to use glReadBuffer. I'm
rendering all parts of the hemicube at 256x256 or 256x128.
> Have you applied any filters to the result to make it so smooth?
Nope, just normal triangle interpolation between the vertices. All light
comes from the environment cubemap, so there are no point light sources
which would make sharper shadows.
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
> glReadBuffer
Er, glReadPixels
- Slime
[ http://www.slimeland.com/ ]
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
"Slime" <fak### [at] email address> wrote in message
news:43627a77$1@news.povray.org...
>> How many vertices are in the scene?
>
> 15106, so it seems to be doing a little over 1000 a minute (ow).
Ah, well that explains why we haven't been using this technique at work (our
photon-based method takes only a couple of hours for a 3 million vertex
scene! But the results aren't as smooth as this).
In fact that time of 1000 a minute is hardly surprising. Rendering a cube
map at every vertex that means you're rendering 100 frames per second, and I
doubt if you'll get it much faster than that on a good game level.
> The two major bottlenecks in my implementation are the rendering of the
> scene itself (there's no visibility algorithms yet so the entire object is
> drawn for every vertex, and needs more optimization) and the retrieval of
> the render to calculate the (weighted) average color (I'm using
> glReadBuffer
> which appears to be extremely slow). I'm hoping to find a way to do the
> latter part with OpenGL itself so I don't have to use glReadBuffer. I'm
> rendering all parts of the hemicube at 256x256 or 256x128.
It should be possible to sample your cube maps down to one pixel with GL
itself, then maybe do this for several of your points so you end up building
up a texture where each point represents the lighting value for 1 vertex.
Then you can read them all at once with one read call instead of many. But
afaik there's no efficient way within GL to apply those values to the
vertices, you'll have to read them back at some point.
>> Have you applied any filters to the result to make it so smooth?
>
> Nope, just normal triangle interpolation between the vertices. All light
> comes from the environment cubemap, so there are no point light sources
> which would make sharper shadows.
Interesting. I'd be very interested in seeing this on a more organic-shaped
model, I suspect it's going to struggle a bit when you have sharp points or
grooves in your shapes.
--
Tek
http://evilsuperbrain.com
Post a reply to this message
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |
| ![](/i/fill.gif) |
|
![](/i/fill.gif) |
|
![](/i/fill.gif) |
| ![](/i/fill.gif) |