hi friends,
I have used QPixmap Item to display the images in QGraphicsview viewport
as im loading thousands of pixmaps at a time , i decided to set some options to make cache for the pixmap im loading for the images .
so i did
View
->setRenderHint
(QPainter::Antialiasing,
false);
fmt.setSampleBuffers(true);
fmt.setSamples(2);
//View->setViewport(new QGLWidget(QGLFormat(QGL::SampleBuffers)));
View->scene()->setItemIndexMethod(QGraphicsScene::NoIndex);
View->setRenderHint(QPainter::Antialiasing, false);
QGLFormat fmt;
fmt.setSampleBuffers(true);
fmt.setSamples(2);
//View->setViewport(new QGLWidget(QGLFormat(QGL::SampleBuffers)));
View->setViewport(new QGLWidget(fmt));
View->setOptimizationFlags(QGraphicsView::DontSavePainterState | QGraphicsView::DontAdjustForAntialiasing);
View->setViewportUpdateMode(QGraphicsView::FullViewportUpdate);
View->setTransformationAnchor(QGraphicsView::AnchorUnderMouse);
View->setCacheMode(QGraphicsView::CacheBackground);
To copy to clipboard, switch view to plain text mode
if i dont use QGLWidget and Opengl as viewport of QGraphicsVIew the pixmaps are looking normal but if i use OpenGL Viewport ,the rendered pixmaps are looking blurred than normal .
i attached the screenshots of bot cases with the thread .
please help me
..withOpenGL.jpg and with opt open gl
wtOutOpenGL.jpg
Bookmarks