Revision 9cb381ec server/src/Utterance.cpp
server/src/Utterance.cpp | ||
---|---|---|
72 | 72 |
|
73 | 73 |
//fetch first end time |
74 | 74 |
symbol_duration_pair_t symbol_duration_pair = *phonemes_vector_iterator; |
75 |
symbol_end_time = get_system_time() + boost::posix_time::milliseconds(symbol_duration_pair.second);
|
|
75 |
symbol_end_time = std::chrono::steady_clock::now() + std::chrono::milliseconds(symbol_duration_pair.second);
|
|
76 | 76 |
|
77 | 77 |
printf("> we have %d pairs\n",(int)phonemes_vector.size()); |
78 | 78 |
|
... | ... | |
87 | 87 |
//empty phoneme list |
88 | 88 |
if (phonemes_vector.size() == 0) return ""; |
89 | 89 |
|
90 |
system_time now = get_system_time();
|
|
90 |
std::chrono::time_point<std::chrono::steady_clock> now = std::chrono::steady_clock::now();
|
|
91 | 91 |
|
92 | 92 |
while(now > symbol_end_time){ |
93 | 93 |
//fetch next phoneme: |
94 | 94 |
symbol_duration_pair_t symbol_duration_pair = *phonemes_vector_iterator; |
95 |
symbol_end_time = symbol_end_time + boost::posix_time::milliseconds(symbol_duration_pair.second);
|
|
95 |
symbol_end_time = symbol_end_time + std::chrono::milliseconds(symbol_duration_pair.second);
|
|
96 | 96 |
//printf("time: %d", symbol_duration_pair.second); |
97 | 97 |
|
98 | 98 |
//do we have to increment the iterator or are we done? (NOTE: -1 is necessary here!) |
Also available in: Unified diff