Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [vertex]

In geometry a vertex is a point defining the corners of polygons or intersections of lines. A triangle for example is defined by 3 vertices with lines between them. In 3D-graphical APIs like OpenGL and Direct3D a vertex is a data structure containing information about the positions, normals, colors, tangents etc of the points defining the triangular faces of 3D-meshes.

0
votes
1answer
27 views

XNA 4.0 How to combine triangles vertices 3D

Preview for the problem: I'm making a similar game to Minecraft (a game that it's world is made by cubes), but the fps of the game is getting low only by rendering a little amount of cubes in the ...
0
votes
0answers
20 views

Generating skeleton bind pose from vertex weights

Assuming that you know how many bones should be in the skeleton, and you have the bone hierarchy, is it possible to calculate the bind pose of the bones just based on the vertex weights? To elaborate ...
-1
votes
0answers
21 views

How can I add vertex normal support to MD5 model animation?

I am trying to add skeletal animation to my project. I followed one tutorial, but it did not include vertex normals. Therefore I can't perform lighting, bump mapping, etc. How can I add support for ...
2
votes
1answer
63 views

How to inflate geometry?

I have a shape containing vertices and triangles I want to inflate that geometry using some radius to get something like that I should move each point along ...
0
votes
1answer
77 views

How can I reorder the order in which the vertices are in an .obj file?

Blender saves the files with the structure of All the vertices All the normals All the UV The game to which I want to import the model, only accepts the following order in structure 1 vertex 1 ...
3
votes
4answers
367 views

Algorithms for calculating vertex normals in 2D polygon

I have the points of a 2D polygon in the order in which they are connected, and I need to calculate the vertex normals and move them along it. An example is shown. I would like to know how to ...
0
votes
2answers
222 views

How can I convert my list of vertices and indices to a list of triangles?

I have a full 3D collision mesh that is represented by a list of vertices and another list of indices. I need to convert the list of vertices and the list of indices into a set of triangles. First I ...
0
votes
1answer
139 views

Removing duplicate vertices on a mesh

I have a set of vertices and another set of indices. Sometimes I find that I have duplicate vertices in my mesh. I tried at first to check if two identical vertices were in the array of vertices but ...
0
votes
1answer
132 views

Issues to display a texture loaded with libPNG with opengles 3.0

I'm trying to load a texture loaded with libPNG on a XY coordinates. I know the width and the height of the texture (32x32). The texture is already loaded successfully and I have his Id. Here is my ...
0
votes
1answer
89 views

How to get a reflex edge on a non-convex mesh

I am trying to implement a convex decomposition and I need to find the convex vertex on a mesh. Is there a algorithm that I can use to find the convex vertex on a mesh.
1
vote
0answers
319 views

Shadow & sorting issues with vertex colored PBR Shader Graph

I'm working on a custom shader using Unity 2018's new shader graph feature. Previously, I was using this shader, which worked great for awhile, but it ended up constantly breaking for seemingly no ...
2
votes
1answer
1k views
1
vote
1answer
190 views

Use heightmaps or direct vertex manipulation for runtime terrain editing in UE4?

I am creating a terrain editor and creator for in our game, in which we should be able to create hills and dales, create different shapes(forms) in the terrain etc. I came up with 2 approaches on ...
0
votes
1answer
235 views

How can I sort vertices efficiently in a specific direction (CW/CCW)?

I am trying to triangulate a set of points using a very simple approach where a base vertex is chosen, and then every other vertex is joined to its neighbouring vertex and then back to the base vertex,...
0
votes
1answer
111 views

How to create class for storing different types of vertex?

