Commit Graph

332 Commits

Author SHA1 Message Date
Cedric Bail 635448a0a9 evas: readjust pushed engine geometry without the output offset. 2018-02-21 11:55:25 -08:00
Cedric Bail 4959286c29 evas: add output coordinate debug. 2018-02-21 09:39:04 -08:00
Jean-Philippe Andre 0f1469280d win: Show windows created by efl_add with a job
This fixes efl_add(WIN) on wayland, using an internal API.
Test scenario:
  ELM_DISPLAY=wl elementary_test -to "Part Shadow"
2017-12-19 20:37:25 +09:00
Cedric Bail dd4be85d7e evas: forgotten adjustement to handle the output geometry offset. 2017-12-14 10:56:49 -08:00
subhransu mohanty b038d7df25 Remove evas internal dependency from the evas_font module
Summary:
dev branch : devs/subhransu/font

The Final goal is to move the evas_font module to ector so that both ector and evas can reuse the code.
make the api simple so that sam eapi can be used by evas_textblock and ector text.

This is the 1st stage to achive that gola, first remove the evas internal dependancy as much as possible before moving to ector library.

Reviewers: jpeg, raster, herdsman, cedric, id213sin

Subscribers: cedric, jpeg

Differential Revision: https://phab.enlightenment.org/D5419
2017-11-07 11:34:53 +09:00
Cedric BAIL 84907e719d evas: allow to suspend the rendering of an output. 2017-10-26 13:35:27 -07:00
jiin.moon 98147ce097 evas : Improve the performance by reusing map surface
Summary:
If object just has update of map point without other changes included child,
the map surface can be reused.

Reviewers: jpeg, cedric

Differential Revision: https://phab.enlightenment.org/D5181
2017-09-28 12:30:36 +09:00
Jean-Philippe Andre 0c46fc7103 evas: Use Eina_Rectangle internally
Instead of Evas_Coord_Rectangle which is exactly the same thing but with
a different name and typedefs.
2017-09-13 18:03:34 +09:00
Cedric BAIL 4cfc8f12fc evas: actually output might not be initialized until later. 2017-09-11 11:32:44 -07:00
Jean-Philippe Andre d920b36ab4 evas: Fix a few shadow warnings 2017-08-29 10:43:33 +09:00
Cedric BAIL 8286a56279 evas: enable rendering of multiple output. 2017-08-25 10:55:15 -07:00
Cedric BAIL 4b1505c294 evas: no more ENDT. 2017-08-25 10:55:06 -07:00
Cedric BAIL 7fc0ebee37 evas: move updates to be per output. 2017-08-25 10:55:02 -07:00
Cedric BAIL e7527e06d6 evas: decorrelate canvas size from output size. 2017-08-25 10:54:59 -07:00
Cedric BAIL cce4dcc58e evas: remove dead code to improve readability. 2017-08-25 10:54:52 -07:00
Cedric BAIL 545c1a70f4 evas: make Evas_GL work with multi output. 2017-08-25 10:54:19 -07:00
Cedric BAIL 7f8bbe4972 evas: reorder rendering phase to group output related operation. 2017-08-25 10:52:52 -07:00
Cedric BAIL f354463dc1 evas: propagate output in evas_render_updates_internal_loop instead of using ENDT. 2017-08-25 10:52:42 -07:00
Cedric BAIL 79ed7a0cc2 evas: enable handling multi output in evas_render_mapped. 2017-08-25 10:52:38 -07:00
Cedric BAIL 750b9d065f evas: propagate output to evas_render_mask_subrender and don't use ENDT there. 2017-08-25 10:52:33 -07:00
Cedric BAIL a5b4defdd5 evas: use output instead of default one during rendering of proxy. 2017-08-25 10:52:29 -07:00
Cedric BAIL 7bcf483d6f evas: handle multiple output for plane assignment. 2017-08-25 10:51:20 -07:00
Cedric BAIL 1d57cb2627 evas: move all image object related function to use the engine instead of the output. 2017-08-25 10:51:10 -07:00
Cedric BAIL 14f1a0bde7 evas: forgotten convertion from output to engine. 2017-08-25 10:51:05 -07:00
Cedric BAIL 28397e7206 evas: differentiate engine from output. 2017-08-25 10:49:53 -07:00
Jean-Philippe Andre 1a1b8bc451 evas: Set weight to "expand" by default
This is a semi experimental patch to set the default weight
of objects to (1, 1), i.e. EXPAND. This seems like a more
sensible default value than no weight. Some objects may not
need the expand weight, but this seems to be the minority,
not the majority.

