Commit Graph

23982 Commits

Author SHA1 Message Date
Gwan-gyeong Mun
ca0b6fc3ac Update Korean translation 2019-02-28 03:16:37 +00:00
Trần Ngọc Quân
7c3a0d54cc Updated Vietnamese translation
Signed-off-by: Trần Ngọc Quân <vnwildman@gmail.com>
2019-02-28 07:47:58 +07:00
Niels De Graef
16a2eab290 clutter: Animatable: Use G_DECLARE_INTERFACE()
It cuts away a bit of the GObject boilerplate, gives us support for
`g_autoptr`, and removes the typedef hack inside clutter-scroll-actor.c.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/380
2019-02-27 16:44:24 +00:00
Niels De Graef
41a69f194d clutter: MasterClock: Use G_DECLARE_INTERFACE()
It cuts away a bit of the GObject boilerplate, gives us support for
`g_autoptr`, and removes the typedef hack inside clutter-master-clock.c.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/380
2019-02-27 16:44:24 +00:00
Niels De Graef
b77e6f0c98 clutter: Content: Use G_DECLARE_INTERFACE()
It cuts away a bit of the GObject boilerplate, gives us support for
`g_autoptr`, and removes the typedef hack inside clutter-content.c.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/380
2019-02-27 16:44:24 +00:00
Niels De Graef
b67394dcd1 clutter: StageWindow: Use G_DECLARE_INTERFACE()
It cuts away a bit of the GObject boilerplate, gives us support for
`g_autoptr`, and removes the typedef hack inside clutter-stage-window.c.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/380
2019-02-27 16:44:24 +00:00
Olivier Fourdan
f9e33a89fd clutter: cleanup/remove core input X11 backend
We don't use the core input X11 backend, remove it.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/459
2019-02-27 12:07:24 +01:00
Adam Jackson
39e9e53871 clutter: Remove the rest of deprecated/clutter-animator.c
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
7f3fda6df6 clutter: Simplify clutter_state_change
clutter_state_get_animator now always returns NULL, because
_set_animator is never called.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
73ce5b3a8d clutter: Remove tests/interactive/test-state-animator.c
This is the only caller of the (deprecated) clutter_state_set_animator.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
53319a121f clutter: Remove unused deprecated code from clutter-actor-deprecated.c
Since clutter_actor_set_shader() is never called, none of this has any
effect.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
cf2d06e9b9 clutter: Remove deprecated clutter-score.c
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
d39211f438 clutter: Remove deprecated clutter_egl{,x}_display
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
909464f749 clutter: Remove deprecated XInput code
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
5669b64021 clutter: Remove unused clutter-glx-texture-pixmap.c and friends
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Adam Jackson
8f0b4767de clutter: Remove deprecated clutter_x11_get_stage_visual
https://gitlab.gnome.org/GNOME/mutter/merge_requests/452
2019-02-27 03:32:21 +00:00
Jonas Ådahl
9e75ce2ad7 monitor-config-store: Read system wide config files
Before introducing the new config store, the old monitor configuration
system read system wide monitor configuration files. Add back that
feature.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/253
2019-02-26 21:04:27 +00:00
Tim Sabsch
c010a3b195 Update German translation 2019-02-26 19:44:02 +00:00
Jonas Ådahl
7c807c6e2a org.gnome.Mutter.ScreenCast: Document what was added in API version 2
RecordWindow and the cursor-mode property are only available if the
advertised version is at least 2.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
9a20271f90 screen-cast-window-stream: Add support for cursor modes
Make the RecordWindow method also understand the 'cursor-mode' property.
For 'embedded' the cursor is drawn onto the pixel buffer using cairo,
otherwise it works similarly to how RecordMonitor deals with it.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
1760a6e560 screen-cast: Bump API version to 2
https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
8c2b805d88 screen-cast-src: Add helper to draw cursor sprite into pixel buffer
It makes sure the cursor sprite is correctly scaled and positioned in
stream coordinate space.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
2f01418d45 screen-cast-window: Add API to check if content has damage
https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
a76107a19f screen-cast-window: Add API to transform cursor state
To be used to translate absolute cursor positions to relative positions,
as well as to determine whether a cursor sprite is inside the stream or
not. It also helps calculating the scale the cursor sprite needs to be
scaled with to be in stream coordinate space.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
6372e3e4db clutter: Add clutter_actor_has_damage() API
Will be used to check whether there are any damage to an actor.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
c80ba819e7 screen-cast-window-src: Keep a screen cast window instead of an actor
Practically it's the same object, but ideally, we should not deal
with "actors" anywhere here.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
14c6a347c1 screen-cast-window-src: Rename painted callback to after_paint
We'll add a before_paint soon, so better have the names somewhat match.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
11bd847896 screen-cast-window-stream: Don't set the position property
It was not meant to be set for window streams, and was set to (0, 0)
anyway. This removes the corresponding MetaScreenCastWindow API, as it's
not needed anymore.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
870f38542d screen-cast-window-stream: Set the size property to the logical size
As the stream size is the logical monitor size multiplied with the ceil
of the logical monitor scale, the corresponding logical size, which is
what should be passed via the size property on the D-Bus object, should
be the logical monitor size.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
c22edeff1f screen-cast-window-stream: Use initable to initialize
Move the initialization from _new() to an initable implementation. This
will allow us to initialize fields before MetaScreenCastStream
initializes.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
183de60d91 screen-cast-src: Move back MetaSpaType to C file
It's not needed by the monitor source anymore.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
176b508029 screen-cast-src: Change offscreen cursor helper to take a uint8_t *
Instead of a `uint32_t *`. Eventually we shouldn't assume pixels are
always 32 bit, and this gets rid of some casts while at it.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Jonas Ådahl
9be189daa7 screen-cast: Move cursor metadata setting to generic source
Make the monitor implementation do things strictly related to its own
source type, leaving the Spa related logic and cursor read back in the
generic layer, later to be reused by the window source type
implementation.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/413
2019-02-26 13:39:11 +00:00
Carlos Garnacho
bf12a2497b clutter: Make docs match with signal description
Makes gobject-introspection happy again.

