Poll: do you think unfolding would be a nice addition to Wings?
Absolutely
Not at all
What are you talking about?
[Show Results]
 
 
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
 
Share Thread:
Reddit Facebook Twitter
unfold
09-06-2020, 12:28 PM (This post was last modified: 09-06-2020 12:51 PM by engrenage.)
Post: #5
RE: unfold
I believe something like this should do it:

Code:
face_clicked()

is it connected to two or more faces present in the tree?
{
  // connect where?
  request from user: EDGE = select_edge() or FACE = select_face()
}

if is_set(EDGE) {
  FACE = from the connected faces, find which one connects to face_clicked() with that EDGE ; make sure it doesn't crash if no face match (invalid edge clicked, FACE not in tree)
}

if FACE not in tree: try again (or make new group)

is it connected to another face present in the tree?
{
- what edge connects the two faces? (unless EDGE is set)
- compute position and add to tree ; output can be generated on-the-fly
- update face color and edge colors ; color faces by first-level branch (group) and edges by unset/cut/fold
} else {
- make new group
}

I see it necessary to have the option of saving the tree and loading it to/from a text file, so it can be used with different versions of a model. upon loading, simply traverse the tree and if a face is missing just cut the rest of the branch.

to simplify the computation of the position of each face added to the tree, it may be advantageous to have a secondary list of fold (connecting) edges their X-Y position and orientation on the plane. when creating a tree and/or branch, a new sheet (page) with custom dimensions MAY be added for that branch and displayed alongside the 3D model ; the user should be able to move around and rotate each branch in the sheet in order to optimize placement simultaneously while building up the tree.
Reply


Messages In This Thread
unfold - engrenage - 09-03-2020, 09:51 AM
RE: unfold - micheus - 09-03-2020, 09:35 PM
RE: unfold - engrenage - 09-06-2020, 09:12 AM
RE: unfold - engrenage - 09-06-2020, 11:09 AM
RE: unfold - engrenage - 09-06-2020 12:28 PM
RE: unfold - engrenage - 09-06-2020, 03:40 PM
RE: unfold - micheus - 09-07-2020, 04:12 PM
RE: unfold - engrenage - 09-07-2020, 09:24 PM
RE: unfold - micheus - 09-08-2020, 12:22 AM
RE: unfold - engrenage - 09-13-2020, 10:10 AM
RE: unfold - micheus - 09-13-2020, 05:34 PM
RE: unfold - engrenage - 09-19-2020, 10:25 AM
RE: unfold - gilboonet - 09-19-2020, 04:24 PM
RE: unfold - micheus - 09-21-2020, 05:46 PM
RE: unfold - gilboonet - 09-22-2020, 06:53 AM
RE: unfold - engrenage - 10-15-2020, 10:42 AM
RE: unfold - engrenage - 10-15-2020, 11:11 AM
RE: unfold - engrenage - 10-15-2020, 04:18 PM
RE: unfold - engrenage - 10-15-2020, 05:30 PM
RE: unfold - micheus - 10-15-2020, 06:36 PM
RE: unfold - micheus - 10-15-2020, 09:11 PM
RE: unfold - engrenage - 10-17-2020, 12:13 PM
RE: unfold - micheus - 10-17-2020, 02:28 PM
RE: unfold - micheus - 10-20-2020, 06:18 AM
RE: unfold - engrenage - 10-22-2020, 05:30 PM
RE: unfold - micheus - 10-23-2020, 09:55 PM
RE: unfold - engrenage - 11-03-2020, 03:28 PM
RE: unfold - engrenage - 11-10-2020, 11:31 AM
RE: unfold - micheus - 11-10-2020, 12:12 PM
RE: unfold - engrenage - 12-17-2020, 10:58 AM
RE: unfold - engrenage - 06-06-2021, 05:07 PM
RE: unfold - micheus - 06-06-2021, 07:45 PM

Forum Jump:


User(s) browsing this thread: 1 Guest(s)