Ref T5301
2017-08-23 11:16:45 +09:00
Jean-Philippe Andre c7ca7221ab evas: Fix auto-show of EO objects
Objects show should happen as early as possible during the render cycle,
as it affects smart objects calculation and everything else.

Thanks @JackDanielZ for the report!

Fixes T5880
2017-08-17 10:28:10 +09:00
Jean-Philippe Andre fd9cf1d3b6 evas: Make all EO canvas objects visible by default
All legacy objects remain invisible by default. Any call to
visible_set() will prevent the automatic show() to happen.

show() will be done just before render time, which may be a
bit too late in order to propagate the necessary changes.

This may break some things where some objects are created
internally using efl_add() instead of the legacy API, and
the intent was not to show the object.

@feature
2017-08-04 10:24:03 +09:00
Carsten Haitzler 29eebb44fc evas render - remove obj null check in proxy clip as obj not null
obj is never null. so this check is pointless. not a bug though.

found by PVS studio
2017-07-29 12:26:49 +09:00
Jean-Philippe Andre 7243b71a19 evas: Restore flag pre_render_done in render_mapped
Some objects don't go through render_pre (unchanged, child
of mapped parents), even though they will go through
evas_render_mapped. Those were marked as pre_render_done
inside evas_render_mapped since it seemed to fix some issues
a long time ago.

Unfortunately, if those objects are changed their flag may
not be reset to false, which means they never go through
render_pre, leading to render issues.

I believe simply restoring the value of the pre_render_done
flag should be good enough. I don't know why it is set to
true inside evas_render_mapped but I also don't want to find
out :)

See 9ac13e4aec (old)
See 87e5e70a9d (older)

Patch made with @jiin.moon
2017-07-20 15:17:36 +09:00
Jean-Philippe Andre 505aca0e42 evas: Fix compilation warnings
See 7365c087c7
Shadow variable.
2017-06-29 16:02:36 +09:00
Derek Foreman 7365c087c7 evas_render: Use hardware planes
This is a very simple proof of concept for using hardware planes for
evas image objects.

Right now only dmabuf objects will be dropped into planes, and they're
considered in the order they're in in the scene graph with no attention
paid to which objects will have the most benefit from being on a plane
at all.  There's nothing to prevent your mouse cursor from consuming the
only hardware plane capable of UHD video. :)

This is mostly just to help test the low level functionality in the
engines and ecore_drm2 that enable hardware planes.  Smarter plane usage
is coming.
2017-06-23 08:15:42 -05:00
Cedric BAIL 35e54acc46 evas: stat introducing a concept of engine and output in the backend. 2017-05-12 15:24:45 -07:00
Mike Blumenkrantz ef471e4eca evas: ensure even no-op renders emit RENDER_PRE
ref 67fae7aa0fdc9d778e8db88fc49bc149576994d2
2017-05-12 12:08:24 -04:00
Jean-Philippe Andre 0a224da86f evas map: Introduce new API for maps (Efl.Gfx.Map)
This implements an entirely new API model for Evas Map by relying
on high-level transformations on the object rather than an external
Evas_Map structure that needs to be constantly updated manually.

The implementation relies on Evas_Map.

To rotate an object all you need to do now is
  efl_gfx_map_rotate(obj, 45.0, NULL, 0.5, 0.5);

Or with a C++ syntax:
  obj.rotate(45.0, NULL, 0.5, 0.5);

Or even simply (with default arguments):
  obj.rotate(45.0);

The map transformation functions are:
 - rotate
 - rotate_3d
 - rotate_quat
 - zoom
 - translate (new!)
 - perspective_3d
 - lightning_3d

@feature
2017-05-11 17:54:00 +09:00
Cedric BAIL 688cbeae97 evas: make sure that even when nothing is rendered there is a pair of RENDER_PRE and RENDER_POST events generated. 2017-05-09 15:40:14 -07:00
Cedric Bail dc841ed9b2 evas: always pair RENDER_PRE and RENDER_POST. 2017-05-05 17:55:06 -07:00
Cedric Bail 689e1c8ded evas: don't double check if the canvas has changed. 2017-05-05 17:55:06 -07:00
Cedric BAIL 849a182018 evas: only call output function on initialized output. 2017-04-28 16:11:23 -07:00
Jean-Philippe Andre ac121a628d evas: Fix crash in idle_flush
As reported by raster on the ML. The pointer passed to the
engines is not an engine output but an Efl_Canvas_Output.
2017-04-25 21:19:42 +09:00
Jean-Philippe Andre b25d464f9f evas render: Fix issue with map render
Test case:
  elementary_test -to "Gesture Layer"

Just move the pictures around (eg. to the bottom). They could
disappear entirely.

This is because the geometry used was based on the smart
object "bounding box" rather than the mapped output.

@fix
2017-04-25 14:37:00 +09:00
Cedric BAIL 55e1b3f205 evas: remove engine.data.output.
This is the first step toward handling multi output. This patch
remove engine.data.output from Evas structure and use an Eina_List
for it instead. It also start moving code around to fetch an output
or an engine context (which are the same at the moment, but will be
split in a later patch).
2017-04-24 15:10:48 -07:00
Derek Foreman fddbf75fc9 Fix sed error that changed "video" to "videfl"
commit c662934be8 seems to have accidentally
renamed a few instances of _video_ to _videfl_, this hopefully changes
them all back.
2017-04-17 17:06:28 -05:00
Jean-Philippe Andre 4cbff5f0ea evas filters: Fix maps with filtered snapshots
Another wonder of evas render... maps, clips, snapshots, filters...
This fixes animations with windows that have a snapshot decoration.
2017-04-14 11:26:44 +09:00
Jean-Philippe Andre 08a8072571 evas: Fix cutout handling for snapshot objects
This improves over the previous code for handling
snapshot objects and cutouts. Basically any opaque object
above a snapshot should be obscuring it. That is true
unless a crazy filter is applied, or the snapshot object
is itself the source of a map or proxy.

This also uses eina_tiler instead of a custom (and really
bad) algorithm to compute the obscure regions.
2017-04-14 11:26:44 +09:00
Jean-Philippe Andre c53f1526f1 evas: Make save() work on snapshots
This make save() work on snapshot objects, provided the call
is done from inside render_post.

Also, this saves the filtered output of an image, rather than
its source pixels. Any call to save() on a filtered image must
be done from post-render as well.

Fixes T2102

@feature
2017-04-14 11:26:44 +09:00
Jean-Philippe Andre 530399acde evas filters: Force redraw of snapshot if cutout shrank
The situation is clearly visible in the Snapshot test case:
increase the radius and a red glow would appear. This is because
the snapshot object was not marked as needing redraw and so had
no pixels under the opaque rectangle.
2017-04-14 11:26:44 +09:00
Jean-Philippe Andre b6c5af5edc evas: Fix excessive redraws of snapshot objects 2017-04-14 11:26:44 +09:00
Jean-Philippe Andre 1336b2d9e0 evas filters: Expand snapshot regions by blur radius
When using a snapshot object we have access to exactly all
the pixels below it inside the snapshot surface. So, in order
to produce a nice blur, it is necessary to expand this snapshot
and then clip it otherwise the edges will look a bit ugly.

Unfortunately, there are still places where blurs didn't look
so good, as objects below an opaque region would never get
rendered into the snapshot object. So the edges, inside a
snapshot object, around an opaque region would have blur
artifacts.

This fixes that by shrinking the cutout regions by the radius
of the filter. Eg for blur this is the blur radius.

The test case in elm_test can exhibit this fix very clearly:
a red glow would be visible around the opaque rectangle, but with
these changes we instead see the blurry edges of the objects
below the rectangle.
2017-04-14 11:26:43 +09:00
Jean-Philippe Andre 9b1ea2fc6b evas: Pass obscuring region to the filters
This will be most useful in a special case, where a filter is
used in a window decoration, applied to a snapshot object.

Another optimization that might be wanted is passing a list
of update regions (from the proxy or snapshot).

The filters don't support the obscuring region yet, only some
of the high-level logic is implemented.
2017-04-14 11:26:43 +09:00