FFD 2 Quad

13 votes
Version: 
1.08
Date Updated: 
10/31/2012
Author Name: 
jonah peele

10/31: Added a vertex normal projection option by pressing alt while clicking, fixed some small issues. Hope you find this useful, Happy Halloween everyone

about: the script sets up an 2x2x2_FFD modifier (FFD group button). It lets you automatically build new geometry by cloning and aligning the the orginal object to a quad of an Editable_Poly (place group). It also adds the 'Archetype Holder' modifier which lets you set up simple rules to run the script based on MatID's in an edit_poly.

"BBox2Face" macro does the same thing as above, but automatically builds the group based on whatever object is selected at the time. (also deletes the temp group when finnished)

Installation:

1) put the script in scripts/startup folder

2) There should now be a new macros "FFD2Quad" and "BBox2Quad"  under the "FFD to Quad" catagory in the customize UI menu

3) put the macro ui whereever you want

 

enjoy ;)

 

Additional Info: 

10/31/2012: I realized, that while the ability to set up very complex groups was neat, I tend to only use the basic FFD type most of the time. So I made a pared down version of the Macro (BBox2Quad ) that is a bit more user-friendly. Now it works like a mouse tool should, select a singular object (should work on anything that will take a FFD mod, noe not just epoly), run the macro, click to place, right click to stop. The placement can be modified by pressign ctrl(delete face), shift(inset), alt (project by vert normal). No need to set up the group ahead of time, just assumes it will work an FFD.

Added vertex normal projection option. Its based on the underlying smoothing group of each vert so if it is acting funny, make sure your smothing groups are set up correctly e.g. in a faceted model using the vert normal projection and face normal projection would give the same result

small fixes: small issue with trying to make groups out of flat objects has been resolved. The FFD Group button is no longer limitted to just epoly. Will also work on groups, but it is still buggy. EZLinkXF should work on splineshapes with multisplines now.

10/08/2012: I've got a fair amount of buttons on the rollout now, I should probaly explain what they do:

FFD Archetype: sets up the basic group for use with the script, (only works on epoly)

Clone+Attach Arch: does the same as the FFD button, except will attach the selected to what ever object is picked after the button is pressed. (Useful if you are trying to keep all the archetypes relative placement referential to echother, I used it in the bungalo example video to keep the individual component peices placements relative to the selected quad. Once the group has been created  you can open it up and delete the reference geometry, the ffd_duper makes sure the FFD lattice remains a constant size)

Linked XF Archetype: creates a new group where the corner points control the geometry usign linked xform instead of FFD. (useful for things that need to keep a relative dimension like frames, or walls, etc. I think this type of group builds faster than FFD groups so try to use this when posible, but it gives less consistent results)

Static Archetype: when placed static groups won't change deform any geometry, they simply stick the the new geometry on the face center

Half pnt: creates a point helper that has a scripted controller that keeps the position averaged between whatever objects were selected when the button was pressed. (finally fixed it so it will work rather the point is in a group or not)

Attach $: attaches all currently selected objects into a new editable_poly

Clone Faces: clones selected faces :P (if you have arcetype defintions that involve random components, cloning the face will put multiple random components in the same place, will sometime place the same geometry twice though)

EZ link XF: Cycles through selected Epoly and point helpers to create a linked x-form for each point that controls the vertices closest to the point. (It sounds more complicated than it is. Useful, for things where only some of the dimensions are vaiable. For example a pillar would need the height to be variable but not the length or width. My workflow would be: 1)create a simple FFD archetype group from the pillar 2) explode the group 3) select the top corner point helpers, press 'half pnt' to create a new point in the center of the top helpers, repeat for the bottom points 4)select the newly created points and the orginal geometry, press 'EZ link XF' 5) select everything, in this case should be 10 point helpers and the epoly, create a group. 6)test it out. place the new groupwith the 'Pick Faces button', you'll probably need to press the refresh button for the group to show up in the drop down list

