-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathsyllable.c
50 lines (43 loc) · 1.31 KB
/
syllable.c
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
#include <string.h>
#include "syllable.h"
/***********************************************************************************//**
* ctor
**************************************************************************************/
cSyllable::cSyllable( )
{
Erase( );
}
/***********************************************************************************//**
* dtor
**************************************************************************************/
cSyllable::~cSyllable( )
{
}
/***********************************************************************************//**
* initialise a void syllable
**************************************************************************************/
void cSyllable::Erase( void )
{
m_theSyllable[0] = 0;
m_start = 0;
m_duration = 0;
m_note = 0;
}
/***********************************************************************************//**
* define a syllable
*
* @param [in] start :
* @param [in] duration :
* @param [in] note :
* @param [in] syllable :
*
* @return : 1
**************************************************************************************/
int cSyllable::Set( int start, int duration, int note, const char *syllable )
{
strncpy( m_theSyllable, syllable, MAXCHARSYLLABLE-1 );
m_start = start;
m_duration = duration;
m_note = note;
return ( 1 );
}