Fret Class

The Fret class is from derived from VObject. It models a guitar fret. It provides variables for storing the fret's number and relative location. It overrides two functions inherited from VObject allowing the positional information to be used when visualizing the fret.

Defined in: fret.hpp and fret.cpp

Class Members

Data Members

public

unsigned short number

The number of the fret.

float xPosition

Its relative position on the fretboard.

Member Functions

public

Fret (void)

Constructs a Fret object.

Fret (unsigned short fret_nunber, float x_position)

Constructs a Fret object with the specified number and position.

Fret (const Fret & fret)

Constructs a Fret object that is a copy of the specified Fret.

virtual ~Fret (void)

Fret destructor

Fret & operator= (const Fret & fret)

Assignment operator.

bool operator== (const Fret & fret)

Equality operator.

virtual unsigned short getPosition (float x_origin, float y_origin, float & object_x, float & object_y, unsigned short coord_type)

Overrides VObject's getPosition to return positional information about the object.

virtual unsigned short setPosition (float x_origin, float y_origin, float object_x, float object_y, unsigned short coord_type)

Overrides VObject's setPosition to set an object's  positional information.

Copyright 2002-2007 Outerface Technologies, Inc.