Commit Graph

123 Commits

Author SHA1 Message Date
Vincent Torri 8db62cb22b remove arguments of LOGFN in ecore_wayland modules as the are always the same
Reviewers: raster, devilhorns

Reviewed By: devilhorns

Subscribers: devilhorns, cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D11777
2020-05-06 09:18:31 -04:00
Christopher Michael ea2b24b182 ecore-evas-wayland: Minor formatting fix
NB: No functional changes
2019-10-22 10:04:01 -04:00
Hermet Park 1c974289e4 ecore_evas wayland: fix a build break.
Summary: missed changing here.

Subscribers: cedric, #reviewers, #committers

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D8712
2019-04-25 18:56:39 +09:00
Derek Foreman e382bac1a0 wayland: Fix elementary setting window parents at creation time
Summary:
We need to pass the entire pointer, not just 32-bits of it.

Fixes a crash with enlightenment sandbox gadgets where
ecore_wl2_window_alpha_get() is called with an invalid pointer while
trying to display a pop-up.

Reviewers: zmike, devilhorns

Reviewed By: zmike, devilhorns

Subscribers: devilhorns, cedric, #reviewers, #committers, zmike

Tags: #efl

Differential Revision: https://phab.enlightenment.org/D6775
2018-08-08 09:37:30 -04:00
Chris Michael dc43017906 ecore-evas-wayland: Remove unused includes
As most of the "hard work" has been moved into
ecore_evas_wayland_common file, these includes are no longer needed
here.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2016-12-02 14:25:10 -05:00
Derek Foreman c425140a67 ecore_evas_wayland: Minimize differences between shm and egl
Finally bring these together as much as possible to avoid future
diversions when bugs are only fixed in one or the other.

There are functional changes - state tracking for client side effects is
now added to the shm engine, some bug fixes for the egl engine have been
brought to the shm engine.
2016-11-02 13:37:02 -05:00
Derek Foreman 4260d5d3a2 ecore_evas_wayland: Make resize code common
Brings resize code into the common implementation - there is a functional
change.  There appears to have been a bug in the egl resize where it
used the same w, h order for portrait evases as for landscape.  This was
fixed in shm.  I've used the shm variant for the common code.
2016-11-02 13:37:02 -05:00
Derek Foreman b23797c55a ecore_evas_wayland: Make rotation_set common
Rotation set can be moved into common now - should be no functional
change.
2016-11-02 13:37:01 -05:00
Derek Foreman 5d2a25a01d ecore_evas_wayland: Make transparent_set common
Moves transparent set into the common implementation - there is a
functional change here - the egl engine now calls transparent_set in
render_updates like the shm engine.

It is probable the this was the intended behaviour all along.
2016-11-02 13:37:01 -05:00
Derek Foreman 9ca6e274a4 ecore_evas_wayland: Make alpha set common
Moves alpha set into the common implementation - there is a functional
change here - the egl engine now calls alpha_do in render_updates like
the shm engine.

It is probable that this was the intended behaviour all along.
2016-11-02 13:37:01 -05:00
Derek Foreman 82277ae6b3 ecore_evas_wayland: Move more functions into the common implementation
Show and hide can be made common with almost no functional changes.
2016-11-02 13:37:01 -05:00
Derek Foreman af4a71bcf0 wayland evas engines: share engine info structure
These engines are incredibly similar - by sharing the same engine info
structure we'll be able to simplify the wayland ecore_evas bits and
make them much more maintainable.
2016-11-02 13:37:01 -05:00
Derek Foreman 54cf6dac4a wayland evas engines: rename wayland display to wl_display
Continuing to make the shm and egl engines closer to eachother.
2016-11-02 13:37:00 -05:00
Derek Foreman b898d3f929 wayland ecore evas: move move_resize to common
It's identical in both shm and egl variants, share it.
2016-11-02 13:37:00 -05:00
Derek Foreman 398771bf8a evas_engines: Add fn_evas_changed callback
To allow using the pageflip completion event to drive timing in the DRM
engine we need to know as soon as possible that a render has been after
a render has been considered if it will cause a page flip or not.

The fn_evas_changed callback sends this information.
2016-09-08 13:55:23 -05:00
Chris Michael 0da58a8d78 ecore-evas-wayland: Fix issue of passing wrong values to resize
Coverity detected that the same code was being passed to resize
regardless of canvas orientation. This patch fixes the issue by
passing the proper values to window_resize.

Fixes Coverity CID1357150

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-06-30 11:03:07 -04:00
Chris Michael 1fb3c33286 ecore-evas: Fix error handling issues in wayland_shm engine
This patch fixes 2 Coverity issues where engine_info_set was being
called, but the return was never being checked.

