[PATCH weston 1/4] libweston: Export weston_output_transform_scale_init

Armin Krezović krezovic.armin at gmail.com
Sun Oct 9 17:01:12 UTC 2016


On 07.10.2016 11:52, Pekka Paalanen wrote:
> On Fri, 30 Sep 2016 23:25:27 +0200
> Armin Krezović <krezovic.armin at gmail.com> wrote:
> 
>> This is required for implementing output layout setting
>> which relies on current output width and height, and
>> those are calculated in this function.
>>
>> It also changes the function signature to make use
>> of already stored scale and transform values in the
>> weston_output object.
>>
>> Signed-off-by: Armin Krezović <krezovic.armin at gmail.com>
>> ---
>>  libweston/compositor.c | 31 ++++++++++++++++++-------------
>>  libweston/compositor.h |  2 ++
>>  2 files changed, 20 insertions(+), 13 deletions(-)
> 
> Hi,
> 
> I think this would need a bit more thought on the API.
> 
> The requirement is that one has to set some output parameters (video
> mode, transform, scale) before the output size is available. Output
> size then is needed for doing the layout.
> 
> IMO it would make more sense to add a new function
> weston_output_get_size(), which would take into account the currently
> set (pending) parameters and compute the resulting size.
> 
> This is also good in the long term since we would like to make struct
> weston_output opaque to the libweston user. We are going to need a
> getter for the size anyway.
> 
> 
> Thanks,
> pq
> 

Hi,

It makes sense, yes. Do you think we'd need a similar function to get
the current output coordinates (used for computing new position)?

Thanks, Armin.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 837 bytes
Desc: OpenPGP digital signature
URL: <https://lists.freedesktop.org/archives/wayland-devel/attachments/20161009/f5cf86c9/attachment.sig>


More information about the wayland-devel mailing list