Classes | Typedefs | Enumerations | Functions

GUIDO Mapping

Classes

struct  GuidoElementInfos
class  TimeSegment
 a time segment definition and operations More...
class  MapCollector
class  RectInfos
class  TimeMapCollector

Typedefs

typedef std::vector< std::pair
< TimeSegment, FloatRect > > 
Time2GraphicMap
typedef std::pair< FloatRect,
RectInfos
MapElement

Enumerations

enum  GuidoElementSelector {
  kGuidoPage, kGuidoSystem, kGuidoSystemSlice, kGuidoStaff,
  kGuidoBar, kGuidoEvent, kGuidoScoreElementEnd
}
enum  GuidoElementType {
  kNote = 1, kRest, kEmpty, kBar,
  kRepeatBegin, kRepeatEnd, kStaff, kSystemSlice,
  kSystem, kPage
}

Functions

std::ostream & operator<< (std::ostream &out, const GuidoDate &d)
std::ostream & operator<< (std::ostream &out, const TimeSegment &s)
GuidoErrCode GuidoGetMap (CGRHandler gr, int pagenum, float width, float height, GuidoElementSelector sel, MapCollector &f)
 Retrieves the graphic to time mapping.
GuidoErrCode GuidoGetPageMap (CGRHandler gr, int pagenum, float w, float h, Time2GraphicMap &outmap)
 Retrieves a guido page graphic to time mapping.
GuidoErrCode GuidoGetStaffMap (CGRHandler gr, int pagenum, float w, float h, int staff, Time2GraphicMap &outmap)
 Retrieves a guido staff graphic to time mapping.
GuidoErrCode GuidoGetVoiceMap (CGRHandler gr, int pagenum, float w, float h, int voice, Time2GraphicMap &outmap)
 Retrieves a guido voice graphic to time mapping.
GuidoErrCode GuidoGetSystemMap (CGRHandler gr, int pagenum, float w, float h, Time2GraphicMap &outmap)
 Retrieves a guido system graphic to time mapping.
bool GuidoGetTime (const GuidoDate &date, const Time2GraphicMap map, TimeSegment &t, FloatRect &r)
 Retrieves a time segment and the associated graphic segment in a mapping.
bool GuidoGetPoint (float x, float y, const Time2GraphicMap map, TimeSegment &t, FloatRect &r)
 Retrieves a time segment and the associated graphic segment in a mapping.
GuidoErrCode GuidoGetSVGMap (GRHandler gr, int pagenum, GuidoElementSelector sel, std::vector< MapElement > &outMap) __attribute__((deprecated))
 Retrieves the graphic to time mapping corresponding to the SVG output.
GuidoErrCode GuidoGetTimeMap (CARHandler gr, TimeMapCollector &f)
 Retrieves the rolled to unrolled time mapping.

Typedef Documentation

typedef std::vector<std::pair<TimeSegment, FloatRect> > Time2GraphicMap
typedef std::pair<FloatRect, RectInfos> MapElement

Enumeration Type Documentation

Enumerator:
kGuidoPage 
kGuidoSystem 
kGuidoSystemSlice 
kGuidoStaff 
kGuidoBar 
kGuidoEvent 
kGuidoScoreElementEnd 
Enumerator:
kNote 
kRest 
kEmpty 
kBar 
kRepeatBegin 
kRepeatEnd 
kStaff 
kSystemSlice 
kSystem 
kPage 

Function Documentation

std::ostream& operator<< ( std::ostream &  out,
const GuidoDate d 
) [inline]

References GuidoDate::denom, and GuidoDate::num.

std::ostream& operator<< ( std::ostream &  out,
const TimeSegment s 
) [inline]

References TimeSegment::print().

GuidoErrCode GuidoGetMap ( 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.
selGuidoElementSelector to filter undesired objects out.
fa MapCollector object that will be called for each selected element.
Returns:
an error code.
GuidoErrCode GuidoGetPageMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
Time2GraphicMap outmap 
)

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.
outmapcontains the mapping on output.
Returns:
an error code.
GuidoErrCode GuidoGetStaffMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
int  staff,
Time2GraphicMap outmap 
)

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).
outmapcontains the mapping on output.
Returns:
an error code.
GuidoErrCode GuidoGetVoiceMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
int  voice,
Time2GraphicMap outmap 
)

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).
outmapcontains the mapping on output.
Returns:
an error code.
GuidoErrCode GuidoGetSystemMap ( CGRHandler  gr,
int  pagenum,
float  w,
float  h,
Time2GraphicMap outmap 
)

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.
outmapcontains the mapping on output.
Returns:
an error code.
bool GuidoGetTime ( 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.
bool GuidoGetPoint ( 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.
GuidoErrCode GuidoGetSVGMap ( GRHandler  gr,
int  pagenum,
GuidoElementSelector  sel,
std::vector< MapElement > &  outMap 
)

Retrieves the graphic to time mapping corresponding to the SVG output.

Parameters:
gra Guido opaque handle to a GR structure.
pagenuma page index, starting from 1.
selGuidoElementSelector to filter undesired objects out.
outMapon output: a vector containing the map elements
Returns:
an error code.
GuidoErrCode GuidoGetTimeMap ( 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.
Returns:
an error code.