Jump to content

Raytrace Settings


Wolf
 Share

Recommended Posts

Here are some settings that i use to speed up the raytrace material, and make it look a lot better.

these settings are found in the

Raytracer controls....Global Parameters and Options.

 

The raytracer has been setup with default settings that work in most scenes without a hitch, but optimizing the settings can make a huge difference if you have an out of the ordinary scene...like one with lots of geometry.

 

For starters, before i render anything i go to....Raytracer controls...options.....

and set the antialiasing to be off.

the reason for this, is that the tracer antialiases with a lot of extra rays, that take a long time to compute.

 

but...how do i get rid of the jaggies you ask?

well...instead of antialiasing using the raytracer, i use the supersample button instead(Raytrace basic parameters)

since this uses an image based antialiasing technique, it is much faster for complex scenes.

 

Since you dont want to test render every scene using supersampling, turn it off globally in your rendering dialog box, and switch it back on when your about to do a final render.

 

btw...i use supersampling on almost all textures, due to the fact that max is set up for blazing speeds, not image quality.

so it antialiases only the edges of objects.

Have you ever noticed crawling textures in your animations? just hit the supersample button...and its gone.

 

Now onto the raytrace settings....

For small scenes, the raytracing settings are fine, dont even bother touching them.

But if you have a scene with 1 million polys or more, the raytracer slows down to a crawl.

 

This is where you should launch the Global Parameters.

And switch to Manual Acceleration.

and set your face limit slightly larger than the poly count of your biggest object in your scene (like trees)

 

My scene weighing in at 2.4 million polys was rendering at 5.40 mins,

after i set the face limit to 10,000 (my trees were 8,500 polys each)

i got the rendering time down to 3.50 mins

with the big improvement in speed, at the raytrace engine setup stage.

 

Another thing to keep an eye on, is the raytrace depth, which is on 9 as default.

great for doing a glass statue, with lots of rays shooting in and out of the statue,

but i find your basic architecture scene uses no more than 2-3

If in doubt about what depth will be enough,

next to the raytrace depth is a button that you can set a colour to use at max depth, if you set this colour to be bright red for instance, and render your scene, just look out for any bright red areas where your ray has died and used that colour instead.

and then if u see any, slowly up your raytrace depth untill the red is gone.

 

Hope this helps a few of you, as the default settings are meant for simple scenes, not complex architecture, such as what we do.

 

Wolf

Link to comment
Share on other sites

thank you for sharing this tips... Yes. It's very important to use the supersampling and not the antialiaser. the problem is when you want to make a blur reflection (ie. some metals...) then you have to activate the multiresolution antialiasing.

 

I also uncheck the following options in the raytraced material that are not useful for architectural models:

 

Enable Self reflect/refract (it depends of how is it modeled of course)

Render objects inside raytraced objects

Render atmospherics inside raytraced objects

Link to comment
Share on other sites

  • 2 weeks later...
Guest juanco

Wolf: thanks a lot man!!!...finally I will be able to try some raytracy on my works...till now it was a taboo for my computer...lol

take care..

thanks again

 

enoone.

Link to comment
Share on other sites

  • 3 weeks later...

I've also found that in the raytraced shadows parameters of max you can change the max quadtree depth from default of 7 to a max of 10 and it really shortens the time to render. 1 is the slowest and 10 is the quickest. I'm still experimenting with this parameter and haven't really seen any shadow quality changes yet. ;)

Link to comment
Share on other sites

Hi sandpiper,

 

I had a hard time believing this as the manual states "Max Quadtree Depth: Adjusts the depth of the tree used by the raytracer. The greater this value, the more accurate the shadows but the longer they take to render. Default=7.".

 

I tested it myself and got these rendering times:

Max Quadtree = 7 : 5min59sec

Max Quadtree = 10: 1hour5min42sec

 

rgds

 

nisus

Link to comment
Share on other sites

hi nisus,

 

thanks for the reply. Assuming you are using 3dsmax 4.26, this should work the way I described. I had an image taking up to one hour and it is now rendering in less than ten minutes. If you have the manual, check out v2-p.453 and also v3-p.647 to see what it says there: "Greater quadtree depth values can improve raytracing time at the cost of memory use. However, there is a depth value where the performance improvement is offset by the time it takes to generate the quadtree itself. This depends on the geometry of the scene. Default=7."

 

Be sure watch it with the omni lights because they generate up to six quadtrees and take much longer than spot or direct lights.

 

Maybe it's a memory issue. I don't know. All I know is that it worked for my problem and I thought I would help others by relaying this info on. It may be a lot more picky about geometry and types of light than I thought. I think it depends on what amount of geometry is seen and how it's hitting the geometry as well.

 

I'll continue to experiment with it and see what I can find out. Thanks for trying it though! :cool:

Link to comment
Share on other sites

In the help file from MAX is the true story behind quadtree depth... READ IT!!! ;):cool:

 

okay okay... here it is:

 

quote:"

Quadtree

A quadtree is a data structure used to calculate ray-traced shadows.

 

