Commit Graph

50 Commits

Author SHA1 Message Date
dragonn 53c6bf003f suppres clippy len_without_is_empty for LayerMap 2022-01-20 19:18:00 +01:00
dragonn 957f1c522b rework renderlayer to zindex solution 2022-01-20 19:11:58 +01:00
dragonn dea000921b add comments to DynamicRenderElementMap 2022-01-19 22:02:35 +01:00
dragonn 2b1e389495 move DynamicRenderElementMap and it's friends to elements.rs 2022-01-19 21:12:54 +01:00
dragonn 3ae387e991 DynamicRenderElementMap as a helper for iter on custom_elements 2022-01-19 17:35:30 +01:00
Mateusz 478fe62808
Move chain to upper chain in loop
Co-authored-by: Victoria Brekenfeld <4404502+Drakulix@users.noreply.github.com>
2022-01-19 16:49:15 +01:00
Mateusz d7dfe2e3b6
Move chain to upper chain in render loop
Co-authored-by: Victoria Brekenfeld <4404502+Drakulix@users.noreply.github.com>
2022-01-19 16:49:03 +01:00
dragonn b9ecc3c2d4 add layer definition to RenderElement 2022-01-18 22:15:47 +01:00
Poly d5bfc6f613 desktop.space: Fix multioutput rendering 2022-01-17 20:33:56 +01:00
Victoria Brekenfeld 37693f31d9
Merge pull request #466 from Smithay/fix/damage_output_transform
Apply transformations correctly
2022-01-17 16:04:13 +01:00
Victoria Brekenfeld 3c7b84ff88
Merge pull request #464 from Smithay/fix/multi_overlap_damage
space: Handle multiple overlapping rects when merging damage
2022-01-17 14:19:22 +01:00
Victor Brekenfeld 439d5a7820 Consistently use buffer coordinates
- Moves `Transform` into utils::geometry
- Changes conversion from and into buffer-coordinates to take
  `Transform` arguments.
- `Renderer` take `Buffer`-space damage now
- buffer_transform is taken into account everywhere
2022-01-16 20:32:17 +01:00
Victor Brekenfeld a53d64053f space: Handle multiple overlapping rects when merging damage 2022-01-16 16:41:10 +01:00
Victor Brekenfeld 8f73a1e4f8 desktop: Fix damage for removed popups 2022-01-16 16:39:37 +01:00
Victor Brekenfeld 75929919ba space: Clarify state reset on `map_output` 2022-01-07 19:48:43 +01:00
Victor Brekenfeld 14d10e4863 space: `output_under` may return multiple outputs 2022-01-07 19:48:43 +01:00
Victor Brekenfeld ccec794af7 desktop: `draw_layer` -> `draw_layer_surface` 2022-01-07 19:48:43 +01:00
Victor Brekenfeld a779e6b5c0 docs: Always referr to layer surfaces as such 2022-01-07 19:48:43 +01:00
Victoria Brekenfeld 75c84796f6
space: documentation fixes
Co-authored-by: Victor Berger <vberger@users.noreply.github.com>
2022-01-06 00:26:14 +01:00
Victor Brekenfeld 58f20fb6c7 space: Make `RenderError` require Debug 2022-01-05 21:26:44 +01:00
Victor Brekenfeld 8059bdc5db desktop: docs 2022-01-05 20:48:07 +01:00
Victor Brekenfeld 8e34865acc space: Let downstream `RenderElements` hash `(&Space, &Output)` 2022-01-05 20:46:59 +01:00
Victor Brekenfeld a5f3c5c5d2 clippy fixes 2022-01-05 13:03:55 +01:00
Victor Brekenfeld d69d15630e space: make render error check more readable 2022-01-04 19:06:47 +01:00
Victor Brekenfeld 26e1576f87 space: make window activation optional 2022-01-04 19:06:47 +01:00
Victor Brekenfeld 537b34fe0b cleanup: imports 2022-01-04 19:06:47 +01:00
Victor Brekenfeld 3674daf083 utils: Add macro for global ids 2022-01-04 19:06:47 +01:00
Victor Brekenfeld 5b6700c151 desktop: fix popup placement 2022-01-04 15:11:21 +01:00
Victor Brekenfeld 08ac5ba6d1 desktop: Make window damage public 2022-01-04 12:50:40 +01:00
Victor Brekenfeld ab21df1943 space: Return new damage on render 2022-01-04 12:50:40 +01:00
Victor Brekenfeld 359c060e0f space: apply transform for output_geometry 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 8536fa90a1 desktop: streamline custom elements logic 2022-01-04 12:50:39 +01:00
Victor Brekenfeld bb1e68c916 space: Add support for drawing custom elements 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 5b85333eaf desktop: clamp damage to bbox 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 827a3c8c2a desktop: Fixup intersection calls 2022-01-04 12:50:39 +01:00
Victor Brekenfeld a948ff8829 space: commit does not need mutable self 2022-01-04 12:50:39 +01:00
Victor Brekenfeld a20fd0c65d window: cache bbox 2022-01-04 12:50:39 +01:00
Victor Brekenfeld d84a66e053 desktop: api cleanups 2022-01-04 12:50:39 +01:00
Victor Brekenfeld d7350d18ee desktop: fix negative damage values 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 94968e2d0f desktop: track damage per space/output 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 3b39d780fe desktop: layer-shell support 2022-01-04 12:50:39 +01:00
Victor Brekenfeld cea88fdde0 desktop: Various cleanups 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 31b308836f renderer: Use fine grained damage for rendering
Up until now we always redrew the whole windows, which worked
fine - except for some transparency issues - but left performance
on the table.

So now we use instancing to render only the actually damaged regions
inside the window, which also fixes our few rendering issues.

We also use a shader now for clearing the screen to use instancing as
well and lower the amount of draw calls at the begin of a frame for
clearing parts of it.

And while we are add it we remove the last rendering artifacts
by optimizing the damage vector by deduplicating and merging rectangles.
2022-01-04 12:50:39 +01:00
Victor Brekenfeld f55f1bbbe0 desktop: handle xdg-popups 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 90f7d53a3a space: fixup miscalculations 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 25b74e2eaa space: change output_for_window to return Vec 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 7578fab9cf desktop: map_window remove unnecessary Result and activate 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 2c0ae025de desktop: Track surface enter/leave for outputs 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 44829d8fba desktop: Only render surface damage, if window was not moved 2022-01-04 12:50:39 +01:00
Victor Brekenfeld 98906555f5 desktop: Add new desktop abstractions module
Adds a new `Window` and `Space` abstraction to make it easier
to handle windows of various shells and their positions in a
compositor space.
2022-01-04 12:50:39 +01:00