# primitive type question...

## Recommended Posts

ehem, this question sounds totally lame (and is lame) but i couldn't find any clear anwser for it in the pdf's...

ok, what's the difference between 'polygon' , 'mesh' and 'poly mesh'?

when i create some very basic primitives such as boxes, turuses etc. i may choose between these options in the 'primitive type' menu. it seems so obvious but somehow i can't tell the difference... when do you use 'mesh', 'polygon' and 'polygon mesh' primitive types?

thanks a lot!

##### Share on other sites

Hi!

The difference between these primitive types is the internal representation inside Houdini. Basically it distinguishes the two types "polygon" and "mesh". "Polygon Mesh" is a combination of both (and only available in the box-SOP)

An object consisting of "polygons" can have any arbitrary topology. That means it can have handles, an arbitrary number of boundaries, etc. The internal representation is the following:

-point list: A list of vectors specifying a list of positions in space

-polygon list: a list indexing into the point list to create triangles, quadrilaterals, etc. For each face you have to store additionally the number of corners.

For example

pointlist: (0,0,0) (1,0,0) (0,1,0) (0,0,1)

polygon list: ((3) 0,1,2) ((3) 2,1,3) ((3) 0,3,1) ((3) 0,2,3)

This would specify a tetrahedron with 4 triangles.

Also, this tetrahedron can't be represented as a "mesh". A "mesh" has an implicit topology, and therefore no polygon list. This is similar to NURBS. Well, a "mesh" is actually a NURBS surface. Namely one with degree 1 (or order 2). A mesh always looks like:

```0-----1-----2-----4
|     |     |     |
5-----6-----7-----8
|     |     |     |
9----10----11----12
|     |     |     |
13---14----15----16
|     |     |     |
17---18----19----20```

The numbers I have written at the crosspoints are the indices into the point array (which is also needed by a mesh). They can be easily calculated. If the mesh has a widith of w columns and a height of h rows the index into the point array of crosspoint(x,y) (0<=x<w && 0<=y<h)

crosspoint(x,y) = y*w + x

In the example above w=4 and h=5.

The "Polygon Mesh" mode in the box-SOP is generating faces like the "mesh" primitives, but is using "polygons" instead. Therefore one can continue with extruding handles out of the box, which could not be represented by a simple mesh.

The mesh has its right to exist, because it needs less memory and is therefore more efficient concerning rendering performance. At least this was true in the old days, when memory was rare.

• 1
• 1

##### Share on other sites

oh geez, what you've just written proves that Houdini is a tough beast to comprehend i guess i'll have to read it tomorrow when i weak up with a fresh mind because now i don't understand much

anyway, thank you very much!

##### Share on other sites

In a simpler way,

Polygons; have arbitrary topology - any number of edges.

Mesh; its a patch surface with mxn structure with straight edges (isoparms). Kinda like a NURBs patch with straight edges. This can be converted to Polygons using the Convert SOP.

• 1

##### Share on other sites

I tend to just think of it as:

- Polygons: what you think it is

- Mesh: very low level of detail NURBS

##### Share on other sites

ok, thanks guys! that explains a lot. but then why bother dividing geometry into poly, poly mesh, mesh , nurbs, etc? wouldn't it be easier to only have polygons, nurbs and, say, subD primitives? like in maya. does this houdini's primitives division have any particular use? when do you use 'polygons' and when 'polygon-mesh'? and what about 'mesh' primitives?

##### Share on other sites

Meshes end up being less useful than the other surface types, but they're regular (like NURBs) and faster.

Houdini also supports "Primitive" primitive type to describe the basic primitives like spheres and tubes. You'd wonder why these are useful too, but you'll end up using them fairly often for particles and rendering purposes.

Like most things in Houdini you may wonder at first why something exists, but pretty soon find the most obscure uses for things

##### Share on other sites

Well it's only Polygons, Mesh, NURBS and Bezier really (although admittedly I never use bezier).

The poly-mesh only exists in the box SOP as its a mixture of the two, and is the only time you'll ever use it as a primitive type. It allows the faces of the box to be divided up into smaller divisions. Before we had to put down a box SOP and then a divide SOP to achieve the same result.

As for subD primitives, I don't even know what they are. Are they a valid geometry type? I always thought that they were some weird Alias invention to represent subdivided geometry. And from what I've heard, they're not very user friendly anyway.

In Houdini you would just use standard polygons and then subdivide them with a subdivide SOP. They're still polygons, and still subject to the same rules people mentioned with polygons (arbitrary topology).

M

edit: Almost beat ya J.

##### Share on other sites

