I'm porting my Blitz3d project to NF and reached a Milestone of getting the basic application working. Even thought it's basic there was still a lot to learn and understand, so it took longer than I thought it would. So far I have:
Gtk+ running as the gui. The icon containers and main window are adjustable with the mouse and the NF window in the middle auto-adjusts to fit properly.
Icons and models are loaded from an SQLite database.
manipulator widgets for translate, rotate and scale
Camera controls for navigation using the std w ,a, s, d keys
Lots of stuff yet to add, but its the material system next. In the meantime, here's my first screenshot:
Yep, still working on it, but got side tracked to work on some shaders.
Added in the TreeView, but had a small issue with it as Gtk does return a constant pointer to a node when you add it to the tree. If I select a node I can easily get a handle to the 3d object in the scene, but it's not so easy the other way round, i.e. click on an object and get the node handle. I've had to set up an indexing system and loop through the tree each time an object is clicked on. Not ideal, but it works.
I've also gone through a couple of iterations of the Material editor, and I think I'm happy with the way it's set up now. I'm keeping it quite simple at the moment as I'm not sure how to export a material into a different engine/tool. For example, I can create a damaged looking wall material that uses two blended diffuse maps and then bumped with parrallax offset mapping, but when I export the model to .dae, how does a program like UDK, Blender, Unity or lightwave etc create the same material? This isn't a problem for NF or NB users though as they can just use the same .fx file as used in modbox4d.
very nice! looks like the interface of Cinema 4D
Ha, someone noticed! I've been a user of Cinema4D for about 10 years now so it has influenced my design of modbox4d ( and I am using a couple of their icons as placeholders until I've redesigned my own ones ) Just a quick note to say I didn't add the 4D bit to Modbox because of Cinema4D. I did it because the modbox domain name had already been taken :(
seems most editor have gone dark tones as of late . LOL
I quite like the Darktone interfaces, but users can swap the interface to any compatible Gtk+ gui they like, or even create their own. This was one of the reasons I went with Gtk over other gui's.
yeah i use teh GTK skin in FLTK a fair bit in mine.
PS for indexing try this .
\\ nodehadle is whatever data type/struct your node point with
the index in ItemsNodes holds the node (nodehadle ) as it is in your tree , the vlaue
but the index is a of size_t , or unsigned int . so ..
you can save that index in your scene's ent(s) data slot , say slot 4 .
so if you click on a ent . check if it's 4th data slot is populated .
if so read that as a uInt ,
when you scan you ents into your scene graph populate their 4th user data slot with their index in your ItemsNodes
because your tree has the ent NUKE , so you can find either very fast without iterating thorough anything , however you could make a search by index or some shiz .. if you need reverse search to be faster
I've been quite busy working on Modbox4D, but I haven't posted much of an update for a while.
I had to re-write the Treeview a few times, but I think I've cracked now. With this Treeview you can drag-drop nodes, but you can also multi-select several nodes and then hit CTRL+G to group them all into a single 'Group' node. The new grouped nodes also preserve the hierarchy of any child-parent relationships being moved into that group.
I've got the material editor pretty much working now too which is great. Icons of the finished materials are saved to the DB and can be dragged/dropped onto the textures panel for a particular object.
The Treeview was a real pain in the proverbial. Gtk+ lets you build Treeviews very easily, but manipulating the nodes on a tree can get complicated as each node doesn't have a constant pointer, they change all the time and so I had to track everything with a custom index. This Treeview consists of about 1,600 lines of code so far and I'm still not sure that it works properly!