Bullet Time FX Plugin





What does this plugin do?



This plugin time warps the motion of objects in the scene selected by the user making them all appear to be moving in slow motion.. It also helps the user in setting up a special "bullet time camera" attached to a path that can be modified byt the user. The plugin can also create a "bullet trail" effect that can be adapted to fit different objects' shape. The plugin was not featured in "Don't slam the door" because the scene in which the bulllet time effect was being used got cut due to a shortage of time.


How?

The UI was written using MEL (the Maya scripting language). All the time warping code is written in C++ and uses the Maya API. The keyframes are interpolated linearly and the tangeants are flattened in order to prevent distortions in the motion. The user can specify which objects are affected by the "time warp", the user can also specify the factor by which he/she want's the motion to be slowed down.
The trail effect is created using an expression (mostly because it's easier to do it that way). For now the variables that shape the effect are not controllable from the UI (they will be soon). There are about 15 variables that control the shape of the trail effect.
The expression creates an EP Curve with a 1000 control points and positions the control points based on a home made "double sine" function. After the cruve is created it is revolved around a (soon to be user selected) axis to create the final shape. A glass shader is applied to the shape to obtain good looking reflections and refractions. The shape had to be made one sided in order for it to look correct when being raytraced (the rays cast by the raytracer could not get out of the shape and the effect would look mostly black) Marcin Szymanski was the designer of the effect (his artistic skills are much more evolved than mine :).




Using the plugin


Before anything can happen the plugin binary must be loaded. First you need to download the binary file to the c:\temp directory it must be in c:\temp). You also need to download the UI mel script to any directory. Then load the UI script using the script editor:
window-> general editor-> script editor.
then choose file->source script and choose the file called bulletTimeUI.mel.
this will add an extra "Plugin" pull-down menu on top of the window in which you can choose the bulletTimeFX plugin.
Once you choose to run the plugin this window should come up
Then just click on the "Load" button in the "load/unload plugin" section of the window (the plugin never really needs to be unloaded the unload button is there mostly for convienience)


here's what the main window looks like.

In the main window the user can set the start/end time of the time warp and select the objects that he/she want to be affected by the time warp (if objects do not appear in the text box clicking the "refresh" button in the command section will make them show). The "BulletTime camera" can also be selected from a list of all the perspective cameras on the scene. The slow motion factor is an integer between 1 and 100.
The setup button in the camera control section of the window will help the user setup a bulletTime camera (it is not required to use this option, the user can use any camera)
The setup button will spawn a camera setup window. In this window the user can attach the previously selected camera to a path, set begin and end times for the path, and have the camera viewpoint follow a selected locator by a given distance.



The effect setup button is not active yet. Fitting the expression in the plugin created some problems, plus no spare time was available so I decided to leave the effect to be an expression for now. I will add the effect setup to the plugin very soon though. The expression I used to create the effect just needs to be plugged into the expression editor.

When everything is setup just press the "Run button" and you have BulletTime! Objects' motion will be time warped and a great matrix style effect will trail.



The curve and the effect created by revolving it.




A frame rendered from this maya 3.0 scene.