GUIDOLib
1.7.7
A Music Score Rendering Engine
|
This section provides examples of the GUIDO library use.
Displaying a score
#include <iostream>
#include "GDevicePostScript.h"
using namespace std;
void DrawGMNFile (const char * filename)
{
GDevicePostScript dev ((int)(21*72/2.54), (int)(29.7*72/2.54), "outfile.eps", "", "");
}
int main(int argc, char **argv)
{
const char * file = argv[1];
DrawGMNFile (file);
return 0;
}
Building music using the GUIDO Factory
void TestGuidoFactory()
{
if( gr )
{
}
}
A data structure containing all information required by GuidoInit()
Definition: GUIDOEngine.h:49
int scrolly
Definition: GUIDOEngine.h:169
Contains all graphic-related information required by GuidoOnDraw()
Definition: GUIDOEngine.h:152
GuidoErrCode GuidoFactoryOpen(ARFactoryHandler *outFactory)
Opens the Guido Factory.
GuidoErrCode GuidoFactoryOpenEvent(ARFactoryHandler inFactory, const char *inEventName)
Creates and opens a new event (note or rest).
GuidoErrCode GuidoFactoryAddFlat(ARFactoryHandler inFactory)
Add a flat to the current event.
GuidoErrCode GuidoFactoryOpenVoice(ARFactoryHandler inFactory)
Creates and opens a new voice.
void GuidoFactoryClose(ARFactoryHandler inFactory)
Closes the Guido Factory.
void * ARFactoryHandler
Definition: GUIDOFactory.h:48
GuidoErrCode GuidoInit(GuidoInitDesc *desc)
int sizey
Definition: GUIDOEngine.h:176
GuidoErrCode GuidoFactoryOpenMusic(ARFactoryHandler inFactory)
Creates and opens a new music score.
GuidoErrCode GuidoFactoryAddSharp(ARFactoryHandler inFactory)
Adds a sharp to the current event.
GRHandler handle
A Guido handler to a graphic representation.
Definition: GUIDOEngine.h:155
GPaintStruct updateRegion
Indicates what to (re)draw.
Definition: GUIDOEngine.h:162
ARHandler GuidoFactoryCloseMusic(ARFactoryHandler inFactory)
Closes the current music score.
struct NodeGR * GRHandler
Definition: GUIDOEngine.h:37
GuidoErrCode GuidoParseFile(const char *filename, ARHandler *ar) GUIDOAPI_deprecated
VGDevice * hdc
A graphic device context.
Definition: GUIDOEngine.h:158
int page
The page number. Starts from 1.
Definition: GUIDOEngine.h:160
GuidoErrCode GuidoFactoryCloseEvent(ARFactoryHandler inFactory)
Closes the current event.
struct NodeAR * ARHandler
Definition: GUIDOEngine.h:36
bool erase
a flag to ignore the following rect and to redraw everything
Definition: GUIDOEngine.h:67
GuidoErrCode GuidoFactoryCloseVoice(ARFactoryHandler inFactory)
Closes the current voice.
GuidoErrCode GuidoAR2GR(ARHandler ar, const GuidoLayoutSettings *settings, GRHandler *gr)
int sizex
Definition: GUIDOEngine.h:176
int scrollx
Definition: GUIDOEngine.h:169