mirror of
https://github.com/sunnypilot/sunnypilot.git
synced 2026-02-23 18:43:54 +08:00
* cleanup include path
* continue
* format includes
* fix testraw.cc
* remove include path from SConstruct
* regroup
* rebase master
* almost done
* apply review
* rename FileReader.xx to filereader.xx
* rename Unlogger.x->unlogger.x
* rename FrameReader.xx -> framereader.xx
* apply reviews
* ui.h
* continue
* fix framebuffer.cc build error:mv util.h up
* full path to msm_media_info
* fix qcom2 camerad
Co-authored-by: Comma Device <device@comma.ai>
old-commit-hash: 7222d0f20d
32 lines
896 B
C++
32 lines
896 B
C++
#include <QApplication>
|
|
#include <QSslConfiguration>
|
|
|
|
#include "selfdrive/hardware/hw.h"
|
|
#include "selfdrive/ui/qt/qt_window.h"
|
|
#include "selfdrive/ui/qt/window.h"
|
|
|
|
int main(int argc, char *argv[]) {
|
|
QSurfaceFormat fmt;
|
|
#ifdef __APPLE__
|
|
fmt.setVersion(3, 2);
|
|
fmt.setProfile(QSurfaceFormat::OpenGLContextProfile::CoreProfile);
|
|
fmt.setRenderableType(QSurfaceFormat::OpenGL);
|
|
#else
|
|
fmt.setRenderableType(QSurfaceFormat::OpenGLES);
|
|
#endif
|
|
QSurfaceFormat::setDefaultFormat(fmt);
|
|
|
|
if (Hardware::EON()) {
|
|
QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
|
|
QSslConfiguration ssl = QSslConfiguration::defaultConfiguration();
|
|
ssl.setCaCertificates(QSslCertificate::fromPath("/usr/etc/tls/cert.pem"));
|
|
QSslConfiguration::setDefaultConfiguration(ssl);
|
|
}
|
|
|
|
QApplication a(argc, argv);
|
|
MainWindow w;
|
|
setMainWindow(&w);
|
|
a.installEventFilter(&w);
|
|
return a.exec();
|
|
}
|