Vertices

Blitz3D Forums/Blitz3D Programming/Vertices

SoggyP(Posted 2004) [#1]
Hi Folks,

Does the number of vertices in a model affect speed? I know that number of surfaces hits and I guess to some degree the number of tris. In my previous post http://www.blitzbasic.com/Community/posts.php?topic=35411 I want to build a mesh and the suggestion, for example with a di, is that each face off the di will have four vertices (making 24 in all) despite the fact that sides could share vertices (reducing it to 8).

Any thoughts (or help with my previous post)

Later,

Jes


Gabriel(Posted 2004) [#2]
Do you mean a die? As in the singular of dice? I don't think it matters in static geometry, though it probably does if the object had skeletal animation. In any case, there's no point fretting about it. If you want a hard, clean edge between two triangles you can't share vertices and if you want a smooth edge between two triangles, you will want to share verts.

Share them where you can, but don't mess up the shading of objects trying to save a few vertices. It's not worth it.

In your example of a cube, you can share verts between the triangles on each of the six faces, but you can't share them between different faces because then you won't have clean, crisp edges between the faces. ( You'll end up with a squared off sphere instead of a nice clean cube. )


SoggyP(Posted 2004) [#3]
Hi Folks,

@Syb: Cool, it's not often someone corrects my spelling(even though I did actually meant a car-wrecked princess, but that's beside the point).

Actually, it's not just a question of a few vertices - in the example of a die(thank-you) if I don't re-use the vertices then I use three times the amount which is a little excessive.

But if that's it, then that's it. Thanks for the help.

Later,

Jes


Gabriel(Posted 2004) [#4]
it's not often someone corrects my spelling(even though I did actually meant a car-wrecked princess, but that's beside the point).


lol, I wasn't trying to be clever, I was genuinely concerned I had misunderstood. That plus I haven't slept since Monday and my vision is more than a little blurry.


Yes, in the example of a die, you're using three times the number of verts, but it's a small number. With a much larger object where the number of verts was more significant, it's highly unlikely you would be using three times as many verts, because you probably wouldn't want that many sharp edges. I suppose it it is technically possible, and certainly if you have a really large amount of low poly objects, it could happen, but generally it probably won't.

But if you need them, you need them. Having smooth edges when you really need a sharp edge is ugly, and I'm pretty confident you won't notice a speed hit no matter what you're doing with them.