Cutting meshes
Community Forums/Developer Stations/Cutting meshes
| ||
I need to split my terrain into sections and export them as individual files. Does anyone know of a program that will allow me to do that, and be easy enough? xxx xxx x = each section, and everything matches once put together. |
| ||
xml, is your terrain a mesh or a series of height maps? IPete2. |
| ||
terrain mesh |
| ||
I can only give you advice how to write your little utility. Use the ClusterizeMesh source from the archives, make sure it will restore vertexalpha as well (I think it already does, not sure). This will result in a 3d grid of meshes, eg: arr(3,3,3). You may save them this way: for i=0 to 3 for j=0 to 3 for k=0 to 3 save mesh mymesh(i,j,k), "terr_"+i+""+j+""+k+".b3d" next next next to save a mesh use the SaveB3D code from the archives. You may have to tweak it a little to make it work with VertexAlpha, as well as with multiple texture layers, if required by your terrain meshes. Probably you best refer to the early FLE source on how it used to save the meshes: http://www.blitzbasic.com/toolbox/toolbox.php?tool=167 The good part is, once saved this way, you may load and position them all on 0,0,0 and they should be aligned correctly. Oh, and you may have to be able to save the normals as well to make sure seams are lit correctly. |
| ||
The good part is, once saved this way, you may load and position them all on 0,0,0 and they should be aligned correctly. Considering the way Blitz3D works with frustrum culling, I would consider that a bad thing. |
| ||
Yeah, good point, but you may easily fix this by using MeshCullBox. Just get the minmax vertex world coords. Thought it's a good thing because you don't have to mess with the patches positions. EDIT : although, from what I know of the CLusterizeMesh function, runtime created meshes frustrum culling doesn't seem to behave that way, they cull nicely. I think it's more a problem of animated meshes. |