Pointed out by Robert Mader at:
https://gitlab.gnome.org/GNOME/mutter/merge_requests/196
2019-02-25 20:12:21 +01:00
Carlos Garnacho
55d168d01a clutter: Add ClutterPaintVolume argument to ClutterActor::queue_redraw
This is an ABI break, hopefully an unimportant one since this signal/vmethod
is barely overridden.

The signal has been added an extra ClutterPaintVolume argument, and has been
given a boolean return value. The recursion to the parents has been taken
out of the default implementation and into the caller, using the returned
boolean parameter to control further propagation.

Passing the ClutterPaintVolume is easier on performance, as we don't need
setting this pointer as gobject data just to retrieve/unset it further
in propagation.

https://bugzilla.gnome.org/show_bug.cgi?id=782344
2019-02-25 18:17:34 +00:00
Carlos Garnacho
8a9a78ec8a wayland: Check whether Xwayland window had a prior surface in generic code
Since commit 8df2a1452c (As pointed out by Robert Mader) we just happened
do this check when doing the first lookup for a Wayland surface for a
XWayland window, when we are later notifying upon surface creation we just
set the relation with no further checks.

The cases pointed out in the comment (eg. window changing decoration) might
presumably happen in a quick enough sequence that we have two scheduled
associations on the fly, so move this check to the more generic
meta_xwayland_associate_window_with_surface() which is called on both
immediate and delayed paths.

https://gitlab.gnome.org/GNOME/mutter/issues/361
2019-02-25 17:53:52 +00:00
Robert Mader
803ffc19a4 shaped-texture: Clean-up deprecated NPOT check
There are most likely no GNOME users left still using hardware that
does not support NPOT textures. Further more, they would crash much
earlier and never hit this code-path. So remove the unnecessary check
here.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/447
2019-02-25 17:51:48 +01:00
Robert Mader
ddd2ce3a88 wayland/buffer: Fall back to CoglTexture2DSliced
XWayland creates buffers of the combined size of all connected displays.
This can, especially on older but still in use hardware, exceed the limits
of the GPU.

If that is the case, use `CoglTexture2DSliced` instead of `CoglTexture2D`

https://gitlab.gnome.org/GNOME/mutter/merge_requests/447
2019-02-25 17:51:44 +01:00
Jonas Ådahl
979e689278 renderer/native: Retry page flip after one vsync if EBUSY
We might fail to page flip a new buffer, often after resuming, due to
the FIFO being full. Prior to this commit, we handled this by switching
over to plain mode setting instead of page flipping. This is bad because
we won't be synchronized to the refresh rate anymore, but just the
clock.

Instead, deal with this by trying again until the FIFO is no longer
full. Do this on a v-sync based interval, until it works.

This also changes the error handling code for drivers not supporting
page flipping to rely on them returning -EINVAL. The handling is moved
from pretending a page flip working to explicit mode setting in
meta-renderer-native.c.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/460
2019-02-25 15:48:29 +00:00
Jonas Ådahl
2c1ab8b3cc renderer/native: Remove legacy non-stage-view code
A renderer view will, under the native backend, since long ago always
have a logical monitor associated with it, so remove the code handling
the legacy non-stage view case.

