View Full Version : more control over vertices, edges and faces
05-18-2002, 08:52 AM
Is there anyway other than geBegin() and geEnd() block to draw vertices, edges and faces?
I want to make a simple 3d editor, and I need more control over which vertice connects with each vertice, and which edges form a certain face.
05-20-2002, 05:47 PM
glBegin/glEnd give you the most flexibility you can ever get. All other kinds of representing geometry can be emulated with them.
05-22-2002, 04:44 PM
Got the point.
But how this make a vertix connect to more than 2 vertices, since it's a list of vertices? Or should put the previous vertice again and again?
05-23-2002, 12:25 AM
You have to construct your own data-structure in wich you can store your vertex-information. f.e. a class wich holds a list of structs of 3 floats could be your datastructure for a polygon.
Point is, glBegin & glEnd are designed for drawing drawing drawing only and nothing else. If you want specific functionality to store and edit vertices you have to program it yourself http://www.opengl.org/discussion_boards/ubb/smile.gif isn't that flexible?
and yes, if you want to connect several vertices, they should be 1 vertex in your datastructure, and you should draw them several times inb. glBegin()/glEnd().
[This message has been edited by JeeTriX (edited 05-23-2002).]
Powered by vBulletin® Version 4.2.0 Copyright © 2013 vBulletin Solutions, Inc. All rights reserved.