# glass marble -- an experiment in faking deep raytracing.

#1

an experiment i’m working on and I could use some suggestions/advice from anyone with some experience dealing with tough raytracing problems.

`````` here's the very first render and scene setup:
[img]http://pha3z.the-eloquent.com/ball1.jpg[/img]
``````

The color balls of glass inside the main sphere particles spawned with PFlow in max6. The outter surface of each particle has colored glass and the backfacing surface has colorless glass (to maintain the solidity of the whole object as being glass). There are about 400 particles above.

`````` now on to the real problem!
[img]http://pha3z.the-eloquent.com/ball11.jpg[/img]
``````

In this one, we have 18,000 particles with raytraced surface on every single material in the scene. render time was about 20 minutes.

The problem is that I had to tell the particles not to reflect/refract each other. You can think about it as if each particle sees itself as being the only particle in the whole glass sphere. You’ll notice realism issues as a result of this in the image. The lighting on the left side is especially flawed since it doesn’t look diffused and distorted enough, as it should be from traveling through a few thousand particles!

Anyone got ideas on how I could fake the effect of the reflections/refractions bouncing hundreds/thousands of times without rendering for a year!?

`````` thoughts, suggestions?

later,
pha3z

---------
See my chevy:

#2

Here’s a solution i’m working on. This is only the first step to a larger solution.

I’ve divided the sphere into three sections. The red circle represents a Non-renderable divider between the small particles in the outter layer and the big particles in the “core”. The green line marks the section that already existed in the previous renders; it is where the green and yellow particles spawn (now large size instead of small). The particles in the outter layer still do not refract each other, however ALL particles now refract the core big particles! Now we are able to produce a fairly accurate raytrace where light becomes colored and spread somehhat as it passes through the sphere.

There are some depth issues as i only rendered with a refraction depth of 6. Despite the issues, this image shows a glimpse of an early test of this solution. Looking at the lower left area of the sphere, you can see a lot less of the bright windows from the kitchen scene penetrating the sphere in full brightness. The lighting within the sphere is much more accurate and balanced.

#3

the previous method of using large particles for reflection/refraction proved to be a weak solution. It was difficult to tweak the particles to the right size and number to get the light to look evenly distributed enough.

I am now experimenting with an extension of the method. Instead of using a few big particles as the refractive core, I’m going to use a single sphere for the core with an environment map of the inside. Here is an environment map of the inside of the sphere with 18,000 particles:

My idea is to use this map as a diffuse/color layer on the core and give it a sub-surface scattering shader so the sides of the sphere opposite the light sources are darker but still recieve some diffused light. will post results

#4

new cross-section of sphere:

the red line still represents the “core” but it now has nothing to do with particle spawning. Each particle still thinks it is the only particle in the sphere. The core has the environment map from the previous post. It has a Brazil Wax shader with sub-surface scattering. The core is not visible to the camera; only the particles are allowed to see it.

Here is the render! There are some small artifacts from the environment map, but these can be fixed!

#5

same render as previous post but with environment map on refractive core changed to RGB Level of 2.0 instead of 1.0:

lighting is starting to look more balanced but the shading isn’t right. will post again asap.

#6

RGB Level: 1.3
SSS Shader now absorbs more light at its deep point.
Particles no longer cast shadows (was interfering with light hitting hte core properly).

#7

Not sure what the real objective was, but it still looks really good, and i like the way u have really explaned the progression of your work.

Dave

#8

the objective is to try to find a way to render this scene without having to calculate incrediby deep ray traces with a high bounce limit. Because the particles are so dense, sending one ray through them takes ages for accurate results. In a professional situation, what i’m doing is not very practical as you would instead have a render farm where you could leave the scene rendering for a day or two and get perfect results. What i’m trying to achieve is a close-to-perfect look while maintaing a short render time on a single PC. So far, my work is ok, but not great. The image doesn’t look near as good as it would were it all raytraced but I have another idea i’m going to try when i get some time.

#9

This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.