[Kst] double buffering
nicolas.brisset at free.fr
Fri Jan 2 16:20:44 UTC 2015
Happy New Year to you and the labplot project, hoping to see increased cooperation in 2015!
Regarding your question I'm not the right person for the technical questions behind painting, as I never really looked at that part. But what I can say is that the blurred aspect sounds familiar when you don't turn off antialiasing. We have an option to antialias plots in the settings menu in Kst, which I always turn off because otherwise I find the result to be too blurred.
Hoping that helps until you get a more expert answer from someone else...
----- Mail original -----
> De: "Alexander Semke" <Alexander.Semke at web.de>
> À: "kst at kde.org" <kst at kde.org>
> Envoyé: Jeudi 1 Janvier 2015 11:26:54
> Objet: [Kst] double buffering
> Hi all,
> I'm struggling with a problem in LabPlot since a couple of days and
> find a solution for that problem. Since a similar technique is used
> in kst I'd
> like to ask the question here. Maybe somebody has an idea...
> In kst, in PlotItem::paint() you paint the pixmap created before with
> painter->drawPixmap(rect().topLeft(), _plotPixmap);
> In LabPlot, the double-buffering is currently implemented for the
> only. In XYCurvePrivate::paint() I have
> painter->drawPixmap(boundingRectangle.topLeft(), m_pixmap);
> Though the curve is (re)painted much faster now, as expected, the
> quality has
> worsen. Please take a look at the pictures attached. I also have to
> painter->setRenderHint(QPainter::SmoothPixmapTransform, true);
> Without this hint the quality is even more worse. I suspect the
> interpolation/extrapolation from the integer values of the bounding
> rectangular and the float numbers of QPixmap's size in
> to be responsible for the quality drop. But if this is true, the same
> should also occur in kst which I don't observe, though. You don't
> need to use
> the SmoothPixmapTransform-hint neither...
> Do you have any idea on this issue?
> Best regards and happy and productive New Year,
> Kst mailing list
> Kst at kde.org
More information about the Kst