Back to plugins

Noise for AC3D

Released under the GNU LESSER GENERAL PUBLIC LICENSE.

Latest release (version 1.1)
Download Windows version 1.1
Download Linux version 1.1 Debian 3.0 *
Download Linux version 1.1 Debian Sarge 3.1 **
Download source code

* NOTE: Courtesy of AJ MacLeod, this Linux version was compiled and linked on a Debian 3.0 install. If this does not work for you, the source code has been proven to compile/link under Linux, so you may wish to download the source code and compile for your system.

* NOTE: Courtesy of little_penguin, this Linux version was compiled and linked on a Debian Sarge 3.1 install. If this does not work for you, the source code has been proven to compile/link under Linux, so you may wish to download the source code and compile for your system.

History

Version 1.1

  • Added noise support for texture coordinates

Applies random movement or rotation to the current selection.

This plugin and code are freely distributable

AC3D versions prior to version 5 have not been tested with this script.

Description

Applies random movement or rotation to the current selection.

Noise is selection context sensitive. For example, when in Vertex mode, random Moves will be unique for each vertex, while in Object mode, random Moves are applied to each object as a whole.

Installation

Copy the noise.tcl and noise.p files to your AC3D plugins folder (for example, if using Windows, C:\Program Files\AC3D5\plugin) and (re)start AC3D.

You will find the "Noise..." menu item under the "Tools" menu.

Example : The Move utility

The Move utility moves groups, objects, surfaces, or vertices randomly, depending on the current Select mode. The select mode has a significant effect on the result of the Move command.

The distance moved is expressed as a range of units. For example, if you specify "1" unit, this means that a random movement between -0.5 and +0.5 will be applied to each selected element.

This example uses four cubes. Each cube is a 1x1x1 unit box. The cubes were divided 3 times each (using Surface | Divide), and were arranged as shown.

The two cubes on the right side have been grouped together using Edit | Group.

With all 4 boxes selected, a Move was enacted in each of the 4 select modes, with the following results.

Vertex mode
Move by 0.04 on the X, Y, and Z axes
This moved every vertex in the selection within a 0.04 unit range, meaning that each vertex moved from -0.02 to +0.02 from it's original location.
Surface mode
Move by 0.04 on the X, Y, and Z axes
This moved the vertices of each surface by a random x/y/z direction. I did make a special change just for this example, however. I performed a Vertex | Unshare on all of the surfaces on the cube in the upper-right. Notice in ththis cube, all surfaces were moved uniformly. The others look a bit like like a twisted mess --- this is because the vertices between each surface was shared, so while the vertices of one surface were moved uniformly, the adjacent surfaces were also moved, which moved these vertices even further.
Object mode
Move by 0.5 on the X, Y, and Z axes
This moved the entire objects by a random x/y/z direction.
Group mode
Move by 0.5 on the X, Y, and Z axes
This moved entire groups by a random x/y/z direction. Notice that the grouped cubes on the right moved the same amount in the same direction.

The following is an example of moves in vertex mode with subdivision applied.

The cube is similar to one of the cubes in the previous examples.

The sphere is not actually a native AC3D sphere. You may find that if moving vertices in a standard sphere, the top and bottom of the sphere will "pinch". This is caused by the way the triangles are arranged at the top/bottom of the sphere.

To get this more natural looking, stone/asteroid-like sphere, I used the Tools | Create polyhedron... utility that ships with AC3D. This is a rather intimidating utility, and does call for experimentation unless you're somewhat geometry/poly savvy. The steps to achieve this shape were:

  1. Using Tools | Create polyhedron..., select "cube" in the left window, and "snub cube" in the right window. Check the right-most radio button beside the "Dual" label. Click "Make".
  2. Perform a Surface | Divide on the polyhedron.
  3. In Vertex mode, perform a Vertex | Smooth
  4. Perform a second Vertex | Smooth
  5. Perform a Noise... with the Move x/y/z all set to 0.3.
  6. The last step created some bad triangulation for us, but we can fix that by Subdividing the object. I set the subdivision level to 2 for this example.

You should then have a cube similar to the one above. If you do not care for the results, you can Undo and try again. Also, you could have performed the Subdivision (step 6) before applying the noise - this allows you to experiment a bit more easily.

Example : The Rotate utility

The Rotate utility rotates geometry randomly. Rotation is always based on the center of the group (in Group select mode) or the object (all other select modes). Rotation is specified in degrees.

This example uses an array of 256 cubes, arranged as shown. Unlike the Move example, each "square" is a distinct object.

With all 256 boxes selected, a Rotate was enacted with the following results.

Vertex mode
Rotate by 30 degrees on the X, Y, and Z axes
This rotated every vertex in every object a random direction. Because each Vertex was rotated by a different angle, we were left with "warped" cubes as a result.
Object mode
Rotate by 30 degrees on the X, Y, and Z axes
This produced results very similar to a Vertex rotation, but every object was kept as a perfect cube, rotated as a whole.
Object mode
Rotate by 10 degrees on the X, Y, and Z axes
Similar to the last example, but a more subtle rotation was applied. This effect is more suitable for effects like uneven cobblestones or tiles.

Back to plugins



All content Copyright © 2006 Dennis Hawthorne, except where explicitly noted
supercoldmilk © 2006 Dennis Hawthorne