Re: [PATCH] src/shell.c: set black_surface-width and height

2013-11-29 Thread Pekka Paalanen
On Fri, 29 Nov 2013 11:18:14 +0800 Xiong Zhang xiong.y.zh...@intel.com wrote: From: XiongZhang xiong.y.zh...@intel.com full screen black_surface doesn't have associated wl_buffer, so black_surface-width and height can't get value through weston_surface_commit(). then

Re: [PATCH weston 4/8] protocol: crop scale RFC v3

2013-11-29 Thread Pekka Paalanen
On Fri, 29 Nov 2013 01:51:03 + Daniel Stone dan...@fooishbar.org wrote: Hi, On 26 November 2013 17:19, Jonny Lamb jonny.l...@collabora.co.uk wrote: + arg name=src_x type=fixed summary=source rectangle x/ + arg name=src_y type=fixed summary=source rectangle y/ + arg

Re: [PATCH weston 4/8] protocol: crop scale RFC v3

2013-11-29 Thread Bill Spitzak
Okay I think perhaps I am completely failing to comprehend what is going on. The client I am thinking of is not trying to do partial pixels. What I am thinking of is the most simple client you can imagine that knows what the output_scale is and decides it wants to render images at full

Re: [PATCH weston 4/8] protocol: crop scale RFC v3

2013-11-29 Thread Bill Spitzak
Fractions are required so that a client can get the same scale in both directions for a destination that is not square, or to get the same scale for different crops of the destination rectangle. Also all hardware must do this if it is capable of cropping the output, since a cropped

Re: [PATCH weston 4/8] protocol: crop scale RFC v3

2013-11-29 Thread Pekka Paalanen
On Fri, 29 Nov 2013 01:20:21 -0800 Bill Spitzak spit...@gmail.com wrote: Okay I think perhaps I am completely failing to comprehend what is going on. The client I am thinking of is not trying to do partial pixels. What I am thinking of is the most simple client you can imagine that knows

[PATCH 3/3] tests: add wl_buffer tests

2013-11-29 Thread Marek Ch
Using scanner to have current code of wl_buffer_* static function, test their behaviour --- src/connection.c | 3 ++ tests/Makefile.am | 5 +++- tests/test-runner/Makefile.am | 1 + tests/wl_buffer-test.c| 64 +++ 4 files

[PATCH 2/3] tests: scanner

2013-11-29 Thread Marek Ch
Scanner is program that crawles through given files and copies out every definition/declaration marked by WL_EXPORT_TEST. It saves these definitions into test-runner/tests-private.[ch] so that these definition can be tested. Using the scanner guarantee testing of current code of functions

[PATCH 1/3] tests: move test-runner into subdirectory

2013-11-29 Thread Marek Ch
It's nice to keep helper sources separately from tests sources. It's better for searching files as well as for extending the test-suite. Also, there were no need to compile each test with test-*.c files so I used them to create noinst library and link the tests against it. Now we don't need to

[PATCH/RFC] Scanner for tests

2013-11-29 Thread Marek Ch
Hi! I was looking into wayland's code and I saw static wl_buffer_* functions and I thought: These would use a test.. But how to do it when they are static? I can take the code and copy it into test manually, but that is not good. The code can change.. I solved it by writting simple scanner that

Re: [PATCH/RFC] Scanner for tests

2013-11-29 Thread Pekka Paalanen
On Fri, 29 Nov 2013 14:52:30 +0100 Marek Ch mchqwe...@gmail.com wrote: Hi! I was looking into wayland's code and I saw static wl_buffer_* functions and I thought: These would use a test.. But how to do it when they are static? I can take the code and copy it into test manually, but that

Re: [PATCH/RFC] Scanner for tests

2013-11-29 Thread Marek Ch
Thanks! I'll look at that :) Marek Ch On 29 November 2013 15:36, Pekka Paalanen ppaala...@gmail.com wrote: On Fri, 29 Nov 2013 14:52:30 +0100 Marek Ch mchqwe...@gmail.com wrote: Hi! I was looking into wayland's code and I saw static wl_buffer_* functions and I thought: These would

Simple EGL Clients on latest Weston w/ Raspberry Pi backend - 'wayland-egl' package not found?

