skybox cracks
Blitz3D Forums/Blitz3D Programming/skybox cracks
| ||
just wonder if there was anyway to get rid of the 'cracks' in skyboxes. i had the same probs in uT2003. basically where each face meets, there appears a white line. its almost like each face has shrunk a little .perhap;s texture stretching? Anyone have a workaround |
| ||
Try turning off mipmapping when you load the texture (flag 8, I believe) to see if that helps. |
| ||
- |
| ||
ahh, sounds like a good idea, will try that |
| ||
It's quite simple to work around. 0,0 is the top left corner of the top left pixel in your skybox image. 1,1 is the bottom right corner of the bottom right corner of your skybox image. You need to scale the texture up by one pixel on the X and Y axis, and move it up and left by half a pixel. Then these two points will be in the CENTER of the texels at the corners, and you won't have bleeding from the opposite sides of the texture. Alternatively, when you load the textures, set the texture flags on the load command to enable U clamp and V clamp. Then bilinear filtering won't grab pixels from the opposite edges. |
| ||
cheers, sswift , will try that tomorrow |
| ||
hey that worked, thanks. used the texture filter using 16 and 32 flags |
| ||
Set the CameraClsMode to 0,1 or 1,0, or forget which...if the problem is cracks in geometry. |
| ||
Halo, how is it that you can write the "Best physics engine EVER!" and yet you have difficulty grasping the whole "texture's bleed at the edge of my skybox" issue, and until a week ago you apparently had no clue that UV clamping existed? :-) |
| ||
He said "skybox cracks", which sounds like those little flecks of background you see through skyboxes sometimes. |
| ||
its when there are cracks in the 'real' sky I will start to worry |
| ||
:) BTW. If you load the Skybox with automatic Textures Loading (like DarkMatter Skyboxes) then you might use this: cleartexturefilters texturefilter "",48 or whatever thingy=loadmesh("skybox.3ds") cleartexturefilters texturefilter "",9 ; reset to defaults |
| ||
What is the clear texture filters for?. have been ignoring it so far. just been doing textureflter "blah.bmp", 16, 32 textureflter "blah1.bmp", 16, 32 textureflter "blah2.bmp", 16, 32. seems to cause massive frame rate slow down when I use clear texture filters . BTW ,My skyboxes are just 3dsmax cubes with terragen textures mapped to em |
| ||
normally the mipmap and color filters are automatically applied no matter what you type for the filter parameter. Cleartexturefilters disables that automatic setting. You can change the automatic settings to something else too, but I think that's pretty worthless. Anyhow, the slowdown is because you no longer have any mipmaps on. full size textures are used all the way into the distance. And 3d cards don't like that. The end. |
| ||
gotcha, thanks sswift |