I am writing graphics engine for educational pursoses and have some problems. I need to have ability to use different vertex formats (for example position+normal+uv or position+normal+uv+bones+...
0
votes
1answer
63 views

Change center point and size with the help of the Matrix in Unity

Let us suppose I have an array of Vector3, it contains vertices. Now I want to scale the vertices and/or change the center point of the texture (move texture ...
7
votes
3answers
969 views

Why is the depth test not done on geometry before rasterization?

It seems the only time depth is used to discard data is during rasterization, i.e. at the fragment level. In the geometry stage, I've only see culling and clipping of vertices. Is it not possible to ...
12
votes
2answers
2k views

3D models budget. What matters more number of triangles or vertices

When I am making a model for a 3D game what should I take as a measure in my budget Polygons (triangles) or vertices? I have made an experiment with two sets 40000 cubes one with 8 vertices and 12 ...
0
votes
0answers
255 views

Unity - add vertex color to part of a mesh?

I have a scenario where I need to automatically assign vertex color to a mesh in order to manipulate (deform) a part of it. As an example gradient I'd like to apply I will be dynamically loading new ...
0
votes
1answer
74 views

Matrix transformations vs manipulating vertex data directly

I was wondering whats more efficient to do if you want to transform a mesh. 1) Transforming a matrix and pass that to a shader or 2) Manipulate the meshs vertex data directly I was wondering because ...
0
votes
2answers
138 views

OpenGL NDC initial values

I have a set of vertex locations to create a plane: ...
2
votes
2answers
76 views

Easy way to edit vertex attributes

I'm trying to edit large amounts of vertex attributes in my models for my game. The main attributes I really care about are strength (so wind can interact with them) and a couple of other things so ...
9
votes
1answer
2k views

How can I get the normal vector for a plane from a set of vertices?

I'm working on a HLSL / C++ little project to going over my graphics work, and I am unsure how I am to get a facing vector from a vertex polygon. I can't seem to find the formula. The positions are ...
3
votes
2answers
3k views

Generating a UV map for a procedural mesh

I have created a procedural low poly rock mesh and now I would like to apply textures on it. I have the 3D-coordinates of every vertex of the mesh but that's about it. How would I automatically ...
31
votes
4answers
8k views

What is a vertex color?

My question is what is written in title. This term "vertex color" appear a lot. I am having hard time to understand this. For example: Isn't a vertex simple point on 3D space? If so, how can a point ...
2
votes
2answers
450 views

OpenGL Water Waves - gradually advance

I want to make a simulation of water drops producing waves, in OpenGL with C++. I calculated the height for each point of my plane grid in the 'Vertex Shader' with this formula: The problem is that ...
1
vote
1answer
107 views

What to do with unused vertices?

Imagine yourself a vertex array in OpenGL representing blocks in a platform game. But some vertices may be not used. The environment is dynamic, so there always some vertex may suddenly become ...
1
vote
2answers
422 views

OpenGL Water Waves Problem

I want to do a simple simulation of water drops producing waves in OpenGL with C/C++. I calculate height for each point of my plane grid in Vertex Shader with formula but it seems wrong at the ...
1
vote
0answers
179 views

3D software-based engine projection issues

I have been writing a 3D soft-engine for a little while and I have gotten it a reasonable position but recently noticed a bug that I can't seem to solve. When I am rendering a few cubes as a test, if ...
1
vote
2answers
768 views

Unity procedural smooth normals

I have a Unity project, which heavily relies on the marching cubes algorithm. Because this algorithm doesn't return the triangles in order, I can only index them in the order they are present in the ...
0
votes
1answer
450 views

Planar mapping/projecting UV coordinates from normal

I've got set of vertices, and would like to calculate their UV coordinates by projecting them by a given normal. Similar to what "planar mapping" does in 3ds max. Another way of looking at it is ...
1
vote
1answer
123 views

Why is my texture skewed?

I'm creating hexagonal prisms from code and am having a difficult time understanding how UV mapping works, as the texture I apply to the hexagonal face comes out skewed: Forgetting the sides for now, ...
1
vote
0answers
151 views

Get mesh height at position

Me and my friends are creating a simple 3D game in LibGDX and are currently trying to implement simple collision detection with the terrain (ground). For this I thought the best way would be to simply ...
0
votes
1answer
292 views

In trying to get vertex positions on a Blender-generated mesh in Unity, they seem to be badly off?

