artofillusion.procedural
Class NumberModule

java.lang.Object
  extended by artofillusion.procedural.Module
      extended by artofillusion.procedural.NumberModule

public class NumberModule
extends Module

This is a Module which outputs a number.


Field Summary
 
Fields inherited from class artofillusion.procedural.Module
linkFrom, linkFromIndex
 
Constructor Summary
NumberModule(java.awt.Point position)
           
NumberModule(java.awt.Point position, double v)
           
 
Method Summary
 Module duplicate()
          Create a duplicate of this module.
 boolean edit(ProcedureEditor editor, Scene theScene)
          Allow the user to set a new value.
 double getAverageValue(int which, double blur)
          This module simply outputs the value.
 double getValue()
          Get the value.
 void getValueGradient(Vec3 grad, double blur)
           
 void readFromStream(java.io.DataInputStream in, Scene theScene)
          Read in the module's parameters from an input stream.
 void setValue(double v)
          Set the value.
 void writeToStream(java.io.DataOutputStream out, Scene theScene)
          Write out the module's parameters to an output stream.
 
Methods inherited from class artofillusion.procedural.Module
calcSize, checkFeedback, draw, getBounds, getClickedPort, getColor, getInputIndex, getInputPorts, getName, getOutputIndex, getOutputPorts, getValueError, getValueGradient, init, inputConnected, layout, setInput, setPosition
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NumberModule

public NumberModule(java.awt.Point position)

NumberModule

public NumberModule(java.awt.Point position,
                    double v)
Method Detail

getValue

public double getValue()
Get the value.


setValue

public void setValue(double v)
Set the value.


edit

public boolean edit(ProcedureEditor editor,
                    Scene theScene)
Allow the user to set a new value.

Overrides:
edit in class Module

getAverageValue

public double getAverageValue(int which,
                              double blur)
This module simply outputs the value.

Overrides:
getAverageValue in class Module

getValueGradient

public void getValueGradient(Vec3 grad,
                             double blur)

duplicate

public Module duplicate()
Description copied from class: Module
Create a duplicate of this module. Subclasses with adjustable parameters should override this.

Overrides:
duplicate in class Module

writeToStream

public void writeToStream(java.io.DataOutputStream out,
                          Scene theScene)
                   throws java.io.IOException
Description copied from class: Module
Write out the module's parameters to an output stream. Subclasses with editable parameters should override this method.

Overrides:
writeToStream in class Module
Throws:
java.io.IOException

readFromStream

public void readFromStream(java.io.DataInputStream in,
                           Scene theScene)
                    throws java.io.IOException
Description copied from class: Module
Read in the module's parameters from an input stream. Subclasses with editable parameters should override this method.

Overrides:
readFromStream in class Module
Throws:
java.io.IOException


Copyright © 1999-2011 by Peter Eastman.