Merge lp://staging/~nick-dedekind/qtmir/multiwindow.textures into lp://staging/qtmir
- multiwindow.textures
- Merge into trunk
Status: | Needs review |
---|---|
Proposed branch: | lp://staging/~nick-dedekind/qtmir/multiwindow.textures |
Merge into: | lp://staging/qtmir |
Prerequisite: | lp://staging/~unity-team/qtmir/qtmir.api |
Diff against target: |
834 lines (+353/-131) 12 files modified
debian/changelog (+2/-1) src/modules/Unity/Application/CMakeLists.txt (+1/-0) src/modules/Unity/Application/compositortextureprovider.cpp (+87/-0) src/modules/Unity/Application/compositortextureprovider.h (+77/-0) src/modules/Unity/Application/mirsurface.cpp (+99/-78) src/modules/Unity/Application/mirsurface.h (+11/-9) src/modules/Unity/Application/mirsurfaceinterface.h (+5/-5) src/modules/Unity/Application/mirsurfaceitem.cpp (+39/-22) src/modules/Unity/Application/mirsurfaceitem.h (+2/-2) tests/framework/fake_mirsurface.cpp (+9/-9) tests/framework/fake_mirsurface.h (+5/-5) tests/modules/WindowManager/mirsurface_test.cpp (+16/-0) |
To merge this branch: | bzr merge lp://staging/~nick-dedekind/qtmir/multiwindow.textures |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Unity8 CI Bot (community) | continuous-integration | Approve | |
Daniel d'Andrada (community) | Needs Fixing | ||
Review via email: mp+316864@code.staging.launchpad.net |
This proposal supersedes a proposal from 2017-02-07.
Commit message
Multiple compositor support for surface textures.
Description of the change
Gerry Boland (gerboland) wrote : Posted in a previous version of this proposal | # |
Daniel d'Andrada (dandrader) wrote : Posted in a previous version of this proposal | # |
Worth checking how this affects the new frame dropping implementation in MirSurface
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:595
https:/
Executed test runs:
FAILURE: https:/
SUCCESS: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:596
https:/
Executed test runs:
FAILURE: https:/
SUCCESS: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
- 596. By Nick Dedekind
-
merged parent
- 597. By Nick Dedekind
-
merged parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:597
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 598. By Nick Dedekind
-
merged parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:598
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 599. By Nick Dedekind
-
merged parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:599
https:/
Executed test runs:
FAILURE: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
FAILURE: https:/
SUCCESS: https:/
deb: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
- 600. By Nick Dedekind
-
merged with parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:600
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Daniel d'Andrada (dandrader) wrote : | # |
Missing https:/
Missing copyright headers in src/modules/
Daniel d'Andrada (dandrader) wrote : | # |
In src/modules/
"""
windowmode
+ compositortextu
# We need to run moc on these headers
"""
Please try to put it as close as you can to an alphabetical order (thus near the top of that list).
Daniel d'Andrada (dandrader) wrote : | # |
The cyclic dependency between MirSurfaceItem and its SurfaceItemText
That might even lead to more correct code as it will update SurfaceItemText
Daniel d'Andrada (dandrader) wrote : | # |
"""
+++ src/modules/
@@ -20,6 +20,7 @@
#include "session_
#include "timer.h"
#include "timestamp.h"
+#include "compositortext
"""
Again, striving for an alphabetical order would be nice.
Daniel d'Andrada (dandrader) wrote : | # |
In MirSurface:
Daniel d'Andrada (dandrader) wrote : | # |
If you could keep MirSurface:
Nick Dedekind (nick-dedekind) wrote : | # |
> The cyclic dependency between MirSurfaceItem and its
> SurfaceItemText
> latter upon QQuickItem:
>
> That might even lead to more correct code as it will update
> SurfaceItemText
> implementation.
Where is there a cyclic dependency? The items texture is dependant on the items smooth property.
Daniel d'Andrada (dandrader) wrote : | # |
> > The cyclic dependency between MirSurfaceItem and its
> > SurfaceItemText
> the
> > latter upon QQuickItem:
> >
> > That might even lead to more correct code as it will update
> > SurfaceItemText
> > implementation.
>
> Where is there a cyclic dependency?
Item has TextureProvider and TextureProvider has Item.
Nick Dedekind (nick-dedekind) wrote : | # |
> In MirSurface:
> implementation. Is that intentional? If not, please update the current
> implementation to work with that new multi-texture scenario.
It was intentional.
Your reason for changing the code was "Make frame dropper work even when there's no texture around".
In this impl for the frame dropper we iterate over the textures which we have already generated and update the texture. We wouldn't have any renderables for something we hadn't requested (and therefore have a texture).
- 601. By Nick Dedekind
-
review comments
Nick Dedekind (nick-dedekind) wrote : | # |
> > > The cyclic dependency between MirSurfaceItem and its
> > > SurfaceItemText
> > the
> > > latter upon QQuickItem:
> > >
> > > That might even lead to more correct code as it will update
> > > SurfaceItemText
> > > implementation.
> >
> > Where is there a cyclic dependency?
>
> Item has TextureProvider and TextureProvider has Item.
Removed. Added TextureProvider
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:601
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Daniel d'Andrada (dandrader) wrote : | # |
> > In MirSurface:
> old
> > implementation. Is that intentional? If not, please update the current
> > implementation to work with that new multi-texture scenario.
>
> It was intentional.
> Your reason for changing the code was "Make frame dropper work even when
> there's no texture around".
> In this impl for the frame dropper we iterate over the textures which we have
> already generated and update the texture. We wouldn't have any renderables for
> something we hadn't requested (and therefore have a texture).
What you're explaining is the wrong assumption that the previous implementation had.
The problematic case is this: When closing and application, QSG might have already freed the texture by the time you try to drop the pending surface frame. Since there's no texture anymore, updateTexture() fails to consume the frame.
The client application will then get stuck on swap_buffers(), unable to consume the pending close_surface event coming from mir.
See https:/
- 602. By Nick Dedekind
-
merged with parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:602
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 603. By Nick Dedekind
-
use newer drop frame algorithm
Nick Dedekind (nick-dedekind) wrote : | # |
> > > In MirSurface:
> > old
> > > implementation. Is that intentional? If not, please update the current
> > > implementation to work with that new multi-texture scenario.
> >
> > It was intentional.
> > Your reason for changing the code was "Make frame dropper work even when
> > there's no texture around".
> > In this impl for the frame dropper we iterate over the textures which we
> have
> > already generated and update the texture. We wouldn't have any renderables
> for
> > something we hadn't requested (and therefore have a texture).
>
> What you're explaining is the wrong assumption that the previous
> implementation had.
>
> The problematic case is this: When closing and application, QSG might have
> already freed the texture by the time you try to drop the pending surface
> frame. Since there's no texture anymore, updateTexture() fails to consume the
> frame.
>
> The client application will then get stuck on swap_buffers(), unable to
> consume the pending close_surface event coming from mir.
>
> See https:/
> 15911 for details
I see! I've changed it to match the current impl + multiple textures.
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:603
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 604. By Nick Dedekind
-
merged with parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:604
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Daniel d'Andrada (dandrader) wrote : | # |
Since CompositorTexture is only meant to be created and filled in by CompositorTextu
Daniel d'Andrada (dandrader) wrote : | # |
That would simplify your code:
http://
Daniel d'Andrada (dandrader) wrote : | # |
MirSurface:
Daniel d'Andrada (dandrader) wrote : | # |
> That would simplify your code:
> http://
Actually not, as the new texture would lose its only strong ref when leaving the if(){}
Ignore me. :)
Daniel d'Andrada (dandrader) wrote : | # |
> Since CompositorTexture is only meant to be created and filled in by
> CompositorTextu
> setTexture methods private and declaring CompositorTextu
> That would make roles more clear when you read the header
Aside from this nit, code looks good and unity8 still works.
- 605. By Nick Dedekind
-
merged parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:605
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 606. By Nick Dedekind
-
merged with parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:606
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:606
https:/
Executed test runs:
FAILURE: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
- 607. By Nick Dedekind
-
merged parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:607
https:/
Executed test runs:
FAILURE: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
FAILURE: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 608. By Nick Dedekind
-
Compositor texture privates
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:608
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
FAILED: Continuous integration, rev:608
https:/
Executed test runs:
FAILURE: https:/
FAILURE: https:/
Click here to trigger a rebuild:
https:/
- 609. By Nick Dedekind
-
merged with parent
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:609
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 610. By Nick Dedekind
-
merged pre-req
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:610
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 611. By Nick Dedekind
-
merged pre-req
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:611
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
- 612. By Nick Dedekind
-
changelog
- 613. By Nick Dedekind
-
changelog
Unity8 CI Bot (unity8-ci-bot) wrote : | # |
PASSED: Continuous integration, rev:613
https:/
Executed test runs:
SUCCESS: https:/
SUCCESS: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
SUCCESS: https:/
deb: https:/
Click here to trigger a rebuild:
https:/
Unmerged revisions
- 613. By Nick Dedekind
-
changelog
- 612. By Nick Dedekind
-
changelog
- 611. By Nick Dedekind
-
merged pre-req
- 610. By Nick Dedekind
-
merged pre-req
- 609. By Nick Dedekind
-
merged with parent
- 608. By Nick Dedekind
-
Compositor texture privates
- 607. By Nick Dedekind
-
merged parent
- 606. By Nick Dedekind
-
merged with parent
- 605. By Nick Dedekind
-
merged parent
- 604. By Nick Dedekind
-
merged with parent
+ int curentFrame() :setTexturePorv ider
MirSurface:
typos
+ int m_currentFrameN umber;
unsigned would help, would give 136 years at 60fps instead of 68 :)
Overall, this looks ok. I'm curious about one thing. We're using Mir's user_id thing, passing it to generate_ renderables for each display. I am curious if that returns a single texture to be shared between each display - or a distinct texture per display. If the later, I would wonder why, and we (later) might try eradicating the copy and just share one, to save GPU memory.