mirror of
https://github.com/rene-dev/stmbl.git
synced 2026-09-22 06:44:03 +08:00
term width fix, autoconnect
This commit is contained in:
+3
-10
@@ -55,7 +55,7 @@ void BasicDrawPane::paintEvent(wxPaintEvent & evt)
|
||||
gc->SetPen(pen[i]);
|
||||
x = 0;
|
||||
y = h/2;
|
||||
xstep = w/(data[i].size()-1);
|
||||
xstep = (double)w/(double)(data[i].size()-1);
|
||||
path.MoveToPoint(x, y);
|
||||
for(auto point : data[i]){
|
||||
y = h/2-point*h/2;
|
||||
@@ -80,16 +80,9 @@ void BasicDrawPane::paintEvent(wxPaintEvent & evt)
|
||||
|
||||
void BasicDrawPane::plotvalue(float values[])
|
||||
{
|
||||
//std::cout << "data:" << value << std::endl;
|
||||
//data.at(xpos) += 0.1;
|
||||
for (int i = 0; i<channels; i++) {
|
||||
data[i].at(xpos) = (float)values[i];
|
||||
}
|
||||
xpos = (xpos+1)%data[0].size();
|
||||
//if(wxGetUTCTimeMillis()-time > 50){
|
||||
Refresh();
|
||||
// time = wxGetUTCTimeMillis();
|
||||
//}
|
||||
//oder
|
||||
//Update();
|
||||
xpos = ((int)xpos+1)%data[0].size();
|
||||
Refresh();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user