Re: [PATCH 1/2] Add to output protocol to allow rotate/resize

2011-05-02 Thread Casey Dahlin
On Fri, Apr 29, 2011 at 04:58:24PM -0400, Kristian Høgsberg wrote:
 Apps shouldn't generally change the *default* resolution.  Games and
 such may want to show their window at the native resolution and that's
 part of the fullscreen plan:
 
   
 http://lists.freedesktop.org/archives/wayland-devel/2010-November/000117.html
 

Ah, that does make sense?

 Of course, the DE config tool will want to be able to change the
 default mode and placement of monitors.  In that case we're talking
 about a specific DE with it's own display configuration tool, and
 perhaps the tool can just update the underlying config (GConf or so)
 and the compositor picks up the change from there.  As a first step
 I'd rather just add the extra info to wl_output (list of available
 modes, refresh rates, sub pixel layout, connector name etc), and punt
 on how to change it for now.
 

Would it make sense for the demo compositor to grow some sort of config
backend then? Obviously it wouldn't be directly useful to anyone else
but it would at least let us test the functionality that should be
exposed elsewhere.

--CJD
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [PATCH 1/2] Add to output protocol to allow rotate/resize

2011-04-29 Thread Casey Dahlin
On Fri, Apr 29, 2011 at 09:43:53AM +0200, Benjamin Franzke wrote:
 2011/4/29 Casey Dahlin cdah...@redhat.com:
  Adds some parameters to the output geometry event. Also adds a move method 
  to
  change those parameters.
  ---
   protocol/wayland.xml |   15 ---
   1 files changed, 12 insertions(+), 3 deletions(-)
 
  diff --git a/protocol/wayland.xml b/protocol/wayland.xml
  index 11976fa..187e961 100644
  --- a/protocol/wayland.xml
  +++ b/protocol/wayland.xml
  @@ -446,12 +446,21 @@
         published as global during start up, or when a screen is hot
         plugged.  --
    interface name=wl_output version=1
  -    !-- Notification about the screen size. --
  +    !-- Move or rotate this output's area --
  +    request name=move
  +      arg name=x type=int/
  +      arg name=y type=int/
  +      arg name=transform_flags type=uint/
  +    /request
 
 I think we need a general debate first, about how to grant permission
 to only specific clients to change output configuration.
 Or even not making it part of the main protocol at all, just being an
 extension or so.
 We might not want every application to have control of these things.
 

xrandr doesn't seem to have much more authentication than this. Its not much
more dangerous than changing the resolution, which many fairly pedestrian apps
expect to be able to do (i.e. games). Indeed its potentially a good deal less
dangerous than fullscreen mode (though that can be fixed with UI), far less
dangerous than screenshots from a security perspective (and we can't have
clients render certain effects if they can't get a copy of what's behind them
to distort), and even a good deal safer than input grabs.

  +
  +    !-- Notification about the screen size, rotation, and applied
  +        transformations. --
      event name=geometry
        arg name=x type=int/
        arg name=y type=int/
  -      arg name=width type=int/
  -      arg name=height type=int/
  +      arg name=transform_flags type=uint/
  +      arg name=width type=uint/
  +      arg name=height type=uint/
      /event
    /interface
 
 Why changing the width and height datatype within this patch?
 That would be another patch. But Kristian denied that somewhen already.
 

Oh yeah, I did do that didn't I? X( I'll kill it in the revision.

--CJD
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


Re: [PATCH 1/2] Add to output protocol to allow rotate/resize

2011-04-29 Thread Kristian Høgsberg
On Fri, Apr 29, 2011 at 11:35 AM, Casey Dahlin cdah...@redhat.com wrote:
 On Fri, Apr 29, 2011 at 09:43:53AM +0200, Benjamin Franzke wrote:
 2011/4/29 Casey Dahlin cdah...@redhat.com:
  Adds some parameters to the output geometry event. Also adds a move method 
  to
  change those parameters.
  ---
   protocol/wayland.xml |   15 ---
   1 files changed, 12 insertions(+), 3 deletions(-)
 
  diff --git a/protocol/wayland.xml b/protocol/wayland.xml
  index 11976fa..187e961 100644
  --- a/protocol/wayland.xml
  +++ b/protocol/wayland.xml
  @@ -446,12 +446,21 @@
         published as global during start up, or when a screen is hot
         plugged.  --
    interface name=wl_output version=1
  -    !-- Notification about the screen size. --
  +    !-- Move or rotate this output's area --
  +    request name=move
  +      arg name=x type=int/
  +      arg name=y type=int/
  +      arg name=transform_flags type=uint/
  +    /request

 I think we need a general debate first, about how to grant permission
 to only specific clients to change output configuration.
 Or even not making it part of the main protocol at all, just being an
 extension or so.
 We might not want every application to have control of these things.


 xrandr doesn't seem to have much more authentication than this. Its not much
 more dangerous than changing the resolution, which many fairly pedestrian apps
 expect to be able to do (i.e. games). Indeed its potentially a good deal less
 dangerous than fullscreen mode (though that can be fixed with UI), far less
 dangerous than screenshots from a security perspective (and we can't have
 clients render certain effects if they can't get a copy of what's behind them
 to distort), and even a good deal safer than input grabs.

Apps shouldn't generally change the *default* resolution.  Games and
such may want to show their window at the native resolution and that's
part of the fullscreen plan:

  http://lists.freedesktop.org/archives/wayland-devel/2010-November/000117.html

Of course, the DE config tool will want to be able to change the
default mode and placement of monitors.  In that case we're talking
about a specific DE with it's own display configuration tool, and
perhaps the tool can just update the underlying config (GConf or so)
and the compositor picks up the change from there.  As a first step
I'd rather just add the extra info to wl_output (list of available
modes, refresh rates, sub pixel layout, connector name etc), and punt
on how to change it for now.

Kristian
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel