3-vector to ramp ?
7569 34 1-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
@tamte - In one your examples, the pig head retained it's size, and you can scale the points along the Y.
I'm scattering points over the object, those points are not conforming to the object, while allowing me to move the points along the Y to which the points are scattered & keep the scattered points volume or shape unlike previously whereas all the points were aligned along the Y.

The points are retaining their shape based on the input geometry, although when I manipulate the spline ramp, the points on the input geometry aren't moving on the Y axis ?
I'm scattering points over the object, those points are not conforming to the object, while allowing me to move the points along the Y to which the points are scattered & keep the scattered points volume or shape unlike previously whereas all the points were aligned along the Y.


The points are retaining their shape based on the input geometry, although when I manipulate the spline ramp, the points on the input geometry aren't moving on the Y axis ?
Edited by _Christopher_ - April 5, 2017 23:55:00
【T】【C】【S】
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
The object node with the following name; modify_py_using_single_ramp_based_on_relatie_bbox_in_y in the scene file you attached in one of your posts. The pig head can be adjusted along the Y while retaining the X & Z position of the pig head.
This was my goal, except I want the points to retain their conformity to the input mesh I thought this would occur since there is obviously an input geometry in the attriVop unfortunately it didn't ?
This was my goal, except I want the points to retain their conformity to the input mesh I thought this would occur since there is obviously an input geometry in the attriVop unfortunately it didn't ?

【T】【C】【S】
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
they will not as the scattered points within each polygon can sample the ramp more precisely
so while polygon shape is defined by the positions of it's points whose are displaced in Y by the ramp
each scattered point within that poly will compute it's own displaced Y position which will be much more precise than just linear interpolation of displaced position of original polygon's points
you can scatter on the original pighead then attribinterpolate their positions to deformed pighead
look at the example
so while polygon shape is defined by the positions of it's points whose are displaced in Y by the ramp
each scattered point within that poly will compute it's own displaced Y position which will be much more precise than just linear interpolation of displaced position of original polygon's points
you can scatter on the original pighead then attribinterpolate their positions to deformed pighead
look at the example
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
You can't use it this way, you need to interpolate P from the deformed geo like in the example, not from deformed points as that not only has different topology than the geo you scattered the points on, it as well was what you wanted to avoid since deforming points would give you more precise P than you want and therefore it will be misaligned with deformed geo
One thing to note is that in the example the scatter has sourceprim and sourceprimuv attribs turned on so that the attribinterpol can use them to find the locations on the geo of the same topology as input geo to scatter
One thing to note is that in the example the scatter has sourceprim and sourceprimuv attribs turned on so that the attribinterpol can use them to find the locations on the geo of the same topology as input geo to scatter
Edited by tamte - April 7, 2017 14:03:36
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
You can't use it this way, you need to interpolate P from the deformed geo like in the example, not from deformed points as that not only has different topology than the geo you scattered the points on, it as well was what you wanted to avoid since deforming points would give you more precise P than you want and therefore it will be misaligned with deformed geo
Sorry, I understand what you mean but I don't know how to interpolate P from a deformed geo node rather from deformed points ?

【T】【C】【S】
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline

I want to add finer control; therefore I added a intersect as so the points would always stick to the surface when the spline ramp was adjusted, although even when negating the normals to the ray direction in the intersect vop node, the points are offset to the surface ? As well when adjusting the spline ramp, the scattered points don't flow along the surface of the object to which the points are scattered ?
When comparing the outcome strictly of the AttribVOP and strictly of the AttribInterpolate node, there is a difference; can I not achieve consistency between both ? The difference is the AttribInterpolate node results scale the scattered points while the AttributeVOP results are more or less the result I want ?
【T】【C】【S】
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
Christopher_R
When comparing the outcome strictly of the AttribVOP and strictly of the AttribInterpolate node, there is a difference; can I not achieve consistency between both ? The difference is the AttribInterpolate node results scale the scattered points while the AttributeVOP results are more or less the result I want ?
who knows at this point, I really have no idea what you want
maybe rather post a file
- if you use attribinterpolate method, you will get exactly the same result as applying AttribVOP to the original geo as the points will interpolate deformed positions from the geo
- if you apply AttribVop only on scttered points (assuming the bbox in y is the same) you will get more precise result and therefore point's will not stick to the surface, so obviously a difference
- if you apply xyzdist or intersect to stick them back to the live deforming surface, you are just asking for a trouble, but maybe it's what you want? That'd be just ray SOP with minimum distance after deforming points to ray them to deformed surface
- what do you mean attribinterpol scles the points? it just deforms them to match the deformed original geo, well it really depends how you are using it, hard to see without a file
- or is the problem that the bbox of the points is different from bbox of the surface? in that case you can easily sample bbox from the surface when deforming points
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
if you apply xyzdist or intersect to stick them back to the live deforming surface, you are just asking for a trouble, but maybe it's what you want? That'd be just ray SOP with minimum distance after deforming points to ray them to deformed surface
This is my goal.
I know I'm only adding the intersect with the spline ramp based on the previous screen shot. As you mentioned I can use the RaySOP or IntersectVOP. What am I doing wrong that the points have an offset from the original geometry when I template the original geometry node.
Otherwise I'll post a file

【T】【C】【S】
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
Christopher_R
What am I doing wrong that the points have an offset from the original geometry when I template the original geometry node.
based on screenshot, there seems to be couple of things wrong:
assuming that the geometry flowing to the AttribVOP is only the scattered points you are mentioning
- you can't intersect with just points, so you need to plug the actual geometry to project to in the second input and use that as Intersect File input
- positive or negative N direction doesn't guarantee the hit so you either test both directions per point or rather use XYZdist or entioned Ray SOP in Minimum Distance mode to get the closest surface regardless of N direction
- even if Intersect found the location on the geo you are projecting the original P onto the geo, then adding deformed P to it so obviously creating huge offset as add1 vop is adding two king of final positions together
what you may want is using output of fit2 as a sampling P for Intersect or XYZDist/Primuv, then using just resulting P without any addition
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- _Christopher_
- Member
- 767 posts
- Joined: April 2014
- Offline
-
- tamte
- Member
- 9249 posts
- Joined: July 2007
- Offline
it almost seems like you always pick the least convenient option from all the solutions and decide to go that way
not sure if you even tried Ray SOP or XYZ dist as mentioned, but anyway
here are all 3 options, hopefully it'll shed some light to their usage
intersect and xyzdist aside, from all your posts is apparent that you are clearly struggling with very fundamental principles of cg or even math concepts and therefore having problem to grasp and understand any kind of answer
I highly suggest you to browse the forums, dissect any interesting hip files you find (or even help example scenes), read replies to topics solving problems that interest you, learn from tutorials, maybe even search houdini help for nodes and functions if not sure how to use them or what they are doing
not sure if you even tried Ray SOP or XYZ dist as mentioned, but anyway
here are all 3 options, hopefully it'll shed some light to their usage
intersect and xyzdist aside, from all your posts is apparent that you are clearly struggling with very fundamental principles of cg or even math concepts and therefore having problem to grasp and understand any kind of answer
I highly suggest you to browse the forums, dissect any interesting hip files you find (or even help example scenes), read replies to topics solving problems that interest you, learn from tutorials, maybe even search houdini help for nodes and functions if not sure how to use them or what they are doing
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- Quick Links