Friday, July 27, 2012

Uploading Mesh for LOD and Decay in Second Life

Consider these four tables. All four tables are 100% mesh and were created from the same model made in Mesh Studio.



Now let's say we're having a bad day in Second Life and can't seem to get good LOD (Level Of Detail) settings to stick in our viewer. Let's pan our camera back away from the tables and see what happens to them. I deliberately turned my LOD down to 0.5 to take these example photos.



Hmmm, the one on the left looks like crap. It has decayed (collapsed).  Let's pan back some more.


Curiouser and curiouser, the two in the middle still look okay, but they've changed shape! Let's pan back even more.


Now this is truly strange. The first table has decayed even further, and now the second table looks like crap too. The third table has changed shape again, but the fourth table hasn't changed at all. 

The difference is in how they were uploaded. I made 3 versions of the table, the original one with four legs, a crossbeam, a spike to hold the crossbeam in the legs, and feet; a simpler one with two legs and a crossbeam and feet; and an extremely simplified one with only 2 legs. 

When making models like this, remember that each model will have to use the same number of textures (materials, faces) to be accepted by the uploader. The table uses 2 textures, a wood, and a metal for a little iron spike that holds the crossbeam in place (which is probably too small to see in these photos), which were grouped into 2 faces by the Mesh Studio Object-2-Joined-Mesh script. When the spike was removed to make the simpler models, I had to remember to put the metal texture somewhere else on the model so it would remain a 2 faced object.  I put the metal on the end of the crossbeam in the lower detail model, and on the inside of the leg in the lowest detail model. 

In Mesh Studio, you texture your working prim model in world, then texture your final mesh model using the working prim model as a reference after you upload it. Make sure your working prim model is textured to its final detail in default mapping, and the repeats and offsets will be baked in. Planar mapping is still buggy, so use cautiously. 

Now lets look at how each table was uploaded. 





The first table was uploaded by loading the high detail file into the High LOD field, then letting the uploader generate the decay for Medium, Low, and Lowest. I could have previewed what I was going to see in other LOD settings using the drop down menu under the preview picture, which would have looked just like what we saw in the previous photos when I panned my camera back. My Land Impact is going to be 0.600 prim if I decide to use this version of the table. 






I loaded the high detail model from file for the High and Medium settings, and noticed my Land Impact rose to 0.680. Then I loaded the lower detail modet into the Low field, and the Land Impact stayed at 0.680. I let the uploader generate the Lowest detail, then uploaded it. This is why the table changed shape at a distance, then collapsed completely at long distance. 





Table number three has the high detail model file loaded into High and Medium, the lower detail model loaded into Low, and the lowest detail model loaded into Lowest. My land impact has gone up to 1.285 (this will be rounded down to 1, since it is lower than 1.5). It costs more, but it will always look like some kind of table. 





The last table has the high detail model file loaded into ALL levels of detail. It will always look like what I originally wanted it to look like, but the Land Impact has gone up to 5.959, which will be rounded up to 6. (This slide was used in a building class in New Babbage, where I worry about how the skyline looks, hence the extra text.)

Now it is time to make a judgement call. This is furniture, and it will be inside a room. No one is going to see it from far away, so I decide that table #4 has more level of detail than I care about. In the end, I decided to use table #2 as the best compromise between LOD and Land Impact. Remember when you link objects, the cost is added according to the actual Land Impact, not the rounded figure, so I could have two of table #2 for the same Land Impact cost as one of table #3.  

Make more sense now? 





No comments:

Post a Comment