Jump to content

Get the current rendering stereo camera


ericgd

Recommended Posts

Greetings,

Long time listener, first time caller.

How do we query the stereo camera that is currently rendering (left or right).

I want to add an expression to switch (with the switch node) 2 sops depending if it's currently rendering the left or the right.

I would expect my sop to switch at render time depending what it is rendering.

I don't want to have 2 mantras node.

A quick test I did was to add put "$EYE" in the text field of a Font SOP, but the $EYE variable gives me "stereo" for both cameras.

Thank you.

EricGD

Link to comment
Share on other sites

Greetings,

Long time listener, first time caller.

How do we query the stereo camera that is currently rendering (left or right).

I want to add an expression to switch (with the switch node) 2 sops depending if it's currently rendering the left or the right.

I would expect my sop to switch at render time depending what it is rendering.

I don't want to have 2 mantras node.

A quick test I did was to add put "$EYE" in the text field of a Font SOP, but the $EYE variable gives me "stereo" for both cameras.

Thank you.

EricGD

:) No. Things does not work that way. $EYE global variable(like any other) exists only in houdini context, mantra has nothing to do with that variable. When you press render, houdini evaluates parameters with expression ($EYE in your case) and write a result to ifd file. Then, this ifd will be used by mantra to render both, left and right camera.

For your particular task its better to use takes, and setup 2 mantra nodes.

And if you want to go really deep:

There is a new render property in build 11.0.861 camera:stereoeye

Journal

Then you can querry this property in python callback, but you can't change geometry(your text) anyway.

Edited by Stalkerx777
Link to comment
Share on other sites

:) No. Things does not work that way. $EYE global variable(like any other) exists only in houdini context, mantra has nothing to do with that variable. When you press render, houdini evaluates parameters with expression ($EYE in your case) and write a result to ifd file. Then, this ifd will be used by mantra to render both, left and right camera.

For your particular task its better to use takes, and setup 2 mantra nodes.

And if you want to go really deep:

There is a new render property in build 11.0.861 camera:stereoeye

Journal

Then you can querry this property in python callback, but you can't change geometry(your text) anyway.

Spassiba.

I see.

I guess it makes sense. It's more efficient for Houdini to "(1) build the scene then render this scene from multiple point of view" than "(2) get the current view and build the scene for this particular view".

It would make huge ifd files by default, which would suck, I admit. And it would really slow down the render time.

However, for my particular situation, I would not mind this huge ifd. But I guess I would have to settle for 2 ifds.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...