Object Indexes VS Render layers

Hello everybody. Can someone explain to me what the difference is between Object Indexes and Render Layers when you only need to change a single object in a scene through compositing? I watched an Andrew Price tutorial on making Caves and he wanted to make an object have a glare in the scene and he used object indexes instead of setting the object on a different layer and doing it that way. Is there any difference between the two?

well, he could have done so but that would have meant using additional nodes. a render layer node for the gem and the subsequent nodes require to bring them into the main scene. ( not certain if there would be extra nodes at that end, but maybe) with the object index you simply need to bring the object index noodle out and composite from a single node ( then add the object index node making the whole process redundant…)

it just save time duplicating lights on a seper… oh wait it’s its own light source

personal preference really. do it which ever way you’re comfortable with. though the object index is more useful if the scen is really heavy and many layers are being used.

perhaps he just wanted to show you the object index node.
(maybe no one taught him about layers yet…)

I like that. Thanks for your answer. I honestly prefer to use the object index because it makes much more sense in my head than render layers. Anyway…

Render layers are more time consuming than object index as well, maybe that’s why he did it.

The bottom line is … “TMTOWTDI = There’s More Than One Way To Do It.™”

Remember that the word “layer” is one of the most-abused terms in Blender. It means “the four little groups of buttons,” yes, but this is not the same as “RenderLayers.” Not at all.

Ultimately, what you’ve got to accomplish is to “single-out” one particular object or set of objects, so that you can treat them separately. “Object indexes” happen to be a handy way to do this, in some cases, because you can have as many as you want and you can assign them individually and arbitrarily. But they’re not the only way to do it. Sometimes, you just pick one “way to do it,” and hope for the best. :yes:

Both can be viewed as masking schemes but it’s really more about economy than anything else. You can really save a lot of time, memory and processing power by properly configuring your post processing setup, and knowing when to use what comes with study & practice. Slicing and dicing is the name of the game and some things can only be accomplished when you properly set up your scenes, scene layers, render layers, objects, materials, indices, masks for compositing, etc…all at the same damn time. It can become extremely involved depending upon what you’re after. Sometimes you even do this within the scene layers & the materials themselves with features such as “exclusive light groups” but that’s getting off topic here.

A piece of advice here concerning the id masks…use the Full Sample option (along with the Save Buffers option which is enabled by default) rather than the Anti Aliasing check box on the ID mask. This will yield a proper anti aliased mask for any ID pass that has perfect edges rather than the crude mask that results from the AA function on the ID mask node (which yields a chewed up mask with premultiplied edges that look like total crap). AA level of 5 usually gets the job done even for HD renders. Shift + R with mouse hover in the compositor window will re-sample the image at any time and you can even change the AA filter type B4 doing this to check out which one looks best, just be sure that filter size is set to 0.5 B4 rendering. AA filter types look completely different with Full Sample than they do without, but the end result of being able to change on the fly without having to re-render is well worth it.