dguitar.codecs.guitarPro
Class GPChordDiagram

java.lang.Object
  extended bydguitar.codecs.guitarPro.GPChordDiagram

public class GPChordDiagram
extends java.lang.Object

This class describes a chord diagram.

Author:
Mauricio Gracia Gutierrez

Field Summary
private  int addedNote
          add: byte Allows to determine if a 'add' (added note) is present in the chord.
private  int[] barreEnds
          Barre end: List of 5 Bytes Indicates the first string of the barre, 1 being the lowest.
private  int[] barreStarts
          Barre start: List of 5 Bytes Indicates the first string of the barre, 1 being the highest.
private  int baseFret
          Base fret: Integer Shows the fret from which the chord is displayed.
private  GPChordNote bass
          Bass: Integer Lowest note of the chord.
private  boolean chordFingeringDisplayed
          ShowDiagFingering: byte if it is 0x01, the chord fingering is displayed.
private  GPChordType chordType
          Determines the chord type as followed: - 0: M - 1: 7 - 2: 7M - 3: 6 - 4: m - 5: m7 - 6: m7M - 7: m6 - 8: sus2 - 9: sus4 - 10: 7sus2 - 11: 7sus4 - 12: dim - 13: aug - 14: 5
private  GPFingering[] fingering
          Fingering: List of 7 Bytes Describes the fingering used to play the chord.
private  int[] fretOfBarres
          Fret of the barre: List of 5 Bytes Indicates the fret number of each possible barre.
private  int[] frets
          Frets: List of 7 integers.
private  boolean isSharp
          Determines if the chord is displayed sharp or flat.
private  java.lang.String name
          Name: String 20 characters long string containing the chord name.
private  int nineElevenThirteen
          Nine, Eleven of Thirteen: byte Determines if the chord goes until the ninth, the eleventh, or the thirteenth.
private  int numBarres
          Number of barres: byte Indicates the number of barres there are in the chord.
