profile/ivi/weston.git
12 years agofix build for --disable-clients --enable-simple-clients
Pekka Paalanen [Tue, 17 Apr 2012 13:49:12 +0000 (16:49 +0300)]
fix build for --disable-clients --enable-simple-clients

Simple clients were relying on AM_CFLAGS and AM_CPPFLAGS set for
toytoolkit clients. With toytoolkit clients disabled, the build fails
with missing wayland-client.h.

Move AM_CFLAGS and AM_CPPFLAGS outside of conditional sections, since
they are meant to be global settings.

Let simple clients override AM_CPPFLAGS with their own
SIMPLE_CLIENT_CFLAGS, which the configure script already sets up for us,
but was unused until now.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agosimple-shm: no need for wayland-egl.h
Pekka Paalanen [Tue, 17 Apr 2012 13:34:47 +0000 (16:34 +0300)]
simple-shm: no need for wayland-egl.h

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agosimple-shm: handle shm buffer failure
Pekka Paalanen [Wed, 18 Apr 2012 10:23:09 +0000 (13:23 +0300)]
simple-shm: handle shm buffer failure

Do not segfault, if creating the shm buffer fails.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: report .so path when load_module() fails
Pekka Paalanen [Thu, 26 Apr 2012 07:31:36 +0000 (10:31 +0300)]
compositor: report .so path when load_module() fails

I want to know which module is failing to load with unresolved symbols.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agosimple-shm: render meaningful diagnostics
Pekka Paalanen [Thu, 26 Apr 2012 12:14:50 +0000 (15:14 +0300)]
simple-shm: render meaningful diagnostics

Previously, simple-shm was rendering an image that looked like stride
gone wrong somewhere, and was quite confusing if you did not know it was
supposed to look like that.

Replace the drawing code. Two circles, inner and outer, now delimit
three co-centric areas. The outmost area from surface borders to outer
circle contains horizontal gradients that move (animate) to the left.
The area between outer and inner circles contains vertical gradients
that move upwards. The center disc has circular gradients moving towards
the center.

The circles are not ellipses.

Diagnostics:
The X-channel is manipulated so, that if a compositor takes the XRGB
image, and uses the X channel as alpha instead of ignoring it, the whole
image will be crossed out by two lines that either quickly saturate to
white or show through with additive blending. Does not work on black
background.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agogears: Allow model rotation with pointer
Scott Moreau [Tue, 24 Apr 2012 17:28:26 +0000 (11:28 -0600)]
gears: Allow model rotation with pointer

12 years agoshell-animation: add conf option in shell
Juan Zhao [Wed, 25 Apr 2012 11:09:52 +0000 (19:09 +0800)]
shell-animation: add conf option in shell

Now we can choose zoom or fade in weston.ini
to fulfill and customize the user experence easier.

Signed-off-by: Juan Zhao <juan.j.zhao@intel.com>
12 years agoanimation: add fading-in animation
Juan Zhao [Wed, 25 Apr 2012 11:09:51 +0000 (19:09 +0800)]
animation: add fading-in animation

To ful-fill user experience, add the fading-in animation
when mapping a window.
v2: update that westom_surface_damage to repaint
    remove that transform part in fade struct

Signed-off-by: Juan Zhao <juan.j.zhao@intel.com>
12 years agoAdd COPYING
Kristian Høgsberg [Wed, 25 Apr 2012 14:16:27 +0000 (10:16 -0400)]
Add COPYING

12 years agoxserver: Move window property reading to set_window_id handler
Kristian Høgsberg [Sun, 22 Apr 2012 19:12:45 +0000 (15:12 -0400)]
xserver: Move window property reading to set_window_id handler

This will work for override-redirect windows too.

12 years agoxserver: Read window properties in map request handler
Kristian Høgsberg [Sun, 22 Apr 2012 03:28:34 +0000 (23:28 -0400)]
xserver: Read window properties in map request handler

12 years agoshell: Don't ping internal shell surfaces
Kristian Høgsberg [Sun, 22 Apr 2012 03:20:07 +0000 (23:20 -0400)]
shell: Don't ping internal shell surfaces

This is a hack for now to get xserver surfaces working again.

12 years agocompositor: introduce internal shell_interface
Tiago Vignatti [Thu, 19 Apr 2012 13:18:18 +0000 (16:18 +0300)]
compositor: introduce internal shell_interface

We're able now to create shell_surfaces inside Weston. This makes possible the
glue needed between shell and xserver-launcher.

On the desktop-shell, it was split the protocol part from shell_surface
specific functions to make this possible.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agocompositor: Set pointer surface input region to empty on attach
Kristian Høgsberg [Sat, 21 Apr 2012 18:14:20 +0000 (14:14 -0400)]
compositor: Set pointer surface input region to empty on attach

We set up an emtpy region for the initial NULL-cursor, and then going
from no buffer to a 32x32 buffer didn't trigger the undeffing of the input
region.  So when something sets a cursor of a different size, the cursor
surface input region gets initialized and starts swallowing events.

12 years agoshell: Move binding-modifier to shell section
Kristian Høgsberg [Fri, 20 Apr 2012 20:48:21 +0000 (16:48 -0400)]
shell: Move binding-modifier to shell section

12 years agoshell: modifier bindings configurable
Tiago Vignatti [Fri, 20 Apr 2012 15:54:25 +0000 (18:54 +0300)]
shell: modifier bindings configurable

This patch makes the main modifier configurable.  We used to hardcode super
(windows key) for most bindings, but now that can be changed.

The change affects two key bindings: rotation moves to mod+right click
and backlight moves to from ctrl+f9/f10 to mod+f9/f10.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agoscreenshooter: Don't assume output offsets start at zero
Scott Moreau [Fri, 20 Apr 2012 19:37:35 +0000 (13:37 -0600)]
screenshooter: Don't assume output offsets start at zero

12 years agoscreenshooter: Move buffer assembly to client side
Scott Moreau [Fri, 20 Apr 2012 19:37:34 +0000 (13:37 -0600)]
screenshooter: Move buffer assembly to client side

12 years agoscreenshooter: Grab pixel data directly before buffer swap
Scott Moreau [Fri, 20 Apr 2012 19:37:33 +0000 (13:37 -0600)]
screenshooter: Grab pixel data directly before buffer swap

12 years agoSend surface enter/leave events
Casey Dahlin [Fri, 20 Apr 2012 02:50:09 +0000 (22:50 -0400)]
Send surface enter/leave events

These new protocol events allow us to tell which outputs a surface is on, and
potentially update where we allocate our buffers from.

Signed-off-by: Casey Dahlin <cdahlin@redhat.com>
12 years agoAdd an id field to outputs
Casey Dahlin [Fri, 20 Apr 2012 02:50:08 +0000 (22:50 -0400)]
Add an id field to outputs

All outputs now have a unique integer ID, allocated from a bitfield pool in the
compositor.

Signed-off-by: Casey Dahlin <cdahlin@redhat.com>
12 years agoChange find_resource_for_surface to find_resource_for_client
Casey Dahlin [Fri, 20 Apr 2012 02:50:07 +0000 (22:50 -0400)]
Change find_resource_for_surface to find_resource_for_client

This function has generic applications and should be made generic.

Signed-off-by: Casey Dahlin <cdahlin@redhat.com>
12 years agoshell: Cleanup ping_timer code.
Scott Moreau [Thu, 19 Apr 2012 19:06:17 +0000 (13:06 -0600)]
shell: Cleanup ping_timer code.

 - Added ping_timer_destroy() to simplify cleanup.
 - Changed timeout and fade step to more realistic values.
 - Renamed ping_timeout_fade_frame() to unresponsive_fade_frame().

12 years agocompositor-drm: Remove an useless code line.
Alex Wu [Thu, 19 Apr 2012 02:08:59 +0000 (10:08 +0800)]
compositor-drm: Remove an useless code line.

12 years agoDim unresponsive windows
Scott Moreau [Wed, 18 Apr 2012 01:06:20 +0000 (19:06 -0600)]
Dim unresponsive windows

If a client is not responding, lower the brightness and
saturation to indicate it's stalled. The surface is restored
to it's original color values if the client later becomes
responsive.

12 years agoInstall brightness and saturation variables for surface shader
Scott Moreau [Wed, 18 Apr 2012 01:06:19 +0000 (19:06 -0600)]
Install brightness and saturation variables for surface shader

12 years agoInstall structuring for ping-pong protocol
Scott Moreau [Wed, 18 Apr 2012 01:06:18 +0000 (19:06 -0600)]
Install structuring for ping-pong protocol

12 years agoshell: Implement "driver" method of fullsceen.
Alex Wu [Tue, 17 Apr 2012 09:20:49 +0000 (17:20 +0800)]
shell: Implement "driver" method of fullsceen.

Switching display mode may happen when:
1. The fullscreen surface is at top most in fullscreen layer and with
   "driver" method. Shell will switch output mode to match the surface
   size. If no matched mode found, fall back to "fill" method.
2. The top fullscreen surface is destroyed or unset. Switch back to the
   origin mode.

12 years agocompositor-drm: Add switch_mode support.
Alex Wu [Tue, 17 Apr 2012 09:20:48 +0000 (17:20 +0800)]
compositor-drm: Add switch_mode support.

Implement switch_mode hook for drm backend.

12 years agocompositor: Add a switch_mode hook and a wrapper into the output.
Alex Wu [Tue, 17 Apr 2012 09:20:47 +0000 (17:20 +0800)]
compositor: Add a switch_mode hook and a wrapper into the output.

This allow each output backend to switch the display mode. It is
useful to some applications like fullscreen game, xbmc.

12 years agoweston-launch: be more descriptive with output messages
Tiago Vignatti [Tue, 17 Apr 2012 17:10:11 +0000 (20:10 +0300)]
weston-launch: be more descriptive with output messages

Specially the "either" word there is essential, so users don't confuse
thinking that both steps are needed.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agocompositor: make GL_EXT_read_format_bgra optional
Pekka Paalanen [Tue, 17 Apr 2012 12:02:08 +0000 (15:02 +0300)]
compositor: make GL_EXT_read_format_bgra optional

Some GL implementations do not provide GL_EXT_read_format_bgra
extension.

Set a glReadPixels format based on whether the extensions is supported
or not, and use that format in all backends.

Add RGBA->BGRA swapping copy to screenshooter to keep the shm buffer
data format as BGRA.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agoscreenshooter: refactor the copy loop
Pekka Paalanen [Tue, 17 Apr 2012 08:55:41 +0000 (11:55 +0300)]
screenshooter: refactor the copy loop

This makes it easier to later add an alternative copy loop.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: check queryString success
Pekka Paalanen [Thu, 12 Apr 2012 11:45:35 +0000 (14:45 +0300)]
compositor: check queryString success

During a bring-up of a new backend, it would be nice to get a real error
message, when the EGL and GL contexts have not been properly set up.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: use GL_EXT_unpack_subimage only if available
Pekka Paalanen [Wed, 11 Apr 2012 13:19:37 +0000 (16:19 +0300)]
compositor: use GL_EXT_unpack_subimage only if available

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: add EGL_WL_bind_wayland_display definitions
Pekka Paalanen [Fri, 30 Mar 2012 12:45:40 +0000 (15:45 +0300)]
compositor: add EGL_WL_bind_wayland_display definitions

This is a workaround for platforms, whose EGL headers miss the
definitions for EGL_WL_bind_wayland_display.

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: move libudev.h to evdev.h
Pekka Paalanen [Fri, 30 Mar 2012 12:20:23 +0000 (15:20 +0300)]
compositor: move libudev.h to evdev.h

Compositor core does not do anything with udev, so the header is not
needed there. Move the #include into evdev.h, from where it gets used by
compositor-drm.c, too.

Also fix the fallout:
tty.c: In function 'tty_create':
tty.c:143:2: warning: implicit declaration of function 'fstat'

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agoconfig-parser: add missing return for an error case
Pekka Paalanen [Fri, 30 Mar 2012 10:54:53 +0000 (13:54 +0300)]
config-parser: add missing return for an error case

Fixes
config-parser.c: In function 'handle_key':
config-parser.c:81: error: control reaches end of non-void function

Signed-off-by: Pekka Paalanen <ppaalanen@gmail.com>
12 years agocompositor: init shell after xserver
Tiago Vignatti [Mon, 16 Apr 2012 14:31:44 +0000 (17:31 +0300)]
compositor: init shell after xserver

This reverts a snip from commit d012e9df. On that commit, it was lost the
ability of calling X applications from desktop panel; xserver module
was setting DISPLAY only later, after panel was already launched.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agodesktop-shell: use more consistent name for the main structure
Tiago Vignatti [Mon, 16 Apr 2012 14:31:41 +0000 (17:31 +0300)]
desktop-shell: use more consistent name for the main structure

wl_shell is more likely to be used for core protocol specific. Now it follows
pretty much the same style of what tablet-shell is using.

No functional changes.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agodesktop-shell: use description tags and improve protocol doc a bit
Tiago Vignatti [Mon, 16 Apr 2012 14:31:40 +0000 (17:31 +0300)]
desktop-shell: use description tags and improve protocol doc a bit

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agotty: Fall back to K_RAW if K_OFF is not available
Kristian Høgsberg [Fri, 13 Apr 2012 18:54:15 +0000 (14:54 -0400)]
tty: Fall back to K_RAW if K_OFF is not available

12 years agowindow.c: Drop the toolkit grab when we start a compositor grab
Kristian Høgsberg [Fri, 13 Apr 2012 16:55:45 +0000 (12:55 -0400)]
window.c: Drop the toolkit grab when we start a compositor grab

We do this right for move and resize, but dnd and popups need the same
treatment.

12 years agoshell: Tighten shell.set_popup semantics
Kristian Høgsberg [Fri, 13 Apr 2012 16:40:07 +0000 (12:40 -0400)]
shell: Tighten shell.set_popup semantics

We need to use the input device from the request, and check that the
serial matches the serial from the latest button press.

12 years agowindow: Send serial number in set_popup request
Kristian Høgsberg [Fri, 13 Apr 2012 16:37:19 +0000 (12:37 -0400)]
window: Send serial number in set_popup request

12 years agowindow: Initialize redraw_task.link so we can always remove it
Kristian Høgsberg [Fri, 13 Apr 2012 16:01:18 +0000 (12:01 -0400)]
window: Initialize redraw_task.link so we can always remove it

12 years agoxserver-launcher: Pass serial to wl_input_device_set_selection()
Kristian Høgsberg [Fri, 13 Apr 2012 15:02:21 +0000 (11:02 -0400)]
xserver-launcher: Pass serial to wl_input_device_set_selection()

12 years agoMake xserver-launcher a module
Kristian Høgsberg [Thu, 12 Apr 2012 14:37:23 +0000 (10:37 -0400)]
Make xserver-launcher a module

12 years agocompositor: Add a destroy signal and turn weston_shell into signals
Kristian Høgsberg [Thu, 12 Apr 2012 13:55:26 +0000 (09:55 -0400)]
compositor: Add a destroy signal and turn weston_shell into signals

12 years agoUse wl_signal mechanism
Kristian Høgsberg [Thu, 12 Apr 2012 03:18:23 +0000 (23:18 -0400)]
Use wl_signal mechanism

Mostly mechanical rewrite to track waylands change to struct wl_signal.

12 years agoFollow wayland change to serial numbers
Kristian Høgsberg [Thu, 12 Apr 2012 02:42:15 +0000 (22:42 -0400)]
Follow wayland change to serial numbers

12 years agoshared: Use $(GCC_CFLAGS), fix warnings
Kristian Høgsberg [Wed, 11 Apr 2012 13:43:53 +0000 (09:43 -0400)]
shared: Use $(GCC_CFLAGS), fix warnings

12 years agoAlways build tests
Kristian Høgsberg [Wed, 11 Apr 2012 13:38:29 +0000 (09:38 -0400)]
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.

12 years agoweston: update .gitignore files
Casey Dahlin [Wed, 11 Apr 2012 04:20:33 +0000 (00:20 -0400)]
weston: update .gitignore files

Updates the .gitignore files for clients and tests to reflect a new test and a
couple of renamed applications.

Signed-off-by: Casey Dahlin <cdahlin@redhat.com>
12 years agowindow: Fix remaining references to the egl image surface type
Kristian Høgsberg [Tue, 10 Apr 2012 20:55:11 +0000 (16:55 -0400)]
window: Fix remaining references to the egl image surface type

Didn't catch these before, was compiling with sw cairo.

12 years agoMerge branch 'output-hotplug' of git://people.freedesktop.org/~bnf/wayland-demos
Kristian Høgsberg [Tue, 10 Apr 2012 17:05:11 +0000 (13:05 -0400)]
Merge branch 'output-hotplug' of git://people.freedesktop.org/~bnf/wayland-demos

12 years agocompositor: Damage output in weston_output_init
Benjamin Franzke [Tue, 10 Apr 2012 16:35:33 +0000 (18:35 +0200)]
compositor: Damage output in weston_output_init

So that hotplugged outputs are marked damaged initially.

12 years agocompositor: Remove wl_output-global on unplug
Benjamin Franzke [Tue, 10 Apr 2012 16:28:54 +0000 (18:28 +0200)]
compositor: Remove wl_output-global on unplug

Or we would segfault when a client binds to a output thats already
destroyed.

12 years agowindow: Drop EGLImage surface type
Kristian Høgsberg [Tue, 10 Apr 2012 15:49:45 +0000 (11:49 -0400)]
window: Drop EGLImage surface type

12 years agowindow: Only unmap shm surface backing memory if it belongs to surface
Kristian Høgsberg [Tue, 10 Apr 2012 15:32:35 +0000 (11:32 -0400)]
window: Only unmap shm surface backing memory if it belongs to surface

Memory allocated out of the resize shm pool will be unmapped when the pool
is destroyed.

12 years agowindow: Simplify the shm surface management
Kristian Høgsberg [Tue, 10 Apr 2012 15:23:13 +0000 (11:23 -0400)]
window: Simplify the shm surface management

We can destroy a shm wl_buffer immediately after sending it to the server.

12 years agoshell: handle surface destruction during move, resize and rotate grabs
Ander Conselvan de Oliveira [Wed, 4 Apr 2012 14:48:05 +0000 (17:48 +0300)]
shell: handle surface destruction during move, resize and rotate grabs

When the surface being moved, resized or rotated was destroyed, the
compositor would crash.

Fix this by using a destroy listener on the referenced surface. To
reduce code duplication, the surface reference and the destroy
listener is added to a new struct shell_grab.

12 years agoweston-launcher: Fix uninitialized variable warning
Kristian Høgsberg [Tue, 10 Apr 2012 05:31:09 +0000 (01:31 -0400)]
weston-launcher: Fix uninitialized variable warning

12 years agoweston-launcher: Fix aliasing warnings
Kristian Høgsberg [Tue, 10 Apr 2012 05:26:18 +0000 (01:26 -0400)]
weston-launcher: Fix aliasing warnings

12 years agocompositor: End keyboard grab when compositor loses keyboard focus
Kristian Høgsberg [Tue, 10 Apr 2012 04:33:40 +0000 (00:33 -0400)]
compositor: End keyboard grab when compositor loses keyboard focus

12 years agotty: Put console in K_OFF mode
Kristian Høgsberg [Tue, 10 Apr 2012 04:18:33 +0000 (00:18 -0400)]
tty: Put console in K_OFF mode

This disables all kernel key bindings (VT switch keybindings, caps lock
etc) and disables delivery of console input.

12 years agodrm: Add vt switch keybindings
Kristian Høgsberg [Tue, 10 Apr 2012 04:11:50 +0000 (00:11 -0400)]
drm: Add vt switch keybindings

12 years agoevdev: Get key state from kernel on vt enter
Kristian Høgsberg [Tue, 10 Apr 2012 04:03:30 +0000 (00:03 -0400)]
evdev: Get key state from kernel on vt enter

We need this to correctly initialize compositor key state, modifier state and
to send the right keys in the key enter event.

12 years agodrm: Remove input devices before cancelling repaints in vt switch away
Kristian Høgsberg [Tue, 10 Apr 2012 04:08:45 +0000 (00:08 -0400)]
drm: Remove input devices before cancelling repaints in vt switch away

Removing the input devices will trigger events and activity that will cause
a redraw.  Do this before we put the compositor to sleep so we can cancel it
properly and avoid immediately waking the compositor again.

12 years agoxserver: Return EEXIST if unlinking lockfile fails
Kristian Høgsberg [Tue, 10 Apr 2012 02:14:52 +0000 (22:14 -0400)]
xserver: Return EEXIST if unlinking lockfile fails

Otherwise we'll keep trying to unlink it.

12 years agoxserver: Don't leak lockfile fd on error path
Kristian Høgsberg [Tue, 10 Apr 2012 02:13:17 +0000 (22:13 -0400)]
xserver: Don't leak lockfile fd on error path

12 years agocompositor: Don't pass output to notify_keyboard_focus
Kristian Høgsberg [Tue, 10 Apr 2012 02:10:00 +0000 (22:10 -0400)]
compositor: Don't pass output to notify_keyboard_focus

Doesn't make sense and was only used to distinguish between enter/leave.

12 years agoevdev: Disable the udev monitor when another vt becomes active
Benjamin Franzke [Mon, 9 Apr 2012 16:14:58 +0000 (18:14 +0200)]
evdev: Disable the udev monitor when another vt becomes active

We dont want to receive hotplug events while being inactive.
When getting back active we enumerate all devices and would end up
with two sources for one device that may be hotplugged in the mean time.

12 years agoIntroduce weston-launch
Benjamin Franzke [Mon, 30 Jan 2012 13:04:04 +0000 (14:04 +0100)]
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.

12 years agoscreenshot.c: Fix up a few stylistic issues
Kristian Høgsberg [Wed, 4 Apr 2012 18:52:35 +0000 (14:52 -0400)]
screenshot.c: Fix up a few stylistic issues

12 years agoscreenshooter: Properly handle multiple outputs.
Scott Moreau [Wed, 4 Apr 2012 17:49:21 +0000 (11:49 -0600)]
screenshooter: Properly handle multiple outputs.

12 years agoclient: tablet-shell: fallback in the lack of lockscreen icon
Tiago Vignatti [Wed, 28 Mar 2012 17:56:48 +0000 (20:56 +0300)]
client: tablet-shell: fallback in the lack of lockscreen icon

lockscreen, homescreen and shell launchers are falling back okay already and
only lockscreen icon was missing some way to keep the shell client running in
the absence of images. This patch fix it.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agowindow: Check load_image result for NULL
Kristian Høgsberg [Tue, 3 Apr 2012 18:49:50 +0000 (14:49 -0400)]
window: Check load_image result for NULL

12 years agoFix `unused-result' warnings.
Jonas Ådahl [Fri, 30 Mar 2012 21:10:27 +0000 (23:10 +0200)]
Fix `unused-result' warnings.

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
12 years agowindow: Use a persistent, big shm pool during resize
Kristian Høgsberg [Tue, 3 Apr 2012 16:00:48 +0000 (12:00 -0400)]
window: Use a persistent, big shm pool during resize

The biggest performance bottleneck while resizing is the continous
setting up and tearing down of mmaps and faulting in pages.  This commit
introduces a per-window pool that we'll allocate buffers out of if it's
available.  Then we set initialize it to a big shm pool when we start
resizing and free it when resizing is done.

12 years agowindow: Only initialize egl if we have cairo egl
Kristian Høgsberg [Tue, 3 Apr 2012 15:57:44 +0000 (11:57 -0400)]
window: Only initialize egl if we have cairo egl

12 years agoclients: Use new shm interface
Kristian Høgsberg [Tue, 3 Apr 2012 15:21:27 +0000 (11:21 -0400)]
clients: Use new shm interface

12 years agocairo-util: Use nearest filtering for rendering frame
Kristian Høgsberg [Tue, 3 Apr 2012 14:53:15 +0000 (10:53 -0400)]
cairo-util: Use nearest filtering for rendering frame

We don't need bilinear filtering here, the corners aren't scaled and
the scaled edges are just stretched along one axis.

12 years agoshell: Break up a few long lines
Kristian Høgsberg [Tue, 3 Apr 2012 02:18:58 +0000 (22:18 -0400)]
shell: Break up a few long lines

12 years agoshell: set black surface alpha properly in switcher_next()
Alex Wu [Sun, 1 Apr 2012 12:13:09 +0000 (20:13 +0800)]
shell: set black surface alpha properly in switcher_next()

Make the black surfaces semitransparent when switching surface, and
if associated fullscreen surface is chosen, make black surface opaque.

12 years agoshell: Add fullscreen path into activate()
Alex Wu [Sun, 1 Apr 2012 12:13:08 +0000 (20:13 +0800)]
shell: Add fullscreen path into activate()

Use shell_stack_fullscreen() to raise fullscreen surface in activate(),
and before activate() a regular surface, move all the fullscreen
surfaces from fullscreen_layer to toplevel_layer.

Also add a void *private into struct wesont_surface since we already
have a configure() vfunc. That helps to get the associated fullscreen
surface of black surface.

12 years agoAdd signedness warning flag and fix fallout
Kristian Høgsberg [Fri, 30 Mar 2012 15:52:39 +0000 (11:52 -0400)]
Add signedness warning flag and fix fallout

12 years agoFix warnings resulting from wayland signedness fixes
Kristian Høgsberg [Fri, 30 Mar 2012 15:31:25 +0000 (11:31 -0400)]
Fix warnings resulting from wayland signedness fixes

12 years agoRemove weston_shell map and configure function pointers
Kristian Høgsberg [Thu, 29 Mar 2012 17:08:32 +0000 (13:08 -0400)]
Remove weston_shell map and configure function pointers

12 years agoshell: Remove obsolete workaround
Kristian Høgsberg [Thu, 29 Mar 2012 15:35:32 +0000 (11:35 -0400)]
shell: Remove obsolete workaround

Cursor surface now are properly initialized.

12 years agocompositor: Support alpha for solid color surfaces
Kristian Høgsberg [Thu, 29 Mar 2012 15:34:39 +0000 (11:34 -0400)]
compositor: Support alpha for solid color surfaces

12 years agotty: Improve error handling in tty_create()
Jonas Ådahl [Wed, 28 Mar 2012 20:36:10 +0000 (22:36 +0200)]
tty: Improve error handling in tty_create()

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
12 years agoProperly dispose event sources and event loops
Jonas Ådahl [Wed, 28 Mar 2012 20:36:09 +0000 (22:36 +0200)]
Properly dispose event sources and event loops

Signed-off-by: Jonas Ådahl <jadahl@gmail.com>
12 years agocompositor: Stop using EGL_KHR_surfaceless_gles2
Kristian Høgsberg [Thu, 29 Mar 2012 02:53:49 +0000 (22:53 -0400)]
compositor: Stop using EGL_KHR_surfaceless_gles2

The remaining use case was making our context current before we had any
output surfaces.  We can do that now using a dummy surface, so let's stop
relying on surfaceless.

12 years agocompostor-drm: Use gbm surface
Kristian Høgsberg [Sun, 11 Mar 2012 22:27:41 +0000 (18:27 -0400)]
compostor-drm: Use gbm surface

Instead of using the hacks of gbm_bos, EGLImage, FBOs and surfaceless
we switch to using the new gbm surface API.  This gives us an EGL
native window type for gbm and lets us use a real EGL surface.

12 years agotablet-shell: come back to life
Tiago Vignatti [Wed, 28 Mar 2012 10:04:02 +0000 (13:04 +0300)]
tablet-shell: come back to life

A couple of fixes were made: Weston tablet-shell needed to use weston_layer,
so the compositor could rebuild the surface list correctly when repainting;
homescreen and locking are using the widget + window abstration of toytoolkit;
and widget_set_redraw_handler are being set for widgets redraw.

Also, it was given some basic meaning for lockscreen_button_handler, which
was completely disabled before. As a clean up, I updated the global listener
mechanism on tablet-shell client, using the regular way of registering a
handler instead wl_display_roundtrip -> wl_display_get_global.

Switcher still without code to proper work and the same for tablet-shell
clients, which are not launched.

krh: Edited to not scale down homescreen icons, use new load_cairo_surface()
for image loading.

Signed-off-by: Tiago Vignatti <tiago.vignatti@intel.com>
12 years agocompositor: Use GL_EXT_unpack_subimage for texture updates
Kristian Høgsberg [Tue, 27 Mar 2012 21:10:13 +0000 (17:10 -0400)]
compositor: Use GL_EXT_unpack_subimage for texture updates

12 years agocompositor: Rename weston_buffer_attach to weston_surface_attach
Kristian Høgsberg [Tue, 27 Mar 2012 21:04:59 +0000 (17:04 -0400)]
compositor: Rename weston_buffer_attach to weston_surface_attach

This was always an operation on the surface, not the buffer.

12 years agodnd: Damage surface after attaching new buffer
Kristian Høgsberg [Tue, 27 Mar 2012 20:44:57 +0000 (16:44 -0400)]
dnd: Damage surface after attaching new buffer

12 years agoclients: Fix a couple of warnings
Kristian Høgsberg [Tue, 27 Mar 2012 20:39:00 +0000 (16:39 -0400)]
clients: Fix a couple of warnings