1
0
Fork 0
Commit graph

22 commits

Author SHA1 Message Date
Jonas Ådahl
d050fdb17f monitor-manager: Add per backend capabilities
Add a private API for querying backend capabilities. For now, only
mirroring capability is reported.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-04-07 22:30:47 +08:00
Jonas Ådahl
9e8ee491e6 monitor-manager: Add API to get scales supported by the backend
For the Xrandr backend, only scale 1 is supported, for the others, 1
and 2 are reported as supported.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-04-07 22:30:47 +08:00
Jonas Ådahl
fcc0288f0c monitor-manager: Let the backends handle no configuration
Let the backends decide whether to just rebuild a derived state, or use
the NULL config to rebuild an empty logical state.

This also changes the expected screen size values of the no-outputs
test; as this case is actually handled now.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-04-07 22:30:47 +08:00
Jonas Ådahl
a393a614a1 monitor-manager: Remove 'scale' from MetaOutput
Replace the 'scale' of an output with a vfunc on the MetaMonitorManager
class that takes a monitor and a monitor mode which calculates the
scale. On X11 this always returns 1, on KMS, the old formula is used.
On the dummy and test backends, the already configured values are
returned.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-04-07 22:30:46 +08:00
Jonas Ådahl
1039386e10 backend/x11/nested: Enable emulating offscreen transform framebuffer
Enable the usage of an offscreen transform texture, as used in the
native backend when the GPU doesn't support the transform configured.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
944339f6a5 monitor-manager: Expose whether the backend handles a transform
Expose via a new API whether the transform on a logical monitor is
handled by the backend. This was previously only exposed only in the
native backend. This will be used to emulate not supporting transforms
in the backend in the nested backend.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
4f386e5131 monitor-manager-dummy: Add way to emulate tiled monitors
By setting the environment variable MUTTER_DEBUG_TILED_DUMMY_MONITORS
to "1", the dummy MetaMonitorManager backend used when running mutter
nested will create tiled monitors instead of single-output/CRTC
monitors. This makes it possible to test tiled monitor configuration.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
3ace913aed monitor-manager-dummy: Add non-preferred mode
Add an extra mode besides the preferred one. This makes it possible to
test monitor configuration paths when running nested.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
8f2daed9e0 monitor-manager-dummy: Refactor monitor generation
Refactor monitor generation by splitting the generation of modes, CRTCs
and outputs into a separate function. A side effect is that each output
will have its own set of possible modes.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
979bc4390a monitor-manager-dummy: Don't set up state at the wrong time
Don't set the CRTC rect and screen size at in read_current(), as those
depends on how the configuration is done. Instead, don't set the CRTC
rect at all, and update the screen dimensions when being configured.

https://bugzilla.gnome.org/show_bug.cgi?id=779745
2017-03-09 10:17:30 +08:00
Jonas Ådahl
644ee666f6 Introduce new monitor configuration system
The new monitor configuration system (MetaMonitorConfigManager) aims to
replace the current MetaMonitorConfig. The main difference between the
two is that MetaMonitorConfigManager works with higher level input
(MetaMonitor, MetaMonitorMode) instead of directly looking at the CRTC
and connector state. It still produces CRTC and connector configuration
later applied by the respective backends.

Other difference the new system aims to introduce is that the
configuration system doesn't manipulate the monitor manager state; that
responsibility is left for the monitor manager to handle (it only
manages configuration and creates CRTC/connector assignments, it
doesn't apply anything).

The new configuration system allows backends to not rely on deriving the
current configuration from the CRTC/connector state, as this may no longer be
possible (i.e. when using KMS and multiple framebuffers).

The MetaMonitorConfigManager system is so far disabled by default, as
it does not yet have all the features of the old system, but eventually
it will replace MetaMonitorConfig which will at that point be removed.
This will make it possible to remove old hacks introduced due to
limitations in the old system.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-01-25 16:28:55 +08:00
Jonas Ådahl
ee0677a021 monitor-manager: Let backend implementations handle inital config
How the initial configuration is done depends on the backend, so let
them do it themself.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-01-25 16:28:55 +08:00
Jonas Ådahl
0873e3812b backends: Rename MetaMonitorMode to MetaCrtcMode
The MetaMonitorMode referred to the mode of a CRTC, and with the future
introduction of a MetaMonitor, theh old name would be confusing.
Instead call it what it is.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-01-25 16:28:53 +08:00
Jonas Ådahl
1650c35e38 monitor-manager: Rename MetaCRTC(Info) to MetaCrtc(Info)
Change to follow the naming convention used everywhere else. This means
changing CRTC to Crtc even though it is an abbreviation.

https://bugzilla.gnome.org/show_bug.cgi?id=777732
2017-01-25 16:28:53 +08:00
Florian Müllner
bc00f118f3 Avoid shadowing existing variables 2015-09-24 03:08:22 +02:00
Jonas Ådahl
bede9970de nested: Allow configuration of dummy output configuration
Enable a user to test and debug multi output configurations on Wayland
without having the available hardware by enabling some basic
configuration of the dummy monitor manager.

Currently available configuration options are:

MUTTER_DEBUG_NUM_DUMMY_MONITORS - to set the number of monitors
MUTTER_DEBUG_DUMMY_MONITOR_SCALES - to configure the monitor scales

See src/backends/meta-monitor-manager-dummy.c for detailed description
of the available configuration parameters.

https://bugzilla.gnome.org/show_bug.cgi?id=747089
2015-07-15 14:55:55 +08:00
Jonas Ådahl
301a65e05a backends/dummy: Set scale of dummy output
To make the nested compositor mode work again after "backends/native:
Calculate the output scale in here", set the scale when creating the
dummy output.

https://bugzilla.gnome.org/show_bug.cgi?id=745401
2015-03-02 10:58:16 +08:00
Jasper St. Pierre
57af975154 monitor-manager-dummy: Fill in connector_type 2014-12-29 17:15:23 -08:00
Jasper St. Pierre
eb952819c2 monitor: Don't use wl_output_transform in our APIs
Invent our own API so we can build without Wayland headers.
2014-07-13 11:35:01 -04:00
Jasper St. Pierre
af135c0b0b monitor-manager: Rename output_id to winsys_id
The output_id is more of an opaque identifier for the monitor, based on
its underlying ID from the windowing system. Since we also use the term
"output_id" for the output's index, rename our use of the opaque cookie
"output_id" to "winsys_id".
2014-07-01 13:24:34 -04:00
Jasper St. Pierre
899d4d8477 monitor-manager: Move default get_edid_file / read_edid to base class
These are also used by the native manager.
2014-04-01 10:24:34 -04:00
Jasper St. Pierre
229360b248 Start molding out a new src/backends/ dir
Right now this just has all of the files in one directory. We'll
be introducing more structure to this in the future, and build
a proper backend system.
2014-03-31 22:11:00 -04:00
Renamed from src/core/meta-monitor-manager-dummy.c (Browse further)