Build Sub-Definitions: if this is checked whenever a face is picked, the created geometry will try to build any of the archetype definitions saved in the 'archetype Holder' modifier of the group you are using.

Further notes: picking faces is a very intensive process in the script, the simpler the geometry is better the script will work. On complex models, it works better (faster) to detach all the faces you plan on picking before hand, hide the rest, and then pick the faces to use. Or set the material ID's and use the Archetype Holder Modifier for creating the geometry.

TODO: I'll try to make a video example of how to use the x-form based groups if people are interested. I'm still working on how to optimize the script. plan to add scale and vertex-normal projection option to the modifier when I get a chance.

 

9/18/2012-- I sideline the original script for a while, but I finally got around to fixing it up. Changed it over to relying on the FFD modifier instead of linked xforms like it did before

notes: if you run the add a 'archetype holder' modifier inside one of the groups created with the script, the all of the settings from the modifier will be added build queue of any other 'archetype holder' that uses the group. So if a edit_poly has its own group listed in the saved archetype definitions, it will stack its own geometry on top of itself. Use the iterations to controll how many times this can happen. you can set up a rudimentary L-system fractal this way, but unfortunately the script runs too slow to really experiment with this potential.

also, though the script was designed to run using a ffd modifier, the build execution only moves the corner helper points. you can open up the group or continue attaching geometry to it once it is created. any nodes linked to corners helpers should be cloned and moved when the group is called. This can be useful if you want to make something that is positioned relative to a quad without having to deform the geometry (the halfway helper button was supposed to help with this process, but it's still has some kinks to work out <--FIXED)

I'm still trying to find fun ways to use this script if you have any ideas please post them

09/21: fixed the the archetype holder modifier that comes with the script. Added a youTube example on how to use the modifier

Version Requirement: 
3ds max 2012/2013
Video URL: 
AttachmentSize
ffd2quadexample.max1.29 MB
ffdtoface_latest.ms64.25 KB

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
Yusuf_ES's picture

Object in volume

any chance to sub-controller snap to vertices?

if an option "use target height" would be great.

Yusuf_ES's picture

Super script

Thank you nudity.
i always searching to like this script. Finally i found.
Sub-controller gizmo box amazing.

nudity's picture

@SIL: you're probably

@SIL: you're probably thinking of VRAY PATTERN. I try keeping up with what was happening with its development, but all their updates are in russian. check out http://www.scriptspot.com/3ds-max/scripts/patternmaker, which I use all the time, since my script compliments it approach to design very well.

SIL's picture

Great script! Thank you

Great script! Thank you nudity!

I remember had similar a script that copies one element for all polygons. Help me to remember it?

lightcube's picture

FFD2Quad... excellent

I was just pondering this very concept recently for one of my tools. I've sent you an email requesting some assistance adapting some of your functions (with your permission) as I'd rather not reinvent the wheel.

Edit: Denis Trofimov helped me do what I needed. You may find some useful tidbits of info from the funcs he provided.

_______________________

Shawn Olson

Developer of Wall Worm

JokerMartini's picture

Very cool tool.

Very cool tool.

John Martini
Digital Artist
http://www.JokerMartini.com (new site)

barigazy's picture

I send you a mail. Take a

I send you a mail. Take a look and tell me what you think.

bga

barigazy's picture

+1

Very interesting method you have here
Thanks for sharing this tool

bga

llld's picture

wow it's amazing.can you

wow it's amazing.can you please upload the max scene of the 3rd video example?i think some people like me want to study from that.thanks so much!

nudity's picture

@mustafa mamdouh : it doesn't

@mustafa mamdouh : it doesn't work with ffd because ffd control vertices can't have linked xforms. however using the skinwrap modifier works exactly the same way, if you try the sample scene I attached the brick wall uses this method. so... yes you can make it work exactly like a ffd deformer. in the first video, one of the window types was a loft where the base spline was kept in this form(hide the object being used for the skin wrap modifier so that alt+click automatically deletes it)

I'll try to get an example out there using more complex groups, maybe proBooleans, or railcloneLites

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.