From kde-panel-devel Thu Feb 27 21:59:07 2014 From: "David Edmundson" Date: Thu, 27 Feb 2014 21:59:07 +0000 To: kde-panel-devel Subject: Re: Review Request 116024: Port IconItem to native QSGTexture Message-Id: <20140227215907.18925.9270 () probe ! kde ! org> X-MARC-Message: https://marc.info/?l=kde-panel-devel&m=139353835912862 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--===============9036046988385022467==" --===============9036046988385022467== Content-Type: multipart/alternative; boundary="===============3899585081250379239==" --===============3899585081250379239== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit > On Feb. 27, 2014, 8:17 p.m., David Edmundson wrote: > > src/declarativeimports/core/fadingnode.cpp, line 85 > > > > > > Despite my code being clearly right this doesn't work. (according to apitrace and then qDebug) > > > > oldState is always 0 > > > > This means we are binding textures every frame, which is what we wanted to avoid. > > > > I'm quite confused as to why. I understand it now (I think) If I have 2 icons, I will have 2 materials, but still only 1 shader. oldState is used so that when SG batches operations I don't have to update all my uniforms if properties are the same between different materials being rendered in different nodes. It is not the previous state of the current material being updated. Sorry for the noise. - David ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/116024/#review51129 ----------------------------------------------------------- On Feb. 27, 2014, 1:44 p.m., David Edmundson wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://git.reviewboard.kde.org/r/116024/ > ----------------------------------------------------------- > > (Updated Feb. 27, 2014, 1:44 p.m.) > > > Review request for Plasma. > > > Repository: plasma-framework > > > Description > ------- > > Port IconItem to native QSGTexture including the animation. > This will save constantly uploading a new texture to OpenGL throughout the animation. > > > Diffs > ----- > > CMakeLists.txt 4bc47bf > src/declarativeimports/core/CMakeLists.txt 97e9283 > src/declarativeimports/core/fadingnode.cpp PRE-CREATION > src/declarativeimports/core/fadingnode_p.h PRE-CREATION > src/declarativeimports/core/iconitem.h 26ee410 > src/declarativeimports/core/iconitem.cpp fed2f9b > > Diff: https://git.reviewboard.kde.org/r/116024/diff/ > > > Testing > ------- > > Test app: http://paste.kde.org/pl5pwdnel > > > Thanks, > > David Edmundson > > --===============3899585081250379239== Content-Type: text/html; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit
This is an automatically generated e-mail. To reply, visit: https://git.reviewboard.kde.org/r/116024/

On February 27th, 2014, 8:17 p.m. UTC, David Edmundson wrote:

src/declarativeimports/core/fadingnode.cpp (Diff revision 3)
85
    if (!oldState || oldState->source != newState->source) {
Despite my code being clearly right this doesn't work. (according to apitrace and then qDebug)

oldState is always 0

This means we are binding textures every frame, which is what we wanted to avoid.

I'm quite confused as to why.
I understand it now (I think)
If I have 2 icons, I will have 2 materials, but still only 1 shader.

oldState is used so that when SG batches operations I don't have to update all my uniforms if properties are the same between different materials being rendered in different nodes. It is not the previous state of the current material being updated.

Sorry for the noise.

- David


On February 27th, 2014, 1:44 p.m. UTC, David Edmundson wrote:

Review request for Plasma.
By David Edmundson.

Updated Feb. 27, 2014, 1:44 p.m.

Repository: plasma-framework

Description

Port IconItem to native QSGTexture including the animation.
This will save constantly uploading a new texture to OpenGL throughout the animation.

Testing

Test app: http://paste.kde.org/pl5pwdnel

Diffs

  • CMakeLists.txt (4bc47bf)
  • src/declarativeimports/core/CMakeLists.txt (97e9283)
  • src/declarativeimports/core/fadingnode.cpp (PRE-CREATION)
  • src/declarativeimports/core/fadingnode_p.h (PRE-CREATION)
  • src/declarativeimports/core/iconitem.h (26ee410)
  • src/declarativeimports/core/iconitem.cpp (fed2f9b)

View Diff

--===============3899585081250379239==-- --===============9036046988385022467== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Plasma-devel mailing list Plasma-devel@kde.org https://mail.kde.org/mailman/listinfo/plasma-devel --===============9036046988385022467==--