By RichG
#369967
Does anybody know how to get Xpresso to access the Z-buffer distance settings in the Maxwell Scene file? Just had another situation where I moved my camera and forgot to re-calculate the min & max Z-buffer distances again before rendering. So I decided to exercise my feeble Xpresso skills and try to set up a system where I could have 2 nulls in the scene defining the start and end of the Z-buffer which would automatically update the scene file when the camera moves. Unfortunately I have hit a wall now as the node for the scene file allows a z-buffer input but I can't go deeper to the numerical boxes. My tree can be seen here, the node: Scene HDR 1 is the Maxwell scene file:

http://www.loopcorp.com//Miscellany/Xpresso_Tree.jpg
By JDHill
#369973
Here's the problem: the near/far values are not given string names, and this is making them inaccessible to xpresso. To get around it, you can go into your plugin folder, to res/strings_us/description/Omxsceneobject.str, and insert the following entries into the string table:
Code: Select all
MX_SCENEOBJECT_IMAGECH_ZBUFFER_RANGE_NEAR "Near";
MX_SCENEOBJECT_IMAGECH_ZBUFFER_RANGE_FAR  "Far";
Just to be sure, the structure of the file will now be:
Code: Select all
STRINGTABLE Omxsceneobject
{
    Omxsceneobject "Maxwell Scene Object";

    MX_SCENEOBJECT_IMAGECH_ZBUFFER_RANGE_NEAR "Near";
    MX_SCENEOBJECT_IMAGECH_ZBUFFER_RANGE_FAR  "Far";

   // lots of other param names follow...
}
After doing so, you should find there are now "Near" and "Far" ports available under Scene Object > Output > Render Channels (also visible in the AM). As long as you make sure "Camera Dependent" is enabled in the xpresso tag, it should now work as you intended.
By JDHill
#369981
Yes, I can do that, I will just have to do some fussing with the layout, since as you may notice, with the near/far strings, the whole Scene Manager UI gets wider, forcing a horizontal scrollbar at widths where it did not otherwise have one.
By RichG
#369999
Hi Eric

Not sure if you're just pulling my leg there but I'll assume not! It's useful for post processing. I usually use it for adjusting the focus in post or adding colour correction based on distance i.e. atmospheric haze etc but yes, it could create fog too.

In this case I had rendered a huge 35000 pixel wide image looking across a plane of grass but decided I wanted a much wider angle. So I dollied in a lot and made the fov much wider but forgot to adjust the distances on my Z-buffer which now started way beyond where I needed it to end. With this method I know that wherever my camera is positioned, the Z-buffer always begins at the start of the grass plane and finishes at the end. I always found that z-buffer dialogue a bit hard to work with, needing lots of tests to get it just so, and thought "if only I could just put a null where I want it to start and finish". So that's what that Xpresso does now.

I'll not be surprised to find that NL is done by n[…]

Haha, thanks.

Hello, I'm still waiting for a solution to the pro[…]