Commit Graph

209 Commits

Author SHA1 Message Date
Armin K
49c36c6804 Don't fail if colord or libunwind are not present
This patch adds auto detection for presence of
the colord and libunwind packages.
2013-06-04 00:31:23 -04:00
Louis-Francis Ratté-Boulianne
6cd1de33ba toytoolkit: Make the window resizing optimization optional
Whether or not a shm pool is used for resizing is now configurable at
build time (--disable-resize-optimization).

[pq: removed an unnecessary hunk from the patch]
2013-05-22 18:07:30 -04:00
Pekka Paalanen
e31e053369 rpi: switch to rpi-renderer
Replace the GL renderer with the new rpi-renderer on the Raspberry Pi
backend. This makes Weston on rpi not use EGL or GL anymore, at all.

The weston_plane feature is disabled, since the rpi-renderer does the
same, but better.

Add a command line option to select the output transform. It is not a
weston.ini option for now, since the rpi backend does not read the
configuration file yet. Hopefully that will be done later with some
shared code.

Add the rpi options to 'weston --help' output.

Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk>
2013-05-22 18:06:01 -04:00
Mun Gwan-gyeong
fe097f95a3 configure.ac: colord version to 0.1.27 2013-05-20 17:29:28 -04:00
Richard Hughes
be7c4dd2a0 Add a colord implementation of a CMS plugin for weston
This allows users to change the assigned display profile in GNOME (using
gnome-control-center) or KDE (using colord-kde) and also allows the profiling
tools to correctly inhibit the calibration state whilst measuring the native
screen response.
2013-05-14 10:15:39 -04:00
Pekka Paalanen
7ff7a80007 clients: add subsurfaces demo
Add a demo program with:
- a main surface (green)
- a Cairo-image sub-surface (red)
- a raw GLESv2 widget (triangle)

Sub-surface input region is set empty to avoid problems in toytoolkit.

If Cairo links to libGL, then we will end up with also libGLESv2 linked
to subsurfaces program, and both libs getting really used, which leads
to disaster.

Do not build subsurfaces demo, if Cairo links to libGL and cairo-egl is
usable.

The GL rendering loop is not tied to the toytoolkit or the widget, but
runs directly from its own frame callback. Therefore it runs
independent of the rest of the application. This also relies on one of
two things:
- eglSwapInterval(0) is implemented, and therefore eglSwapBuffers never
  blocks indefinitely, or
- toytoolkit has a workaround, that guarantees that eglSwapBuffers will
  return soon, when we force a repaint on resize.
Otherwise the demo will deadlock.

The code is separated into three sections:

1. The library component, using only EGL, GLESv2, and libwayland-client
   APIs, and not aware of any toolkit details of the parent application.
   This runs independently until the parent application tells otherwise.

2. The glue code: a toytoolkit application widget, who has its own
   rendering machinery.

3. The application written in toytoolkit.

This patch also adds new toytoolkit interfaces:
- widget_get_wl_surface()
- widget_get_last_time()
- widget_input_region_add()

Toytoolkit applications have not had a possibility to change the input
region. The frame widget (decorations) set the input region on its own
when used, otherwise the default input region of everything has been
used. If a window does not have a frame widget, it can now use
widget_input_region_add() to set a custom input region.

These are not window methods, because a widget may lie on a different
wl_surface (sub-surface) than the window.

Changes in v3:
- replace set_commit_mode with set_sync and set_desync

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2013-05-10 14:35:53 -04:00
Richard Hughes
b24e48e2ff Add initial color management framework code
ICC profiles can now be specified in weston.ini for each output, or a CMS
implementation can optionally loaded from a pluggable module.
2013-05-10 12:51:08 -04:00
Kristian Høgsberg
2158a889a1 Import input structs and helper functions from wayland 2013-05-06 21:40:32 -04:00
Kristian Høgsberg
93c76fe4b1 configure.ac: Bump to 1.1.90 to open master for 1.2 work 2013-04-29 16:33:32 -04:00
Kristian Høgsberg
c08bc364fc configure.ac: Bump version to 1.1.0 2013-04-15 21:51:35 -04:00
Quentin Glidic
5daccc373e autotools: Add a libunwind configure switch
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
2013-04-03 14:31:44 -04:00
Hardening
a83409cbff RDP compositor take 6
This patch is the 6th version of the FreeRDP based compositor.
Changes from last version:
 * use pixman_image_get_stride() when appropriate
 * always realloc

Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2013-04-01 20:50:54 -04:00
Damien Lespiau
b5bae3450c build: Make the X11 compositor explicitely depend on xcb-shm
Otherwise, it means the X11 compositor depends on another library to
pull xcb-shm (cairo?), which is not always the case. Here I end up with:

[01:54:38.970] Failed to load module:
$prefix/lib/weston/x11-backend.so: undefined symbol: xcb_shm_id
2013-03-28 12:18:51 -04:00
Kristian Høgsberg
383b60fad5 configure.ac: Use automake color-tests 2013-02-28 14:57:00 -05:00
Quentin Glidic
f14977f854 tests: Use&Fix parallel tests
Also fix automake 1.13 support

Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
2013-02-22 08:35:22 -05:00
Quentin Glidic
bb41005259 configure.ac: Make xwayland tests depend on xwayland
Signed-off-by: Quentin Glidic <sardemff7+git@sardemff7.net>
2013-02-18 16:03:51 -05:00
Kristian Høgsberg
af4f2aaf19 Install header files and pkg-config file for external modules
This patch installs the three header files that define the compositor
plugin interface as well as a pkg-config file.  This allows
building weston plugins outside the weston tree.  We currently don't make
any guarantees about the plugin API/ABI except that within a stable
branch we won't break it.
2013-02-18 15:29:35 -05:00
Marcin Slusarz
554a0da74a compositor: Use libunwind if available for better backtraces
libunwind has a dwarf parser and automatically queries the dlinfo
for location of dlopened modules.  The resulting backtrace is much
better and includes stack frames in dynamically loaded modules.

krh: Originally submitted for Xorg, adapted for weston:

  http://lists.x.org/archives/xorg-devel/2013-February/035493.html

Note this require libunwind at least 1.1 to get the pkg-config files.

Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
2013-02-18 15:29:17 -05:00
Jan Arne Petersen
0a1cf393c6 editor: add support for pre-edit styling
Add pango dependency to the example and use pango for text handling.

Signed-off-by: Jan Arne Petersen <jpetersen@openismus.com>
2013-02-15 16:57:37 -05:00
Kristian Høgsberg
3c087e4e29 configure.ac: Add version to bug URL as well 2013-02-14 12:10:03 -05:00
Scott Moreau
bf0f4b9d21 configure.ac: Change bugs.freedesktop.org product to Wayland
Update the bug link. Thanks to Rune K. Svendsen for spotting this.

https://bugs.freedesktop.org/show_bug.cgi?id=60818
2013-02-14 12:09:53 -05:00
Tiago Vignatti
19dadf2617 tests: Add XWayland test
By default enabled but one can disable it by passing --disable-xwayland-test
to the configure script. Also, the weston-tests-env script is trying to load
xwayland.so in either case, but it behaves resilient in the absence of that
meaning all the other tests are still going to be kicked for running.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2013-02-08 12:18:05 -05:00
Konno, Joe
314d988b28 configure: prevent premature HAVE_GLU check
When cairo-gl and mesa-glu are present on the system, autoconf successfully
recognizes both. However, I was wondering why weston-screensaver was not
building since autoconf reported all dependencies were met.

Move the mesa-glu PKG_CHECK before the conditional. Additionally, remove
redundant check for enable_egl, as it is implied when GLU is 'yes.'

Signed-off-by: Joe Konno <joe.konno@intel.com>
2013-02-07 21:20:07 -05:00
Philip Withnall
4f49917ec5 fbdev: Add an fbdev compositor backend using pixman and evdev
Add a frame buffer backend using pixman to render to fbdev.
This has been tested against nouveaufb but nothing else. Much of the code
came straight from the rpi backend (and copyright has been attributed
accordingly).

The behaviour of this backend on less modern frame buffers has yet to be
tested.

The refresh rate is calculated from the frame buffer's metadata. Every frame
is finished in synchrony with the refresh rate.

Frame buffer devices are currently specified on the command line (or using
the default of /dev/fb0); udev could be used in future to enumerate them.

pixman is used for compositing, and a suitable pixman format is built from
the frame buffer's metadata. This doesn't support the full range of
frame buffer formats, but does support varying BPPs of RGBA and ARGB. That
should be enough for now.

The following are not currently supported:
 • FOURCC
 • Non-packed formats (interleaved, planes, etc.)
 • Non-true-colour formats (monochrome, greyscale, etc.)
 • Big-endian formats (with component MSBs on the right)
 • Non-RGBA and non-ARGB formats

Signed-off-by: Philip Withnall <philip@tecnocode.co.uk>
2013-02-07 20:49:22 -05:00
Kristian Høgsberg
4174791d9e configure.ac: Bump git master version to 1.0.90
We use 1.0.90 as the version number for the git master code.  This way it's
always newer than any stable version.
2013-02-02 10:32:25 -05:00
Pekka Paalanen
a95efd3bb7 configure: remove C++ support
With the Android backend gone, there is no C++ code anymore. Remove
support for C++ in the build.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2013-01-24 16:30:08 -05:00
Pekka Paalanen
a87ccdc993 compositor: remove android backend
The Android backend has been fairly unused, since we do not have
projects actively using it. It gets basic build testing as part of the
normal build, but runtime testing it takes a considerable effort, and so
I have not done that in a long time. The code is slowly rotting, and
with new emerging backends it starts to be a burden, since it cannot use
udev, but needs evdev.

Therefore to ease Weston going forward, remove the Android backend. If
someone misses it, it can still be found in the stable 1.0 branch, and
of course resurrected from git history if someone wants to put in the
effort and maintain it.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2013-01-24 16:30:04 -05:00
Kristian Høgsberg
f82a80675c configure.ac: Indent --disable-egl option correctly 2013-01-09 13:36:39 -05:00
Vasily Khoruzhick
1bfe2e6f4b Make EGL/GLESv2 dependencies optional
Introduce --disable-egl switch for configure to disable
EGL/GLESv2 support.

Signed-off-by: Vasily Khoruzhick <anarsoul@gmail.com>
2013-01-08 15:32:00 -05:00
Kristian Høgsberg
6006ecb497 configure.ac: Don't link weston to cairo or image libraries
We were pulling in cairo and the image loading libraries through libshared.
Split out libshared into a core libshared and a libshared-cairo that
pulls in the extra libraries.
2012-11-29 13:32:11 -05:00
Pekka Paalanen
e8de35c922 rpi: a backend for Raspberry Pi
Add a new backend for the Raspberry Pi.

This backend uses the DispmanX API to initialise the display, and create
an EGLSurface, so that GLESv2 rendering is shown on the "framebuffer".
No X server is involved. All compositing happens through GLESv2.

The created EGLSurface is specifically configured as buffer content
preserving, otherwise Weston wouuld show only the latest damage and
everything else was black. This may be sub-optimal, since we are not
alternating between two buffers, like the DRM backend is, and content
preserving may imply a fullscreen copy on each frame.

Page flips are not properly hooked up yet. The display update will
block, and we use a timer to call weston_output_finish_frame(), just
like the x11 backend does.

This backend handles the VT and tty just like the DRM backend does.
While VT switching works in theory, the display output seems to be
frozen while switched away from Weston. You can still switch back.

Seats and connectors cannot be explicitly specified, and multiple seats
are not expected.

Udev is used to find the input devices. Input devices are opened
directly, weston-launch is not supported at this time. You may need to
confirm that your pi user has access to input device nodes.

The Raspberry Pi backend is built by default. It can be build-tested
without the Raspberry Pi headers and libraries, because we provide stubs
in rpi-bcm-stubs.h, but such resulting binary is non-functional. If
using stubs, the backend is built but not installed.

VT and tty handling, and udev related code are pretty much copied from
the DRM backend, hence the copyrights. The rpi-bcm-stubs.h code is
copied from the headers on Raspberry Pi, including their copyright
notice, and modified.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-11-08 16:56:26 -05:00
Pekka Paalanen
a51e6fa322 build: make default backend configurable
Instead of hardcoding drm-backend.so as the default if environment
presents neither Wayland nor X11, have a ./configure option to change
it. It still defaults to drm-backend.so, if not given.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-11-08 16:56:25 -05:00
Ander Conselvan de Oliveira
11f8d403a8 Add a headless backend
Add a headless backend and a noop renderer, mainly for testing
purposes. Although no rendering is performed with this backend,
this allow some of the code paths inside Weston and shm clients
to be tested without any windowing system or any need for drm
access.
2012-11-08 16:56:25 -05:00
Kristian Høgsberg
191e0eee77 simple-egl: Add a default cursor
If clients don't set a cursor, they get whatever the last cursor was
before the pointer entered their window.  That's a little confusing, so
set a pointer on enter to avoid that.  The down-side is that simple EGL
isn't very simple anymore.

https://bugs.freedesktop.org/show_bug.cgi?id=52452
2012-10-29 17:41:46 -04:00
Kristian Høgsberg
b98905e810 configure.ac: Check for libGLU for screensaver
https://bugs.freedesktop.org/show_bug.cgi?id=56376
2012-10-29 13:44:33 -04:00
Kristian Høgsberg
42470cfc49 configure.ac: Bump version to 1.0.0 2012-10-22 18:50:03 -04:00
Pekka Paalanen
379d3d140d configure: build tablet-shell client conditionally
Do not build the tablet-shell client if --disable-tablet-shell is given.

Change --enable-tablet-shell to --disable-tablet-shell in ./configure
--help output, since it is enabled by default. Add a description.

Use proper quoting in the conditional.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-10-16 10:49:08 -04:00
Pekka Paalanen
5f8a67cce8 configure: separate simple EGL clients from others
Separate simple EGL clients from other simple clients. This allows to
build either simple-shm or simple-egl, whichever you want. We avoid
linking libEGL and GLESv2 into simple-shm, and we can build simple-shm
even if nothing provides EGL, GLESv2, or wayland-egl APIs.

Change the options in configure --help from --enable to --disable, since
these are enabled by default, and you would normally only ever give the
--disable flavor. Add descriptions.

Remove the #define BUILD_SIMPLE_CLIENTS since it is not used.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-10-16 10:48:19 -04:00
Pekka Paalanen
fb39d8d23c toytoolkit: make all EGL code dependant on cairo-egl
configure.ac: The toytoolkit clients used to get libEGL linked to them
even if there was no cairo-egl. This is useless, and actually harmful on
platforms, where libEGL absolutely requires one of the GL ES libraries
to be linked in, too.

Look for EGL-related packages only for cairo-egl with toytoolkit.

window.c: protect all GL header includes with HAVE_CAIRO_EGL, since that
is the only case we can support EGL, GL, or GLESv2 at all. In the case
we do not have cairo-egl, add enough definitions to let us build the
stubs for EGL-related functions.

Remove some #ifdefs that were inside of the same #ifdef already.

These changes allow to build sorfware rendering toytoolkit clients
without any bits of EGL libs or headers.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-10-16 10:47:22 -04:00
Pekka Paalanen
de7fe62a54 configure: fix --without-cairo-glesv2
Make it do what you would think it does, instead of enabling GLESv2.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-10-16 10:46:52 -04:00
Pekka Paalanen
e46289795f configure: tell why cairo-egl could not be used
Otherwise the user has no indication which package is missing for
CAIRO_EGL, and has to dig into config.log for it.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-10-16 10:46:32 -04:00
Kristian Høgsberg
f255690e54 configure.ac: Bump version to 0.99.0 2012-10-15 21:49:23 -04:00
Pekka Paalanen
a91291c4d6 man: add man page for weston
It is not complete, but has lots of stuff already.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-08-29 15:32:05 -04:00
Philipp Brüschweiler
585acb0013 weston-info: client that print out information about the running compositor
This includes seat capabilities, shm formats and output information.
2012-08-15 11:40:42 -04:00
Pekka Paalanen
4b141597c6 configure: make setbacklight optional
Modify the pkg-config check for setbacklight so that failure only
disables building setbacklight, instead of failing the whole configure.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-08-03 13:32:43 -04:00
Pekka Paalanen
4ddf1b2c4d android: add basic evdev input support
Android backend needs mtdev now, and evdev-touchpad.c, too.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-08-03 13:32:26 -04:00
Pekka Paalanen
d9a8e16b7b compositor: remove OpenWFD backend
This backend has not seen even build testing for months, presumably does
not even compile, and is starting to hinder development a little.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
Cc: Benjamin Franzke <benjaminfranzke@googlemail.com>
2012-08-01 10:09:53 -04:00
Tiago Vignatti
4f238a590d configure: link image libs with libshared
This fix xwayland.so that was complaining about jpeg symbols from the
libshared.

Note that xwayland is not using the jpeg ones, but now that symbols are read
up front we need to link anyway.. or break apart that library.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-07-31 22:34:21 -04:00
Damien Lespiau
ea40bf88bc tests: Use pkg-config to find setbacklight CFLAGS and libs
setbacklight depends on udev and drm, one cannot just add the -l flags
if you want to support unusual install paths.
2012-07-25 10:40:11 -04:00
Kristian Høgsberg
e302b3ef77 Bump version to 0.95.0 2012-07-24 16:01:29 -04:00
Kristian Høgsberg
8d25a5a633 configure.ac: Don't require vpx now that we don't build the webm encoder 2012-07-20 18:05:10 -04:00
Kristian Høgsberg
71375066a4 Never install weston setuid
We don't support this anymore.  weston requires a setuid helper (such as
weston-launch) to run under kms, and should never run as root itself.

Disabe the setuid warning in configure.ac since we now only install the
minimal weston-launch as setuid.
2012-07-19 14:17:58 -04:00
Tiago Vignatti
90fada4338 xwayland: add simple xcb-cursor hook based on libXcursor
It's in fact based on the core of libXcursor, which doesn't bring any Xlib
dependency.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-07-16 13:35:27 -04:00
Kristian Høgsberg
e28fd7d5e0 configure.ac: Bump version to 0.94.90 2012-06-25 21:35:42 -04:00
Daniel Stone
62b33b6964 compositor-x11: Add base XCB/XKB support
Try to find the XKB extension, to be used in later commits.

Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-06-22 11:52:06 -04:00
Pekka Paalanen
b7a9498a8e compositor: add fallback strchrnul()
Android does not have this function.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-06-12 12:29:13 -04:00
Pekka Paalanen
1da1b8f3f1 Rewrite shm buffer file allocation v2
We had duplicated code in many places, using hardcoded paths for
temporary files into more than one path. Some cases did not bother with
O_CLOEXEC, and all hardcoded paths that might not exist.

Add an OS helper function for creating a unique anonymous file with
close-on-exec semantics. The helper uses $XDG_RUNTIME_DIR as the
directory for a file.

This patch unifies the buffer file creation in both Weston and the
clients.

As simple clients are better not linking to libshared, as it would
require e.g. Cairo, they pull the OS compatibility code directly.

Android does not have mkostemp(), so a configure test is added for it,
and a fallback used if it is not available.

Changes in v2:
	remove all the alternate possible directory definitions and use
	XDG_RUNTIME_DIR only, and fail is it is not set.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-06-06 13:26:30 -04:00
Pekka Paalanen
15643f627d build: introduce GCC_CXXFLAGS
The patch "compositor-android: fix build flags" started using GCC_CFLAGS
for C++ files, too. That lead to the following warnings when building a
C++ file:

cc1plus: warning: command line option "-Wstrict-prototypes" is valid for
Ada/C/ObjC but not for C++
cc1plus: warning: command line option "-Wmissing-prototypes" is valid
for Ada/C/ObjC but not for C++

Introduce GCC_CXXFLAGS, similar to GCC_CFLAGS, but for C++, avoiding the
problematic compiler flags.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-06-01 10:32:39 -04:00
Pekka Paalanen
3ae50bb45c Add Android backend
The Android backend provides basic EGL/GLES2 graphics, where everything
is always composited. Overlays are not used. Input is stubbed, therefore
there is no input yet.

This adds the first C++ source file into Weston compositor. The Android
gralloc and fb HAL glue code to the Android EGL library is in C++, and
there is no way to access it from plain C. We have a simple wrapper to
the required C++ class API. Android forces the C++ file name extension
to .cpp.

The android backend is compiled by default. However, all Android
specific calls are protected with #ifdef ANDROID, so it will build also
without Android headers. The binary produced without the Android build
system is useless, but allows build-testing generic Weston changes.
Therefore the android backend is not installed.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-05-31 13:54:01 -04:00
Pekka Paalanen
200019c0c6 compositor: check for execinfo.h
Some systems may not have execinfo.h. Add a configure test for it, and
if it is not found, make the backtrace() call a no-operation.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-05-31 13:52:24 -04:00
Kristian Høgsberg
61cfa66d6f wcap: Add option to disable building wcap tools 2012-05-26 13:19:22 -04:00
Tiago Vignatti
629ce23bd0 xwayland: change library name
Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-05-25 22:54:40 -04:00
Kristian Høgsberg
2bcb2fc1fd wcap: Rename wcap-encode to just wcap 2012-05-25 18:03:52 -04:00
Kristian Høgsberg
89060c0a8b Import vpxenc from libvpx as a starting point 2012-05-25 11:59:53 -04:00
Ander Conselvan de Oliveira
1042dc15e0 window: use libwayland-cursor instead of libXcursor 2012-05-22 10:17:34 -04:00
Kristian Høgsberg
a921901369 Move xwayland integration into xwayland subdirectory 2012-05-21 17:03:16 -04:00
Kristian Høgsberg
c0a7ff5524 configure: Add pixman-1 to the compositor required packages
We used to get it through the IMAGE_LIBS/CFLAGS but we use it directly
in the compositor to add it as a direct dependency.
2012-05-15 22:54:33 -04:00
Kristian Høgsberg
5a315bc72d Move cairo-util to shared/ 2012-05-15 22:33:43 -04:00
Kristian Høgsberg
13e8e4717e xwm: Reparent X windows, paint a red decoration frame
It's red, and that's about it.
2012-05-15 09:28:38 -04:00
Daniel Stone
db095ff3c3 Link compositors to xkbcommon as well
Signed-off-by: Daniel Stone <daniel@fooishbar.org>
2012-05-08 16:04:21 -04:00
Rob Bradford
eb95d0de7e build: Tighten mtdev dependency to reflect requirement
The mtdev_new_open symbol was added in 1.1.0.
2012-05-08 10:02:32 -04:00
Ander Conselvan de Oliveira
1493d2ae1c window: use libXcursor for loading pointer images 2012-05-03 10:14:04 -04:00
Kristian Høgsberg
6412718c0d Always build tests
There are no dependencies or requirements there that we don't already
need for weston itself.  So lets just always build them.

Use check_PROGRAMS for the matrix unit test case.
2012-04-11 09:38:32 -04:00
Benjamin Franzke
bfeda130de Introduce weston-launch
weston-launch starts weston and provides mechanism
for weston to set/drop drm master, open a tty,
and read input devices without being root.

Execution is allowed for local-active sessions
or users in the group weston-launch.
2012-04-06 14:01:19 +02:00
Kristian Høgsberg
875ab9e735 Add signedness warning flag and fix fallout 2012-03-30 11:52:39 -04:00
Tiago Vignatti
23fdeedf82 evdev: use mtdev for multitouch devices
mtdev library translates all multitouch based devices to the slotted evdev
protocol. It provides an uniform interface for Weston, which eases mt
implementation when dealing with a big variety of devices.

Weston on drm now directly depends on such library.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
Reviewed-by: Peter Hutterer <peter.hutterer@who-t.net>
2012-03-20 22:43:56 -04:00
Eric Anholt
0e8d48b920 configure: Fix build on debian by avoiding bashisms in the test command. 2012-03-13 12:39:00 -07:00
Kristian Høgsberg
f02a649a3c Consolidate image loading code and move to shared/ 2012-03-12 01:40:59 -04:00
Kristian Høgsberg
51cba3ca38 compositor-drm: Just pull in libbacklight source for now
libbacklight is 300 lines of code in one .c file, and we're relying on
udev changes that aren't yet upstream.  For now, let's just keep a
copy in weston and if the Xorg DDX drivers start using libbacklight and
it becomes more widely available, we'll make it an external dependency.
2012-02-29 14:23:51 -05:00
Tiago Vignatti
8e53c7f566 compositor: add dpms and backlight support
DPMS kicks in only when wscreensaver is launched, in the moment that shell
call lock() for the second time. Backlight control internals are managed by
libbacklight:

	http://cgit.freedesktop.org/~vignatti/libbacklight/

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
2012-02-29 14:01:56 -05:00
Jesse Barnes
58ef379be6 compositor-drm: Add sprite support
Add support for assigning surfaces to overlay sprites using the new
assign_planes hook.
2012-02-23 20:12:31 -05:00
Eric Anholt
6f82cf5dc5 configure: Fix build on debian by avoiding bashisms in the test command. 2012-02-09 14:17:54 -05:00
Kristian Høgsberg
3b03b3d68e Use dist-xz for tarballs 2012-02-09 14:17:49 -05:00
Kristian Høgsberg
a7313e7cf4 configure: Change project to weston, set version to 0.89 2012-02-09 09:17:47 -05:00
Kristian Høgsberg
3d5437c48d Add support for webp image format 2012-02-08 12:46:57 -05:00
Jesse Barnes
3bd6917199 configure.ac: fix cairo-glesv2 help text
Finally figured out why --enable-cairo-gles2 wasn't working like
configure --help said it should.
2012-02-07 16:17:51 -05:00
Pekka Paalanen
0e4452e02a configure: add libpng to client libs
http://lists.freedesktop.org/archives/wayland-devel/2012-January/001975.html
reports a linking problem:

/usr/bin/ld: libtoytoolkit.a(cairo-util.o): undefined reference to
symbol 'png_set_filler@@PNG12_0'
/usr/bin/ld: note: 'png_set_filler@@PNG12_0' is defined in DSO
/usr/lib/i386-linux-gnu/libpng12.so.0 so try adding it to the linker command line
/usr/lib/i386-linux-gnu/libpng12.so.0: could not read symbols: Invalid
operation
collect2: ld returned 1 exit status
make[3]: [weston-terminal] Error 1 (ignored)

A similar problem is diagnosed here:
http://lists.fedoraproject.org/pipermail/devel/2010-March/133601.html

As some distros are shipping linkers, that do not resolve symbols from
implicitly linked libraries, check and link libpng explicitly.

Cc: nerdopolis <bluescreen_avenger@verizon.net>
Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-02-01 12:12:19 +02:00
Pekka Paalanen
f571d63372 configure: use --disable-tests, since default is enabled
Add a nice help text, too.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-01-31 09:41:06 -05:00
Pekka Paalanen
51d2195937 configure: toytoolkit GL apps depend on cairo-egl
Do not build toytoolkit applications that use GL, if Cairo-egl is not
available. These applications (which happen to be also the full GL
clients) do not work at all without Cairo-egl, and fail at runtime with
"unable to acquire window surface".

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-01-31 09:40:27 -05:00
Pekka Paalanen
4520d5cafb tests: add matrix-test
Add a new directory tests/ for unit test applications. This directory
will be built only if --enable-tests is given to ./configure.