I've imported a number of track-terrain pieces into a game I'm working on, and I would like to get the mesh vertex arrays so I can position objects at their exact end. However, when I try to collect ...
1
vote
1answer
833 views

Vertex Displacement Distortion Correction

I am developing for Mobile VR using GoogleVRSDK and Unity. My target platform is Android. I have a shader which displaces vertices to create a reverse lens distortion. Following is my shader, <...
1
vote
1answer
472 views

How to pass array of dozens of floats to OpenGL 3.0 vertex shader?

I use PyOpengl and Python 3. I have 50 thousand vertices. Position of each vertex could be calculated in vertex shader as ...
1
vote
1answer
464 views

How are the positions of skinned mesh vertices with multiple weighted parents stored?

I'm trying to wrap my head around the basics of skinning and skeletal animation. I understand not every skeletal animation implementation works exactly the same, but I'm just trying to understand the ...
1
vote
1answer
362 views

Loading non-skeletal animation to opengl via assimp

I'm a newbie in assimp and openGL. I'm trying to import .fbx or .dae formatted file to openGL via assimp. Importing skeletal animation was kind of easy. Lots of introductions and sample projects ...
2
votes
3answers
258 views

Process of writing to the depth texture

In openGL, let's say I output one single point from the vertex shader with this value gl_Position = vec4(2.0,3.0,5.0,7.0); what exact math operations happen to "...
2
votes
1answer
219 views

Point welding on generated terrain

I am converting two 2D images (A Voronoi graph and a Diamond Square noise map) into a 3D object. However when finding the corner points of the Voronoi I am left with gaps, so I thought to drop these ...
2
votes
1answer
143 views

How do I make my indices anti-clockwise, so I can cull triangles in OpenGL? (immediate mode)

At the moment, I'm attempting a basic game engine in OpenGL using immediate mode. I'm trying to render a cube. Cube is a class with the vertices, normals, and indices. Here is part of the Cube class: ...
0
votes
0answers
117 views

How to prevent object from moving when it's mesh/collider is being updated?

So I a made a script that lets the player grab a vertex, move it, and then update the mesh. To help prevent the player from trying to clip it through other objects I made it so the mesh/collider is ...
1
vote
1answer
82 views

DirectX 11 Vertex Shader Fragmentation

I was wondering how my vertex shader is causing my cube to be render weirdly? I am using the Visual Studio graphics tool and see that my input assembler is correctly receiving the cube and I can only ...
1
vote
1answer
53 views

Mesh/Path reduction to simulate traveled path to target

I generate that kind of mesh during runtime to display the path to follow to a target (think at something like the path your GPS shows you when you are travelling): I need to reduce the displayed ...
1
vote
0answers
270 views

indices for surface of revolution

I'd like to implement a surface of revolution. I already implemented creating Vertices based on a 2D line. I now want to get the indices to render the mesh with ...
3
votes
1answer
83 views

Vertex position problem for connected lines

I’m trying to generate a mesh to display connected segments representing street lines in a mini map. I have problem with vertex orientation that my math knowledge has hard time to resolve. Let’s ...
0
votes
1answer
583 views

Avoiding GC when rebuilding Mesh.uv and Mesh.vertices

Since unity will not allow users to iterate over mesh.uv and mesh.vertices, I am stuck having to use GC intensive calls when applying an array of uvs and vertices to a mesh. I run into high GC ...
2
votes
1answer
551 views

Why doesn't Array.Copy to mesh.verticies work in Unity?

I am rebuilding a mesh but something seems odd that I have to create a temp array just to hold the verticies rather than copy an array. I'm not using list because this is used frequently and I do not ...
2
votes
0answers
56 views

Weird warping with per-vertex normals

I've had this little problem for a while now, where for some reason my calculations for per-vertex normals results in a weird distortion or warping, skewing my lighting, shading, and reflection passes....
3
votes
2answers
994 views

Most efficient way to get the world position of the 8 vertexes of a Box Collider (C#)

What I am looking for is the most efficient way to get the world position of the 8 vertexes of the Box Collider of a freely rotated Gameobject. I cannot use collider.bounds since object is rotated, ...