Class Score_hkn_svg_v00

java.lang.Object
eu.bandm.music.haken.Score_hkn
eu.bandm.music.haken.Score_hkn_svg_v00

public class Score_hkn_svg_v00 extends Score_hkn
A first version of a haken score for realization with svg geometric forms. Input is dura=duration, color = red/yellow/green, pos=bottom/middle/top, size=tiny/middle/large, form=circle, sixside, triangle
Usage: create a new instance with an already raw-parsed TimeScape; then call update(...) with the six(6) selected voices.
The main(String[]) method takes filenames and voice names from the command line parameters.

See SvgSource for documentation on the generation of dynamic SVG. That class is NOT used here because this class extends Score_hkn instead.
FIXME PAUSENMODUS einstellbar
FIXME Allerletzte taktnummernanzeige
  • Field Details

    • punit

      static final String punit
      Source text for "pixel" as an appended unit string.
      See Also:
    • screensize

      public static final int screensize
      Upper limit of (physical) device coordinates, in "pt" = "points".
      See Also:
    • fixedDuration

      public static final float fixedDuration
      Duration how long each graphical state will be presented. (Can effectively be enhanced by "non-dark-pauses").
      See Also:
    • pauseDuras

      public static final float[] pauseDuras
      Durations for pauses p0..p4
    • maxPause

      public final int maxPause
      Max index into pauseDuras
    • pauseDark

      public static final float pauseDark
      Only pause durations ABOVE this value will be dark.
      See Also:
    • poss

      public static final int[] poss
      Values for vertical and horizontal positions by U,M and O.
    • forms

      public static final String[] forms
      Values for graphical form, by U,M and O.
    • formEnd

      public static final String[] formEnd
      Svg source text to end the graphical form, by U,M and O.
    • scaleString

      public static final String[] scaleString
      Values for size, by U,M and O.
    • colorString

      public static final String[] colorString
      Values for colors: green/yellow/red by U,M and O.
  • Constructor Details

  • Method Details

    • fromTimeScape

      FIXME DOC
    • polyPoints

      protected static String polyPoints(int n)
      Create a polygon with radius = 100. COPIED from MovingForms FIXME
    • update

      public void update(PrintWriter pw, String title, @Opt @Opt String subtitle, @Opt @Opt Vox vpause, @Opt @Opt Vox vx, @Opt @Opt Vox vy, @Opt @Opt Vox vcol, @Opt @Opt Vox vsiz, @Opt @Opt Vox vfrm)
      Convert the K-voices and write out to file.
      Parameters:
      pw - where to write the result
      title - for generating html title only
      subtitle - currently not used
      vpause - K-voice controling additional pauses, may be ==null
      vx - K-voice controling the x coordinate, may be ==null
      vy - K-voice controling the y coordinate, may be ==null
      vcol - K-voice controling the color, may be ==null
      vsiz - K-voice controling the size, may be ==null
      vfrm - K-voice controling the form, may be ==null
    • getPauseByIndex

      protected float getPauseByIndex(List<Tp> tps, Vox vpause, int i)
      Pause stands with a K-Event and means a Pause BEFORE this event start.
    • printTopTp

      protected void printTopTp(PrintWriter pw, float start, float end, @Opt @Opt Integer barNum)
      Enter the dynamic display of the top tp (measure number) into the source text. (Cf. the svg docu concerning text http://svg.tutorial.aptico.de/start2.php?knr=8&kname=Text
    • main

      public static void main(String[] args)
      Main method, translates input file in HKN-vox format to svg output file.
      Parameters:
      args -
      [0] input file name
      [1] basic score name (appending ".svg" gives the output file name)
      [2] "subtitle", second part of html title ("-" stands for "none", first part is stem name of the outputfile) (FIXME source file inidication in generated comment still missing.)
      [3] name of pause voice ("-" stands for "none")
      [4] name of H-Voice for "xpos"
      [5] name of H-Voice for "ypos"
      [6] name of H-Voice for "color"
      [7] name of H-Voice for "size"
      [8] name of H-Voice for "form"