Vray render elements/ Maya Layers/ EXR.multi layer

i asked about this some time ago but i got a response from tech support that said Vray doesn’t come with that.

i made a photoshop’d pic, which i will upload later am in a rush today.

(yea finally got to post, ‘hello world’)

Could you elaborate a bit more on this, please? I can’t fully understand what to look at from the screenshots. Thanks in advance.

Do you mean you want to store all frames in one multichannel EXR file or something like that? I’m still not sure I fully understand the question.
Thanks.

yes i can see how that would be confusing to a programmer. from an artist point of view it seems simple, but B does look like 8 to a computer.

so… i would like to create a capsule in the .EXR which has the render elements from the 2nd and 3rd (so on) layers from maya. with a name starting with the ‘layer’ and then the ‘render elements’
of course it should have the R G and B channels from the master layer, and the Alpha channel. but also ‘matte’, ‘motion blur’ etc… so for starts the RGBA and then render elements.

of course i could just render out a separate file for each render layer as people do now, even some use ‘maya software or hardware or vector’ render engines to render other layers. but that would cause it to have a header and file name and table of contents and so on, and when you have 100 terabyte project every megabyte counts.

it seems tedious to me when i just need an alpha channel for a shadow layer. or separate animation layers for different avatars with a matte, to print out a totally separate folder and file and
then further down the pipeline in the compositing stage a separate node tree for blending, again adding extra megabytes on the processor and ram. which if you are familiar with Nuke gets pretty intense when working with 4k and 100 layers.

sorry if my grammar and vocabulary is not as good as a scripter. just ask if you want to know more about my idea :slight_smile:

bob

I can see how that could come handy, but I’m afraid it’s not possible. A separate image file is created for each render layer and for each frame of that layer (if there’s animation). It’s how Maya works.

You could disable every render layer but the one you need. Even if you only need the alpha, there an option to not save the RGB channel, so for a particular render layer you can disable all but one render element, and for another render layer - you can disable all render layers + disable the RGB and just get the alpha. But it will again result in a separate image file and there’s no way around it.

so you can’t write a script that puts the separate layer in an envelope of the master layer, and set a render override for the render elements you want? like a post operation of the render process, so the render engine renders 3 passes and then stacks the elements together in a single .EXR

You can try using the DWAA and DWAB compression types for EXR - they should save you quite some storage space. The option is in the Render Settings > Common tab > Image Format Options (button) > EXR compression type.

Otherwise, it’s not that simple and I think that this is fundamentally impossible. It’s just not how Maya works. V-Ray can’t access what’s on one render layer, while Maya is telling it to render a different one. Think of render layers as separate scenes - they can contain different geometry and so on. That’s (roughly) how V-Ray and other renderers treat them and accessing such information is only possible during rendering, which is, as I understand, too late for what you need to happen.

You can use the render layer overrides to disable the undesired render elements per layer.

yea… don’t know much about .exr extensions, but i thought it should be possible to add new layers like a PSD in photoshop.

this is not exactly what i was thinking… but i guess it could be tinkered into a post process

originally i found this problem when my buddy who does not cg at all
asked me about making a shadow for the truck i was debugging nuke with.

after i researched it i found that making a shadow in vray was a complicated process, which required a separate render layer. i thought this was a waste to make an entirely different image file and folder
just for a shadow. also this could become complicated in a scene with multiple character shadows, which i will probably find shortly in my classroom scene with 20 some students and 9 lites. each student will probably need its own render layer, plus adjoining shadow.

i probably should have asked how to make a shadow easier, but i can think of other instances when adding a separate render layer to a .exr layer would be nice.

looking at a photoshop scripting code in java, to Batch the process. #keyword: merge_multiple photos_by \filename.###.ext

may make a tut on this. to fix my shadow quandary

Might be light down the tunnel…

https://forums.cgsociety.org/t/nuke-how-to-write-multi-channel-exrs/1294860

i tested this out, and had mixed results, nuke tried to add a alpha layer to each of the 30 render elements, and not to the PNG of the shadow. which of course photoshop displayed as a stack
and there is still the end result, to Import to maya and use in the hypershade or node graph to split back into a series of images for multiple shaders or textures from one file. so you can send your scene down a pipeline, with only one file which can be reimported into the modeling/rendering program with all the connections intact. haven’t tested that out yet in maya, am using 2016, seems that version is aimed more at the node graph and less hypershade so i will see.