Merge lp:~unity-team/qtmir/surfaceItemFillMode into lp:qtmir
| Status: | Merged |
|---|---|
| Approved by: | Michael Zanetti on 2015-12-09 |
| Approved revision: | 425 |
| Merged at revision: | 425 |
| Proposed branch: | lp:~unity-team/qtmir/surfaceItemFillMode |
| Merge into: | lp:qtmir |
| Prerequisite: | lp:~nick-dedekind/qtmir/polite-close |
| Diff against target: |
137 lines (+42/-7) 5 files modified
CMakeLists.txt (+1/-1) debian/control (+2/-2) src/modules/Unity/Application/mirsurface.cpp (+1/-1) src/modules/Unity/Application/mirsurfaceitem.cpp (+33/-3) src/modules/Unity/Application/mirsurfaceitem.h (+5/-0) |
| To merge this branch: | bzr merge lp:~unity-team/qtmir/surfaceItemFillMode |
| Related bugs: |
| Reviewer | Review Type | Date Requested | Status |
|---|---|---|---|
| Michael Zanetti (community) | 2015-12-07 | Approve on 2015-12-09 | |
| PS Jenkins bot | continuous-integration | 2015-12-07 | Needs Fixing on 2015-12-07 |
|
Review via email:
|
|||
This proposal supersedes a proposal from 2015-12-04.
Commit Message
Add MirSurfaceItem.
Ensure that by the time we enter the phase of updating the scene graph, all qml items are up to date regarding the size of the buffer about to be rendered.
NB: This rendering scheme needs triple buffering to work.
Description of the Change
* Are there any related MPs required for this MP to build/function as expected? Please list.
https:/
https:/
* Did you perform an exploratory manual test run of your code change and any related functionality?
Yes
* If you changed the packaging (debian), did you subscribe the ubuntu-unity team to this MP?
Not applicable
| Daniel van Vugt (vanvugt) wrote : | # |
Glad to have helped. This isn't the first time someone has told me I'm wrong and then they went ahead and copied my code :)
| Gerry Boland (gerboland) wrote : | # |
What's the use-case of this fillMode? The crop ability might have use in the spread? But it's not a proper solution for the stretched frames issue on rotation.
| Daniel d'Andrada (dandrader) wrote : | # |
On 18/09/15 08:02, Gerry Boland wrote:
> What's the use-case of this fillMode? The crop ability might have use in the spread? But it's not a proper solution for the stretched frames issue on rotation.
Resize untiy8-dash in desktop mode on a Nexus device and you'll see.
| Michael Zanetti (mzanetti) wrote : | # |
Code looks ok, but as noticed on the related unity8 branch, I'm not sure if this is the proper place to calculate the innerRect stuff. It has the effect that it makes window content and window decoration/shadow go out of sync.
| Daniel d'Andrada (dandrader) wrote : | # |
On 23/09/2015 07:32, Michael Zanetti wrote:
> Review: Needs Information
>
> Code looks ok, but as noticed on the related unity8 branch, I'm not sure if this is the proper place to calculate the innerRect stuff. It has the effect that it makes window content and window decoration/shadow go out of sync.
They're two separate things. fillMode is there to ensure that you never
see a stretched surface even if the MirSurfaceItem size doesn't match
it. See it as yet another MirSurface feature that shells (unity8) can
take and use it on their UI/interaction designs.
What unity8 *does with it* is another thing. That shadow "going out of
sync" is a crude implementation or that unity7 window resize mode where
the window is not resize live, but you drag a translucent orang bounding
rect of it and only on release does the window get committed to that
bounding rect size (or actually a hint for the possibility doing the same).
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:389
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:391
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| Michael Zanetti (mzanetti) wrote : | # |
I've tested this and it works fine. Would prefer Gerry to have a look at the code as there is quite some buffer handling involved which I'm not too experienced with.
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:392
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| Gerry Boland (gerboland) wrote : | # |
Remind me why we want to support Stretch?
| Daniel d'Andrada (dandrader) wrote : | # |
> Remind me why we want to support Stretch?
Stretch does sound like a bad name, but scaling is stretching while respecting the aspect ratio of the surface.
And we want scaling working to display window thumbnails in the alt-tab spread, for instance.
| Loïc Molinari (loic.molinari) wrote : | # |
Using polish() sounds like the right thing to do in order to correctly sync surface size and item size, no more temporary frame drawn with surface size different than item size. Emitting the item sizeChanged signal in the GUI thread right before the updatePaintNode() callback in the render thread doesn't imply 2 frames anymore when Unity requires a surface resize. It should also fix that [1].
Regarding the fill mode, I think we should expose the same enum names that the standard QtQuick Image uses with, for now, just the needed ones : Stretch and Pad. That would make things cleaner IMO, easier to understand for people used to that and would allow to add the PreserveAspectFit and PreserveAspectCrop (and maybe the alignment props) later if ever needed.
(Take my comments with a grain of salt because I'm not completely aware of the whole picture, but I'm taking the liberty of commenting on that because I've been working a bit on qtmir lately for the mutlibuffer stream thing and for the AA optimization which kinda touches the same code path ;) )
[1] https:/
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:418
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:420
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:423
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:425
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:426
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
| PS Jenkins bot (ps-jenkins) wrote : | # |
FAILED: Continuous integration, rev:425
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild:
http://
- 426. By Michał Sawicz on 2015-12-10
-
Revert changes related to surface/texture handling as they caused black apps from time to time

FAILED: Continuous integration, rev:370 jenkins. qa.ubuntu. com/job/ qtmir-ci/ 412/ jenkins. qa.ubuntu. com/job/ qtmir-wily- amd64-ci/ 145/console jenkins. qa.ubuntu. com/job/ qtmir-wily- armhf-ci/ 145/console
http://
Executed test runs:
FAILURE: http://
FAILURE: http://
Click here to trigger a rebuild: s-jenkins. ubuntu- ci:8080/ job/qtmir- ci/412/ rebuild
http://