2013-11-29 Thread Nicholas Levin
Hello everyone, I am attempting to get the simple EGL clients up and running on Weston for Raspberry Pi, based on the latest code in the Git repo for the Wayland libraries and Weston. With the generous guidance of Pekka Paalanen, I was able to get Weston to build with --enable-egl and a special

Fortifying demo apps against running out of disk space

2013-11-29 Thread Pekka Paalanen
Hi, I have been looking at RaspberryPi and especially how small the filesystem for XDG_RUNTIME_DIR is. Well, Raspbian does not provide XDG_RUNTIME_DIR, so you define that yourself. In any case, it is very small, I am using /run/shm which is somewhere around 25 MB. Weston demos and also

[PATCH wayland 1/2] os: use posix_fallocate in creating sharable buffers

2013-11-29 Thread ppaalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk If posix_fallocate is available, use it instead of ftruncate. Unlike ftruncate, when posix_fallocate succeeds, it guarantees that you cannot run out of disk space, when later writing to the mmap()'ed file. With posix_fallocate, if

[PATCH wayland 2/2] cursor: handle running out of buffer space

2013-11-29 Thread ppaalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk If posix_fallocate is available, use it to detect when we are running out of buffer space. Propagate the failure properly through the various functions, stopping loading cursors but keeping the cursors that were already successfully loaded.

[PATCH weston 1/2] os: use posix_fallocate in creating sharable buffers

2013-11-29 Thread ppaalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk If posix_fallocate is available, use it instead of ftruncate. Unlike ftruncate, when posix_fallocate succeeds, it guarantees that you cannot run out of disk space, when later writing to the mmap()'ed file. With posix_fallocate, if

[PATCH weston 2/2] window: handle insufficient buffer space

2013-11-29 Thread ppaalanen
From: Pekka Paalanen pekka.paala...@collabora.co.uk It is quite possible for os_create_anonymous_file() to fail when trying to allocate a new wl_shm buffer. Propagate this failure out from shm_surface_prepare. Most parts of toytoolkit are already avoiding NULL cairo surfaces. If cairo surface

Re: Simple EGL Clients on latest Weston w/ Raspberry Pi backend - 'wayland-egl' package not found?

2013-11-29 Thread Tomeu Vizoso
On 29 November 2013 15:49, Nicholas Levin ngle...@vivarium.gs wrote: configure: error: Package requirements (wayland-client wayland-egl wayland-cursor) were not met: No package 'wayland-egl' found Consider adjusting the PKG_CONFIG_PATH environment variable if you installed software in a

Re: Simple EGL Clients on latest Weston w/ Raspberry Pi backend - 'wayland-egl' package not found?

2013-11-29 Thread Nicholas Levin
On 11/30/13, 3:03 AM, Tomeu Vizoso wrote: On 29 November 2013 15:49, Nicholas Levin ngle...@vivarium.gs wrote: configure: error: Package requirements (wayland-client wayland-egl wayland-cursor) were not met: No package 'wayland-egl' found Consider adjusting the PKG_CONFIG_PATH environment

Re: [PATCH 00/16] xdg-shell protocol, implementation and port of toytoolkit.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:16PM -0200, Rafael Antognolli wrote: As discussed previously, this patch series adds the xdg-shell protocol, its implementation on weston, and the client implementation on toytoolkit. Hi Raphael, I think we want to get this in early and then iterate on it in-tree

Re: [PATCH 01/16] xdg_shell: Adding a new shell protocol.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:17PM -0200, Rafael Antognolli wrote: xdg_shell is a protocol aimed to substitute wl_shell in the long term, but will not be part of the wayland core protocol. It starts as a non-stable API, aimed to be used as a development place at first, and once features are

Re: [PATCH 02/16] shell: Remove SHELL_SURFACE_FULLSCREEN and SHELL_SURFACE_MAXIMIZED.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:18PM -0200, Rafael Antognolli wrote: These surface types don't exist anymore inside weston desktop shell implementation. They are just exposed as wl_shell surface types, but internally the implementation is done with surface states. The previous behavior

