View Full Version : Superposition of a triangles and its edges...
02-08-2003, 06:34 AM
I would like to know what functions i should use for creating a full colored triangle and its edges in a different color without any problem of superposition.
02-09-2003, 07:39 AM
If I understand you correctly, some pixels of your lines don't show. That's because of z fighting, and can be fixed with glPolygonOffset.
02-09-2003, 10:54 PM
Did this method affect the real coordinates of the triangles or picking method?
I will try it and will imform you.
02-09-2003, 11:01 PM
No, it only affects the fragment depths. It'll be safe with picking.
02-11-2003, 05:22 AM
Certainly i don't know how to use this command but it doesn't seem to work...I think if I want you could help me, i must be more explicit...
I'm working on a optimisation meshing programm, and i want to use it esaly on windows. Is this program i use in same time triangles, its egdes(lines) and the points of the lines. My aim is actually to select this item on the screen. But in the GL scene i draw triangles, lines and points whith the same coordinates. It's look like superposition pixels. Sometime i saw traingles, or edges... I don't konw what i must do to correct this problems.
Maybe you could help me....i hope.
02-11-2003, 10:03 AM
No wonder you can't use it, the polygon offset specs are quite technical and not very helpful to learning how to actually use it. Maybe the way they should be but...
The polygon offset is used to offset the depths of rasterized polygons. It's designed for situations like yours where nearly equal depth values cause problems. As far as I know, it can only be used for filled polygons, so you offset them a little bit further so that the lines can be drawn solid. In practice:
That should do it. If the lines still have holes in them, increase the polygonOffset values.
02-15-2003, 04:00 AM
The result was perfect...
Powered by vBulletin® Version 4.2.3 Copyright © 2016 vBulletin Solutions, Inc. All rights reserved.