7

Nice idea by the author. From experience... High vertex counts aren't that much of a problem (100Ks, millions even). Dealing with complex UV mapping is far more so. Sometimes it is worth staying closer to the actual description of the surface (i.e. the backing 3D array), than optimising yourself into a place where it's not as easy to change the mesh when you ...


6

Quoting the meshing page you link: It isn’t too difficult to modify the code deal with either multiple block types or different normal directions. What you would do is modify the array called “mask” in the code to store an integer value which encodes the type of each block. You’d need at least 1 bit for orientation, and then you could use the rest to store ...


3

I’m not an expert. I only just recently got into modding using Blender. I had a similar issue with a custom model I imported into MonoGame using FXB format. What fixed it for me was downgrading to Blender 2.79b. In 2.8, Blender stopped supporting the FXB 7.4 binary export format, which also had something to do with how the program handles bounding boxes. I’d ...


2

There's an additional detail I want to clarify here: As far as I understand (at least I would do this), we store the original mesh, and then for every change (shift, rotation or scaling) we turn the change into a matrix, and apply it to all vertices of the copy of the original mesh, with which we will work later. This seems to imply that when I translate a ...


2

You correctly describe how transformations work, you're just making a wrong assumption that the process seems slow. Graphics processing units are tailor-made to do this specific thing, i.e. linear algebra calculations. My thinking is that you have a wrong view of what a GPU is and compare it to a CPU. If a CPU has 4-8 cores, a GPU has 1000s of them and each ...


1

Solution was to use Parabox CSG for boolean operations. But there was a problem. If I just take a box flip normals and try combining it with a room I'll get a recessions in walls, but not holes. And then I tried to remove one face of that flipped cube and positioned it inside that flipped dome mesh, so that they do not intersect. And in result I had exactly ...


1

Given that we do not know from what tool did the fbx come from I will just share our experience. Importing rigs from fbx in blender that were made in other tools does not work. Altough blender might have the same functionality as lets say Maya, its internals are different and there seems to be no corelation between features. I would reccomend you give up on ...


1

First up, our triangle count is... int numTriangles = numLatitudeLines * numLongitudeLines * 2; (That's a middle section of (numLatitudeLines - 1) * numLongitudeLines quads, doubled to two triangles each, and a row of numLongitudeLines triangles around each pole) Triple that to get our ultimate count of vertex copies: Vertex[] vertices = new Vertex[...


1

Solved the problem myself. The remaining triangles were being generated on the other side of the mesh. This was I didn't know that the order of the vertices had to be in clockwise order.


1

The issue turned out to be in my code for importing UVs. I was skipping indices in the UV buffer due to an arithmetic error.


1

This issue looks to me like the array that you are feeding for the buffer binding process might be the issuse. glBufferData(GL_ARRAY_BUFFER, cube.vertBufferSize, cube.vertBuffer, GL_STATIC_DRAW); --------------This*----------------------^^ this* parameter requires a stride , glBufferData(GL_ARRAY_BUFFER, vertexArray.size() * sizeof(float), vertexArray....


1

You usually do not want your polygons to draw from both sides in a game. If you're standing outside a building, you want to see the outside faces that point toward you. You don't want to waste time and GPU resources drawing the back side of the building. Similarly when you're standing inside a building, you want to see the faces of the interior walls. You ...


1

Thanks to @DMGregory! I had indeed forgotten to generate the uvs for the meshes. I fixed that and now the shaded material is displayed correctly! Here is the new ConstructMesh Method: public void ConstructMesh(){ Vector3[] vertices = new Vector3[resolution * resolution]; int[] triangles = new int[(resolution - 1) * (resolution - 1) * 6]; ...


1

There are a couple things missing from your mesh generation code: You forgot to set any uv (texture) coordinates for all corners of your triangless. You might wonder why you need those when your material doesn't even have a texture. The reason is that the Global Illumination engine requires UV coordinates for calculating its lightmaps, even for shaders ...


1

Adding a new answer because I cannot reply with a comment. PatrickSharbaughs code works for me in Unity 2019 using the Cloth component with some small changes. Basically, the state of the cloth simulation can be accessed using the BakeMesh method on the SkinnedMeshRenderer (which is a required component for the Cloth simulation). using UnityEngine; using ...


Only top voted, non community-wiki answers of a minimum length are eligible