Questions tagged [vertex]

A vertex is a single point in a 3D object, used for simple model creation or advanced animation systems.

756 questions
7
votes
4 answers

OpenGL: Add vertices with vertex shader

Tell me, please, how I can add new vertex in vertex shader?
itun
  • 3,439
  • 12
  • 51
  • 75
7
votes
1 answer

SceneKit per vertex color

I've been playing with SceneKit, but I can't figure how to create a per vertex color geometry. So to be more precise, I would like to do this : http://openglbook.com/chapter-2-vertices-and-shapes.html Let me know if it's not clear Thanks.
MonkeyDMat
  • 111
  • 2
  • 9
7
votes
4 answers

How to edit mesh/vertices in Unity

I would like to edit 1 vertex on a cube, but I don't know how to. I've tried looking everywhere for this function, but I can't find a solution. Here is an image of what I want to achieve:
7
votes
2 answers

Does the winding direction in an OpenGL triangle strip alternate from triangle to triangle?

I'm trying to clear up some inconsistencies I'm seeing in triangle strip vertex winding direction (clockwise and counter-clockwise). I'm drawing a trapezoid rotated 90 degrees counter-clockwise in OpenGL. Here's the relevant code: unsigned char…
charon00
  • 109
  • 1
  • 5
7
votes
1 answer

OpenGLES 2.0: gl_VertexID equivalent?

I'm trying to create a grid of points by calculating vertex positions dynamically, based on their index in the array of vertices sent to the shader. Is there an equivalent of the gl_VertexID variable that I can call from within my shader? Or another…
Josh
  • 331
  • 2
  • 10
6
votes
1 answer

Identify visible vertices in OpenGL

What is the most efficient way to identify the vertices that are visible from a particular viewpoint? I have a scene composed of several 3D models. I want to attach an identifier to each vertex (ModelID, VertexID) then generate 2D images from…
tat0
  • 133
  • 1
  • 5
6
votes
1 answer

OpenMesh Random Access

I thought OpenMesh would support random access to faces edges vertices. All I can find are iterators and circulators: for( auto v : mesh->vertices() ) mesh->point(v).data(); How can I do something like this: mesh->vertices(42);
6
votes
1 answer

Cocoa and OpenGL, How do I set a GLSL vertex attribute using an array?

I'm fairly new to OpenGL, and I seem to be experiencing some difficulties. I've written a simple shader in GLSL, that is supposed to transform vertices by given joint matrices, allowing simple skeletal animation. Each vertex has a maximum of two…
5
votes
1 answer

How to properly update vertex buffers in DirectX 10

For a little background: I am working on a project in C++ in which I am trying to draw 3D representations of objects based on real time profile data. The profiling data is gathered from external profiling hardware. The system travels along an…
Tim Coolman
  • 595
  • 1
  • 9
  • 19
5
votes
2 answers

How to add faces to THREE.BufferGeometry?

I have created programmatically a simple mesh: var CreateSimpleMesh = new function () { var xy = [], maxX = 7, maxY = 10, river = [[0, 5], [0, 4], [1, 3], [2, 2], [3, 2], [4, 1], [5, 1], [6, 0]], grassGeometry =…
5
votes
1 answer

How does Blender calculate vertex normals?

I'm attempting to calculate vertex normals for various game assets. The normals I calculate are used for "inflating" the model (to draw behind the real model producing a thick outline). I currently compute the normal for each face and average all…
dabigjhall
  • 53
  • 1
  • 3
5
votes
2 answers

OpenGL - Are animations done by shaders?

I started to study OpenGL and I learned how to show figures and stuff using Vertex and Fragment shader. I created a (very) stylized man, and now I want it to move his arm and legs. The question is: should I change vertex data in the VBO, directly in…
Giorgio Arena
  • 81
  • 2
  • 3
5
votes
1 answer

Verification algorithm for minimum vertex cover?

We know that the minimum vertex cover is NP complete, which means that it is in the set of problems that can be verified in polynomial time. As I understand it, the verification process would require the following: Verify that the solution is a…
Govind Parmar
  • 20,656
  • 7
  • 53
  • 85
5
votes
1 answer

Drawing a rectangle in Direct X

Using the tutorial here, I have managed to get a red triangle up on my screen: http://www.directxtutorial.com/Lesson.aspx?lessonid=9-4-4 CUSTOMVERTEX OurVertices[] = { { 0, 0, 0, 1.0f, D3DCOLOR_XRGB( 127, 0, 0 ) }, { WIDTH, 0, 0, 1.0f,…
Jimmyt1988
  • 20,466
  • 41
  • 133
  • 233
4
votes
2 answers

C++ - Function calling when changing member value

My goal is to fire a event receiver when a value is changed in a class. My solution to this is using get and set functions. However, I do not want any performance problems when reading the values. In the class below: class Vertex { public: const…
RPFeltz
  • 1,049
  • 2
  • 12
  • 21
1 2
3
50 51