Thanks for the kind words. Dang, now I have to take this further!
I fixed the FPS display. I was showing the frame duration I suppose. Thanks for the suggested fixes, but I found a very simple algorithm at StackExchange, and converted it to GLBasic (it seems to work):
FUNCTION DisplayFPS: x%, y%
STATIC averageFrameDuration# = 0
averageFrameDuration = (averageFrameDuration * 0.9) + (GETTIMER() * 0.1)
PRINT "FPS: " + FORMAT$(3, 0, 1000.0 / averageFrameDuration), x, y
ENDFUNCTION
@kanonet: ha, ya, I rechecked the code to see what you meant about GENX_OBJ(). First, I didn't even remember there was such a command (it doesn't begin with an 'X_'!). But I may remember when I first created the mesh TYPE (years ago), that it doesn't actually use the returned value from GENX_OBJ() until you add some geometry to the model. So if I call that command 10 times at the program start, all meshes would all get the same id. My fix was my 'smart' way of getting around that. But I took another look, and simply inserted the check (if id<0) in the Generate() function, and that seems to work awesome. I deleted my 'smart' function and now I'm using GENX_OBJ().
@Kitty: Hmm, interesting idea, didn't even know calculating normals by hand was an option. Will have to update to use that. Does a normal have to be normalized (ha, sounds weird)? Is it a simple vector (0,0,0 origin) that points away from the quad face? And relative too I hope, so all north facing walls can all use the exact same normal for all four corner vertices? I could precalculate each face normal during initialization, and use those for the mesh building later. Will try this soon. Does 'X_AUTONORMALS 0' speed up model creation since it doesn't need to auto-calculate normals? I find it still a little slow using '0', but of course the normals are way off.
@dreamerman: Cool, you got this working on Android?
@erico (and others thinking 3d programming is difficult): That's why I created the TMesh TYPE (and TVertice, TQuad). It handles all the low level details for me (like above, I didn't even remember the GENX_OBJ() command since I seldom venture into the mesh code). You just have to keep it straight in your head (or paper) the x, y, and z coordinates of the vertices you need, create some quads (each containing four vertices), and then add those quads to your model (then finally call the .Generate() command to finalize the process and create an actual 3d model). All done in steps to keep your head sane. This project is probably a good starting point for dynamic 3d model generation (especially if you use my TYPEs).
I think I will at least do the texture atlas portion next. I will be using TexturePacker to pack my textures into a sprite sheet (there is a free version, but the full version is only like $25). I'll need to create code (I'll be using bigtunacan's code as a starting point, thanks) to read the sprite sheet definition file, and TYPEs to handle extracting individual sprites/textures from the sheet. Then use this to allow you to define your voxel textures using individual files for each face, and reference them by filename in GLBasic (such as 'cube_grass_top', 'cube_dirt_left' or something meaningful). I've done this in Unity so porting the code shouldn't be difficult.
I attached the updated project with the fps fix, and GENX_OBJ() fix.