Re: [PATCH 03/16] shell: Change set_maximized to receive internal structures.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:19PM -0200, Rafael Antognolli wrote: Change the parameters of set_maximized from wl_resource and wl_client to shell_surface and weston_output. This will allow it to be used with xdg-shell too. --- src/shell.c | 19 --- 1 file changed, 12

Re: [PATCH 04/16] xdg-shell: Implement part of the interface.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:20PM -0200, Rafael Antognolli wrote: Basic requests are implemented, enough to get a surface displayed. --- src/.gitignore | 2 + src/Makefile.am | 6 +- src/shell.c | 228 +--- 3 files changed, 223

Re: [PATCH 06/16] xdg-shell: Implement set_transient_for request.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:22PM -0200, Rafael Antognolli wrote: The implementation just sets a parent/child relationship between the xdg_surface and its parent, passed as argument of this request. Stacking might be affected (that's up to the compositor). This implementation does not

Re: [PATCH 01/16] xdg_shell: Adding a new shell protocol.

2013-11-29 Thread Jasper St. Pierre
On Fri, Nov 29, 2013 at 5:43 PM, Kristian Høgsberg hoegsb...@gmail.comwrote: On Wed, Nov 27, 2013 at 03:50:17PM -0200, Rafael Antognolli wrote: xdg_shell is a protocol aimed to substitute wl_shell in the long term, but will not be part of the wayland core protocol. It starts as a

Re: [PATCH 07/16] xdg-shell: Implement xdg_popup.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:23PM -0200, Rafael Antognolli wrote: --- src/shell.c | 159 ++-- 1 file changed, 155 insertions(+), 4 deletions(-) diff --git a/src/shell.c b/src/shell.c index 98fb0fe..0daa136 100644 --- a/src/shell.c

Re: [PATCH 15/16] xdg-shell: Use xdg-shell in simple-shm.

2013-11-29 Thread Kristian Høgsberg
On Wed, Nov 27, 2013 at 03:50:31PM -0200, Rafael Antognolli wrote: --- clients/Makefile.am | 4 +++- clients/simple-shm.c | 50 ++ 2 files changed, 33 insertions(+), 21 deletions(-) diff --git a/clients/Makefile.am b/clients/Makefile.am

Re: [PATCH 00/16] xdg-shell protocol, implementation and port of toytoolkit.

2013-11-29 Thread Kristian Høgsberg
On Fri, Nov 29, 2013 at 02:23:11PM -0800, Kristian Høgsberg wrote: On Wed, Nov 27, 2013 at 03:50:16PM -0200, Rafael Antognolli wrote: As discussed previously, this patch series adds the xdg-shell protocol, its implementation on weston, and the client implementation on toytoolkit. Hi

Re: [PATCH 01/16] xdg_shell: Adding a new shell protocol.

2013-11-29 Thread Kristian Høgsberg
On Fri, Nov 29, 2013 at 06:41:59PM -0500, Jasper St. Pierre wrote: On Fri, Nov 29, 2013 at 5:43 PM, Kristian Høgsberg hoegsb...@gmail.comwrote: On Wed, Nov 27, 2013 at 03:50:17PM -0200, Rafael Antognolli wrote: xdg_shell is a protocol aimed to substitute wl_shell in the long term, but

Re: [PATCH] src/shell.c: set black_surface-width and height

2013-11-29 Thread Kristian Høgsberg
On Fri, Nov 29, 2013 at 10:10:00AM +0200, Pekka Paalanen wrote: On Fri, 29 Nov 2013 11:18:14 +0800 Xiong Zhang xiong.y.zh...@intel.com wrote: From: XiongZhang xiong.y.zh...@intel.com full screen black_surface doesn't have associated wl_buffer, so black_surface-width and height can't

Re: [PATCH] src/shell.c: set black_surface-width and height

2013-11-29 Thread Kristian Høgsberg
On Fri, Nov 29, 2013 at 11:18:14AM +0800, Xiong Zhang wrote: From: XiongZhang xiong.y.zh...@intel.com Btw, it looks like you have your email name set up in .gitconfig as XiongZhang not Xiong Zhang. Is that intentional? I've edited it to Xiong Zhang as I commit seeing how your sign-off below has