gbadev.org forum archive

This is a read-only mirror of the content originally found on forum.gbadev.org (now offline), salvaged from Wayback machine copies. A new forum can be found here.

DS development > GL_LINES ?

#90236 - ikaris - Thu Jun 29, 2006 12:52 am

I know that the DS is supposed to be able to render wireframe lines faster than other similar hardware (other platforms have to use triangles with two of the three points on top of each other, which is slow...).

You can see this in the 3d map of Metroid Hunters...

However, when I try to use GL_LINES or GL_LINE with a display list, it doesn't like it...

is this possible ?

I know that videoGL.h defines only these types...

Code:

#define GL_TRIANGLE        0
#define GL_QUAD            1
#define GL_TRIANGLES       0
#define GL_QUADS           1
#define GL_TRIANGLE_STRIP  2
#define GL_QUAD_STRIP      3

#90258 - walaber - Thu Jun 29, 2006 2:37 am

http://forum.gbadev.org/viewtopic.php?t=6201&highlight=wireframe
_________________
Go Go Gadget NDS!

#90266 - ikaris - Thu Jun 29, 2006 2:58 am

The one time I don't do a search...

I've learned my lesson !

Just so everyone knows, because its not clear... edit this line:

Code:
glPolyFmt(POLY_ALPHA(31) | POLY_CULL_NONE);


to read this:

Code:
glPolyFmt(POLY_ALPHA(0) | POLY_CULL_NONE);


It works like a charm... the object is then wireframe.

#90312 - silent_code - Thu Jun 29, 2006 4:10 pm

plus: i remember there is an ortho example that also renders wireframe, though i don't looked at the sources. ;)