The quadtree represents the scene from the point of view of the light. The root node of the quadtree lists all objects that are visible in that view. If too many objects are visible, the node generates four other nodes, each representing a quarter of the view, each with a list of objects in that portion. This process continues adaptively, until each node has only a small number of objects, or the quadtree's depth limit (which can be set for each light) is reached.

 

Each shadow-casting light ray needs to test intersection with the objects in only one of the leaf nodes of the quadtree. This helps speed up the ray-tracing process. In general, increasing the maximum quadtree depth can speed up ray-tracing at a cost of memory.

 

The maximum size of a quadtree is the square of two to the power of the maximum quadtree depth. At a depth of 7, the largest quadtree has 128 x 128 leaf nodes; at a depth of 10, the largest quadtree has a size of 1028 x 1028 leaf nodes, and so on. (On the other hand, because each successive node contains fewer objects, the size of a node's record decreases the deeper it is in the tree.)

 

Note: An omni light can generate up to six quadtrees, so omni lights that cast ray-traced shadows use more memory at render time than spotlights do.

 

[ June 20, 2002, 02:21 PM: Message edited by: quizzy ]

Link to comment
Share on other sites

Nisus needs to crack his MAX manual every once in awhile. :rolleyes:

 

I have been adjusting the quad tree depth for awhile and it seems to increase the speed of my frame times considerably.

Link to comment
Share on other sites

Nisus: How much RAM do you have on your machine? I think the way it works is that the lower the value the longer time it takes to render but it uses less RAM, whereas the higher the value, the faster it renders and the more RAM it uses.

 

On my machine I have 1 gig of RAM and that is probably helping my situation out a lot. That may have a lot to do with it.

 

I tested out a scene with about thirty spheres on a plane with raytraced shadows and set the depth to 1 and it took 5 minutes and then set it to 10 and it took less than 30 seconds.

Link to comment
Share on other sites

Hi all,

 

Mmm... very strange I have to admit.

For the record, I am using max3.1 under NT and have only 1Gig ram in my machine. Btw, I found the previous quote in the online reference of max3.1.

 

My testscene was a residential building of about 150.000 polygons. I didn't use any omni lights in the scene, but I did use a 122 shadow-mapped spotlights from a lightdome (fakeiosity). So this could be a fund if it appears out to be ram-problem.

 

I'll check the seetings again on a simpler testscene this weekend.

 

rgds

 

nisus

Link to comment
Share on other sites

Hi all,

 

I got some more results on my test.

 

quadtree value:

6 --> long long long...

7 --> 6:16

8 --> 3:10

9 --> 1:53

10 --> too long (more than 30min)

 

memory usage: about 380Mb Out of 1Gb

this did not change much with the different settings, so ram is not an issue here.

Anyone has an idea for the last result that does not seems to be in line with the rest?

 

rgds

 

nisus

Link to comment
Share on other sites

Yeah, I agree with Quizzy. That's pretty freaky if it was getting faster and faster and then at 10 it crapped out. Maybe you should just use 9 instead of 10 eh? I'm wondering if this quadtree feature was brand new with 3.1 and if release 4.2(6) has fixed some bugs with it?? I started out with 3.1 so I wouldn't know if it was part of 2.5 or anything earlier on... :confused:

Link to comment
Share on other sites

Hi all,

 

Unfortunately I can't post the scene for some reasons (first, it's a commercial project, so these stay in-house and second, it's not finished yet)

 

Anyway, I'm using a quadtree depth of 9 now and I will definately try it in the newer models that will be finished next week.

 

rgds

 

nisus

Link to comment
Share on other sites

  • 3 weeks later...
Guest robert

I have to notes:

 

1. Supersampling doesn't work with field Rendering!

2. The Raytracer has improved greatly in Viz4 and even some steps in Max 5.

 

robert

Link to comment
Share on other sites

  • 3 weeks later...

I might be biased, but I LOVE finalRender.

 

The initial setup and familiarization is a little more complex than max's raytracer - but on a few of my scenes (and a crazy benchmark) raytracing with fR was faster than max's scanline renderer.

You've got all the same controls over the engine as you do with max's and then some, plus you've got real blurry reflections and some of the more advanced functions like that. Worth a peek, I guess.

 

Render happy.

Ken Walton

Link to comment
Share on other sites

guys....

 

robert was talking about FIELD rendering... you know for video...

 

robert:

 

I can not believe that supersampling doesn't work when rendering to fields... I will check that. You are rendering to fields because you need to output a sequence to video I assume???...

 

will get back to ya...

Link to comment
Share on other sites

Ok - here's a stupid question that I'm sure I knew the answer to a year or so ago:

 

When you are producing a sequence for video, and you're planning on compositing/tweaking the render afterwards, isn't it better to render (from 3D) to frames w/no fields for compositing?

Of course, after everything's together you'd render your final composite to fields (like from After Effects) before outputting to video. Am I completely wrong? I seem to recall having done it both ways in the past - not sure which was right... If I am wrong, please let me know, and tell me why.

 

Thanks,

Ken Walton

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...