Is it possible to know when a PlasmaCore IconItem is ready?

David Edmundson david at davidedmundson.co.uk
Thu Jul 28 12:21:13 UTC 2016


On Thu, Jul 28, 2016 at 1:08 PM, Michail Vourlakos <mvourlakos at gmail.com>
wrote:

> David, I had tried it some iterations before in my code path, it wasnt
> as equally performant as the Images solution, I will give it one more
> try...
>

> I suppose you are proposing to drop Images, add a ShaderEffectSource
> with live:false


Yes.


> for DropShadow and the animation for hover to add it
> in the PlasmaCore.IconItem right?
>

I'd put the animation in the DropShadow itself and scale that.

I bet changing the size of a ShaderEffectSource triggers a re-render, and
that's why you see the performance hit.

Currently you're changing the iconImageBuffer but the QSGTextureProvider it
created will just remain static.





>              PlasmaCore.IconItem {
>                  id: iconImage
>                  width: 2 * panel.iconSize - 8
>                  height: 2 * panel.iconSize - 8
>
> property int newTempSize: Math.floor(panel.iconSize *
> wrapper.scale * wrapper.appearScale)
>         width: newTempSize
>         height: newTempSize
>
>
>
> On 7/28/16, David Edmundson <david at davidedmundson.co.uk> wrote:
> > ShaderEffectSource with live:false should be equally performant as this
> (if
> > anything more so).
> > It /should/ also fix your code.
> >
> > Then call scheduleUpdate() whenever onSourceChanged is emitted.
> >
> > We load the pixmap in the polish() event which happens between all QML
> > processing and the frame being rendered.
> > There's no timer.
> >
> _______________________________________________
> Plasma-devel mailing list
> Plasma-devel at kde.org
> https://mail.kde.org/mailman/listinfo/plasma-devel
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/plasma-devel/attachments/20160728/dc195338/attachment.html>


More information about the Plasma-devel mailing list