Details
-
Bug
-
Resolution: Duplicate
-
P3: Somewhat important
-
5.9.1
-
None
-
Windows 7 64-bit, MSVC2015 64-bit, tested with Nvidia and Intel GPUs.
Description
Please see the screenshot attached. If series contains Y-values near the 24-bit boundary and OpenGL is enabled, the series are not rendered correctly. The issue can be reproduced at least with the following values: 16777216, 16777217 and 16777.216, 16777.217.
#include <QtWidgets/QApplication> #include <QtWidgets/QMainWindow> #include <QtCharts/QChartView> #include <QtCharts/QLineSeries> QT_CHARTS_USE_NAMESPACE int main(int argc, char *argv[]) { QApplication a(argc, argv); QLineSeries *noOpenGL = new QLineSeries(); noOpenGL->append(0, 16777216); noOpenGL->append(1, 16777217); noOpenGL->setName("noOpenGL"); QLineSeries *useOpenGL = new QLineSeries(); useOpenGL->append(0, 16777216); useOpenGL->append(1, 16777217); useOpenGL->setName("useOpenGL"); useOpenGL->setUseOpenGL(true); QChart *chart = new QChart(); chart->addSeries(noOpenGL); chart->addSeries(useOpenGL); chart->createDefaultAxes(); QChartView *chartView = new QChartView(chart); QMainWindow window; window.setCentralWidget(chartView); window.resize(400, 300); window.show(); return a.exec(); }