Package eu.bandm.music.top
Class SvgSource.ParamTranslate
java.lang.Object
eu.bandm.music.top.SvgSource.ParamTranslate
- Enclosing class:
SvgSource
Visits all events of a given iterator pairwise and writes out the
Svg/Smil commands.
"animateColor()" seems not necessary (even in examples in the w3c SVG docu!-)
"set()" does NOT affect settings of "@transform".
In the code generation scheme, the target value of an interpolation process is already encoded with the command starting the interpoloation. In non-interpolation, a "set value" command is generated at the time of the event. Symbolically:
#0 #1 #2 #3 first(): prepare registers pairwise(): \-------/ ipol==true v0=====>v1... ipol==false v0!... pairwise(): \--------/ ipol==true v1=======>v2... left value == reachedValue --> NOP (No need for a command iff value simply STAYS!) ipol==false v1!... pairwise(): \--------/ etc. last() AND ipol=false: v3!...ATTENTION:
"animateColor()" seems not necessary (even in examples in the w3c SVG docu!-)
"set()" does NOT affect settings of "@transform".
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected double
protected String
protected final String
protected boolean
Whether between the earlier and later event inpairwise(Event,Event)
an interpolation is requested by the tscore source data.protected final boolean
protected final String
protected final String
protected double
protected String
Value currently valid in the state of the Svg/Smil processor, either as the endpoint of an interpolation, or set and held as a constant. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Here: Prepare the registers for the first call topairwise(Event,Event)
.void
.void
Here: Generate either the source text which describes the interpolation between both events, or one which sets the parameter value only of the earlier event.void
process()
protected double
protected void
writeSet()
Generate the source text which sets the parameter value only of the earlier event.
-
Field Details
-
data
-
ipoltable
-
paramType
-
paramName
-
indent
-
isTransform
protected final boolean isTransform -
getParamValue
-
reachedValue
Value currently valid in the state of the Svg/Smil processor, either as the endpoint of an interpolation, or set and held as a constant. -
predecValue
-
currentValue
-
predecTime
protected double predecTime -
currentTime
protected double currentTime -
ipol
protected boolean ipolWhether between the earlier and later event inpairwise(Event,Event)
an interpolation is requested by the tscore source data.
-
-
Constructor Details
-
ParamTranslate
-
-
Method Details
-
process
public void process() -
time
-
first
Here: Prepare the registers for the first call topairwise(Event,Event)
. -
writeSet
protected void writeSet()Generate the source text which sets the parameter value only of the earlier event.ATTENTION, HACK: "set" does not work with "@transform", so we use a VERY FAST animation.
-
pairwise
Here: Generate either the source text which describes the interpolation between both events, or one which sets the parameter value only of the earlier event. Before processing,predecTime
andpredecValue
correspond to the earlier event. After processing,predecTime
andpredecValue
correspond to the later event = are prepared for the next cyclic call of this method. -
last
. Here: If the very last event's parameter is not reached by the last interpolation, then generate a "setValue" smil event.
-