Output Mesh Vertex Count

   9808   17   2
User Avatar
Member
5 posts
Joined: March 2018
Offline
I've been using Houdini and Houdini Engine for Unity for a few months now and I always thought the vertex count is a bit higher than it should be. To get to the bottom of this I created a simple OTL that outputs an input mesh.


After importing the mesh in Maya for further inspection, it seems that Houdini Engine does not weld any verts together even if they share the same attributes. You can see that each triangle is surrounded by a mesh border. Is there any way to go around this?
Edited by spaceapegames - May 4, 2018 13:17:27

Attachments:
border_edges.jpg (140.9 KB)
Vertex-Count.jpg (87.0 KB)

User Avatar
Member
17 posts
Joined: Jan. 2013
Offline
Uncheck Split Points by Vertex Attributes in Houdini Settings window in Unity. And vertex count in Houdini generated mesh become equal unity mesh. But then you need use point attributes except vertex.

Attachments:
Без имени-1.png (34.9 KB)

User Avatar
Member
571 posts
Joined: May 2017
Offline
That Split Points by Vertex Attributes is only available in version 1 of the plugin. Version 2 will always split vertices. The decision for this was to reduce issues when marshaling attribute data back and forth between Houdini and Unity.
User Avatar
Member
5 posts
Joined: March 2018
Offline
Thank you for the reply! Using Version 1 of the Houdini Engine with “Split Point by Vertex Attributes” seems to output a vert count closer to Unity and solves the issue completely.

We are working on mobile games and keeping an eye on vertex counts is quite important for performance. It would be a shame if we have to stick to v1 when v2 goes out of beta. Is there any chance of having this as an option for Version 2 in the future? Or maybe have a “vertex count reduce” post step when baking the mesh.
User Avatar
Member
571 posts
Joined: May 2017
Offline
I understand your concern. I'll add an RFE to investigate the possibility of perhaps strictly using points, instead of vertices, or another similar method to reduce the overhead. This probably won't happen for a while though.
User Avatar
Member
5 posts
Joined: March 2018
Offline
Thank you for looking into this seelanv. I really like the new Houdini Engine and looking forward to the option of using points instead of verts.

In the meantime, I implemented a “Weld Vertices” post step after a cook in our project. Not ideal since it's quite slow in Unity but it does give me a significant reduction in vert count without affecting the look of the geometry.


Attachments:
HoudiniMenu.jpg (19.3 KB)
WeldedVerts.jpg (40.0 KB)

User Avatar
Member
571 posts
Joined: May 2017
Offline
Available in today's build (16.5.475) is the option to use points instead of vertices.

Also added LOD Groups as well: https://www.sidefx.com/docs/unity/_meshes.html#Meshes_Output_LOD [www.sidefx.com]

Attachments:
mesh_points.png (41.9 KB)

User Avatar
Member
5 posts
Joined: March 2018
Offline
Thank you so much for addressing this so quickly. Can't wait to try this out.
User Avatar
Member
13 posts
Joined: Aug. 2019
Offline
seelan
Available in today's build (16.5.475) is the option to use points instead of vertices.

Also added LOD Groups as well: https://www.sidefx.com/docs/unity/_meshes.html#Meshes_Output_LOD [www.sidefx.com]
Unfortunately use points instead of vertices loose all uv's set ups in hda.
User Avatar
Member
17 posts
Joined: Jan. 2013
Offline
In my assets I use Vertex Split node to split edges and transfer all vertices attribute to points. May be it can help you.
User Avatar
Member
12 posts
Joined: Aug. 2017
Offline
cgrum
seelan
Available in today's build (16.5.475) is the option to use points instead of vertices.

Also added LOD Groups as well: https://www.sidefx.com/docs/unity/_meshes.html#Meshes_Output_LOD [www.sidefx.com]
Unfortunately use points instead of vertices loose all uv's set ups in hda.

Us there any fix for this issue? I'm facing it right now. ‘Generate Mesh Using Points’ handles Cd, but not uvs. Any workaround?
User Avatar
Member
13 posts
Joined: Aug. 2019
Offline
squaredanced
cgrum
seelan
Available in today's build (16.5.475) is the option to use points instead of vertices.

Also added LOD Groups as well: https://www.sidefx.com/docs/unity/_meshes.html#Meshes_Output_LOD [www.sidefx.com]
Unfortunately use points instead of vertices loose all uv's set ups in hda.

Us there any fix for this issue? I'm facing it right now. ‘Generate Mesh Using Points’ handles Cd, but not uvs. Any workaround?
We just downgrade to 17.5.173 it's the way atm to fix that
User Avatar
Member
12 posts
Joined: June 2014
Offline
@seelan

I'm not sure to understand the logic.
If I use vertices each face is detached as you explained but my vertex attribute is at the right spot.
I need faces to be connected in Unity so I checked “use points”. But now the issue is that the attribute is not properly applied, I've uploaded screenshots of the issue here:

https://www.notion.so/melm/Houdini-Engine-Issue-7a30bf684a43486190b95b70f0e5f825 [www.notion.so]

In both cases, I checked the size of the vertices array and the attribute array and each match. (of course, I'm using vertex attributes in the first case and point attributes in the second)

Do you know what can cause this?
User Avatar
Member
12 posts
Joined: June 2014
Offline
Bump anyone?
User Avatar
Member
571 posts
Joined: May 2017
Offline
If you use points, make sure all your attributes are using points as owner.

If you use vertices, make sure all your attributes are using vertex as owner. Otherwise, point attributes will get split into vertices.

If you are still having issues, please submit a bug with a sample HDA to support@sidefx.com
User Avatar
Member
12 posts
Joined: June 2014
Offline
Thanks,
What do you mean by “owner”?
User Avatar
Member
571 posts
Joined: May 2017
Offline
Each attribute has a owner of type which is one of Vertex, Point, Primitive, or Detail. Check out the Attribute Create SOP node.
User Avatar
Member
12 posts
Joined: June 2014
Offline
Oh… yes that’s what I meant by

« (of course, I'm using vertex attributes in the first case and point attributes in the second)« 

In the HDA I’m using a wrangle to set the attribute but as you can see something does not translate right in Unity.

I’ll post a full sample when I have time.
  • Quick Links