ui: disable sync with model until more stable (#24984)

old-commit-hash: 338df150d5
taco
Willem Melching 3 years ago committed by GitHub
parent a643c2f597
commit 403266fdb1
  1. 17
      selfdrive/ui/qt/widgets/cameraview.cc

@ -235,10 +235,21 @@ void CameraViewWidget::paintGL() {
if (frames.empty()) return;
int frame_idx;
for (frame_idx = 0; frame_idx < frames.size() - 1; frame_idx++) {
if (frames[frame_idx].first == draw_frame_id) break;
int frame_idx = frames.size() - 1;
// Always draw latest frame until sync logic is more stable
// for (frame_idx = 0; frame_idx < frames.size() - 1; frame_idx++) {
// if (frames[frame_idx].first == draw_frame_id) break;
// }
// Log duplicate/dropped frames
static int prev_id = 0;
if (frames[frame_idx].first == prev_id) {
qInfo() << "Drawing same frame twice" << frames[frame_idx].first;
} else if (frames[frame_idx].first != prev_id + 1) {
qInfo() << "Skipped frame" << frames[frame_idx].first;
}
prev_id = frames[frame_idx].first;
glViewport(0, 0, width(), height());
glBindVertexArray(frame_vao);

Loading…
Cancel
Save