# Tag Info

Accepted

### Why are quads used in filmmaking and triangle in gaming?

For 3D modeling, the usual reason to prefer quads is that subdivision surface algorithms work better with themâ€”if your mesh is getting subdivided, triangles can cause problems in the curvature of the ...
• 2,222
Accepted

### Programmatically generating vertex normals

Computing the normal from vertex positions is quite simple using the vector cross product. The cross product of two vectors $u$ and $v$ (noted $u \times v$, or sometimes $u \wedge v$) is a vector ...
• 4,420

### Why are quads used in filmmaking and triangle in gaming?

As @Noah Witherspoon correctly, says triangle subdivision does not work as well as quad subdivision. Although, in the beginning triangles could not be subdivided at all. However, he does not really ...
• 8,437
Accepted

### Combination of Triangles and Quads in a mesh

Topologically correct is a very vague. I believe you think of Polygon-Meshes when you say meshes, which is to represent the surface of the object by a patch of polygons, in most cases triangles or ...
• 1,810
Accepted

### Gaussian blurring a function defined over a surface mesh

A few different approaches I'll consider a few variations on your specific request, since you mention efficiency and I suspect your specific request may be the least efficient. I'll also suggest ways ...

### Creating shared vertex normals on GPU

For an nVidia only solution you can use floating point atomic add intrinsics (like NvInterlockedAddFp32) Unlocking GPU Intrinsics in HLSL | NVIDIA Developer I tried this on 80.000 vertex mesh and it'...
Accepted

### Optimal memory access when using lookup tables on GPU?

The best place to put a look up table for a GPU compute shader depends on the size of the lookup table, and the frequency/coherency of access. In your case (you mentioned 4kb), shared local memory ...

### Generate mesh from pointcloud data

one popular Real time surface reconstruction method is TSDF (Truncated Signed Distance Function) used by Microsoft for the Kinect. It is based on the VRIP method but it is faster. It is based on depth ...
Accepted

### How to calculate volume of any given 3D mesh

The triangle form of the Shoelace Formula can be extended to 3D by using tetrahedrons instead of triangles. Pick a point, Any point can be used, even one of the original vertices of the mesh (...
• 456
Accepted

### chess-like rectangles on the mesh

I don't think it's trying to represent anything in particular. In CG there is a concept of textures, which is a bit like painting the surface of an object a specific color/look. For example, on a car ...
• 529
Accepted

### What's the simplest, open, animation format?

For what it's worth, the glTF Tutorials contain a section on Skinning that shows how the raw vertex and joint weight data feed into a vertex shader to distort the mesh. If you do design your own ...
• 369
Accepted

### Are vertices of each LOD version always loaded into VRAM

Many game engines have texture streaming, which means that not all mip levels of each texture are loaded at all times. The game engine will track which textures are in view and how close up they are ...
• 25.1k

### exact down sampling and re-triangulation of mesh data(non-convex)

1. Method: Vertex Clustering This is more or less a low-quality method, but depending on your mesh it could work well. The basic idea is to partition the space into a regular grid, and then choose ...
• 1,810
Accepted

### How can I perform a triangle inside test in polygon meshes?

There is an alternative method that relies on flood filling. First arrange your edge data into a loop where the edges are forming a counterclockwise loop. Then start at an arbitrary point on the loop ...
• 8,437
Accepted

### Extract visible vertices from a 3D geometry model

Idea A: Draw an invisible mesh that will occlude the points we don't want. Create a mesh from the point cloud. Render that mesh to a depth buffer but not to the color buffer. Render the point cloud ...
• 4,420

### Best way to remesh a quad 3D mesh?

I'd recommend using OpenVDB. It's quite battle-tested. Use meshToVolume to voxelize the mesh. Then use volumeToMesh to produce ...
• 151
Accepted

### Triangulation of vertices of an ellipsoid

If you sample the two parameters $\eta$ and $\omega$ with steps $d\eta$ and $d\omega$, then you'll get a grid of points $v_{ij} = f(i\;d\eta,j\;d\omega)$. Any four adjacent points will define a ...
• 901

### Should you measure mesh complexity in triangles or vertices?

Since you're talking about "vertex shaders" and "fragments", I assume that your question is to be interpreted in the context of real-time rendering using the graphics pipeline on a modern GPU through ...
Accepted

### Creating a Smooth 3D Mesh from a 2D Outline

One algorithm that's pretty good for this, but very difficult to implement is to find the Medial Axis of the shape and then have various profiles that are based on the signed distance from the medial ...
• 3,421
Accepted

### How to Sample 3D Points Outside and Inside the Mesh Surface

What you want is something that can perform the inside-outside test for meshes. The simplest solution would be to use Trimesh's implementation which can be ran with Embree to accelerate ray queries. I ...
• 344

### How to Sample 3D Points Outside and Inside the Mesh Surface

I have a few suggestions: Partition the volume by using tetrahedra within the mesh, and outside of it (in the cube). Set the probability to sample each tetrahedron to its volume divided by the inside/...
• 2,226
Accepted

### Why is the valence of regular vertices 6?

If require that all faces have the same number of sides $s$ and require that all vertices also have a certain valency $t$. We see that the following relation between edges, and faces hold for a ...
• 1,283
Accepted

### Computing vertex normals in mesh triangle soup

A very simple, but computationally expensive, way to do this is to pick a triangle, preferably one that you know has the winding you want. Then search every triangle in the soup for triangles that ...
• 3,239
Accepted

### What is the difference between a "meshlet" and just a small mesh?

A "meshlet" is a concept built around the specific architecture of how shaders work. Shaders are invoked in work groups, even when shader stages don't explicitly represent that concept in ...
• 9,842
Accepted

### What is better to use for real-time computing Mesh - Plane intersection points, GPU or CPU?

doing the calculation to decide whether a point is on one side of a plane or the other is very simple (a single dot product). Doing that 3 times and having a special case when they don't match to ...
• 5,950
Accepted

### Most efficient way to render many OO meshes in OpenGL

Don't copy around huge chunks of data if you don't have to. I would delay collecting and building the final forest mesh for as long as possible. However when you have multiple of the same mesh that ...
• 5,950

### How can I perform a triangle inside test in polygon meshes?

I've already commented on the use of flood fill and how it would be better as it's more flexible but another possible solution is scanline. (I say possible because it makes a lot of assumptions about ...

### Extract visible vertices from a 3D geometry model

Conceptually simplest would be to treat it as a ray-casting problem, representing each point as a small sphere. It should work like the shadow rays in a conventional raytracer: iterate over all of ...
• 6,840
Accepted

### Weird rendering in rectangle mesh shader AKA Why has my basic shader become a modern art generator?

I think you are not constructing the index buffer correctly. Firstly you only need 1 degenerate vertex to terminate each triangle-strip row. You also should not need any special handling for odd/...
• 2,322