On alias sub-d geometry type. They have something special: hierachy. i.e. you start modeling at level 0 (just the basic sub-d shape) .. you can switch to level 1 (like poly with sub-d and depth 1) etc. The nice part however is that you can locally do the subdivisions (level changes). The good thing is that those changes at higher levels will get adjusted accordingly when you modify the geometry at a lower level again.

Now if Houdini wouldn't be Houdini, like all those other programs but Houdini , this allows you some non-linear modeling workflow. Oh and you can do creases and they get evaluated at rendertime. One other nice feature I miss slightly in Houdini, you can edit interactivly the cage model and the mesh in the viewport looks perfectly smooth like nurbs surfaces do.

But since you can do pretty much the same with Houdini and named groups as I just recently learned, I actually prefer the Houdini way of it. Those sub-d in Maya didn't allow the usage of all poly tools and you had special tools for them. It was a pain to create uv-maps for them...

Jens

##### Share on other sites

What Houdini really needs is a subD viewport display mode. I don't know if its possible, but it sure would be cool.

And it would make working with subd's so much easier/faster.

##### Share on other sites

thanks a lot for the replies guys! expect some more noob questions soon

##### Share on other sites

On the subject of why have meshes when you can use Nurbs. We model quite a lot as meshes and then convert to Nurbs right at the end. This is usual because we want total control over where the control points of the Nurbs models end up, and how many are created. You lose this control pretty quickly if you let the nurbs tools have their way as they tend to try to keep features intact regardless of the amount of extra geometry created. Basically if you convert a mesh to a Nurb surface and then display the control cage you should notice that the control cage exactly matches where the points in the mesh were.....

##### Share on other sites
One other nice feature I miss slightly in Houdini, you can edit interactivly the cage model and the mesh in the viewport looks perfectly smooth like nurbs surfaces do.

15022[/snapback]

Can't you just template the subdivide sop and edit your cage in wireframe? In the display options, you can change the template to display as smooth shaded instead of wireframe.

##### Share on other sites
Can't you just template the subdivide sop and edit your cage in wireframe? In the display options, you can change the template to display as smooth shaded instead of wireframe.

15032[/snapback]

I think being able to have some kind of attribute or group with defines which polygons are to be considered subdivision surfaces would be cool. The viewer could potentially show these surface types as their limit surface in the Viewer, and as old school once said - why not have the subdivision limit surface calculated in a seperate thread (according to the viewport LOD) and displayed in viewport when the opportunity arises? In this way we could work quickly on the cage using the regular polygon modeling tools.

I think this is one of the most-often requested features for modeling, IMO

##### Share on other sites
Can't you just template the subdivide sop and edit your cage in wireframe? In the display options, you can change the template to display as smooth shaded instead of wireframe.

15032[/snapback]

Sure I can do this, bbut right now things get fairly slower with a sub-d OP. That's what I was referring to with interactively.

Jens

##### Share on other sites

theDunadan: what do you mean by 'interactively'? i guess applying subD OP is the only way to display smooth version of your geometry.. and that's similar to just about every other application out there. whether it's 3dsmax or maya or whatever, you have to use some sobdivide option in order to view your model smooth. the only deifference is that in all programs except for H. you don't have to mess with display options in order to see low poly cage and subD version at the same time... it's impossible to avoid slowing down of the machine if you want to see everything nice and smooth

##### Share on other sites

Nah, on Houdini exchange there are nice little otls that do all the setup work for you and yes in other programs things get slower as well, but I noticed that when loading the same polycage into Maya the smooth function worked much faster. Likely my pc isn't the fastest, but when I worked on this head if setup up everything for this classic 'polycage wireframe -- smoothed geometry thingy' there would be this annoying .1 - .5 s lag before things get updated in the views. In the end I mainly worked on the polycage without the smoothed preview and only checked periodically how the smoothed version will turn out.

A faster (possibly limited) sub-d display OP would be nice for modeling, but no more no less I'm much more anticipating the new DOP's then such thing.

Jens

##### Share on other sites

maybe you should buy a new video card? it's weird that you get up to .5 sec lags... i don't imagine working with some more complex objects...

##### Share on other sites
maybe you should buy a new video card? it's weird that you get up to .5 sec lags... i don't imagine working with some more complex objects...

15038[/snapback]

Don't think it's the graphics card issue, it's no workstation card (though effectively patched to the quadro / firegl counterparts), but I run on my p4 2,4 ghz / gf 5900 is this problem as well the p4 3ghz / radeon 9800 and the dual xeon 2,4 ghz with Wildcat III.

Since the xeon one is so noisy I try avoiding working on it

Jens

##### Share on other sites

well, viewport performance IS dependant on the video card...

but it's really strange since gf 5900 is a pretty decent card, not to mention wildcat.

## Create an account

Register a new account