com.threerings.probs
Class VectorVariable.Uniform

java.lang.Object
  extended by com.threerings.util.DeepObject
      extended by com.threerings.probs.VectorVariable
          extended by com.threerings.probs.VectorVariable.Uniform
All Implemented Interfaces:
Exportable, Copyable, Cloneable
Enclosing class:
VectorVariable

public static class VectorVariable.Uniform
extends VectorVariable

Returns a uniformly distributed value.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.threerings.probs.VectorVariable
VectorVariable.Constant, VectorVariable.Uniform
 
Field Summary
 Vector3f maximum
          The maximum extent.
 Vector3f minimum
          The minimum extent.
 
Constructor Summary
VectorVariable.Uniform()
          No-arg constructor for deserialization, etc.
VectorVariable.Uniform(VectorVariable variable)
          Creates a uniform variable from the parameters of the other variable.
 
Method Summary
 Vector3f getMean(Vector3f result)
          Computes the mean value.
 Vector3f getValue(Vector3f result)
          Computes a sample value according to the variable's distribution.
 
Methods inherited from class com.threerings.util.DeepObject
clone, copy, copy, equals, hashCode, toString
 
Methods inherited from class java.lang.Object
getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

minimum

@Editable(hgroup="range",
          step=-1d/0d,
          scale=-1d/0d)
public Vector3f minimum
The minimum extent.


maximum

@Editable(hgroup="range",
          step=-1d/0d,
          scale=-1d/0d)
public Vector3f maximum
The maximum extent.

Constructor Detail

VectorVariable.Uniform

public VectorVariable.Uniform(VectorVariable variable)
Creates a uniform variable from the parameters of the other variable.


VectorVariable.Uniform

public VectorVariable.Uniform()
No-arg constructor for deserialization, etc.

Method Detail

getValue

public Vector3f getValue(Vector3f result)
Description copied from class: VectorVariable
Computes a sample value according to the variable's distribution.

Specified by:
getValue in class VectorVariable
Returns:
a reference to the result value, for chaining.

getMean

public Vector3f getMean(Vector3f result)
Description copied from class: VectorVariable
Computes the mean value.

Specified by:
getMean in class VectorVariable
Returns:
a reference to the result value, for chaining.


Copyright © 2011. All Rights Reserved.