https://gitlab.gnome.org/GNOME/mutter/issues/460
2019-02-25 15:48:29 +00:00
Jonas Ådahl
252e64a0ea wayland: Move surface texture ownership to MetaWaylandSurface
Prior to this commit, MetaWaylandSurface held a reference to
MetaWaylandBuffer, who owned the texture drawn by the surface. When
switching buffer, the texture change with it.

This is problematic when dealing with SHM buffer damage management, as
when having one texture per buffer, damaged regions uploaded to one,
will not follow along to the next one attached. It also wasted GPU
memory as there would be one texture per buffer, instead of one one
texture per surface.

Instead, move the texture ownership to MetaWaylandSurface, and have the
SHM buffer damage management update the surface texture. This ensures
damage is processed properly, and that we won't end up with stale
texture content when doing partial texture uploads. If the same SHM
buffer is attached to multiple surfaces, each surface will get their own
copy, and damage is tracked and uploaded separately.

Non-SHM types of buffers still has their own texture reference, as the
texture is just a representation of the GPU memory associated with the
buffer. When such a buffer is attached to a surface, instead the surface
just gets a reference to that texture, instead of a separately allocated
one.

Fixes: https://gitlab.gnome.org/GNOME/mutter/issues/199
2019-02-25 15:35:38 +00:00
Jonas Ådahl
d2f1edd6c6 wayland/surface: Process damage also for non-actor surfaces
The texture still needs to be updated with damaged content.

https://gitlab.gnome.org/GNOME/mutter/issues/199
2019-02-25 15:35:38 +00:00
Jonas Ådahl
944a4763f6 cursor-renderer/native: Clear active CRTC gbm_bo when destroyed
When we freed the cursor GPU state including the gbm_bo objects attached
to it, we didn't unset the cursor renderer private of the CRTCs of the
associated GPU. This means that HW cursor invalidation could potentially
break if a new gbm_bo happened to be allocated at the same memory
address as the previous one.

To avoid this, iterate through the CRTCs of the GPU of which the cursor
data is freed, and unset the cursor renderer private if it was the one
destroyed.

https://gitlab.gnome.org/GNOME/mutter/issues/199
2019-02-25 15:35:38 +00:00
Jonas Ådahl
22a296f971 wayland/dma-buf: Don't use API meant for MetaWaylandSurface internally
What was actually done when calling meta_wayland_buffer_attach() was
that the texture was realized, so just call the function
`meta_wayland_dma_buf_realize_texture()` and call that.

This is in preparation to change how meta_wayland_buffer_attach() work.

https://gitlab.gnome.org/GNOME/mutter/issues/199
2019-02-25 15:35:38 +00:00
Benjamin Berg
ef2153739c idle-monitor: Fix duplicate return value of ResetIdletime call
The signal handler must return TRUE as the invocation is already handled
by returning an error. Also update the error message a bit to clarify
that the API exists only for testing purposes.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/457
2019-02-25 14:42:03 +00:00
Milo Casagrande
9e1c8e2c22 Update Italian translation 2019-02-22 11:07:11 +00:00
Florian Müllner
fca0e6abb1 Bump version to 3.31.91
Update NEWS.
2019-02-21 19:45:43 +01:00
Emilio Pozuelo Monfort
6975c8b424 monitor-config-manager: respect other outputs' CRTC
We should not only take the old CRTC for an output whenever
possible, but we should also assign one that is 'free', i.e.
one that another monitor (to be processed after this one)
isn't using, so that that monitor can use the same CRTC.

https://gitlab.gnome.org/GNOME/mutter/issues/373
2019-02-21 17:23:38 +02:00
Emilio Pozuelo Monfort
f4f823f238 monitor-config-manager: reuse old CRTC when possible
We shouldn't change an output's CRTC if we don't have to, as
that causes the output to go black.

This patch depends on
"monitor-unit-tests: initial crtcs in custom_lid_switch".

https://gitlab.gnome.org/GNOME/mutter/issues/373
2019-02-21 17:23:38 +02:00
Pekka Paalanen
1c67260bd4 monitor-unit-tests: initial crtcs in custom_lid_switch
This test forgot to specify the existing CRTC routings in the setup. For the
first output the default 0 was ok, now it is -1 to ensure that the code will
assign it correctly. For the second output the default 0 was incorrect, because
possible_crtcs does not include 0.  Now that CRTC is initialized to off
instead, because the second output is hotplugged later and running a CRTC
without an output does not make sense.

This fix will keep this test passing when a future patch attempts to preserve
existing CRTC routings. Assuming that any existing routing is valid, such
routing will be kept. In this test case the existing routing was illegal, it
should have been impossible, which then causes that future patch to fail the
test by assigning the wrong CRTC.

https://gitlab.gnome.org/GNOME/mutter/issues/373
2019-02-21 17:22:12 +02:00