Fixes Coverity CID1357141 and CID1357142

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-06-30 10:51:29 -04:00
Chris Michael c163e51dd3 ecore-evas-wayland: Minor formatting fixes
NB: no functional changes

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2016-06-13 16:19:46 -04:00
Jean-Philippe Andre 5aa00004a5 ecore_evas: Register direct input cb from modules
If the ecore_evas modules were using
ecore_event_window_register() then they can also redirect
everything though the direct callback instead.
2016-05-31 19:03:04 +09:00
Mike Blumenkrantz 9d5caf00b6 wayland: implement session recovery
add support for reconnecting wayland applications if the compositor dies

disconnect -> destroy gl ctx + image textures -> block rendering ->
reconnect -> create gl ctx -> create image textures -> unblock rendering ->
sprinkle special seasoning on top -> just like ma used to make

 #SamsungFeatures

@feature
2016-05-05 10:49:31 -04:00
Derek Foreman 34e539a3c1 wayland_shm: Add dmabuf to engine info
Get the dmabuf protocol object from ecore_wl2 and store it in engine info
2016-04-19 15:11:09 -04:00
Cedric BAIL bb1a1eef65 ecore_evas: introduce support for per window animator trigger.
This code is currently only using the older fallback code and not any
new event source, so all animator on all window are still triggered
whatever the case are.
2016-02-02 10:47:25 -08:00
Derek Foreman ddae80af1d wayland: use wl_surface.damage_buffer if available
Summary:
wl_surface.damage_buffer() takes surface damage in buffer co-ordinates.

Right now since we don't use wayland's scaling, transforms, or viewports
it's exactly the same as wl_surface.damage().  In the future if we start
using those features it's much easier to do so with damage_buffer().

Reviewers: zmike, devilhorns

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D3457
2015-12-28 09:09:04 -05:00
Mike Blumenkrantz 54df1d9c6a ecore-evas wayland: move frame sending to pre-flush callback
it was possible to deadlock rendering if a pre-render occurred but
the resulting render had no updated regions

@fix
2015-12-15 17:24:52 -05:00
Chris Michael 757f530af9 ecore-evas-wl: Defer creating surfaces for wayland canvas
This code adds support for deferring of surface creation and showing
inside Ecore_Evas Wayland. This is needed for Enlightenment so that it
does not try to create or show surfaces until the compositor has had a
chance to sync globals. This fixes an issue where early surface
creation would cause a crash in the compositor due to globals not
being syncd.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-11 11:26:24 -05:00
Chris Michael abbfde9d68 ecore-evas-wayland: Move configure acknowledge to render_flush_pre
If we acknowledge a configure from xdg during post render, we end up
breaking maximize of EFL clients inside Weston (and perhaps other
compositors). In order to fix that, we will now send the configure ack
post render but pre flush.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2015-12-09 12:08:15 -05:00
Chris Michael 49e645d695 ecore-evas-wayland: Properly cleanup ecore_wl2 during error
If we fail to connect to an existing wayland display, then we should
properly cleanup (call ecore_wl2_shutdown) before exiting

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2015-12-04 11:40:54 -05:00
Chris Michael 04a4b599ab ecore-evas-wl: Cleanup creating a wayland canvas
Unsure where all these extra display_connect calls came from, but
remove them.

@fix

Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
2015-12-04 11:36:15 -05:00
Chris Michael caa1b4323b ecore-wl2: Port Ecore_Evas engines to use Ecore_Wl2 code
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:07:20 -05:00
Chris Michael 7ae6c7d11d ecore-wl2: Port Ecore_Evas engines to use Ecore_Wl2 code
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:05:01 -05:00
Chris Michael 9e83ddbc48 ecore-wl2: Port Ecore_Evas engines to use Ecore_Wl2 code
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:05:01 -05:00
Chris Michael 7f8b269c3e ecore-evas-wayland: Fix error message for connect failures
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:03:35 -05:00
Chris Michael c092941be8 ecore-evas-wl: Use ecore_wl2_display_window_find function
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:02:40 -05:00
Chris Michael da2990b414 ecore-evas-wl: Fix calls to ecore_wl2_window_resize (due to botched
rebase)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:02:40 -05:00
Chris Michael def834380b ecore-evas-wayland: Comment out calls to set custom animator
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:02:40 -05:00
Chris Michael cd1d9ec196 ecore-wl2: Port Ecore_Evas engines to use Ecore_Wl2 code
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-12-03 12:02:40 -05:00
Mike Blumenkrantz a347a47e75 ee-wayland: use frame callbacks exclusively to determine render timing
when running in a wayland compositor, the ideal mode of operation is to
only prepare/send frames when the compositor has finished with the previous
frame

