public class Renderer.Measure extends Renderer.Inner
TimedObject
, by INTERNAL
BarLine
, or by TERMINAL MeasureMark
. This includes
the start time of the next measure.
Modifier and Type | Field and Description |
---|---|
protected float[][] |
allAdd
Contains constant distance for "pre-prended" objects; "[i][j]" starts
"before column i" and ends "before column j".
|
protected Parameters.Distances[] |
allProp
Contains maximal values of best/minimal width of ALL TimedObjects at this
tnum.
|
protected float |
bestEffect |
protected float |
bestFactor |
protected float |
bestWidth |
java.util.List<java.lang.Float> |
colnum2finalPos |
(package private) int |
count_cols |
(package private) int |
count_tps |
protected Renderer.PointwiseLinear |
effect2factor |
protected Renderer.PointwiseLinear |
factor2effect |
protected java.util.Map<Renderer.Segment,java.lang.Integer> |
firstIndex
Map every segment to the last and first element index falling into this measure.
|
protected java.util.Map<Renderer.Segment,java.lang.Integer> |
lastIndex
Map every segment to the last and first element index falling into this measure.
|
protected float |
minEffect |
protected float |
minFactor |
protected float |
minWidth |
protected java.math.BigDecimal |
number |
protected float |
realFactor |
protected float |
realLength |
protected java.util.List<java.lang.Float> |
tnum2abstractPos |
protected java.util.List<Rational> |
tnum2tp |
protected java.util.Map<Rational,java.lang.Float> |
tp2abstractPos |
protected java.util.Map<Rational,java.lang.Integer> |
tp2tnum |
protected java.util.SortedSet<Rational> |
tps
All Tps from all Segments, explicitly def'd in some TimedObject in this measure.
|
Constructor and Description |
---|
Measure() |
Modifier and Type | Method and Description |
---|---|
(package private) void |
calculateRelativePositions()
Find a mapping from the measure relative time points (in Rational)
to percentages of a graphical distance.
|
(package private) void |
calculateStretching(Renderer.NoteSystem noteSystem)
Collects all min distances and calculates best/min stretch factor,
which would result in the best/min distances.
|
int |
findLatestElement(Staff staff,
Rational limit)
returns the index of the latest and right-most element which is
earlier or equal to the given time point "limit".
|
int |
findLatestStaffLines(Staff staff,
Rational when)
Returns the index of the latest StaffLines element which is
valid at the given time point "when".
|
(package private) void |
fixFactor(float factor)
Stores final layout result columns2finalpos.
|
protected int |
tp2col(Rational tp,
boolean isBarLine)
0/1 1/4 2/4 3/4 4/4 <--tp
(b0/1) e0/1 e1/4 b2/4 e2/4 e3/4 b4/4=b0/1 <--barline or event
0 1 2 3 4 <--tnum
0 2 3 4 6 7(=8) <--colnum
| | | : | | ||
| x x : x x ||
| : ||
allAdd:
----------[4][3]
-----[3][3]
-------------[3][2]
--------------------[3][0]
-----[2][2]
------------[2][0]
------[0][0]
|
get_renderer
protected java.math.BigDecimal number
protected java.util.Map<Renderer.Segment,java.lang.Integer> firstIndex
protected java.util.Map<Renderer.Segment,java.lang.Integer> lastIndex
protected java.util.SortedSet<Rational> tps
protected java.util.Map<Rational,java.lang.Float> tp2abstractPos
protected java.util.List<Rational> tnum2tp
protected java.util.Map<Rational,java.lang.Integer> tp2tnum
protected java.util.List<java.lang.Float> tnum2abstractPos
public java.util.List<java.lang.Float> colnum2finalPos
int count_tps
int count_cols
protected float[][] allAdd
protected Parameters.Distances[] allProp
protected float minFactor
protected float bestFactor
protected float minWidth
protected float bestWidth
protected float minEffect
protected float bestEffect
protected float realLength
protected float realFactor
protected Renderer.PointwiseLinear factor2effect
protected Renderer.PointwiseLinear effect2factor
protected int tp2col(Rational tp, boolean isBarLine)
0/1 1/4 2/4 3/4 4/4 <--tp (b0/1) e0/1 e1/4 b2/4 e2/4 e3/4 b4/4=b0/1 <--barline or event 0 1 2 3 4 <--tnum 0 2 3 4 6 7(=8) <--colnum | | | : | | || | x x : x x || | : || allAdd: ----------[4][3] -----[3][3] -------------[3][2] --------------------[3][0] -----[2][2] ------------[2][0] ------[0][0]ATTENTION ASSERT no spontanuous bar line before first event (at 0/1)!
void calculateRelativePositions()
void calculateStretching(Renderer.NoteSystem noteSystem)
| | <- tnum2tp / Tps ====== ======= <- TimedObject --- <- distances proportional -- - <- distances additiv PPPP PP <- Prepended/PostpendedEach Tp is realized by TWO "columns" FIXME MEHR: ??? FIXME ALT ?? All timepoints have been collected in RunningPrefix.positions[segment].
void fixFactor(float factor)
public int findLatestElement(Staff staff, Rational limit)