JOGL v2.6.0-rc-20250706
JOGL, High-Performance Graphics Binding for Java™ (public API).
com.jogamp.graph.ui.AnimGroup.SineLerp Class Reference

Sine target LerpFunc, approaching ShapeData's target position utilizing the angular value for sine amplitude towards the given normalized direction vector. More...

Inheritance diagram for com.jogamp.graph.ui.AnimGroup.SineLerp:
Collaboration diagram for com.jogamp.graph.ui.AnimGroup.SineLerp:

Public Member Functions

 SineLerp (final Vec3f sineDir, final float sineScale, final float shapeStep)
 New sine LerpFunc instance. More...
 
boolean eval (final long frame_cnt, final Set as, final int idx, final ShapeData sd, final float at_s, final float dt_s)
 Evaluate next LERP step for the given ShapeData within the animation Set. More...
 
boolean eval (long frame_cnt, Set as, final int idx, ShapeData sd, float at_s, float dt_s)
 Evaluate next LERP step for the given ShapeData within the animation Set. More...
 

Detailed Description

Sine target LerpFunc, approaching ShapeData's target position utilizing the angular value for sine amplitude towards the given normalized direction vector.

The sine amplitude is flattened towards target.

Implementation uses the current shape position and relative time duration since last call to interpolate, hence allows rugged utilization even if shapes are dragged around.

Definition at line 762 of file AnimGroup.java.

Constructor & Destructor Documentation

◆ SineLerp()

com.jogamp.graph.ui.AnimGroup.SineLerp.SineLerp ( final Vec3f  sineDir,
final float  sineScale,
final float  shapeStep 
)

New sine LerpFunc instance.

Parameters
sineDirnormalized vector for sine amplitude direction
sineScalesine scale factor to amplify effect
shapeStepshape index idx factor for dt_s, amplifying angular distance between each shape. Golden ratio 1.618f reveals dynamic characteristics.

Definition at line 773 of file AnimGroup.java.

Member Function Documentation

◆ eval()

boolean com.jogamp.graph.ui.AnimGroup.SineLerp.eval ( final long  frame_cnt,
final Set  as,
final int  idx,
final ShapeData  sd,
final float  at_s,
final float  dt_s 
)

Evaluate next LERP step for the given ShapeData within the animation Set.

Parameters
frame_cntframe count for the given ShapeData
asSet of the animation
idxShapeData index within the Set#allShapes
sdthe ShapeData matching idx containing the Shape to apply this operation
at_stime delta to animation start, i.e. animation duration [s]
dt_stime delta to last call [s]
Returns
true if target animation shall continue, false otherwise

Implements com.jogamp.graph.ui.AnimGroup.LerpFunc.

Definition at line 779 of file AnimGroup.java.

Here is the call graph for this function:

The documentation for this class was generated from the following file: