Genome
RSS< Twitter< etc

<< Selection Modifiers

Selection By Time

Genome provides an easy way to create a dynamically growing or shrinking selection based on the sub-object index and the current scene time.

Vertex Selection By Time

In the following example, we will select vertices if their index is less than the current scene time. This works best with primitive objects where the indices are well-ordered.  

  • Create a Teapot with 16 Segments and Radius 40.0.
  • Set the scene time range to 500 frames.
  • Add a Genome modifier to the Teapot, set it to "VERTEX" iteration mode.
  • Open the Editor and press Ctrl+[O] to create an Output node, set it to Selection channel.
  • Select the Output node and press [I], [C] and [V] to create a VertexIndex InputChannel.
  • Press [L] and [S] to create a Less operator.
  • Press [I] and [S] to create an InputScript.
  • Enter the expression 'currentTime.frame as integer' in the Script text field. This will output the number of frames as an Integer value as result of the node.
  • Since the Selection channel is supposed to be a Float but logical operators output integers (0 for false, 1 for true), select the Less operator and press "Convert To Float" button in its Properties rollout to insert a ToFloat operator.
  • Moving the time slider now should select one vertex per frame. Since we want it to go faster, select the InputScript node and press [*] for Multiply and [1] for Integer InputValue. 
  • Enter 17 in the InputValue - this will cause 17 vertices to be selected per frame. 

RESULT: The vertices will be selected gradually as time passes until the all of them are selected. The left image shows the selection on frame 80, the right image shows frame 445 out of 500:

  

Dropping a Push modifier on top of the stack and setting it to 5.0 units will produce an animated thickening effect:

  

Vetrex Soft Selection By Time

Using a similar approach, we can set a Soft-Selection based on a user-defined falloff: 

Instead of using a Logical operator, we will simply convert the VertexIndex and Time to Floats, subtract the VertexIndex from the Time, clamp the result between 0.0 and a Float InputValue of 200.0 and divide the result by the same Float value before outputting as Vertex Selection:

RESULT: The leading 200 vertices will be assigned a soft-selection, after that they will be fully selected.

   

Face Selection By Time

Setting the Face Selection by time involves almost the same steps as the Vertex Selection example in the beginning of this topic, minus the conversion to Float:

RESULT: We only need a larger multiplier since the Teapot has about twice as many faces as vertices: