Re: idle tasks starving in toytoolkit

2013-09-26 Thread Pekka Paalanen
On Thu, 26 Sep 2013 16:56:49 +0100 Neil Roberts wrote: > One idea to fix this might be to make dispatch_queue only ever > dispatch the events that were current when the loop is started. That > way if any further events are added while processing the current > events it will give control back to t

Re: conversion from double to fixed and back fails with certain values

2013-09-26 Thread Jason Ekstrand
Micah, It simply means that you can't assume too much precision. For most things such as pointer movement this isn't a problem because there is no good reason why you would want to know the pointer's position more precicely than in units 1/256 of a pixel. Recently, however, there was some discuss

Re: conversion from double to fixed and back fails with certain values

2013-09-26 Thread Micah Nordland
OK, I are there any parts of the Wayland spec where this might cause problems/make things interesting? -- Sent from my Android device with K-9 Mail. Please excuse my brevity.___ wayland-devel mailing list wayland-devel@lists.freedesktop.org http://lists

Re: conversion from double to fixed and back fails with certain values

2013-09-26 Thread Jason Ekstrand
Micah, This is because wl_fixed is a fixed-point format. In particular, it is 24.8 fixed point meaning that the top 24 bits represent the integer part. This means that wl_fixed effectively stores n if the number is written as the (possibly improper) fraction n/256. In your example, 3568.005 = 91

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Jason Ekstrand
On Thu, Sep 26, 2013 at 5:46 PM, Wander Lairson Costa < wander.lair...@gmail.com> wrote: > 2013/9/26 Ran Benita : > > On Thu, Sep 26, 2013 at 06:27:39PM -0300, Wander Lairson Costa wrote: > >> 2013/9/26 Ran Benita : > >> > On Thu, Sep 26, 2013 at 04:00:15PM -0300, Wander Lairson Costa wrote: > >>

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Wander Lairson Costa
2013/9/26 Ran Benita : > On Thu, Sep 26, 2013 at 06:27:39PM -0300, Wander Lairson Costa wrote: >> 2013/9/26 Ran Benita : >> > On Thu, Sep 26, 2013 at 04:00:15PM -0300, Wander Lairson Costa wrote: >> >> 2013/9/26 Ran Benita : >> >> >> >> [snip] >> >> >> >> > >> >> > The information you need, if you

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Ran Benita
On Thu, Sep 26, 2013 at 06:27:39PM -0300, Wander Lairson Costa wrote: > 2013/9/26 Ran Benita : > > On Thu, Sep 26, 2013 at 04:00:15PM -0300, Wander Lairson Costa wrote: > >> 2013/9/26 Ran Benita : > >> > >> [snip] > >> > >> > > >> > The information you need, if you want to use the key-down approach

Re: [PATCH weston] compositor-fbdev: drop dependency on libdrm

2013-09-26 Thread Kristian Høgsberg
On Thu, Sep 26, 2013 at 07:31:32PM +0300, Adrian Negreanu wrote: > From: Adrian Negreanu Thanks, applied. Kristian > Signed-off-by: Adrian Negreanu > --- > configure.ac | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/configure.ac b/configure.ac > index 7c2da44..a43bf

Re: [[PATCH v3 2/2]] compositor: check if seteuid worked

2013-09-26 Thread Kristian Høgsberg
On Wed, Sep 25, 2013 at 02:47:47PM +0100, Alex DAMIAN wrote: > From: Alexandru DAMIAN > > Checking the return value from seteuid in > order to not launch clients with the wrong effective uid. > > Signed-off-by: Alexandru DAMIAN > --- > src/compositor.c | 7 +-- > 1 file changed, 5 insertio

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Wander Lairson Costa
2013/9/26 Ran Benita : > On Thu, Sep 26, 2013 at 04:00:15PM -0300, Wander Lairson Costa wrote: >> 2013/9/26 Ran Benita : >> >> [snip] >> >> > >> > The information you need, if you want to use the key-down approach >> > (which is the only one I can think of), is whether e.g. the Left Shift >> > key

Re: [xkbcommon] Make C++ happy.

2013-09-26 Thread Wander Lairson Costa
2013/9/26 Bill Spitzak : > Wander Lairson Costa wrote: > >> /** Flags for keymap compilation. */ >> enum xkb_keymap_compile_flags { >> +/** Do not apply any flag. */ >> +XKB_MAP_COMPILE_NO_FLAG = 0, >> /** Apparently you can't have empty enums. What a drag. */ >> XKB_MAP_COMPIL

conversion from double to fixed and back fails with certain values

2013-09-26 Thread Micah Nordland
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 The value 3568.005 is not correctly converted back from fixed. The following patch to tests/fixed-test.c demonstrates. Is this expected behavior? diff --git a/tests/fixed-test.c b/tests/fixed-test.c index 739a3b1..89ec188 100644 - --- a/tests/fixed-te

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Ran Benita
On Thu, Sep 26, 2013 at 04:00:15PM -0300, Wander Lairson Costa wrote: > 2013/9/26 Ran Benita : > > [snip] > > > > > The information you need, if you want to use the key-down approach > > (which is the only one I can think of), is whether e.g. the Left Shift > > key is down at any given moment. Th

RE: [PATCH 1/1] config: add command line option for config file

2013-09-26 Thread Eoff, Ullysses A
This patch only instructs the main compositor process to use the command-line specified configuration file. What about the other things that depend on settings from the configuration file: window.c, tablet-shell.c, desktop-shell.c, and terminal.c? Those all load "weston.ini" using the default p

RE: [PATCH 3/3 wayland-fits] core: Add a test for multiple pointer and keyboard resources

2013-09-26 Thread Eoff, Ullysses A
Series applied. The client keyboard stuff is something I've been wanting to add for a while. Thanks Neil! I like more tests :-) U. Artie Eoff > -Original Message- > From: wayland-devel-bounces+ullysses.a.eoff=intel@lists.freedesktop.org > [mailto:wayland-devel- > bounces+u

Re: [xkbcommon] Make C++ happy.

2013-09-26 Thread Bill Spitzak
Wander Lairson Costa wrote: /** Flags for keymap compilation. */ enum xkb_keymap_compile_flags { +/** Do not apply any flag. */ +XKB_MAP_COMPILE_NO_FLAG = 0, /** Apparently you can't have empty enums. What a drag. */ XKB_MAP_COMPILE_PLACEHOLDER = 0 }; I think you can remo

RE: [PATCH wfits v2] core: Add a wrapper for the keyboard

2013-09-26 Thread Eoff, Ullysses A
> -Original Message- > From: wayland-devel-bounces+ullysses.a.eoff=intel@lists.freedesktop.org > [mailto:wayland-devel- > bounces+ullysses.a.eoff=intel@lists.freedesktop.org] On Behalf Of Neil > Roberts > Sent: Wednesday, September 25, 2013 4:33 PM > To: wayland-devel@lists.freede

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Wander Lairson Costa
2013/9/26 Ran Benita : [snip] > > The information you need, if you want to use the key-down approach > (which is the only one I can think of), is whether e.g. the Left Shift > key is down at any given moment. This keys-state information is kept on > the compositor, but now you need to reconstruct

[PATCH weston] compositor-fbdev: drop dependency on libdrm

2013-09-26 Thread Adrian Negreanu
From: Adrian Negreanu Signed-off-by: Adrian Negreanu --- configure.ac | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.ac b/configure.ac index 7c2da44..a43bf5b 100644 --- a/configure.ac +++ b/configure.ac @@ -190,7 +190,7 @@ AM_CONDITIONAL([ENABLE_FBDEV_COMPOSITOR],

RE: idle tasks starving in toytoolkit

2013-09-26 Thread Neil Roberts
One idea to fix this might be to make dispatch_queue only ever dispatch the events that were current when the loop is started. That way if any further events are added while processing the current events it will give control back to the main loop before processing them. Here's a not-heavily-tested

idle tasks starving in toytoolkit

2013-09-26 Thread Tomeu Vizoso
Hi, somewhat related to the issue of posting vs. queuing buffer.release event is a condition I have found that starves idle handlers in window.c. If the SwapBuffers implementation waits for buffer.release events to make sure that the GPU doesn't overwrite the front buffer and the client performs

Re: [xkbcommon] Make C++ happy.

2013-09-26 Thread Wander Lairson Costa
2013/9/26 Ran Benita : > On Thu, Sep 26, 2013 at 09:35:33AM -0300, Wander Lairson Costa wrote: >> For most functions taking an enum flags parameter, we use 0 value to >> indicate that no flags should be applied. >> >> C++ has a stronger type system than C and will not implicitly convert >> int's to

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Ran Benita
On Thu, Sep 26, 2013 at 08:49:24AM -0300, Wander Lairson Costa wrote: > 2013/9/25 Ran Benita : > > On Tue, Sep 24, 2013 at 08:02:30PM -0300, Wander Lairson Costa wrote: > >> Hi, > >> > > > > Hi, > > > >> I am working for some time porting Blender to wayland [1] and I am now > >> adding keyboard han

Re: [xkbcommon] Make C++ happy.

2013-09-26 Thread Ran Benita
On Thu, Sep 26, 2013 at 09:35:33AM -0300, Wander Lairson Costa wrote: > For most functions taking an enum flags parameter, we use 0 value to > indicate that no flags should be applied. > > C++ has a stronger type system than C and will not implicitly convert > int's to enum's. Thus, we create vali

[xkbcommon] Make C++ happy.

2013-09-26 Thread Wander Lairson Costa
For most functions taking an enum flags parameter, we use 0 value to indicate that no flags should be applied. C++ has a stronger type system than C and will not implicitly convert int's to enum's. Thus, we create valid 0 enum values for enum types where it makes sense. Signed-off-by: Wander Lair

[xkbcommon] Second try on *Make C++ happy* patch.

2013-09-26 Thread Wander Lairson Costa
I am resubmitting the patch with additional enums *zero* flags. Wander Lairson Costa (1): Make C++ happy. xkbcommon/xkbcommon.h | 9 + 1 file changed, 9 insertions(+) -- 1.8.1.2 ___ wayland-devel mailing list wayland-devel@lists.freedesktop

Re: [xkbcommon] How to distinguish left-shift and right-shift

2013-09-26 Thread Wander Lairson Costa
2013/9/25 Ran Benita : > On Tue, Sep 24, 2013 at 08:02:30PM -0300, Wander Lairson Costa wrote: >> Hi, >> > > Hi, > >> I am working for some time porting Blender to wayland [1] and I am now >> adding keyboard handing support. For that, I am following weston >> clients code as reference and using lib

[PATCH 1/1] option-parser: mark option value arguments as parsed

2013-09-26 Thread Alex DAMIAN
From: Alexandru DAMIAN Weston options in long name format may have the values separated from option name by the '=' character, or specified as a separate argument, e.g. "--config value". If the option value is a separate argument, we need to mark that argument as parsed and not try to reiterate

Re: [PATCH v3 1/2] config: verify that the config file is not null

2013-09-26 Thread Damian, Alexandru
Disregard this patch, I sent in another that should handle better the config file issues. Alex On Wed, Sep 25, 2013 at 11:23 PM, Damian, Alexandru < alexandru.dam...@intel.com> wrote: > The nice thing was that even if some other code besides the _log tries to > read the file path, that code can

[PATCH 1/1] config: add command line option for config file

2013-09-26 Thread Alex DAMIAN
From: Alexandru DAMIAN Added an option to specify the weston.ini config file to be used. Defaults to ${PWD}/weston.ini Adding a check in weston_config_full_path so that we don't crash if we started without a config file. Fixing a typo in help message. Signed-off-by: Alexandru DAMIAN --- shar