Package guidoengine

Class guidoscore


  • public class guidoscore
    extends guidoscorebase
    The main score API.
    Add extended API to draw score on a bitmap with a native device and draw the bitmap in a java.awt.Graphics object.
    • Constructor Detail

      • guidoscore

        public guidoscore()
      • guidoscore

        public guidoscore​(long ar)
    • Method Detail

      • GetBitmap

        public final int GetBitmap​(int[] dst,
                                   int w,
                                   int h,
                                   guidodrawdesc desc,
                                   guidopaint area,
                                   java.awt.Color color)
        Draws the score into a bitmap. Actually, draws the score to an offscreen that is next copied to the destination bitmap. It use native system of the device, so it's not implemented if a the GuidoEngine library is build with INDEPENDENSVG option, like in android platform.
        Parameters:
        dst - the destination bitmap ARGB array
        w - the bitmap width
        h - the bitmap height
        desc - the score drawing descriptor
        area - clipping description
        color - the color used to draw the score
        Returns:
        a Guido error code.
        See Also:
        guidodrawdesc, guidopaint
      • Draw

        public int Draw​(java.awt.Graphics g,
                        int w,
                        int h,
                        guidodrawdesc desc,
                        guidopaint area)
        Draws the score. Drawing the score should be typically called from the paint method of a Canvas. It use native system of the device, so it's not implemented if a the GuidoEngine library is build with INDEPENDENSVG option.
        Parameters:
        g - a Graphics
        w - the desired drawing width
        h - the desired drawing heigth
        desc - the score drawing descriptor
        area - clipping description
        Returns:
        a Guido error code.
        See Also:
        guidodrawdesc, guidopaint
      • Draw

        public int Draw​(java.awt.Graphics g,
                        int w,
                        int h,
                        guidodrawdesc desc,
                        guidopaint area,
                        java.awt.Color color)
        Draws the score. Drawing the score should be typically called from the paint method of a Canvas. It use native system of the device, so it's not implemented if a the GuidoEngine library is build with INDEPENDENSVG option.
        Parameters:
        g - a Graphics
        w - the desired drawing width
        h - the desired drawing height
        desc - the score drawing descriptor
        area - clipping description
        color - the color used to draw the score
        Returns:
        a Guido error code.
        See Also:
        guidodrawdesc, guidopaint
      • Draw

        public int Draw​(java.awt.Graphics g,
                        int top,
                        int left,
                        int w,
                        int h,
                        guidodrawdesc desc,
                        guidopaint area,
                        java.awt.Color color)
        Draws the score. Drawing the score should be typically called from the paint method of a Canvas. It use native system of the device, so it's not implemented if a the GuidoEngine library is build with INDEPENDENSVG option.
        Parameters:
        g - a Graphics
        top - the top coordinate to begin to draw the image
        left - the left coordinate to begin to draw the image
        w - the desired drawing width
        h - the desired drawing height
        desc - the score drawing descriptor
        area - clipping description
        color - the color used to draw the score
        Returns:
        a Guido error code.
        See Also:
        guidodrawdesc, guidopaint