Warning: If you are a follower of my blog postings and you know nor care NOTHING about creating 3D models for SL then I would strongly suggest you stop reading this blog posting right now. :)
For those are still interested in reading, this blog will focus on my findings of several texture resolution tests I performed today in order to determine what is the minimum settings I should be using when painting textures on mesh models that I create in ZBrush. Performing these tests is not simple since there are several factors that can impact the texture's ultimate effective resolution on the SL mesh model that is rezzed inworld by a customer. As such, I wanted to perform comparison tests for some of the critical factors.
For those that are not familiar to ZBrush some of these tests might not make sense because of the way ZBrush creates textures for ultimate export as a standard UV-Mapped texture. But you might find some of this interesting even if you are not a ZBrush user. Some of the other tests you will find interesting as its common among all of us texture creators.
ZBrush's Method of Texturing a Model
One of ZBrush's powerful features is how its textures / colors the surface of a created 3D model. The concept is amazingly simple. ZBrush uses a feature called POLYPAINTING which is a set of tools that allows the user to actually free-hand paint or even texture apply colour information directly onto each of the polygons of the model. Colouring the model can happen any time prior to the model being mapped to a UV-structured model (which is when the paint information is also converted to a UV-Mapped texture).
Similar to other 3D model software, ZBrush creates many Levels of Details (LOD) from the most basic low poly-count model to LODs with millions of polygons. LODs are important aspects of a 3D model for all modelling software but its critically important for ZBrush because of its POLYPAINT method of texturing. Since ZBrush create model textures by painting colour information on each polygon, its a natural to understand that the more polygons in the model - the higher the resolution of the texture will be. Consider the polygon density of the model to be equal to the DPI resolution of the texture. What ever is painted at the higher LOD is conveyed to the lower LODs but with only a fraction of the remaining polygons (it looks like a blurry mess).
As such, POLYPAINT can paint on any LOD of the model, but common-sense is that the user polypaints on the highest LOD needed to attain the resolution needed for the ultimate output texture. Painting on LOD1 where there is only 500-5000 polygons of resolution for the entire model would be like a fine art oil painter painting on canvas with a 4" house painting brush.
So then, for a ZBrush model creator that is texture a model destined for SecondLife models, the question is:
"What should the the minimum polygon count be for the highest LOD of a single texture model?"
Luckily, logic suggests and experts have already mentioned that since SL's maximum texture / image size that can be imported is 1024x1024, then creating a model LOD with an even distribution of just over 1,000,000 polygons would ensure that no degrade of a texture polypainted onto a model would occur when converted to a 1024x1024 UV-Mapped texture for export to SL.
The ZBrush / Mesh Texture Resolution Tests
To perform these tests, I created a very simple model shape - a long CUBE for all the tests. I created a long cube so that I could divide the cube into a low, medium, and high polygon density (about 6%, 23% and 71% of the total poly count for each cube in the test). By creating a cube with 3 polygon densities, one can see the difference on the exact same cube and also see the effects of dramatic changes of polygon layouts if not evenly distributed.
I also created tests that showed the difference - if any - on using UV-textures generated at much higher resolutions (i.e. 2048x2048). To see if there would be any improvement to the quality during the SL import of the texture.
The images you see in the tests are SL rezzed cubes about 1 x 1 x 3.1 meters - native rez size. In all tests, the Mesh detailed information was identical at the following information: LI=3, Download=3.2, Physics=0.2, Server=0.5, Display=777.
So..... on to the results and finding....
So the first image you see to the right is a photo taken of two SL MESH objects (one placed on top of the other for each comparison of resolution) whereby the top LOD in ZBrush was 3.8 million polygons for polypainting. This meant that the Low, Medium, High polygon density was 200K, 900K, and 2.7M respectively.
The top mesh used an 2048x2048 input texture. The bottom mesh used an SL standard 1024x1024 input texture.
FIRST, you can see that there was almost no difference in quality to the eye between the larger texture map to the normal one.
SECOND, although you can see a subtle improvement between Medium and High resolutions, it appears to be very minor. This as a point of reference, the 900K polygon count in the medium zone would extrapolate to a resolution that would be over the magic 1 million polygon LOD suggested. At 2.7 million polygons, the polypaint information is far higher than the minimum suggested 1 million needed for a good 1024x1024 model.
THIRD, notice that the Low zone of 200K polygon count has a clearly visible degrade of image quality compared to medium and high. Its about 1/2 the polypaint information needed to created a non-degraded 1024x1024 texture.
FOURTH, Notice the significant distortion of the image as it transitions across the zones. This is clear evidence of what happens if you create a poly mesh in ZBrush where the polygons are not evenly distributed. Since the paint information is on the actual polygons, aggressive shifts of polygon density or stretching will impact it. Its more pronounced between low and medium since the poly count is far less - but both transition zones are unacceptable.
The mage you see to the right is a another photo taken in SL of two SL MESH objects (like the 1st image) but whereby the top LOD in ZBrush was only 960,000 polygons for polypainting. This meant that the Low, Medium, High polygon density was only 48K, 220K, and 960K respectively.
Similar to the first test, The top mesh used a 2048x2048 input texture and the bottom mesh used a 1024x1024 input texture.
FIRST, You can clearly see the medium resolution zone is showing clear signs of blurriness. High is still acceptable.
THIRD, The transition zone between low and medium has obviously become even worse because of the lower density of polygons that have been shifted.
The third test to the right (click to enlarge) took the 1K textured mesh model from both the 3.8M and 960K polygon LOD models and compared them head to head. The 3.8M mesh is on top.
This test also shows what the images look like from the worst 48K polycount to the the best 2.7M polycount zone.
The main observation is that at the 680K level, the difference in resolution / clarity of the image with higher resolutions becomes very minor if not even distiguishable. This means that a 1.5 million polygon LOD would be a safe minimum for SL.
As a final test, I wanted to see with high magnification if there was any noticeable difference (degrade) between an SL texture that was imported from a 2048x2048 texture vs a 1024x1024 texture. As such, I exported both types of textures from the same SL model and clipped a small swatch from the high, medium, low zones of each. What you see in the test images below (click to enlarge) is generally the same areas of each image - native scaled and enlarge about 5 times their original clipped size.
The general observation from this test is that there is almost no difference is the images after SL imports and reduces the 2048x2048 image to its maximum 1024x1024.
The only thing I could very subtly notice is that the converted image seems to be slightly darker and had has darker shadows then the native non-converted image. Look at the high resolution zone images to the left... the bottom image tends to be a bit brighter.
CONCLUSIONS FROM THE TESTS
- When ZBrush PolyPainting for an SL destined mesh model, try to make the top LOD where polypainting will be applied to about 1.5 million polygons - just be safe.
- Make sure when building the model's structure not to have sharp / dramatic changes of the polycounts unless its in an areas that the texture cannot see the resulting distortions. The densities do not have to be evenly distributed (although preferred) but if the densities change, it should be done gradually.
- Its proven again that there is no value creating a UV Texture map greater than 1024x1024 for SL destined models. In fact, I even tried increasing the native DPI from 75 to 300 and it also had no noticed differences.
ZBrush - especially the latest versions - is an amazing tool if you have no plans for creating SL rigged models. With its DynaMesh (what they learned and integrated from the powerful and free Sculptris) and PolyPainting, and ZSpheres, its Decimation & UV Creation tools, and other powerful features, ZBrush is a fun 3D modelling tool to work with.
I hope some of you found this ZBrush Texture Resolution Test blog posting helpful. If you have any thoughts about this blog - leave a comment.