Sorting mesh faces using an add node?

   2359   17   2
User Avatar
Member
188 posts
Joined: May 2021
Offline
I have setup a system that uses sorting of mesh faces based on their proximity to a point and then colour is assigned to them. Based on that colour, extrusion scale is setup.







How can I use use point(s) separately (using an add node maybe) that allows me to have more control?

Attachments:
custom sort point question.hip (170.1 KB)

User Avatar
Member
172 posts
Joined: Jan. 2014
Offline
you can reference the position from a null or "add" node?
RMB - "paste relative reference"

Attachments:
custom sort point question_v01.hip (172.1 KB)

I contribute to the beauty of this world
User Avatar
Member
330 posts
Joined: April 2018
Offline
You could do this quite easily with a Mask From Geometry SOP.

User Avatar
Member
188 posts
Joined: May 2021
Offline
deviner
you can reference the position from a null or "add" node?
RMB - "paste relative reference"

Thanks a lot. How did you change the colours even though the ramp is greyscale?
User Avatar
Member
188 posts
Joined: May 2021
Offline
eikonoklastes
You could do this quite easily with a Mask From Geometry SOP.


Interesting. If I try to do the same setup at my end, I don't get any mask. I tried with 'add' node as well as with a 'box' node.
Edited by proceduralist - Sept. 12, 2022 00:56:47

Attachments:
masking.hip (129.6 KB)

User Avatar
Member
419 posts
Joined: Feb. 2012
Offline
Change the distance to outside geo or from surface, if you want the inside to work make your box bigger since you have a big radius. If you want the pt to work you need to change reference grp type to point, this will work with both btw.

Attachments:
houdini_NxYa1FpDVn.gif (8.5 MB)

User Avatar
Member
8516 posts
Joined: July 2007
Online
proceduralist
If I try to do the same setup at my end, I don't get any mask
make sure the visualizer for mask attribute is on

also your Distance Metrics is set to Distance Inside Geometry, in your case you most likely want Distance From Surface if you are planning to use Reference Group Type Primitive to get distance from your cube faces
or change Reference Group Type to Points if you want distances from individual points
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
188 posts
Joined: May 2021
Offline
Thank you @tamte and @sepu. I toggled on the visualizer and that did it. Now I am able to get the mask, now how to integrate this into the attrib vop?

I am trying to get this kind of setup. I want to add multiple points (or geometries) and let the extrusions get affected accordingly with the noise. In the original post, I could achieve that with only one point. I made this arrangement through scripting inside Grasshopper plugin for Rhino
Edited by proceduralist - Sept. 12, 2022 02:02:12
User Avatar
Member
419 posts
Joined: Feb. 2012
Offline
Merge the pts or geo before going into the second input.
User Avatar
Member
188 posts
Joined: May 2021
Offline
How can I use the masking in the attrib vop system? I am able to merge different geometries and get the masking accordingly.
Edited by proceduralist - Sept. 12, 2022 02:38:46
User Avatar
Member
419 posts
Joined: Feb. 2012
Offline
bind to import an attrib and bind export to export an attrib.

I would recommend reading/watching a beginner tutorial on how attributes work, how data flows, etc into H
User Avatar
Member
188 posts
Joined: May 2021
Offline
I have gone through some attribute vops tutorials before but none of them covered using masks. I tried here but the entire geometry gets extruded.


Attachments:
masking.hip (200.8 KB)

User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
You can promote mask from point to prim attribute using Attrib Promote and split each primitive using Primitive Split so they can be extruded individually.

Use mask for the PolyExtrude's Distance Scale:

Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
330 posts
Joined: April 2018
Offline
proceduralist
I have gone through some attribute vops tutorials before but none of them covered using masks.

The Attribute Adjust SOPs have greatly mitigated the need to use VOPs for masking and noises.

You can tweak your mask with an Attribute Adjust Float SOP.

User Avatar
Member
188 posts
Joined: May 2021
Offline
Thanks a lot.

Okay. This is an interesting effect which I did not intend but looks cool for experimentation. If I use a point class in atrib adjust and then promote it to primitive, I get this. The extrusion remains only in the area of masking.



If I choose 'primitive' in the attribute class for attribute adjust, I get this. Why does the unmasked geometry also get extruded in almost the same height range?


Moreover, I am looking for this animated effect that gets affected by two or more masks and ripple travels throughout the grid. How to do that?
https://imgur.com/a/OzU8Vos [imgur.com]

I shared the hip file in the original post. Here's the hip file with the attrib adjust method.
Image Not Found
Edited by proceduralist - Sept. 12, 2022 08:58:25

Attachments:
masking.hip (324.6 KB)

User Avatar
Member
330 posts
Joined: April 2018
Offline
proceduralist
If I choose 'primitive' in the attribute class for attribute adjust, I get this. Why does the unmasked geometry also get extruded in almost the same height range?

At this point you probably want to brush up on how attributes work in Houdini.

By setting the Attrib Adjust Float SOP to operate on Primitives, you're generating a primitive attribute called 'mask' that has no relation to the point attribute (also called 'mask') that you created with the Mask From Geometry SOP.

A quick glance at your Geometry Spreadsheet would inform you on what's happening.
Edited by eikonoklastes - Sept. 12, 2022 07:27:36
User Avatar
Member
188 posts
Joined: May 2021
Offline
Okay. Just checked the geometry spreadsheet. Even though 'mask from geometry' gives the option of primitives in the drop down menu for 'reference group type', it does not give any masking values to primitives ......


and gives values to points instead despite me choosing primitives in the reference group type.



Why is that? Is it only supposed to work on points only?

The attrib adjust float generates new values for primitives though.
Edited by proceduralist - Sept. 12, 2022 09:50:12
User Avatar
Member
330 posts
Joined: April 2018
Offline
At this point, I'd say brush up on some general Houdini fundamentals, particularly groups and attributes. Your questions stem from a fundamental lack of understanding of how things work. Also check the documentation for the nodes. You can get context-sensitive help for each node by clicking the little help icon in the Parameters pane.
  • Quick Links