private  GPChordNote root
          The root of the Diagram (-1 for the customized chords, 0 when root is C,1 = C#...)
private  GPTonalityType tonalityEleven
          Eleventh: byte Tonality of the eleventh: 0: perfect ("juste") 1: augmented 2: diminished this tonality is valid only if the value "Nine, Eleven or Thirteen" is 13.
private  GPTonalityType tonalityFive
          Fifth: byte Tonality of the fifth: 0: perfect ("juste") 1: augmented 2: diminished
private  GPTonalityType tonalityNine
          Ninth: byte Tonality of the ninth: 0: perfect ("juste") 1: augmented 2: diminished this tonality is valid only if the value "Nine, Eleven or Thirteen" is 11 or 13.
private  GPTonalityType tonalityType
          Diminished/Augmented Integer Tonality linked with 9/11/13: 0: perfect ("juste") 1: augmented 2: diminished
 
Constructor Summary
GPChordDiagram()
          Creates a new instance of ChordDiagram
 
Method Summary
 void setAddedNote(int addedNote)
           
 void setBarreEnd(int pos, int barre)
           
 void setBarreStart(int pos, int barre)
           
 void setBaseFret(int baseFret)
           
 void setBass(GPChordNote bass)
           
 void setchordFingeringDisplayed(boolean value)
           
 void setChordType(GPChordType CT)
           
 void setFingering(int pos, int finger)
           
 void setFret(int pos, int fret)
           
 void setFretOfBarre(int pos, int fret)
           
 void setName(java.lang.String name)
           
 void setNineElevenThirteen(int NET)
           
 void setNumBarres(int numBarres)
           
 void setRoot(GPChordNote root)
           
 void setSharp(boolean isSharp)
           
 void setTonalityEleven(GPTonalityType TT)
           
 void setTonalityFive(GPTonalityType TT)
           
 void setTonalityNine(GPTonalityType TT)
           
 void setTonalityType(GPTonalityType TT)
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

isSharp

private boolean isSharp
Determines if the chord is displayed sharp or flat.


root

private GPChordNote root
The root of the Diagram (-1 for the customized chords, 0 when root is C,1 = C#...)


chordType

private GPChordType chordType
Determines the chord type as followed: - 0: M - 1: 7 - 2: 7M - 3: 6 - 4: m - 5: m7 - 6: m7M - 7: m6 - 8: sus2 - 9: sus4 - 10: 7sus2 - 11: 7sus4 - 12: dim - 13: aug - 14: 5


nineElevenThirteen

private int nineElevenThirteen
Nine, Eleven of Thirteen: byte Determines if the chord goes until the ninth, the eleventh, or the thirteenth.


bass

private GPChordNote bass
Bass: Integer Lowest note of the chord. It gives the chord inversions.


tonalityType

private GPTonalityType tonalityType
Diminished/Augmented Integer Tonality linked with 9/11/13: 0: perfect ("juste") 1: augmented 2: diminished


addedNote

private int addedNote
add: byte Allows to determine if a 'add' (added note) is present in the chord.


name

private java.lang.String name
Name: String 20 characters long string containing the chord name.


tonalityFive

private GPTonalityType tonalityFive
Fifth: byte Tonality of the fifth: 0: perfect ("juste") 1: augmented 2: diminished


tonalityNine

private GPTonalityType tonalityNine
Ninth: byte Tonality of the ninth: 0: perfect ("juste") 1: augmented 2: diminished this tonality is valid only if the value "Nine, Eleven or Thirteen" is 11 or 13.


tonalityEleven

private GPTonalityType tonalityEleven
Eleventh: byte Tonality of the eleventh: 0: perfect ("juste") 1: augmented 2: diminished this tonality is valid only if the value "Nine, Eleven or Thirteen" is 13.


baseFret

private int baseFret
Base fret: Integer Shows the fret from which the chord is displayed.


frets

private int[] frets
Frets: List of 7 integers. Corresponds to the fret number played on each string, from the highest to the lowest. -1 means a string unplayed. 0 means a string played "blank" (ie no fret).


numBarres

private int numBarres
Number of barres: byte Indicates the number of barres there are in the chord. A chord can contain up to 5 barres.


fretOfBarres

private int[] fretOfBarres
Fret of the barre: List of 5 Bytes Indicates the fret number of each possible barre.


barreStarts

private int[] barreStarts
Barre start: List of 5 Bytes Indicates the first string of the barre, 1 being the highest. The list order matches the chord different barres frets list order.


barreEnds

private int[] barreEnds
Barre end: List of 5 Bytes Indicates the first string of the barre, 1 being the lowest. The list order matches the chord different barres frets list order.


fingering

private GPFingering[] fingering
Fingering: List of 7 Bytes Describes the fingering used to play the chord. Below is given the fingering from the highest string to the lowest: -2: unknown; -1: X or 0 (no finger); 0: thumb; 1: index; 2: middle finger; 3: annular; 4: little finger.


chordFingeringDisplayed

private boolean chordFingeringDisplayed
ShowDiagFingering: byte if it is 0x01, the chord fingering is displayed. if it is 0x00, the chord fingering is masked.

Constructor Detail

GPChordDiagram

public GPChordDiagram()
Creates a new instance of ChordDiagram

Method Detail

setSharp

public void setSharp(boolean isSharp)

setRoot

public void setRoot(GPChordNote root)

setChordType

public void setChordType(GPChordType CT)

setNineElevenThirteen

public void setNineElevenThirteen(int NET)

setBass

public void setBass(GPChordNote bass)

setTonalityType

public void setTonalityType(GPTonalityType TT)

setAddedNote

public void setAddedNote(int addedNote)

setName

public void setName(java.lang.String name)

setTonalityFive

public void setTonalityFive(GPTonalityType TT)

setTonalityNine

public void setTonalityNine(GPTonalityType TT)

setTonalityEleven

public void setTonalityEleven(GPTonalityType TT)

setBaseFret

public void setBaseFret(int baseFret)

setFret

public void setFret(int pos,
                    int fret)

setNumBarres

public void setNumBarres(int numBarres)

setFretOfBarre

public void setFretOfBarre(int pos,
                           int fret)

setBarreStart

public void setBarreStart(int pos,
                          int barre)

setBarreEnd

public void setBarreEnd(int pos,
                        int barre)

setFingering

public void setFingering(int pos,
                         int finger)

setchordFingeringDisplayed

public void setchordFingeringDisplayed(boolean value)

toString

public java.lang.String toString()