Thanks Zarfius for the comments that made me reply and write down the "goals", now I can just copy it here.
[size="3"]The goals of the application
Due to my relatively poor English, I can't really use the term "goal". In my previous entry, I was talking about my "goals", in this paragraph, I'll write about the application's "goals" (what it does).
The program is for aiding paper modelling, which has nothing to do with computer games. So the main feature is precise unfolding polygon meshes (so it's not the same as UVW unwrapping). I know there are many programs and plug-ins for that, but all the programs I found during a small research was either not "to my liking" or was "expensive". Some of them have manual unfolding (polygon-by-polygon, which is very tedious), some of them are only suitable for low or very-low poly models, some of them produces crappy unfolded geometry or are tedious to work with. And as far as I saw, none of them take the thickness of the paper into account (which is 0.5 mm for the cardboard I worked with for example).
A main goal is to make an algorithm that produces the best output with the least input even with high-poly meshes. Easily and intuitively modifying the unfolded geometry is a must too. And of course printing/plotting the result with different line types and textures. Later I'll add more features, like modifying surfaces of the original 3D mesh to be unfoldable (it's hard to explain what I mean by that); making slices of the mesh for layered paper structures; automatic/manual adding of "flaps" to the edges to be glued together, maybe basic documentation tools like guidelines, arrows, numbers, comments, assembly drawings, etc.
More explanations in my old blog, I don't want to rewrite/copy the whole thing here.
Reused the code from the previous version, and added new features like
- automatic welding of unfolded vertices/edges
It's hard to explain why I need this. So see the first three images of an unfolded box. Second: with welding, third: without welding. You can see how the algorithm builds up the unfolded geometry.
- displaying the split (cut up) edges in the 3D view
and added an "unfold edges only" edge selection method. Of course, welded edges are not displayed
really just using the same texture coordinates as the original mesh
- sharp edges are rendered as broken lines
- triangle identifier numbers on 3D and unfold geometry
This is just the beginning. I plan to add a lot of other and powerful features to it to generate much nicer geometry that needs fewer further manipulation.
And of course taking the thickness of the paper into account. That will be a huge pain in the ass. Maybe I should start with a *perfect* shell generation algorithm (offsetting the faces). Well, even 3ds MAX cannot do that....
You can read more about the algorithm if you like, here.
I played (struggled) with it a lot, programming-wise. With the help of Gamedev of course. Now it has expandable/shrinkable groupboxes, and the whole "Right Panel" is scrollable with left mouse button drag. It still flickers (I didn't dare to use WS_EX_COMPOSITED style for the panel), but (IMHO) feels/looks quite slick. And it will be helpful in the near future, because I still haven't bought a new monitor, and the current has an approx 200x200 pixel dead area at the botton-right corner.
Of course, it's far from finished/polished, but at least I can forget about it for a while.
Or whatevers... I still have no idea about the mechanics of the editor. Especially the mechanics of unfolding.
I unfold the geometry, then I edit the unfolded geometry, then I press unfold again, and Bam! all the editing is lost. Or maybe every unfolding should go on a new "Sheet"? (if the user wants of course). After unfolding, the 3D and the unfolded geometry should be totally separately handled? What about other stuff in the future? When I add new meshes, like layered things of the 3D mesh? How about importing new meshes?
Maybe the user could select which sheet the new unfolding should go, and override the unfolded geometry on that sheet?
So a lot of brainstorming and design is ahead of me.
The first three demonstrates the welding stuff. The box is segmented only for testing this feature.
The other seven images are about the unfolding of the car model, modified by edge selection. The algorithm splits (cuts) the geometry at selected edges. It took me about ten minutes to make it (excluding 3D modelling). I tried two variations for the roof.
The last three shows the GUI.