GUIDOLib  1.7.7
A Music Score Rendering Engine
Functions | Variables
Guido Score Map Adapter

A C++ interface to the Guido score map API. More...

Functions

virtual ~GuidoScoreMapAdapter ()
 
GuidoErrCode getMap (CGRHandler gr, int pagenum, float width, float height, GuidoElementSelector sel, MapCollector &f)
 Retrieves the graphic to time mapping. More...
 
Time2GraphicMap getPageMap (CGRHandler gr, int pagenum, float w, float h)
 Retrieves a guido page graphic to time mapping. More...
 
Time2GraphicMap getStaffMap (CGRHandler gr, int pagenum, float w, float h, int staff)
 Retrieves a guido staff graphic to time mapping. More...
 
Time2GraphicMap getVoiceMap (CGRHandler gr, int pagenum, float w, float h, int voice)
 Retrieves a guido voice graphic to time mapping. More...
 
Time2GraphicMap getSystemMap (CGRHandler gr, int pagenum, float w, float h)
 Retrieves a guido system graphic to time mapping. More...
 
bool getTime (const GuidoDate &date, const Time2GraphicMap map, TimeSegment &t, FloatRect &r)
 Retrieves a time segment and the associated graphic segment in a mapping. More...
 
bool getPoint (float x, float y, const Time2GraphicMap map, TimeSegment &t, FloatRect &r)
 Retrieves a time segment and the associated graphic segment in a mapping. More...
 
GuidoErrCode getTimeMap (CARHandler gr, TimeMapCollector &f)
 Retrieves the rolled to unrolled time mapping. More...
 
TTime2TimeMap getTime2TimeMap (CARHandler ar)
 

Variables

class_export GuidoScoreMapAdapter
 

Detailed Description

A C++ interface to the Guido score map API.

A C++ class to manipulate score map of GuidoEngine.

Function Documentation

◆ getMap()

GuidoErrCode getMap ( CGRHandler  gr,
int  pagenum,
float  width,
float  height,
GuidoElementSelector  sel,
MapCollector f 
)

Retrieves the graphic to time mapping.

Parameters
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
widththe page width.
heightthe page height.
selGuidoeElementSelector to filter undesired objects out.
fa MapCollector object that will be called for each selected element or null if error
Returns
a Guido error code

◆ getPageMap()

Time2GraphicMap getPageMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h 
)

Retrieves a guido page graphic to time mapping.

Parameters
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
wthe page width.
hthe page height.
Returns
contains the mapping on output or null if error

◆ getPoint()

bool getPoint ( float  x,
float  y,
const Time2GraphicMap  map,
TimeSegment t,
FloatRect &  r 
)

Retrieves a time segment and the associated graphic segment in a mapping.

Parameters
xa point x coordinate
ya point y coordinate
mapa time to graphic map.
ron output, the graphic segment containing the point (note that segments are right and bottom opened)
ton output, the time segment associated to the graphic segment
Returns
false when there is no segment containing the point.

◆ getStaffMap()

Time2GraphicMap getStaffMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
int  staff 
)

Retrieves a guido staff graphic to time mapping.

Parameters
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
wthe page width.
hthe page height.
staffthe staff index (starting from 1).
Returns
outmap contains the mapping on output or null if error

◆ getSystemMap()

Time2GraphicMap getSystemMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h 
)

Retrieves a guido system graphic to time mapping.

Parameters
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
wthe page width.
hthe page height.
Returns
outmap contains the mapping on output or null if error

◆ getTime()

bool getTime ( const GuidoDate date,
const Time2GraphicMap  map,
TimeSegment t,
FloatRect &  r 
)

Retrieves a time segment and the associated graphic segment in a mapping.

Parameters
datea date used to select the container time segment
mapa time to graphic map.
ton output, the time segment containing the date (note that segments are right opened)
ron output, the graphic segment associated to the time segment
Returns
false when there is no segment containing the date.

◆ getTime2TimeMap()

TTime2TimeMap getTime2TimeMap ( CARHandler  ar)

◆ getTimeMap()

GuidoErrCode getTimeMap ( CARHandler  gr,
TimeMapCollector f 
)

Retrieves the rolled to unrolled time mapping.

Parameters
gra Guido opaque handle to a GR structure.
fa TimeMapCollector object that will be called for each time segment or null if error.
Returns
a Guido error code

◆ getVoiceMap()

Time2GraphicMap getVoiceMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
int  voice 
)

Retrieves a guido voice graphic to time mapping.

Parameters
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
wthe page width.
hthe page height.
voicethe voice index (starting from 1).
Returns
outmap contains the mapping on output or null if error

◆ ~GuidoScoreMapAdapter()

virtual ~GuidoScoreMapAdapter ( )
virtual

Variable Documentation

◆ GuidoScoreMapAdapter

class_export GuidoScoreMapAdapter
Initial value:
GuidoScoreMapAdapter
class_export GuidoScoreMapAdapter
Definition: GUIDOScoreMapAdapter.h:43

Guido Project Copyright © 2019 Grame-CNCM