Add matrix-test application. It excercises especially the
weston_matrix_invert() and weston_matrix_inverse_transform() functions.
It has one test for correctness and precision, and other tests for
measuring the speed of various matrix operations.

For the record, the correctness test prints:

a random matrix:
   1.112418e-02   2.628150e+00   8.205844e+02  -1.147526e-04
   4.943677e-04  -1.117819e-04  -9.158849e-06   3.678122e-02
   7.915063e-03  -3.093254e-04  -4.376583e+02   3.424706e-02
  -2.504038e+02   2.481788e+03  -7.545445e+01   1.752909e-03

The matrix multiplied by its inverse, error:
   0.000000e+00  -0.000000e+00  -0.000000e+00  -0.000000e+00
   0.000000e+00   0.000000e+00   0.000000e+00   0.000000e+00
  -0.000000e+00  -0.000000e+00   0.000000e+00  -0.000000e+00
   0.000000e+00   0.000000e+00   0.000000e+00   0.000000e+00
max abs error: 0, original determinant 11595.2

Running a test loop for 10 seconds...
test fail, det: -0.00464805, error sup: inf
test fail, det: -0.0424053, error sup: 1.30787e-06
test fail, det: 5.15191, error sup: 1.15956e-06
tests: 6791767 ok, 1 not invertible but ok, 3 failed.
Total: 6791771 iterations.

These results are expected with the current precision thresholds in
src/matrix.c and tests/matrix-test.c. The random number generator is
seeded with a constant, so the random numbers should be the same on
every run. Machine speed and scheduling affect how many iterations are
run.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2012-01-27 10:44:22 +02:00
Kristian Høgsberg
44d4de656b configure: Add --enable-setuid-install
This adds support for installing the compositor setuid.
2012-01-19 13:32:17 -05:00
Kristian Høgsberg
2d57439592 clients: Allow compiling with the cairo glesv2 backend
This disables gears and wscreensaver, which use full GL.
2012-01-18 14:50:58 -05:00
Richard Hughes
2f6219f127 Explicitly add GIO to the client libs
This prevents a build warning on Fedora 16 of:
   undefined reference to symbol 'g_file_get_basename'
2012-01-13 13:01:25 -05:00
Kristian Høgsberg
ab5dacdac8 view: Make view compile again 2012-01-12 10:48:51 -05:00
Kristian Høgsberg
f6a5f7def3 Fix distcheck 2012-01-03 11:04:09 -05:00
Kristian Høgsberg
8334bc1ef9 Rename wayland-compositor to weston
This rename addresses a few problems around the split between core
Wayland and the wayland-demos repository.

1) Initially, we had one big repository with protocol code, sample
compositor and sample clients.  We split that repository to make it
possible to implement the protocol without pulling in the sample/demo
code.  At this point, the compositor is more than just a "demo" and
wayland-demos doesn't send the right message.  The sample compositor
is a useful, self-contained project in it's own right, and we want to
move away from the "demos" label.

2) Another problem is that the wayland-demos compositor is often
called "the wayland compsitor", but it's really just one possible
compositor.  Existing X11 compositors are expected to add Wayland
support and then gradually phase out/modularize the X11 support, for
example.  Conversely, it's hard to talk about the wayland-demos
compositor specifically as opposed to, eg, the wayland protocol or a
wayland compositor in general.

We are also renaming the repo to weston, and the compositor
subdirectory to src/, to emphasize that the main "output" is the
compositor.
2012-01-03 11:04:04 -05:00
Kristian Høgsberg
e7aaec301a x11: Bridge X11 CLIPBOARD selection to Wayland clients 2011-12-27 13:50:04 -05:00
Pekka Paalanen
c1765c67b3 move config parser to a convenience library
Create a new directory for convenience librariers that can be shared
between compositor components and clients.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
2011-12-08 10:25:12 +02:00
Kristian Høgsberg
64f1c3fd52 De-brand the tablet shell
Drop the MeeGo part of the name.
2011-11-14 15:57:59 -05:00
Kristian Høgsberg
27d3866045 cairo-util: Add helper to load jpeg files 2011-10-20 13:11:12 -04:00