fix kx bugs
git-svn-id: svn://db.shs.com.ru/libs@8 a8b55f48-bf90-11e4-a774-851b48703e85
This commit is contained in:
@@ -126,12 +126,14 @@ void KX_Coefficients::received(bool correct) {
|
||||
return;
|
||||
};
|
||||
}
|
||||
if (k_syns.first_index < 0 || k_syns.count < 0) return;
|
||||
if (k_syns.first_index == 0) {
|
||||
//cout << "first receive\n";
|
||||
k_tmp.resize(k_syns.full_count);
|
||||
received_cnt = 0;
|
||||
}
|
||||
//for (int i = 0; i < k_syns.count; i++) K.at(k_syns.first_index + i) = k_syns.coeffs[i];
|
||||
//piCout << k_tmp.size() << k_syns.first_index << k_syns.count;
|
||||
memcpy(k_tmp.data(k_syns.first_index), k_syns.coeffs, k_syns.count);
|
||||
received_cnt += k_syns.count;
|
||||
tm.reset();
|
||||
@@ -168,7 +170,7 @@ void KX_Coefficients::renew() {
|
||||
|
||||
void KX_Coefficients::tick(void * , int ) {
|
||||
//piCout << "timer" << tm.elapsed_s();
|
||||
if (tm.elapsed_s() < 2.) return;
|
||||
if (tm.elapsed_s() < 10.) return;
|
||||
if (waitingCommit) {
|
||||
//cout << "commit timeout\n";
|
||||
//cout << "send failed\n";
|
||||
|
||||
Reference in New Issue
Block a user