constrian object to viewport

   7030   9   3
User Avatar
Member
1 posts
Joined: July 2005
Offline
Sorry for my lingo, I'm still getting used to houdini.

I want to constrain some text I made to my current viewport. I know in the “Look At” parameter, I can put in a path to a camera, but that is different than the default perspective viewport, and I haven't had any luck finding this in hscript or in the python docs, or just by using some houdini nodes.

Can anyone point me in the right direction here?

- fortner
User Avatar
Member
401 posts
Joined:
Offline
You can link the text object to the camera object.

Maybe there are other approaches as well.
But this is simple and working.

Georg
this is not a science fair.
User Avatar
Staff
3455 posts
Joined: July 2005
Offline
but in Houdini there is no ‘perspective’ camera…
Michael Goldfarb | www.odforce.net
Training Lead
SideFX
www.sidefx.com
User Avatar
Member
401 posts
Joined:
Offline
… then I misunderstood the question …
this is not a science fair.
User Avatar
Member
2199 posts
Joined: July 2005
Online
You could set the background image to point at a cop with your text in… maybe.
The trick is finding just the right hammer for every screw
User Avatar
Staff
3455 posts
Joined: July 2005
Offline
@ o0fortner0o
with only a guess at what you're trying to do (please feel free to correct me)
I think what you'll need to do is make a camera with a special name ‘persp’ or something…then all the usual tricks can be used.


HTH
Michael Goldfarb | www.odforce.net
Training Lead
SideFX
www.sidefx.com
User Avatar
Member
344 posts
Joined: July 2005
Offline
What we were trying to do is put labels (font SOP) on locators we are importing from Maya. We thought it would be a nice feature to have the locator's label always always face the screen regardless of what camera the user was viewing the scene through (even no camera). We don't want to end up with a complex solution for this, so well probably just orient the lable to the locator's Z axis.
User Avatar
Staff
3455 posts
Joined: July 2005
Offline
ah…
SESI might have an answer for this…
you might do something like have the locator (it's called a null in Houdin btw mike) point to the mouse position…?
it would also be nice to have that object lable thingy in the display options be available on a per object basis…
Michael Goldfarb | www.odforce.net
Training Lead
SideFX
www.sidefx.com
User Avatar
Member
7725 posts
Joined: July 2005
Offline
In H9, you could also just create a custom attribute and have its text displayed in the viewport. eg.
1. Put down a default null object
2. Dive inside and append a AttribCreate SOP. Set the Name to say, “label”. Set Class to Primitive. Set Type to String. Set String to say “Test”. Set the display flag on the AttribCreate SOP.
3. Hit d with your mouse in the viewer to bring up the display options.
4. Under Custom, choose “Create Attribute Text”. This creates a new custom display option.
5. Right-click on “text1” and choose Edit. Set Attribute to “label”. Hit Accept.
User Avatar
Member
344 posts
Joined: July 2005
Offline
That's pretty sweet, thanks , Edward.
  • Quick Links