In the 3D-editor the sculptie looks correct. but after i imported to SL all gets messed up.
The only reasons that i can imagine why this happens to you are:
- you have not uploaded with “lossless compression” checked
- your sculptmap has less than 4096 pixels
- your sculptmap has more than 8192 pixels
you have not uploaded with “lossless compression” checked
If you do not check “lossless compression” then the importer attempts to compress your image by optimizing for the best visual results. This means it will use a compression algorythm that actually changes the image pixels later when the image is inflated again. For sculpties this is very bad. The reason is that the actual vertex position information is stored in the color code of the image. When you do any image processing on a sculptmap your vertex locations will shift around in a uncontrollable way. And thus you most probably will get very borked results when you forget to check “lossless compression”.
On the other hand when you check “lossless compression”, then the used compresison algorythm ensures that your image will be precisely the same after inflation than the original that you uploaded. And this is actually what you need to get your sculpties up to SL.
your sculptmap has less than 4096 pixels
it is not important whether you use an oblong or a default squared sculptmap. Only the total number of pixels in the map counts. a 8*512 map works as well as a 64*64 map. This is true for all third party viewers which rely on the 1.3 source code. If you use viewer-2 or third parties based on viewer-2, then actually you can upload smaller sculptmaps with less faces, see below.
your sculptmap has more than 8192 pixels
This is a bit weird, but once you understand where it comes from it turns out “logical”. The problem is when you want a very special oblong that has a ratio of 2:1. You must know that the image width and height HAVE to be power of 2 values. When you create a sculptmap for the ratio 2:1 then the smallest possible map that supports 1024 faces is of size 64*32.
Now this is actually equivalent to 2048 faces. But SL scales down the map such that you end up with 46*22 faces = 1012 faces for this situation. And this is the optimal solution regarding the hard constraint of “sculpties can have 1024 faces at maximum” AND getting a ratio of 2:1 (46/22 is close to that ratio).
The next smaller map size with the same ratio and based on power of 2 image dimensions would be 32*16 and that map will only contain 512 faces and that is not what you want. So at the end LL decided to support the 64*32 faces sculptmap with a certain loss of precision due to the downscaling. The last bit of what you need is that a sculptmap must be double the size of the number of faces in each dimension. Hence a sculptmap with 64*32 faces must use an image of size 128*64 = 8192 pixels. And there you are. That is why the maximum pixelcount for sculpties is 8192.
For Viewer-2 or third party viewers based on viewer-2 the smallest reliable sculptmap size seems to be 1024 pixels although this varies over time. The actual supported smallest size is not known. You have to experiment. Please note that it may be possible that your third party viewer displays the sculptie as a messed up bulk of spikes and wrongly placed faces, while viewer-2 has no problems with showing it. That seems to be an issue with one of the open source image libraries. Please look at the Phoenix wiki and at kirsten’s viewer.
Once a sculptmap has been uploaded with success (from any viewer), it looks like it remains stable over time.
Posted in: Sculpted Prims