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 > ndslib GL functions reference?

#151357 - nanou - Sun Feb 24, 2008 10:38 am

Hey guys, I'm starting on a converter/loader for 3d models and I'm wondering if there's a good reference on libnds's gl functions. I've checked the libnds examples, and while they're really good for specific applications I don't feel like I'm any nearer than the tedium of checking the headers against gbatek.

I hope to really simplify the process of getting models loaded and rendered by creating a format (with converter) and support library with some robust features. I don't really understand the target (libnds functions) all that well so it's really slowing me down. I've got some functionality now but it's not much to speak of. Hopefully someone still doing things the hard way will be eager to help me out. :P
_________________
- nanou

#151432 - nanou - Tue Feb 26, 2008 8:27 am

I'm making some progress. I'm converting in perl and exporting to C for testing. I'll rewrite the exporter in C and just use a loader soon before the loader is done I'd like to know what features should be available.

I don't really need the reference as badly as I thought, I just need to know what should be implemented. If you've any input on what you'd like to see here, now is the time to say something. (Actually -- is anyone going to even use this?)

No release yet, so far I basically just have the following features:
    Precomputed normals during export. (Inaccurate, but sufficient for the prototype.)
    Materials export: Ambient, Diffuse, Specular, Emission
    Vertex colour
    Triangles and Quads

Since it's an export to gl* calls, everything above is supported on the NDS end. I'd like to note that these are also efficiently rendered. Materials are set only when needed, etc.

Planned features:
    Correctly calculated normals (very soon)
    Toon shading (very soon)
    Shininess, Fog, etc. (whenever)
    Triangle, Quad strips (later. does AA work better with these when culling is off?)
    Binary format with NDS loader + support lib (pending feedback?)
    Keyframe animation in the library (tweening or whatever you call that in 3d) (in support lib)
    Textures & decals (important, but not current priority)
    Cook to display list in library (much later)
    Cook to display list in exporter (much later, and only maybe)
    Normals recalculation in library (big maybe)

Am I missing anything? I have the suspicion that I am forgetting something obvious.
_________________
- nanou