compositor: Support output/buffer scaling
If you specify e.g. scale=2 in weston.ini an output section for the
X11 backend we automatically upscale all normal surfaces by this
amount. Additionally we respect a buffer_scale set on the buffer to
mean that the buffer is already in a scaled form.
This works with both the gl and the pixman renderer. The non-X
backends compile and work, but don't support changing the output
scale (they do downscale as needed due to buffer_scale though).
This also sends the new "scale" and "done" events on wl_output,
making clients aware of the scale.
diff --git a/src/compositor-headless.c b/src/compositor-headless.c
index 0df0f7d..e4bd1be 100644
--- a/src/compositor-headless.c
+++ b/src/compositor-headless.c
@@ -112,7 +112,7 @@
output->base.current = &output->mode;
weston_output_init(&output->base, &c->base, 0, 0, width, height,
- WL_OUTPUT_TRANSFORM_NORMAL);
+ WL_OUTPUT_TRANSFORM_NORMAL, 1);
output->base.make = "weston";
output->base.model = "headless";