1. unsigned char* as a return type was not even compatible
with the default colorspace (ARGB: 32 bits).
2. Change all unsigned to int for... uh... simplicity
unsigned is more correct than int for things like width,
size or stride, but in fact having both ints (x,y) and unsigned
ints makes the code more complex.
This is a matter of personal taste.
This will be properly implemented by the subclasses. In particular,
map/unmap will be used where it makes sense, and data_get/set will
be limited to Efl.Canvas.Image and Surface.
A small hack to the toolchain allows us to generate enums with eolian
for use by Eet and Emile (internal or otherwise non-eo libraries).
Thanks to how BUILT_SOURCES works, the eo.h files required by Emile
will be generated before they are used.
This adds a partial dependency on eo for eet and emile:
- package dependency
- include dependency
There is no library link dependency.
several draw funcs keep a static Cutout_Rect *rects = NULL; variable
to cache cutout rects to avoid re-allocating them a lot etc. this is
fast and handy but we may use these from multiple threads. thats bad
.... mmmkay. so this fixes it the dirty way - makes them thread local.
:)
this fixes T3348 - the crash mentioned by @zmike
@fix
so there was/is a case where when an elm window is resized from
outside, it will happen to use the last known size (maybe old) and end
up requesting a resize to that size again itself. it basically
triggers its own resize request as a result of resize events. this
fixes that and stops the loop
@fix
this resolves the issue of all elm windows being created at 1x1 and
immediately resizing to another size after being shown, causing all
kinds of failures in various environments
@fix
Summary:
commit f9e6550468 Changed the RENDER_SYNC
the default behaviour (previously it was something you had to
change source code to set that way)
This leads to massive amounts of tearing with the drm and gl_drm backends,
as they no longer wait for vblank before rendering.
I've changed the env var to ECORE_EVAS_RENDER_NOSYNC and made it
non-default as it used to be. People can set the env var to disable
frame limiting instead of having to set an env var to enable it.
Frame limiting really should be the default behaviour.
Reviewers: zmike, devilhorns
Reviewed By: devilhorns
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3829
Summary:
Each Ecore_Wl_Input structure has there own keymap.
This keymap is struct xkb_keymap used in libxkbcommon lib and
the client can get this keymap from server in wayland system.
So if the client want to get keymap and use some libxkbcommon APIs,
use this API to get keymap.
Test Plan: Use this api after initialize wayland system.
Reviewers: raster, zmike, ManMower, devilhorns
Reviewed By: devilhorns
Subscribers: input.hacker, ohduna, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3819
Summary:
add null check in _style_match_tag()
if evas_object_textblock_text_markup_set() is called with markup text before setting style,
segmentation fault is occurred in _style_match_tag()
@fix
Test Plan:
Insert this situation to test suite
-> test id : evas_textblock_simple
Test for without this patch:
1. apply patch just "src/tests/evas/evas_test_textblock.c" partially.
2. $make check
Test for with this patch:
1. apply this patch completely (2 files)
2. $make check
Reviewers: id213sin, herdsman
Subscribers: Blackmole, cedric, jpeg
Projects: #efl
Differential Revision: https://phab.enlightenment.org/D3818
Only Efl.Canvas.Proxy implements efl_canvas_proxy_source_clip_set.
Legacy image objects should use legacy APIs.
Thanks @zmike for the report and sorry I never saw the ERR myself :(
Fixes T3342
Width calculations should consider the x_bear. This has been leading to
inconsistent results between wrapping calculation during layout and the
final formatted size.
Also, we should stop our walk only when exceeding 'x', so changed "<="
to "<".
@fix
Summary:
Previous implementation loaded data from memory first and then checked the borders.
Here I check the borders first as it is for C implementation.
This prevents read of non-accessible memory.
Reviewers: cedric, jypark, Hermet, jiin.moon, jpeg
Reviewed By: jpeg
Projects: #efl
Differential Revision: https://phab.enlightenment.org/D3809
So I forgot to clean my hard drive from previously generated files,
and obviously everything still worked. This lead to having to roll back
evas_smart_clipped.eo as a public eo object until we merge elementary.
Still I would like someone to take a look at elm_pan.eo and figure out
how to not rely on smart clipped there.
There's no point in calling fill_set AND fillet_set(false).
If a users wants to specify the fill, that should be enough
to switch to non-filled mode.
Maybe the "filled" mode should even be called auto or something?
Summary:
Applications usually use edje syntax like as,
```
part { name :"bg";
type: SWALLOW;
description {
state: "default" 0.0;
rel1.relative: 0.0 0.0;
rel2.relative: 0.0 0.0;
align: 0.0 0.0;
min: 100 100;
}
}
```
But edje does not calculate it exactly without "fixed: 1 1".
So edje calculation is repeated until 4000 x 4000, it is waste of time.
Reviewers: woohyun, raster, Hermet, id213sin, cedric
Reviewed By: cedric
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3801
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
This is a bit artificial, as all image objects are still based on
the Evas.Image main class. The inheritance tree alone does not
give much information on what features are supported by which
class (eg. only Efl.Canvas.Image supports the file interface for
file_set).
This replaces standard Evas_Object_Image when it is used "normally",
ie. it's an image from a file or from a pixel buffer. All other APIs
(proxy, snapshot, 3d, gl, ...) are disabled on this object.
Also, reduce number of failing calls when the object is not a legacy
object, but a legacy function is called. This is because a lot of
image APIs are called internally using the legacy APIs, often in
order to reset the state of the image object (eg. set file to NULL,
etc...)
This patch fixes an issue detected by Coverity where 'obj' is written
twice with the same value
CID1353363
@fix
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
This patch fixes an issue detected by Coverity where 'obj' is written
twice with the same value
CID1353365
@fix
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
This patch fixes an issue detected by Coverity where 'obj' is written
twice with the same value
CID1353365
@fix
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
Summary:
Main flow: add several meshes(with different number of polygons) in one node,
enable LOD for node, set boundary distances to choose need mesh depend on distance
to the camera node, render only need mesh. Add API's enable lod in
evas_canvas3d_node module and set boundary distance to module
evas_canvas3d_mesh module Refactored function evas_canvas3d_node_mesh_collect
to calculate distance. Refactored _scene_render to have possibility pass to the
render only need LOD mesh.
Reviewers: cedric, Hermet, raster
Subscribers: jpeg
Differential Revision: https://phab.enlightenment.org/D3731
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
Summary:
Add spin lock to access to new flag can check to
status of the preload
Reviewers: jpeg, cedric, jypark
Subscribers: raster
Differential Revision: https://phab.enlightenment.org/D3775
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
Summary:
Edje data structure is passed as a parameter, but in file.set method
_edje_fetch() is called one more time unnecessarily.
Reviewers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3788
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
Summary:
Use aditional temporary vector for intermedia results in case output vector
the same as target vector in functions:
eina_vector2_transform,
eina_vector2_homogeneous_direction_transform,
eina_vector3_cross_product,
eina_vector3_transform,
eina_vector3_homogeneous_direction_transform
It was in original version (in evas_vecN, module evas_3d_utils.h)
Enrich test suit for this case.
Reviewers: jpeg, cedric
Reviewed By: cedric
Differential Revision: https://phab.enlightenment.org/D3795
Signed-off-by: Cedric Bail <cedric@osg.samsung.com>
It was temporarily eoid, change it to eo_self which is more
descriptive. In this process I also made it a macro to prepare
for the proposed changes on the ML for the fallback implementation
for compilers that don't support the compound statements returning
values gcc extension.
The buffer class is more low-level and alpha is a pretty
common property. I still wonder how to share it with the canvas
and other things.
It doesn't belong to Efl.Gfx.Base since we could have plain old
buffers that are not evas objects (only in-memory buffers) but
Efl.Gfx.Base may also need the alpha flag.
- image_native_init
- image_native_shutdown
init() will be used to test whether the engine supports a
certain type of native image.
Note: Native image support is very much dependent on the engine,
and some stuff like opengl should work everywhere (even in sw
with osmesa) but that's not the case.
Annoying incomplete initializer warning. Apparently gcc/clang
don't consider {0} as good enough for "initialize everything to 0"
even though they do it.
Efl.Canvas.Snapshot and Efl.Canvas.Proxy are specialized
classes previously implemented as features of Evas.Image.
Note: this half of the work, as I suffered from a bad
merge and rebase with my work branch on top of master.
This checks whether the object was created with a legacy
API, ie without not using eo_add directly. This will be used
to help with the transition from EAPI to EO APIs, as some EAPIs
should not be used with the new EO types (eg. file_set on a
Proxy object).
By default it doesn't do anything besides ERR().
In DEBUG mode, it will return immediately.
The macro will return if eo_obj is NULL.
Those APIs should provide a cleaner interface than the
old data_set/data_get APIs, by making sure the operations are
atomic (ie. no need to call size_set, cspace_set and then data_set).
padding/duplicated borders are not supported.
TODO: Implement legacy API on top of the new API, instead of
this quick patch
Hopefully the doc and signature are better than the current
evas image equivalents data_get/data_set.
Those APIs are not like map/unmap so we need to decide which
model we prefer.
This interface groups all low-level animated image functions.
FIXME:
- Rename to Efl.Image.Animated once eolian is fixed
- Fix mess with emile enum (loop_hint)
It's not actually implemented anywhere. There's a flag that's
never read. Proper support would require quite some work.
Once we actually implement fill_spread support, we can bring
the API back without breaking compatibility.
If we fail to schedule a VBlank event, then we should disable custom
ticks and fallback to timer-based animators. This patch fixes some
issues with Intel Atom based setups where rendering would fail when
using custom animators.
@fix
Summary: win-builds provide libcairo-2.dll and not libcairo.dlL
Test Plan: ector test progral
Reviewers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3787
The device struct is API, so its copy of the fb pointer needs to be
kept in sync with the output struct's. We do this when the flip completes
to try to prevent access to an fb that's about to flip.
This fixes Enlightenment screenshots.
@fix
I found a way to keep eo_add() the way it was and gracefully degrade to
a portable (but not as fast) solution for compilers that don't support
the compound macros returning a value gnu extension: ({int a; a;}).
I'm reverting these changes now, and I'll introduce the fallback as soon
as I can.
This reverts commit b85bb37183.
Summary:
Developer cannot notice that any description didn't applied due to missing description or typo.
This message will be helpful to make correct the application.
Reviewers: cedric, Hermet, raster
Subscribers: soohye.shin, minkyu, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3783
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
It has been decided that we would not use any namespace for interface
and they will sit in efl main namespace.
This patch doesn't correct the naming of the event has we don't have a
prefix for event. We do still have EFL_ANIMATOR_EVENT_ANIMATOR_TICK,
instead of a nicer EFL_EVENT_ANIMATOR_TICK.
EINVAL is bad, we can't go on. If we treat it like it's not a fatal
error we'll end up spinning on the fd and constantly retrying sends
on the dead wayland connection.
@fix
As ecore_drm_private.h already includes config.h header, we don't need
to include it here in these files also
@fix
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
As portions of this code have been derived from existing code in
Weston, we should also be including their copyright/licence text to
give credit.
NB: Fixes T3286
@fix
Signed-off-by: Chris Michael <cpmichael@osg.samsung.com>
Reverting this at Felipe's request following my email. There are many
things I strongly object to in this commit. I've touched the surface of
those on the ML (which doesn't work at the moment), though we need to
better discuss it.
The gist:
1. dlsym is a really bad hack that is not even needed.
2. I don't see why eo should even be aware of promises. It's not aware
of list, hash and etc.
3. The eolian changes were done wrong.
This should have been discussed and consulted before done, even if only
because of the amount of hacks it includes and the cross-domain (ecore,
eo and eolian) nature of it.
This reverts commit f9ba80ab33.
Imagine this. You have an object. You pass this object handle as a
message to another thread. Let's say it's not a UI object, so
something you might expect to be able to be accessed from multiple
threads. In order to keep the object alive you eo_ref() it when
placing the message on a queue and eo_unref() it once the message is
"done" in the other thread. If the original sender unref()ed the
object before the message is done, then the object will be destroyed
in the reciever thread. This is bad for objects "expecting" not to be
destroyed outside their owning thread.
This allows thius situation to be fixed. A constructor in a class of
an object can set up a delete interceptor. For example if we have a
"loop ownership" class you multi-ple-inherit from/use as a mixin. This
class will set up the interceptor to ensure that on destruction if
pthread_self() != owning loop thread id, then add object to "delete
me" queue on the owning loop and wake it up. the owning loop thread
will wake up and then process this queue and delete the queued objects
nicely and safely within the "owning context".
This can also be used in this same manner to defer deletion within a
loop "until later" in the same delete_me queue.
You can even use this as a caching mechanism for objects to prevernt
their actual destruction and instead place them in a cached area to be
picked from at a later date.
The uses are many for this and this is a basic building block for
future EFL features like generic messages where a message payload
could be an eo object and thus the above loop onwership issue can
happen and needs fixing.
This adds APIs, implementation, documentation (doxy reference) and tests.
@feature
This reverts commit 7f4ea1a79c.
This reverts one of three parts of the try to get sub directory
compilation back into eina. It breaks our distcheck though and I
talked to Cedric about it and he prefers to revert these as we might
need to go another route to bring this functionality back. Details
will come to the mailing list.
This reverts commit 1affc60d00.
This reverts one of three parts of the try to get sub directory
compilation back into eina. It breaks our distcheck though and I
talked to Cedric about it and he prefers to revert these as we might
need to go another route to bring this functionality back. Details
will come to the mailing list.
This reverts commit e26fcbb1dc.
This reverts one of three parts of the try to get sub directory
compilation back into eina. It breaks our distcheck though and I
talked to Cedric about it and he prefers to revert these as we might
need to go another route to bring this functionality back. Details
will come to the mailing list.
Add a promise object that allows Eolian interface to include promises
as a way to have asynchronous value return and composibility.
The usage is like this in a .eo file:
class Foo {
methods {
bar {
params {
promise: Promise<int>;
}
}
}
}
Which will create the following API interface:
void foo_bar(Ecore_Promise** promise);
and the equivalent declaration for implementation.
However, the API function will instantiate the Promise for the
user and the implementer of the class.
This iterator is convenient when you already have a C-Array and you
need to pass this array to a function receiving an Eina_Iterator.
int array[] = {1, 2, 3, 4};
int* array2[] = {&array[0], &array[1], &array[2], &array[3], NULL};
Eina_Iterator* iterator = eina_carray_iterator_new((void**)array);
Summary:
When glib support is enabled (HAVE_GLIB), _ecore_glib_init()
was always reserving resources. However, its counterpart may not
be called when:
- glib is not always integrated and
- when a user didn't explicitly required the integration.
Calling _ecore_glib_init() within the request code will cause the
resources to be reserved only when the integration with glib is
required and furthermore guarantees that resources always have a
chance to be released.
Reviewers: cedric, raster
Subscribers: cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3749
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Summary: While making new changes after rewieving D3710 we met this bug again, removing eo_unref is the best way to fix it because _eo_ref_replace from D3021 makes nothing special.
Reviewers: cedric, raster, Hermet
Subscribers: jpeg, artem.popov
Differential Revision: https://phab.enlightenment.org/D3745
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
Summary:
If not found edje part description, edje just set default description in spite of RTL status.
This adds to call function for getting the correct description as RTL status.
Reviewers: raster, Hermet, cedric
Subscribers: minkyu, sju27, cedric, jpeg
Differential Revision: https://phab.enlightenment.org/D3735
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>