Fix warning "Painter path exceeds +/-32767 pixels."
In this case OpenGL requires using a stencil buffer. --HG-- branch : develop
This commit is contained in:
parent
ffdf42cc7a
commit
fc92fd4824
|
@ -418,11 +418,16 @@ VMainGraphicsView::VMainGraphicsView(QWidget *parent)
|
|||
QOpenGLWidget *viewport = new QOpenGLWidget();
|
||||
QSurfaceFormat fmt;
|
||||
fmt.setSamples(settings->GetGraphicalOutput() ? 10 : 0);
|
||||
fmt.setStencilBufferSize(8);
|
||||
viewport->setFormat(fmt);
|
||||
|
||||
setViewport(viewport);
|
||||
#else
|
||||
setViewport(new QGLWidget(QGLFormat(QGL::DoubleBuffer|QGL::SampleBuffers)));
|
||||
QGLWidget *viewport = new QGLWidget();
|
||||
QGLFormat fmt = QGLFormat(QGL::DoubleBuffer|QGL::SampleBuffers);
|
||||
fmt.setStencilBufferSize(8);
|
||||
viewport->setFormat(fmt);
|
||||
setViewport(viewport);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user