to achieve this, manual rendering can be toggled upon creating and completing
a frame callback, ensuring that a canvas never has multiple pending buffers at
any given time

fix T2784
2015-10-20 16:57:05 -04:00
Chris Michael e7211c1517 ecore-evas-wayland: Don't use custom animators for frame callbacks
Summary: As we now have per-window timer-based animators in
ecore_wayland for frame callbacks, we no longer should be using Custom
animators to handle surface frame callbacks

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-10-14 14:56:17 -04:00
Chris Michael 6b943ffa70 ecore-evas-wayland: Don't resize ecore_wl window to include frame size
Summary: ecore_wl_window_resize adjusts the internal representation of
the window size so this should not include the "framespace" also. This
fixes an issue where xdg surface would be getting an incorrect window
geometry which included framespace.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-10-12 10:58:00 -04:00
Chris Michael 210c6b9b7c ecore-evas-wayland: Set ee->draw_ok appropriately based on visibility
Summary: A previous code change to the common code which processes
updates is relying on having the ecore_evas->draw_ok flag set in order
to process updates. This change makes sure that ee->draw_ok is in sync
with canvas visibility.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-10-08 16:10:53 -04:00
Chris Michael 65578034ef Add experimental implementation of custom animator ticks
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-08-20 14:21:02 -04:00
Chris Michael 5f8f87df3d ecore-evas-wayland: Set wl_display in the evas engine structure
Summary: This sets the wl_display field of the Evas engine info
structure so that the wl_display can later be used for dispatching
queue while we await a free buffer

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-07-30 14:42:14 -04:00
MinJeong Kim 2cf0ed49ce ecore_evas_wayland: prevent duplicated shutdown of ecore_wl
Summary:
When the ecore_evas of wayland_egl/shm is freed with ecore_evas_free(),
ecore_wl_shutdown() is called by _ecore_evas_wl_common_free().
so ecore_wl_shutdown() after ecore_evas_free() has to be skipped.
@fix

Reviewers: devilhorns, raster, zmike, gwanglim

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2503
2015-05-14 07:55:24 -04:00
Cedric BAIL ce5ccfb5be ecore: remove the need to order the header correctly for Windows. 2015-05-07 09:53:10 +02:00
MinJeong Kim f485d5ffdd ecore-evas-wayland: remove duplicated shutdown of ecore_evas_wl_common
Summary:
 After a creation for ecore_evas_wayland_shm or ecore_evas_wayland_egl is
failed, _ecore_evas_wl_common_shutdown() gets called 'twice'.

 First shutdown is from _ecore_evas_wl_common_free() which is set as fn_free()
of ecore_evas engine, and this fn_free() is called by ecore_evas_free().
 Second is from direct call inside ecore_evas_wayland_shm_new_internal()
(or ecore_evas_wayland_egl_new_internal()).
 This duplicated shutdown causes block of first next _ecore_evas_wl_common_init
because init count is not zero but -1.

 So second shutdown should be removed so that it makes enable fall back to
another wayland engine correctly when one is failed to create ecore_evas_wayland.

@fix

Reviewers: gwanglim, devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D2451
2015-04-30 11:31:19 -04:00
Tom Hacohen 5b5b7113b7 Ecore_evas wayland: remove double parenthesis around comparison.
Double praenthesis should be used around assignments, not comparisons.
Doing this correctly all aronud lets the compiler warn us about potential
mistakes.
2015-04-22 13:13:21 +01:00
Chris Michael b55a24727a ecore-evas-wayland: Remove frame callbacks from Ecore_Evas wayland
engine

Summary: Frame callbacks are now handled inside the engine itself and
are thus not needed here anymore

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-03-17 15:50:56 -04:00
Mike Blumenkrantz 7171135792 ecore evas should not crash when unsetting pointer
ref D812

disappointed.jpg
2015-02-06 17:54:08 -05:00
kabeer khan c1d805d2b4 ecore_evas/wayland_shm: Set alpha of ecore_evas object if parent alpha is set
Summary:
Resolved FIXME ecore_evas_wayland_shm_new_internal to set alpha if parent alpha is set

Signed-off-by: kabeer khan <kabeer.khan@samsung.com>

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1842
2015-01-05 09:12:30 -05:00
Chris Michael 9cd2d614e9 ecore-evas-wayland: Fix issue with ELM_PROFILE=mobile and windows not
showing up correctly.

Summary: If elm config profile is set to Mobile, then the
auto_norender_withdrawn is set to 1, which was causing Elm windows to
not draw properly due to the ee->withdrawn property not being updated.
It was not getting updated due to these checks for override.

NB: Tested this with all elm profiles, tested in weston, and tested in
Enlightenment (Wayland).

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-05 12:52:22 -05:00