Posts Tagged ‘LightWave’

Motion baker… that works

Written by MentalFish. Posted in Computer Graphics

My latest LScript is a motion baker script for LightWave that bakes such things as items animated through Denis Pontonnier’s DP Kit + Node Item Motion and other “non standard” ways of animating in LW.

It also bakes all selected items, and on a test of 100 nulls, it took about 12 seconds to bake them over 100 frames, so 10.000 keys set in total. To make sure that it bakes the correct value, it runs through the timeline once, extracting the values from each selected item, and then afterwards applies those values to the respective channels: position, rotation and scale.

Once it is done baking, it goes back to the frame you were at when triggering the script, nothing grand, but just a little extra touch to make it a nicer workflow. As far as I can tell, this script will bake other tricky animations such as expression based animations and the like. Give it a spin and see if it works in your projects.

Thanks to Mikael Burman for suggesting and testing the script!

Edit: updated the script to have a GUI so you can specify the range of frames to bake.

Download MFMotionBaker

LightWave 2 AfterEffects Followup

Written by MentalFish. Posted in Computer Graphics

I have gotten some questions about what the point is with this script, so I am just going to post a little explanation of it here.

One example of where it would be useful, is if you want to add particle effects inside AE instead of in LW. Say you want to add smoke effects to an animation but can’t afford the render time of using HyperVoxels. Just render out the animation without any particle effects or HyperVoxels, place a null in LW of where you want the particles to emit, and then export that to AE and use that as an emitter inside of that application instead.

So if you have a moving locomotive you parent the null to its chimney, export that and the camera. The rendered image sequence from LW would not be 3D but just a plain 2D backdrop of course, with a null and camera that moves correctly according to the rendered sequence.

It is also generally a good workflow to render out passes so you can tweak the end result in AE instead of having to re-render everything. Janus is supposed to be a very good plugin for rendering out passes in LW, but I have not tried it yet myself. http://janus.faulknermano.com/

Also, keep this in mind:

- 1 meter in LW == 100 pixels in AE
- Check that the x, y, z coordinates of the plane in AE is set to the same as the one in LW (with some potential reversal of some axis, but if something is placed at 0,0,0 in LW it should be the same in AE (which it rarely is by default when a layer is set to 3D)
- Make sure the zoom level on the camera matches. In AE it is specified as pixels and degrees in parenthesis ie. (45.2°). Set this zoom to match the horizontal FOV in LW and you should be good to go.

LightWave to After Effects

Written by MentalFish. Posted in Computer Graphics

This is an LScript for transferring animation data from LightWave to After Effects. It is done by exporting the position and rotation of the selected item in LW into a .ma file (ASCII Maya file). At the same time, After Effects is either launched or brought to front and told to open that specific file. This makes it feel like you have a direct connection between the two applications.

It always exports it as a camera so that AE does not create a whole bunch of solids for the models inside the .ma file. Think of it as exporting a null that just so happens to look like a camera :)

What do you think, should the script also export scale as well, or is it not needed?

Something weird happens with the sound in the end. I might re-record it, but it works for now:

Download LScript

Stranded on an island

Written by MentalFish. Posted in Computer Graphics

I came across an issue the other day while doodling on a 3D model of a car wheel. The nuts, or bolts if you will, were too small and I found it strange that there was no tool inside LightWave to scale them individually as separate entities as they were inside the same layer (mesh) in Modeler. This would mean I had to manually select each island and scale them one by one. Not a giant task by any means as it was only a few items, but still annoying.

http://vimeo.com/moogaloop.swf?clip_id=5802071&server=vimeo.com&show_title=0&show_byline=0&show_portrait=0&color=ff9933&fullscreen=1

So I went to the NewTek forums and posted a question on whether or not there is a solution for this, either hidden somewhere in LW or some sort of plugin. I got some suggestions on plugins to use and a script to try. They weren’t exactly what I was after, but it gave me a starting point and idea of how to get this functionality working as I wanted it to.

I studied the suggested LScript (LightWave Script), got the grasps of what was going on, analyzing why it wasn’t working, and after a couple of iterations came up with a solution that worked. This was in turn taken by someone else, new to the discussion, and improved to yet another level.

At this point the script was doing what I wanted in terms of scaling each “island” of selected polygons, but in a very try-and-see-what-happens kind of way, as there was no interactive feedback of the end result while changing the scale value. So I added an interactive update to it as well as the next step.

From this it was a couple of lines extra and we had “island-rotation” as well. The only problem here is that it happens on world-coordinate axis, so if your island of selected polygons were on differently slanted angles, it could mess them up. If they were aligned flat on the same plane, they were fine.

Now this LScript is in a stage of adding scaling around each polygon-selection’s average normal (its local “up” axis) and if this works then… woohoo! Anyone with some 1337 LScript and/or 3D math knowledge is welcome to contribute.

I would not have found these solutions as fast if it was not for the community and the general attitude of sharing and contributing.

That’s it for now, check out the forum thread and follow the continued development of this:

http://www.newtek.com/forums/showthread.php?t=100587

Download LScript

MentalFish blog is live

Written by MentalFish. Posted in Uncategorized

What better way to start off the MentalFish blog than some words on the release of Unity 2.5? Apart from Unity related issues this blog will contain posts on LightWave, thoughts on usability and interaction design, updates on what is going on with Galactic Fleet and occasional posts on radio controlled planes and the likes.
unity-on-windows
With Unity 2.5 we have the possibility of using Windows and can expect an explosive count of Unity users. This is good news for anyone using Unity as their real time 3D engine of choice, as the general awareness of Unity existing will increase. In time we might even see it becoming a the most installed plug-in for browser based 3D, in the same way as Flash has become the most installed plugin for video and “rich media” on the web.

Also check out the Unite 2008 conference videos, lots of good information. Now I finally get to watch the ones I didn’t attend as I couldn’t replicate myself like Dr Manhatten from Watchmen. I chose to go to the more technical ones, missing out on talks such as bringing concepts to life and making art look good.

Although Unity is now available for Windows, I’ll still stick to Mac OS X. I have gotten fond of having *nix command line available (i.e. cronjobs) and all the applications I use apart from Unity is also available on OS X, especially LightWave which has a Cocoa (true 64bit) version around the corner. Finally my 6 gigs of RAM can be used to its full extent by LightWave (if I ever need to lightmap a massive scene that is).

To be honest, I have bought 3 Mac’s; a Mac Mini to get familiar with Unity, then I bought a Mac Pro as my workstation and the smallest Macbook Pro available for on-the-go work and prestentations. All because of Unity. In other words, I have some hardware investment in the Mac world. That said, if I feel like going back to Windows, all machines can become Wintel machines immediately via Bootcamp, but there is one other aspect that keeps me on the OS X platform: Galactic Fleet turning into an iPhone / iPod game. So I guess I have no need of swapping hardware for at least another 2 years (perhaps a GFX card upgrade for the Mac Pro in a year or two).

For anyone interested and hasn’t seen or tried Unity yet, go get get the demo at their website.