Hi!
I was wondering about up vector. As I dont really know what it is, what is that for, and what does it do in 3d especially in Houdini or maybe it is a math term (pardon me as english is not my first language)…
As far as I know from google, and by looking at the lookat POP node example, http://localhost:48626/nodes/pop/lookat [localhost] , it seems that its purpose is to define the particle's axis perhaps?
So it will be great if somebody could explain up vector.. how do we able to see it in Houdini? Like we can see the point normals etc…
In that example itself, in the upvector1 node, it has this expression :
vector3(0, 1, 0) * rotate(ch(“../../path_object/rz”), “z”)
which the ch() expression was actually returning nothing as that path object is not at the correct level… it should go up one level higher so it could return the rz value of path_object which is 20.
even if I delete everything apart from the vector3() expression, the example still works fine. And i tried to even bypass the upvector node, and it is also still working.
I also read somewhere in the upvector help, that the default z axis for a particle is its velocity, and the y axis is defined by the up vector, and x axis is the cross product between the z and y axis.
So by reading all of this info, I assumed that up vector is to define the axis?
Thank you for the time and thanks in advance for any insight.
Up vector explanation...
18826 3 0-
- sanlin
- Member
- 12 posts
- Joined: Nov. 2008
- Offline
-
- Fabian
- Member
- 127 posts
- Joined: July 2005
- Offline
Hi,
in general terms an up vector helps define a frame of reference for constructing your rotation matrix. This can be used keep a characters knees pointed the right way or a particle aligned or keep a camera up-right or used as a basis for figuring out tangents on a curve, etc.
For example if you only have a point and velocity vector the using an up vector you can use cross products to get the rest. That up vector can either be a a constant like (0,1,0) or something you derive by other means such as position of a null. This isn't a great explanation but I hope it helps.
Fabian
in general terms an up vector helps define a frame of reference for constructing your rotation matrix. This can be used keep a characters knees pointed the right way or a particle aligned or keep a camera up-right or used as a basis for figuring out tangents on a curve, etc.
For example if you only have a point and velocity vector the using an up vector you can use cross products to get the rest. That up vector can either be a a constant like (0,1,0) or something you derive by other means such as position of a null. This isn't a great explanation but I hope it helps.
Fabian
-
- ragupasta
- Member
- 349 posts
- Joined: Aug. 2006
- Offline
As for visulaizing the attrib. Hit D over the viewport for display options. Look at custom in the bottom half of the screen, and click what looks like a point normal to the right side. An edit window will pop up. Name and label it, but make sure you use the correct attribute name (in this case “up”).
After this look on the right viewport stowbar where the display options for the view are. 4th from last, kinda looks like a speech bubble. Left click and hold it and choose which ever custom attribs you have created.
Cheers
Edit: Ick sorry I forgot to resize the image smaller..
After this look on the right viewport stowbar where the display options for the view are. 4th from last, kinda looks like a speech bubble. Left click and hold it and choose which ever custom attribs you have created.
Cheers
Edit: Ick sorry I forgot to resize the image smaller..
-
- sanlin
- Member
- 12 posts
- Joined: Nov. 2008
- Offline
Hi guys,
thanks for the fast reply.
Fabian, is it basically helping us to define a new vector (xyz) orientation? Because I just tried using it, and now, I could see the up attributes in the viewport, and the particle gnomon was changing as well once I change the up vector and when i gave it a force pop, i could see the change… In my last post, my viewport didnt give me any feedback, when i display the particle gnomon, they were just stayed still.. so i had no idea what was happened… But still I need to have a look at this.. still not really sure.. well thanks for the explanation anyway, I know its hard to explain as i myself having difficulties how to ask..
Ragupasta, thanks a lot for the reply. I did try that before, but it wasnt work because there was a problem with the viewport display. I realized it as you told me the same way as I had it before and it wasn't give me any feedback.
I just went to the edit~preferences~3d viewports, and changed the scene renderer to GL 2.1 which by default is H11. Now I could see the particle gnomon rotating and etc which I could'nt before
thanks for the fast reply.
Fabian, is it basically helping us to define a new vector (xyz) orientation? Because I just tried using it, and now, I could see the up attributes in the viewport, and the particle gnomon was changing as well once I change the up vector and when i gave it a force pop, i could see the change… In my last post, my viewport didnt give me any feedback, when i display the particle gnomon, they were just stayed still.. so i had no idea what was happened… But still I need to have a look at this.. still not really sure.. well thanks for the explanation anyway, I know its hard to explain as i myself having difficulties how to ask..

Ragupasta, thanks a lot for the reply. I did try that before, but it wasnt work because there was a problem with the viewport display. I realized it as you told me the same way as I had it before and it wasn't give me any feedback.
I just went to the edit~preferences~3d viewports, and changed the scene renderer to GL 2.1 which by default is H11. Now I could see the particle gnomon rotating and etc which I could'nt before
-
- Quick Links


