Skip to main content

Ground Those Objects

cars floating in air snapped to proper position on the ground

cars floating in air snapped and rotated to proper position on the ground

Ground Those Objects or GTO is a Lightwave layout plug-in to move the selected object(s) along the world Y axis to the ground surface mesh you choose. I use it whenever the ground surface in my model is irregular like the real world and I have lots of trees or cars to position. It also can be used to set the y values of a camera or other object to skim over the irregular surface at a set offset distance.

Originally I wrote it in c and with only a 32 bit compiler, I finally got tired of launching a 32 bit version of Lightwave every time I needed it and re-wrote it in python. Now it works for 64 bit as well as mac's. I hope you find it useful.

../../plugins/DialogueCapture3.2.jpg

Dialogue box showing feature choices

Features: - Option to add random heading - this is useful for makes multiple copies of identical plants look slightly different. - Option to rotate pitch and bank (via pivot rotation) to match ground surface. This works well for setting a car on a sloped parking lot. Beware - it only grounds the pivot point - It doesn't know if you have a curb under one wheel. - Selection can be optionally expanded to include the hierarchy below the selected items. This can save the tedium of selecting a large number of items - Moving items can be grounded for each of a series of frames. - A surface offset can be added to the Y value set. - Nulls are ignored by default but can optionally be grounded also. - Sets key frame only on Y envelope - Frame step size gives more control for grounding over a series of frames.

Usage Notes: The ground surface to place the objects on must be triangulated. Groups of objects can be organized into a hierarchy. Since nulls even if selected wont be moved (by default), use them to organize your parking lot or landscape planting. Grounding a full hierarchy of objects (both parents and child object)s together with the Add random heading option or the Rotate Pitch and bank option is unpredictable because the parent would be rotated which would move the child.

Pre-select your cars, trees, or whatever. Run Ground Those Objects. The list box lets you choose your triangulated ground surface from all objects. After running Ground Those Objects, each of the selected objects will have been moved to have its Y value resting on the ground surface. Of course if your object isn't over the ground it won't be moved The random heading option does just that and makes identical trees look a little different from each other.

The rotate pitch and bank option adjusts pivot rotation to get the object to match the slope of the ground triangle it is over. The include hierarchy below selected items option is for when you have more than a few objects to select.

If you put a 10 in the start frame and a 40 in the end frame options, you will get 30 key frames set for each object.

Installation Download and unzip the python script GTO. Put it in a folder you can find. Open a scene file in layout with a triangulated surface object and one or more objects to place on the ground. Pre-select the objects you want to move, and in the utilities tab click 'python' and navigate to the folder with 'ground3py.py' and select it. Fill out the dialog (image above) and click OK.


If you are looking for lwsn Controller - beta _14, it is available for tinkering with. (Don't bother unless you are a python programmer)

lwsn_Controller is a render farm controller that I developed using Python to provide a lot more flexibility than Layout provides. It features the ability to add or shut down render nodes without disturbing the other nodes still rendering. You can add or delete scenes to the controller while processing continues or even modify which frames to render. You can assign specific nodes to specific scenes and change assignments or use auto-assign during processing.

Comments

Comments powered by Disqus