Summary:
We now track each shm buffer's time since last draw so evas can tell
what it needs to re-render.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2893
Summary:
This is when we're about to start a new render, so it's the best
time to set up the next buffer to draw to.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2892
Summary:
We already have *current, but we're not using it properly. Let's throw
out curr_buff and just use *current.
This temporarily makes swapmode_get do full renders, this will be
fixed in a future commit that adds proper buffer ages.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2890
Summary:
Split out the buffer picking stuff because we're going to want to call
it from somewhere else.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2889
Summary:
It doesn't redraw anything, it posts a buffer full of data to the
compositor.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2887
Summary: Since the surface_swap functionality is changed now, we no
longer need to bother checking if the leaf is busy as we don't use the
leaf itself inside this function anymore.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary:
Looks like the recent changes to swap/redraw have fixed a problem with
damage tracking and we no longer need this.
Damage history seems ok without it now.
@fix
Reviewers: zmike, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2876
Summary:
The way things were, we'd be committing a buffer we hadn't rendered to
yet.
Now redraw() contains all the attach/damage/commit logic, and swap() is
called afterwards to set up a new target buffer for the next render.
@fix
Reviewers: zmike, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2875
Summary:
We don't need to - all the frame callback does for us is ensure a queue
push.
We should destroy any callback we receive when we receive it.
@fix
Reviewers: zmike, devilhorns
Subscribers: cedric
Differential Revision: https://phab.enlightenment.org/D2874
Summary: This fixes an issue where we may been missing a frame
callback due to the wl_surface_commit being called before the frame
callback listener was setup. Now we will setup the frame callback
listener before doing any wl_surface_commit so that we don't miss
frames.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: This fixes an issue where the wrong swapmode was being
returned to the evas render function. This was causing focused windows
to blink.
NB: Big thanks to Derek for assisting !! :)
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: As we override the software_generic function for
eng_output_resize, so we can handle resize edges, we should also be
updating the software_generic's render engine size here because the
function for software_generic->output_resize never gets called.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: This fixes a possible race condition that could happen when
using more than 2 buffers. Instead of searching for a free buffer in
various places, find a free buffer when evas requests the buffer data
and save that free buffer as the 'current buffer'
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: evas_cache and evas_cache2 are expecting the width of the
buffer when caching so just use that directly rather than calculating
bpl.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: As reported by derek & zmike, the previous engine refactor
left some issues where the app would 'flash' during redraws due to
buffer handling. This commit fixes that issue along with flashing
during resize.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Summary: This patch set fixes the issue of Evas wayland shm engine
causing crashes when resizing efl apps in the E wayland compositor. It
refactors the evas engine to wait for release events on buffers, and
hooks into frame callbacks so that release events will get triggered
at the appropriate time.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
We allocate a new eina_rectangle here, but we never free it after
sending damages to the surface.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Software Generic backend can send us OUTBUF_DEPTH_INHERIT during a
reconfigure. If we are inheriting the previous depth, let's check that
so we don't get needless destrouction/recreation of shm buffers.
@fix
Signed-off-by: Chris Michael <cp.michael@samsung.com>
@bugfix: When creating a temporary file for the buffer's mmaped data,
we need to make sure there is an appending '/' in the name else
mkstemp will fail due to improperly formatted filename.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
buffer file.
@bugfix: When we create the mmap'd file for shm buffer access, try
using the XDG_RUNTIME_DIR first as the place to create the file. If
that does not exist in the environment, Then fallback to using /tmp
directory.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
When rotation is 0, we need to advance the destination pointer in the
X direction by a Multiple of Bits-Per-Pixel...not an addition.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Being annoyed by different types of eina critical macros - CRI, CRIT,
CRITICAL -, I concluded to unify them to one. Discussed on IRC and
finally, CRI was chosen to meet the consistency with other macros -
ERR, WRN, INF, DBG - in terms of the number of characters.
If there is any missing bits, please let me know.
When an Ecore_Evas is hidden, it will destroy the buffer swapper. When
it's shown again, it will try to attach a new buffer, that can be same
buffer. If that global var is still pointing to the old buffer, it can
match to it again and avoid sending a new buffer. So, just put this sent
buffer var in the buffer swapper, and it will get set to NULL when the
swapper is destroyed and created again.
This should fix an intermitent problem of ecore_evas_show() not always
working after an ecore_evas_hide() on the wayland_shm engine.
NB: When trying to attach a buffer to a surface, there was a corner
case that could fail in that if we just had 'rects' but count was 0,
then the surface would not get damaged (essentially a call to
wl_surface_damage would get passed 0,0 as the size). This fixes that
problem in that if count is <= 0 now, then we'll damage the whole
surface.
Signed-off-by: Chris Michael <cp.michael@samsung.com>
Evas_Common.h should be used for the public header, and rather rename
evas_common.h internal header to another name.
Sa:
Evas_Common_Header.h -> Evas_Common.h
evas_common.h -> evas_common_private.h
Shouldn't have both Evas_Common.h and evas_common.h because of case
insensitive filesystems.
NB: This is needed because some compositors (Weston) are expecting
wl_surface_get_user_data to return a buffer.
Signed-off-by: Chris Michael <cp.michael@samsung.com>