mirror of
https://github.com/MoreTore/openpilot.git
synced 2026-08-03 08:41:47 +08:00
visionipc connect, make sure opengl context is current
old-commit-hash: b67fed87ba
This commit is contained in:
@@ -243,6 +243,11 @@ void GLWindow::backlightUpdate() {
|
||||
}
|
||||
|
||||
void GLWindow::timerUpdate() {
|
||||
// Connecting to visionIPC requires opengl to be current
|
||||
if (!ui_state.vipc_client->connected){
|
||||
makeCurrent();
|
||||
}
|
||||
|
||||
if (ui_state.started != onroad) {
|
||||
onroad = ui_state.started;
|
||||
emit offroadTransition(!onroad);
|
||||
@@ -262,7 +267,6 @@ void GLWindow::paintGL() {
|
||||
if(GLWindow::ui_state.awake){
|
||||
ui_draw(&ui_state);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
void GLWindow::wake() {
|
||||
|
||||
Reference in New Issue
Block a user