Thursday, July 21, 2011

Flexible Meshes: The Sword That Cuts Both Ways

So, Linden Lab has decided to cut out flexible meshes, due to lag concerns.  I think Linden Lab is wrong on this.  Because, while it would mean more lag, it would also mean an opportunity to reduce it, by replacing the older flexiprims with a more efficient design!

Flexiprims have always been a major source of lag, and they are most commonly used for the creation of dresses, skirts, and hair.  But, if you were to create a skirt from a mesh and use it as clothing, you could reduce the lag generated by the skirt for these reasons:
  • A flexiprim skirt uses a lot of flexiprims.  One friend was wearing one with 18 prims, while another was wearing one using 51 prims!
  • Skirts use flexiprim cylinders.  Each cylinder uses 98 vertices at maximum LOD, and 14 vertices at minimum.
  • By making them flexible, their LOD increases a lot.  At minimum, a flexible mesh will have 56 vertices.  At maximum LOD, it will have 216 vertices.  And if you make them hollow, then the vertex count will roughly double.
As you can see, flexible prims on their own are rather inefficient.  A few of them scattered about won't do much to affect lag, but they will increase lag when there are ton of them all over.

So, I've made the point that flexible objects are laggy.  Why would sculpted meshes allow you to reduce lag?

The answer is simple: optimization.  A skirt maker can create a flexible mesh skirt as one single object, but rather than having the vertex count of a few dozen flexible prims, it would have a vertex count equivalent to just 4-8 flexible prims, depending on how ornate it is.  Mesh hair would also benefit from such improvements to LOD.

There will, of course, be people who would overuse this functionality and mesh itself, resulting in heavy lag-inducing objects with lots of needless and unnoticeable detail.  My personal hope is that such "detail gluttons" will receive a very quick and very harsh lesson for their mistakes.

No comments:

Post a Comment