Commit Graph

1722 Commits

Author SHA1 Message Date
Mike Blumenkrantz 7171135792 ecore evas should not crash when unsetting pointer
ref D812

disappointed.jpg
2015-02-06 17:54:08 -05:00
Jean-Philippe Andre 88e5369eee Evas masking: Add forgotten file in previous commit 2015-02-06 12:35:12 +09:00
Jean-Philippe Andre 73b16a4962 Evas masking: Also fix map masking with non-bgra images 2015-02-06 12:33:29 +09:00
Jean-Philippe Andre 7d6bb7fe5a Evas masking: Fix GL masking with maps and stuff
This fixes an issue spotted after the previous fix.
Passing the Y-invert flag is necessary because in the usual
case a map is rendered with Y-invert (OpenGL coords vs. Evas coords)
but in case a map is rendered in an FBO (another map's surface)
then Y-invert must be unset.
2015-02-05 22:31:35 +09:00
Carsten Haitzler e483d25082 ecore-x - undo api/abi break with input selecting before release 2015-02-04 18:58:48 +09:00
Chris Michael 17a47136c9 evas-image-loaders: Fix compiler warning of comparison between signed
and unsigned values

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-27 11:04:51 -05:00
Chris Michael adc9cbce26 evas-software: Fix compile errors when using xcb
Summary: This fixes compile issues when building evas software engine
using xcb. When calling xcb_outbuf_free, the Render_Engine has no 'ob'
field, so remove that call. Also fix call to
render_engine_software_generic_init using the proper function
parameters.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-27 11:04:51 -05:00
Chris Michael 3b69593761 evas-software: Fix software engine to compile using xcb
Summary: Fix several compile issues with software engine when compiled
against xcb. This fixes an improper call to
evas_software_xcb_outbuf_flush with improper parameters, and adds a
missing EINA_UNUSED to that function.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-27 11:04:51 -05:00
Chris Michael e203b32171 evas-software: Fix call to evas_software_xcb_outbuf_setup function
Summary: Seems we were missing a comma here and this was causing a
compile break.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-27 11:04:51 -05:00
Chris Michael b53e125640 ecore-evas-drm: Fix improper shutdown sequence
Summary: As the launcher code now uses some fields from the
Ecore_Drm_Device, we need to free the device After the launcher has
been disconnected.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-26 08:37:09 -05:00
Cedric BAIL 154e5103c6 evas: fix signed/unsigned warning.
Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-01-26 11:22:33 +01:00
jiin.moon 0a758d10c9 evas: fix to load BMP file compressed with RLE.
Summary:
If the file size of RLE compressed image is bigger than original image,
BMP loader doesn't work as well.
@fix

Reviewers: Hermet, cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1892

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2015-01-26 11:21:37 +01:00
Mike Blumenkrantz 6a934f703c ee engines should not crash when re-setting the same title/name_class
@fix
2015-01-22 14:39:10 -05:00
Jean-Philippe Andre 02594a2519 Evas masking: Simplify ref/unref code
Those masks are always render surfaces so we should
treat them as such. Plus, there are proper functions
to ref/unref GL images.
2015-01-22 18:22:17 +09:00
Jean-Philippe Andre 04ba5a3b99 Evas masking: Aaaand fix another series of memleaks
Don't inc-ref more than we can dec-ref.
2015-01-22 17:56:09 +09:00
Jean-Philippe Andre 5cd200194e Evas masking: Fix potential GPU memory leak
This should free the mask surface properly, like we do
in software.
2015-01-22 17:25:59 +09:00
Jean-Philippe Andre 84c0ea0423 Evas masking: Fix potential crash
This adjusts the clip to match the mask image data.
To be fair, I'm not sure in which situation those two
don't match well. This patch fixes a rare crash.
2015-01-22 16:39:03 +09:00
Cedric BAIL cb1aae1fd2 evas: do not compute things twice.
Fix CID 1265599, 1265597, 1265598 and 1265596.
2015-01-21 16:13:50 +01:00
Jean-Philippe Andre 15f7cefa68 Evas masking: Fix major memory leak
The memory usage graph was going up and to the right!
I was told this is always a good thing!

... maybe not this time :)

Hopefully I didn't forget a case. An intense session of
genlist scrolling with masks all over the place and masks
of masks didn't show any glitch, crash or memory leak.
2015-01-21 17:51:15 +09:00
Mike Blumenkrantz 836650e364 ecore-evas-x should check itself before it wrecks itself when re-setting the same name/class 2015-01-15 01:30:27 -05:00
Jean-Philippe Andre 323db06279 Evas GL common: Remove unused filter_prog 2015-01-14 16:37:11 +09:00
Jean-Philippe Andre 80fe4b1673 Evas GL common: Add shader ID as debug info in the pipe
Simplifies code readability a bit and helps for debugging (with GDB).
2015-01-14 16:37:06 +09:00
Jean-Philippe Andre 1874ea9890 Evas masking: Fix evas map masking in GL
While this may look like a feature, it's definitely a fix.
2015-01-14 16:35:20 +09:00
Chris Michael bb8b00b956 ecore-evas-drm: Init outputs before inputs so that input devices can
have a pointer to outputs

Summary: In order to limit pointer motion, we need to assign an Output
to each Input device. In order to accomplish that, we need to
initialize Outputs first

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-13 10:35:52 -05:00
Jihoon Kim 2c8fbb81a8 ecore_imf/scim: Fix logically dead code in scim module
CID 1261449

@fix
2015-01-10 09:27:10 +09:00
kabeer khan 9bf76ddc8a ecore_evas/wayland_egl: Set alpha of ecore_evas object if parent alpha is set
Summary:
Resolved FIXME ecore_evas_wayland_egl_new_internal to set alpha if parent alpha is set

@fix

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

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1861
2015-01-09 13:24:03 -05:00
Chris Michael 9e485439d7 ecore-evas-wayland: Port fix of min/max size calculations to the
configure event handler

Summary: This patch ports the fix for windows without a min/max size
being set over to the configure event handler (which was also not
taking into account the fact that Some windows may Not have a min/max
property set on them.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-09 09:42:43 -05:00
Myoungwoon Kim 10582235c5 ecore_evas_x: Free XCounter values leak.
Summary:
Whenever creating a window via elm_win_add(), save netwm_sync_counter values to edata->netwm_sync_counter
by ecore_x_sync_counter_new().
However, never free the values when a window has been destroyed.
So this patch is for free the values in _ecore_evas_x_free().

@fix

Reviewers: cedric, raster, Hermet, devilhorns

Reviewed By: devilhorns

Subscribers: cedric, seoz

Differential Revision: https://phab.enlightenment.org/D1855
2015-01-08 08:35:55 -05:00
vivek 2da804f616 ecore_imf: Add null check condition in ecore_imf module
Summary: Fixed null pointer dereference issue in ecore_imf module

@fix

Signed-off-by: vivek <vivek.ellur@samsung.com>

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: raster, cedric

Differential Revision: https://phab.enlightenment.org/D1813
2015-01-08 08:34:21 -05:00
Chris Michael bf9c5873fb ecore-evas-wayland: Fix min/max size calculations
Summary: This fixes an issue for windows which do not set a min or max
size in the properties. This was discovered when running Enlightenment
in a Wayland-Only scenario, and trying to bring up the settings panel
which would cause an endless loop in calculating the proper window
size due to min/max not being set.

@fix

NB: Thanks to Mike for the help in tracing this ! :)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-07 14:50:00 -05:00
Chris Michael d136391108 ecore-evas-wayland: Fix formatting
Summary: no functional changes, just formatting

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-07 14:50:00 -05:00
Chris Michael 2cae004592 ecore-evas-drm: Fix formatting
Summary: No functional changes, just formatting cleanup

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-07 09:52:34 -05:00
kabeer khan 200a9f3421 ecore_evas_drm: Added support for initial rotation in ecore_evas_drm
Summary:
Resolved FIXME added support for initial rotation in ecore_evas_drm initialisation

@fix

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

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1837
2015-01-07 09:51:19 -05:00
Jean-Philippe Andre bb923d5586 Evas masking: Minor fixes in GL masking 2015-01-07 15:06:03 +09:00
Jean-Philippe Andre f876cf31f8 Evas masking: Fix invalid geometry after mask redraw
The proper geometry should be set when rendering the mask,
otherwise we can't create a new surface if it changed dimensions.
2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 44387b60a3 Evas masking: Add rectangle masking for GL 2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 61b847d47a Evas masking: Simplify and fix vertex logic in GL
There was some geometry problem, and this commit also
simplifies a lot of code by factorizing it a lot.
2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 2bd5cf6e6f Evas masking: Use new texm sampler instead of texa
texa should be used only for RGB+A whereas texm should
be used for masking. This should fix RGB+A masking, too.
2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 6552e8a6cc Evas masking: Add support for YUV, YUY2, NV12 masking in GL
RGB+A masking needs to be implemented, because there's a
clash (only one texture name "texa" is available).
2015-01-07 15:06:03 +09:00
Jean-Philippe Andre a2604956f9 Evas masking: Add support for BGRA/ARGB masking
Also, refactor font & image GL masking.
2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 1fac1dcf57 Evas masking: Font masking for GL 2015-01-07 15:06:03 +09:00
Jean-Philippe Andre 124ab102b7 Evas masking: Implement image masking for GL engines 2015-01-07 15:06:02 +09:00
Jaeun Choi 62f3170874 Evas masking: Implement support for map draw (SW) 2015-01-07 15:06:02 +09:00
Jaeun Choi 4eb3a58edd Evas masking: Implement support for polygon draw (SW) 2015-01-07 15:06:02 +09:00
Jaeun Choi 6747fadd9a Evas masking: Implement support for line draw (SW)
Signed-off-by: Jean-Philippe Andre <jp.andre@samsung.com>
2015-01-07 15:06:02 +09:00
Jean-Philippe Andre a9630a77b6 Evas masking: Add clip_image_[un]set functions to draw context
This allows passing a mask image to the render functions.

@feature
2015-01-07 15:06:02 +09:00
Jaeun Choi 9af60b1b04 Evas masking: Use alpha mask in SW engine draw functions
Work done by Jaeun Choi, rebased & squashed by jpeg.

This commit introduces changes to the low-level draw functions
of the SW engine considering the existence of an alpha mask image.

Features:
- Font masking (TEXT, TEXTBLOCK),
- Rectangle masking,
- Image masking (all image scaling functions should be handled).

The mask image itself is not yet set in the draw context (see
following commits).

@feature

Signed-off-by: Jean-Philippe Andre <jp.andre@samsung.com>
2015-01-07 15:06:02 +09:00
Dmytro Dadyka e7752ff7d7 [Evas: Evas_3D]Fixed bug with shadows and blending of vertex position
Reviewers: cedric, Hermet

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1850
2015-01-07 12:00:47 +09:00
Chris Michael 5eb11e1285 ecore-evas-drm: Perform shutdown in proper order
Summary: This fixes an incorrect order with shutdown of drm library.
Sprites are created (during init) before inputs, so they should be
shutdown After inputs are.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-06 11:10:44 -05:00
Chris Michael 7f82494459 ecore-evas: Fix compiler warnings about inproper returns
Summary: This fixes missing return values in functions that return
non-void

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2015-01-05 12:14:46 -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
vivek c5f6c3941c ecore_evas_wayland: Add null check conditions in ecore evas wayland module
Summary:
Added null check conditions to check ecore_evas pointer in various places
of ecore evas wayland common module

Signed-off-by: vivek <vivek.ellur@samsung.com>

Reviewers: devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1812
2015-01-05 09:09:03 -05:00
Daniel Juyung Seo 6e2c311f9d Revert "evas/gl_x11: set EGL_PLATFORM environment variable" as cedric wants to change it.
This reverts commit 6fe870de14.
2014-12-29 20:56:14 +09:00
MinJeong Kim 6fe870de14 evas/gl_x11: set EGL_PLATFORM environment variable
Summary:
Without EGL_PLATFORM environment variable, eglInitialize() can be
failed because egl tried to load DRM platform instead of X11 platform and it
tried to handle XDisplay pointer as a gbm_device pointer as well.
The failure seems to be occured especially if the egl was built
with DRM platform as native platform.

This revision can prevent the failure by indicating proper egl platform using
EGL_PLATFORM environment variable.

@fix

Reviewers: gwanglim, jaehwan, seoz

Reviewed By: seoz

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1828
2014-12-29 20:14:07 +09:00
Cedric BAIL 61b6986880 evas: first destroy the rectangle, then the pool. 2014-12-27 14:10:37 +01:00
Bogdan Devichev 243df1aaba evas: the eet loader use eet_mmap that take an Eina_File instead of eet_open. 2014-12-23 21:20:21 +01:00
Bogdan Devichev 61aab62be0 evas: entry points to modules is Eina_File. Model_Common_Loader is deleted. 2014-12-23 21:20:20 +01:00
Bogdan Devichev 17baa3fa6f evas: entry points to modules is new struct with Eina_file, not const char *file. 2014-12-23 21:20:20 +01:00
Bogdan Devichev e024f861e1 evas: ply_loader and obj_loader work with Eina_File. 2014-12-23 21:19:20 +01:00
Bogdan Devichev 4acbae6947 evas: test cases are changed according to changes of API in step 4. Specific logic in obj_saver is removed for standardization of API. 2014-12-23 21:16:19 +01:00
Bogdan Devichev 02c85b9fe8 evas: add lib/evas/common/evas_model_<action>.c. Functions are renamed similar to functions in image_save_load process. 2014-12-23 21:14:52 +01:00
Bogdan Devichev 9b7e22f5a5 evas: replace and rename savers/loaders. 2014-12-23 21:14:30 +01:00
Bogdan Devichev 8c09ad1b81 evas: dummies for model_saver_loader are created. 2014-12-23 21:14:15 +01:00
Bogdan Devichev 043055fc8e evas: preparation of places for model_saver_loader separated from image_saver_loader. 2014-12-23 21:13:43 +01:00
Jean-Philippe Andre af43bc67e4 Evas GL: Try harder to find a matching config for GLESv1
If MSAA was requested, it is very likely that no config was
found (depending on the driver), so we'll try again without
MSAA. Yeah, this might not look very smooth but it should be
better that failing at eglMakeCurrent.
2014-12-22 22:15:12 +09:00
kabeer khan 48920920a5 evas: fix memory leak in evas_swapper.
Summary: Signed-off-by: kabeer khan <kabeer.khan@samsung.com>

@fix

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1800

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-12-22 12:06:16 +01:00
Jean-Philippe Andre 8f6b34d4cc Evas GL: Fix list of GLES 1.1 extensions
We should use GLESv1 functions in a GLESv1 context to scan for
GLESv1 extensions. Makes sense yeah?

This should expose the proper list... especially enabling FBO
extension when it's supported by the driver.
2014-12-19 18:14:25 +09:00
Jean-Philippe Andre 3572b3bf3d Evas GL: Add a warning in gl_x11 about MSAA & RGBA for GLES1
We've discovered some bugs on some drivers related to
MSAA and RGBA blending. Dunno yet if the same problem can affect
GLES2 as well.
2014-12-19 18:14:25 +09:00
Jaehyun Cho c8a993d1f7 evas - generic loaders - fix possible string overflow on decoders
Summary:
fix possible string overflow on decoders.
         this commit is based on commit 3c5412f728
         that fixes CID 1039580.

Reviewers: raster

Reviewed By: raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1783
2014-12-17 17:49:07 +09:00
kabeer khan 256761bf2f evas/tgv: Added DSSIM metric in evas_image_save_tgv
Summary:
Resolved TODO to add DSSIM metric in DEBUG_STATS

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

Reviewers: cedric

Subscribers: devilhorns, cedric

Differential Revision: https://phab.enlightenment.org/D1773
2014-12-17 16:40:59 +09:00
MinJeong Kim 792af971f1 ecore: Added getting "WarningLevel" on upower module.
Summary:
From UPower 0.99.0, a property "OnLowBattery" was removed and
upower have recommended to use "WarningLevel" instead.
This revision provides "WarningLevel" using the property "DaemonVersion"
and it keeps dealing with "OnLowBattery" as well for old system.

Fixes T1909

Reviewers: gwanglim, barbieri, zmike, stefan_schmidt

Reviewed By: barbieri

Subscribers: zmike, stefan_schmidt, cedric

Differential Revision: https://phab.enlightenment.org/D1717
2014-12-12 16:41:40 +01:00
Chris Michael 251c300b8f evas-gl-common: Fix issue with Coverity reporting null dereferences
Summary: This fixes Coverity CID1257606 and CID1257607: Dereferencing
null return value. _evgl_tls_resource_get Can return NULL so we should
be checking that returned value before trying to use it

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-10 13:30:51 -05:00
Chris Michael 68ede67850 ecore-evas-drm: Fix up error handling
Summary: Due to the change of order in creating outputs & inputs, we
need an additional goto error for destroying inputs if output_create
fails

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-10 12:01:59 -05:00
Chris Michael 61d03472a4 ecore-evas-drm: Create inputs before we create outputs
Summary: Call function to create drm input devices Before we create
outputs. This is done so that when outputs Do get created, it will
update the input's known size of output for device coordinate
transformation

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-10 12:01:59 -05:00
Stefan Schmidt 4d2373e03d modules/tgv: Switch from obsolete LZ4_uncompress function to LZ4_decompress_fast
The function is declared as obsolete and in some newer headers it is no
longer defined. The new function is the same besides the name change.
2014-12-10 14:52:58 +01:00
Jean-Philippe Andre 4cf2d75715 Evas GL: Fix direct rendering with client-side rotation
There was a problem when checking whether the current surface
is compatible with direct rendering. In case of client-side
rotation (it's a flag set on the surface by the app), a surface
can be directly rendered even if the rotation is not 0.

But, before this patch, it was assumed that the surface was
current. Which doesn't make sense because make_current is
called by the pixel callback, from the application, and this
happens *after* we check for direct rendering.

As a consequence, it was not possible to mix directly rendered
surfaces with FBO-based ones, and use client-side rotation.

This patch should solve that issue.
2014-12-10 10:52:22 +09:00
Seunghun Lee b10ab1a86f ecore-drm: added drm launcher that is allow to determine whether to launch with logind or root privilege.
Summary:
- allow to launch drm backend without systemd-logind with root privilege.
- allow to open drm device node via logind, not directly open it, in case exist systemd-logind.
- fixes issue that couldn't switch session, because ecore-drm couldn't drop master to drm device with no permission. (allow to switch session appropriate.)

Reviewers: gwanglim, devilhorns

Subscribers: torori, cedric

Differential Revision: https://phab.enlightenment.org/D1704
2014-12-09 09:36:42 -05:00
kabeer khan 25db7de813 evas_xcb_outbuf: fix memory leak
Summary: This fixes a leak in the xcb engine where the Outbuf_Region
was not being freed.

@fix

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

Reviewers: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1750
2014-12-09 09:23:12 -05:00
Jean-Philippe Andre e4a11c008c Evas GL: Fix scissors with direct rendering
If an app calls glDisable(SCISSORS) and uses direct rendering,
then the DR scissors were dropped and so glClear would erase
the contents of the entire canvas, instead of being restricted
to the image object.
2014-12-09 18:38:08 +09:00
Jean-Philippe Andre 2a69980959 Evas GL: Fix current FBO after make_current(0, 0)
Example scenario:
- Create a direct rendered Evas GL 'sfc' 'ctx'
- Create a PBuffer dummy surface, make it current
- Do some stuff
- Make current (NULL, NULL) to go back to no target
- Make current (sfc, ctx)
--> glClear() will not render anything on screen

Reason:
The current FBO binding is still set to the implicit FBO
bound to the PBuffer surface (it could be any surface, really).
2014-12-09 18:38:08 +09:00
Mike Blumenkrantz 0c6844707f upower module now errors and kills itself off when unsupported new version detected
0.99.0 removed the OnLowBattery property and added the per-device WarningLevel property. this requires what will effectively be a full rewrite of the module to track all the power levels of all the attached batteries and set the ecore power level somehow based on a combination of their levels

since I have no desire to spend any more hours working on and debugging this module which is based on a known-unstable api, I'm making it disable itself if it detects a version >= 0.99.0. hopefully someone will decide to maintain both this and eldbus in the future so that we can more accurately track upstream when they make changes to these things

ref T1908

ref T1909
2014-12-08 15:22:19 -05:00
Gwanglim Lee 353a533ff5 evas/gl_drm: Fix warning
Using int instead of uint32_t.
2014-12-08 19:07:27 +09: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
Mun, Gwan-gyeong d1b8d52e0e evas/gl_drm: add native surface for wayland_egl_client.
Reviewers: zmike, devilhorns, cedric, gwanglim

Reviewed By: cedric, gwanglim

Subscribers: jpeg, torori, cedric

Differential Revision: https://phab.enlightenment.org/D1507
2014-12-04 17:59:30 +09:00
Carsten Haitzler 83512198b8 evas - gif loader - fix technically "wrong" sizeof (doesnt cause a bug)
go from sizeof(char **) to sizeof(char *) ... effectively. so no real bug.
2014-12-04 16:03:32 +09:00
Dmytro Dadyka 720a3726e9 Evas: Evas_3D - Add check of visibilty node.
If the node is not visible, it is not rendered, which improves performance.
@feature.

Reviewers: raster, Hermet, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1722

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-12-03 09:58:02 +01:00
perepelits.m b1f8f3fb17 evas: Evas_3D - fix typo.
Summary:
A little fix of copy-paste, there were problems while changing texture coordinates of indices.

@fix

Reviewers: raster, Hermet, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1725

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-12-03 09:58:02 +01:00
Jean-Philippe Andre 0514cbc1a3 Evas GL: Add preventive padding after Evas_GL_API
Since this struct is likely to grow in size over time, client apps
built against future versions of EFL might start indexing fields
that are not present in the current form.

Also, don't reset the struct memory as this would break
multithreaded GL applications.

While this is not exactly a fix, I'll backport this.

@fix
2014-12-03 16:57:49 +09:00
MinJeong Kim ad0f10950c evas-gl-drm: remove initalizing gbm on engine setup
Summary: Removed evas_drm_gbm_init() on the initial setup of evas gl_drm engine.

Reviewers: gwanglim

Reviewed By: gwanglim

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1728
2014-12-03 16:30:13 +09:00
Gwanglim Lee 9eefb3ea89 Evas GL: Add support for bind_wayland_display extension
This provides EGL_WL_bind_wayland_display EGL extension to bind
and unbind the wl_display of a wayland server to an EGLDisplay.

@feature
2014-12-02 22:45:36 +09:00
Chris Michael c1eb5de916 evas-gl: Fix evas-gl to compile for EGL
Summary: Evas compilation was broken for --with-opengl=es due to the
use of GL_R16 (which is not defined for EGL).

NB: This may Not be the Proper fix, but at least it compiles now.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-01 10:31:47 -05:00
Chris Michael 077261689d evas-gl: Fix improper #ifdef check
Summary: We should be using #ifdef here, not #if

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-12-01 10:29:53 -05:00
Dmytro Dadyka 6762af0beb evas: Evas_3D - add mesh blending mode.
Reviewers: Hermet, raster, cedric

Subscribers: Oleksander, cedric

@feature

Differential Revision: https://phab.enlightenment.org/D1548

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-12-01 08:09:29 +01:00
Dmytro Dadyka 4366057dc6 evas: Evas_3D - fix depth texture size.
Reviewers: raster, Hermet, cedric

Reviewed By: cedric

Subscribers: cedric

The texture used to store the depth map should be a single-channel texture.

@fix

Differential Revision: https://phab.enlightenment.org/D1713

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-12-01 05:57:05 +01:00
Carsten Haitzler 8fcfae57d1 evas - gl - fix warning for unused var in glx build 2014-11-29 12:07:33 +09:00
Hosang Kim cc89a541de ecore_evas_x: Fixed strange condition.
Summary:
To satisfy this condition, ee->visible will be EINA_FALSE. But when iconify is requested, ee->visible is usually EINA_TRUE.

@fix

Reviewers: raster, Hermet, seoz

Reviewed By: seoz

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1710
2014-11-29 01:10:39 +09:00
Jean-Philippe Andre 151eeacec8 Evas GL: Use strncat and strncpy for safety
Fixes Coverity reports:
- CID 1256183

Coverity was a bit stupid there. It knows the size of both
strings and complained about unsafe strcpy. It should have
complained about unsafe strcat instead.
2014-11-28 16:26:49 +09:00
Jean-Philippe Andre 07c68ac42b Evas: Fix shader gen script for Ubuntu
dash was the shell on that machine.
Also, GCC complained about a non const initializer.

Thanks SeoZ for the report.
2014-11-27 21:47:02 +09:00
Jean-Philippe Andre 02d123be77 Evas GL: Fix up some more desktop GL extensions
OpenGL 1.2 already supports some of the features that
GLESv2 has as extensions:
- GL_EXT_read_format_bgra
- GL_EXT_texture_format_BGRA8888
- GL_EXT_texture_type_2_10_10_10_REV

Also, we need to check the proper ARB name of some extensions when
running on desktop, instead of their OES/IMG/EXT equivalent:
- GL_ARB_texture_float
- GL_ARB_texture_half_float
- GL_ARB_texture_non_power_of_two
- GL_ARB_half_float_vertex
- GL_EXT_packed_depth_stencil
2014-11-27 21:07:24 +09:00
Jean-Philippe Andre 45374e2536 Evas GL: Also add read bgra for desktop GL 2014-11-27 20:50:47 +09:00
Jean-Philippe Andre 9be96f4b96 Evas GL: Advertise support for npot on desktop
The extension name is GL_ARB_texture_non_power_of_two
for desktop GL, but GL_OES_texture_npot for GLES.

We will consider the extensions compatible, I believe
the GLES version is a subset of the desktop one. Not sure
if that's 100% true.
2014-11-27 20:50:47 +09:00
Jean-Philippe Andre eaefb7c047 Evas GL: Always support BGRA8888 on desktop GL 2014-11-27 20:50:47 +09:00
Jean-Philippe Andre d8a4792612 Evas GL: Also return fake GLSL version string 2014-11-27 20:50:47 +09:00
Jean-Philippe Andre 9f38aadd38 Evas GL: Always return "OpenGL ES 2.0" as version
This time it's for desktop GL.

I decided to keep some vendor info, as it can help for debugging
purposes.
2014-11-27 20:50:47 +09:00
Jean-Philippe Andre 6d652589ad Evas GL: Print GLSL version with EVAS_GL_INFO 2014-11-27 20:50:40 +09:00
Jean-Philippe Andre af1b679e6c Evas GL: Return supported extensions list in glGetString() 2014-11-27 18:36:29 +09:00
Jean-Philippe Andre 129ba38cc7 Evas GL: Return current framebuffer based on ctx information
ctx->current_fbo should contain the visible FBO value, even
if indirect rendering is used.
2014-11-27 16:46:31 +09:00
Jean-Philippe Andre e2a6f5129c Evas GL: Remove useless field
- fbo_attached is not used.
- buffers_allocated is just a bool
2014-11-27 16:46:31 +09:00
Jean-Philippe ANDRE 85b0992657 Evas GL: Remove unnecessary check
We already checked that re->func.get_pixels wasn't NULL.
2014-11-27 00:46:47 +09:00
Jean-Philippe Andre 8771c78a90 Evas GL: Fix indirect rendering surfaces for GLES 1.1
Carefully select the requested EGL config and match it with
the available visual from X, including the following options:
- Stencil
- Depth
- MSAA

TODO: The same thing for GLX. And fix direct rendering as well.
2014-11-26 22:56:06 +09:00
ChunEon Park 215b52ecc1 evas/map : set antialias context for map rendering. 2014-11-26 12:22:55 +09:00
Jason Gerecke 26c943bac0 Expose device (e.g. pen) axis information to applications
Summary:
This patch set adds the necessary code to expose device axis state to applications. This was primarily written with graphics tablets in mind, which -- in addition to acting like a mouse -- also provide information about pen pressure, tilt, etc. Other devices could potentially benefit from this API as well: touchscreens, joysticks, knob controllers, "spaceballs", etc.

Whenever an update to the device state is recieved, an "Axis update" event is synthesized. This event contains the updated information, typically scaled and normalized to a particular logical range (e.g. zero to one for pressure, -pi to pi radians for angles, etc.). Information about the tool which generated the event is also stored so that applications can disambiguate events from multiple devices (or in the case of multitouch screens, individual fingers).

This API is only wired up for use with X11 at the moment. Support for other backends (e.g. Wayland) should be easy to add for those familiar them.

**Note**: The following is a list of changes from the "v2" patches originally sent to the mailinglist

//Define and implement new Ecore_Event_Axis_Update events//
 * Harcode axis labels instead of including xserver-properties.h
 * Use C89-style comments
 * Use doxygen comments
 * Update comment text to note axes with unbounded/undefined ranges/units
 * Create "Ecore_Axis" and "Ecore_Axis_Label" typedefs
 * Reference typedef'd instead of raw types
 * Adjust how we count through valuators to support tilt/az
 * Add support for tilt and azimuth
 * Tweak memory management in case number of valuators differ
 * Expand TWIST axis normalization to declared range
 * Only normalize TWIST axis if resolution == 1 (wacom bug)
 * Cache label atoms on first use to minimize round-trips

//Implement EVAS_CALLBACK_AXIS_UPDATE event and friends//
 * Update to doxygen comments
 * Update comment text to note axes with unbounded/undefined ranges/units
 * Typedef 'Evas_Axis_Label', 'Evas_Axis'
 * Move typedef for 'Evas_Event_Axis_Update'
 * Reference typedef'd instead of raw types

//Wire the Ecore and Evas implementations of axis update events together//
 * Expose ecore_event_evas_axis_update in Ecore_Input_Evas.h
 * Move ecore_event_evas_axis_update to more logical position

//DEBUG: Add axis update logging to evas-multi-touch.c//
 * Removed from patch set

//Make evas-multi-touch demo use new axis functionality//
 * Have pressure adjust rectangle brightness instead of size
 * Use more available axis data when rendering rectangle (azimuth, tilt, twist)

Test Plan: The evas-multi-touch demo was updated to support axis update events. A graphics tablet was then used to verify that the pressure, azimuth, tilt, and twist data was coming through correctly.

Reviewers: cedric, raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1514

Conflicts:
	src/lib/ecore_input/Ecore_Input.h

Carsten Haitzler -

** fixed forward enum typedefs (make things unhappy)
** fixed conflict above
** fixed wrong param type for _evas_canvas_event_feed_axis_update()
** fixed @sinces to be 1.13
** fixed formatting/indeting
** fixed order of operation reliance in if's with ()'s to be clear
** fixed functions to be static that should have been
2014-11-25 12:43:15 +09:00
Jean-Philippe Andre f6e73c7903 Evas GL common: Cosmetic change
Don't cast "ext" a hundred times when you can do it once.
2014-11-24 18:52:14 +09:00
Jean-Philippe Andre 2e83b076db Evas GL common: Scan extension string for ETC1 subimage
There is an official name for it:
GL_EXT_compressed_ETC1_RGB8_sub_texture

Thanks Mythri for pushing that specification.
2014-11-24 18:52:14 +09:00
Jean-Philippe Andre 09934be788 Evas GL common: Fix RGB+A textures draw
Also rename texm into texa for consistency.
Even though texa might be a mask image, it's still used only
for it's a (alpha) channel.
2014-11-24 18:52:14 +09:00
Carsten Haitzler 516691de9b ecore-evas - fix focus skip flag to be one way
this fixes focus skip being set if someone else sets skip
pager/taskbar. it's a one-way prop. if focus skip is set THEN skip
pager/taskbar is set. not the other way.
2014-11-23 22:01:34 +09:00
Jean-Philippe Andre f902de616e Evas: Check load_error before loading again (GL)
This is a new attempt at avoiding reload of an image
that failed to load during async preload.

See 42d2f8a12b (reverted).

I still can't figure out why setting load_error does not
work as expected (E pager becomes blank).
2014-11-19 19:47:33 +09:00
Jean-Philippe Andre 64238ca9f1 Revert "Evas: Set image load_error after load"
Oops, I didn't test this enough.
This causes some problems with E's pager for instance.

This reverts commit 42d2f8a12b.
2014-11-19 19:19:56 +09:00
Jean-Philippe Andre 42d2f8a12b Evas: Set image load_error after load
In case of async preload, this avoids loading an image twice
if it already failed loading.

Thanks Minkyoung Kim for spotting this.
2014-11-19 19:07:19 +09:00
Jean-Philippe Andre 9afe5ffb9d Evas: Cosmetic changes in evas_gl_image 2014-11-19 18:54:36 +09:00
Jean-Philippe Andre 54afef04c2 Evas GL: Change comment and DBG message 2014-11-19 16:22:37 +09:00
Jean-Philippe Andre 1a403849dc Evas GL: Wrap glGetString for VERSION
- glGetString(GL_VERSION) should not return "OpenGL ES 3.0" because
  GLESv3 is not supported yet.

- GL_EXTENSIONS should return only the list of supported extensions
  --> disabled for now as the whitelist of safe extensions is way
      too small.
2014-11-19 16:22:37 +09:00
Jean-Philippe Andre 1608d30390 Evas GL: Create TLS during make_current if there isn't any
Apps would crash if they call make current without creating
a surface in the same thread. I don't see a good reason why
we should have this a limitation.
2014-11-18 18:46:58 +09:00
Jean-Philippe Andre f663980111 Evas GL: Add some debug
It will be triggered when EVAS_GL_API_DEBUG is set.
Yeah, that's abusing the variable a bit, as it was intended for
GL calls only, but this is pretty harmless.

Also add string  "GL_DEPTH_STENCIL".
2014-11-18 18:46:58 +09:00
Jean-Philippe Andre f3a53acbf0 Evas GL: Fix bug in evgl_eng_pbuffer_surface_create (EGL)
Thanks Henry Song for the report.

@fix
2014-11-14 11:32:56 +09:00
Jean-Philippe Andre cd8d68cda4 Evas GL: Import a few more extensions and fix a name 2014-11-14 11:32:46 +09:00
Jean-Philippe Andre 0be124ca4d Evas GL: Add extension string for ETC2 2014-11-14 10:43:00 +09:00
Jean-Philippe Andre 198a508f9d Evas GL: Scan extensions for OpenGL-ES 1.1 2014-11-14 10:43:00 +09:00
Jean-Philippe Andre cd63cb0215 Evas GL: Enable some more GLES2 extension APIs
NOTE: The draw_buffers extension might need to be checked more and
wrapped, if it can have adverse effects on how Evas works (could
it replace the default render target?).

This adds support for the following extensions:
- disjoint_timer_query
- occlusion_query_boolean
- alpha_test
- draw_buffers
- read_buffer
- read_buffer_front
- framebuffer_blit
2014-11-14 10:43:00 +09:00
Jean-Philippe Andre d2aee4e5ca Evas GL: Add support for some required extensions
- debug
- debug_label
- debug_marker
2014-11-14 10:43:00 +09:00
Jean-Philippe Andre 56a64756eb Evas GL: Introduce concept of safe extensions
This will mark some extension functions as "safe", which means
we don't need to wrap them in order to expose them.

All the known extensions from Evas_GL_API have been marked as safe
for now.

In the future, we may encounter extensions that are not safe
out of the box, but can be wrapped. At that time, we will have
to mark them as safe but return the pointer to the wrapper instead.
Until then, only whitelisted extensions will be supported.

@feature
2014-11-14 10:43:00 +09:00
Jean-Philippe Andre cb534366f3 Evas GL: Pass calls to getProcAddress down to the engines
Later we need to add a whitelist of supported functions.
2014-11-14 10:43:00 +09:00
Jean-Philippe Andre aff423e3bd Evas GL: Introduce macro _EVASGL_EXT_FUNCTION_DRVFUNC_PROCADDR
It will be used to link to extension functions that need no
wrapping.
2014-11-14 10:43:00 +09:00
Jean-Philippe Andre 9741f298c0 Evas GL: Scan for GL-ES 1.1 extensions 2014-11-14 10:42:59 +09:00
Jean-Philippe Andre ce3146b262 Evas GL: Add original extension names to the EVAS_GL_EXTENSIONS string
The idea is that normal opengl applications might very well want to
check for an extension using the usual string and not have to do
something special just because they're using evas_gl and not egl.
2014-11-14 10:42:59 +09:00
Jean-Philippe Andre e18886a2a3 Evas GL: Fix list of shaders to distribute
Some shader files (shd) were not included in EXTRA_DIST. This didn't break
the build because the .x file was correctly generated.
I guess the missing files in previous releases also had no impact because
the .h files would be generated and shipped.

Also generate the enum automagically. New shaders need to be added
to Makefile_Evas.am.
2014-11-14 10:01:30 +09:00
Jean-Philippe Andre ae4f7f4e61 Evas shaders: Auto-generate the shaders from Makefile
Let's regenerate the shaders when a SHD file changes.
I've removed the Git commit id because only touching a file
would insert a code change.
2014-11-12 16:28:56 +09:00
Jean-Philippe Andre 8e52ade2e2 Evas shaders: Write new shader generator script
All shaders will be in a single .x (C) file.
There shall be no more useless .h files.

This also removes the need for awk (replaced by sed and bash stuff)
2014-11-12 16:28:52 +09:00
Jean Guyomarc'h 704c448141 warnings: remove 2 "equality comparison with extraneous parentheses"
Reviewers: stefan_schmidt, cedric

Reviewed By: cedric

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1644

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-11-05 00:15:52 +01:00
Carsten Haitzler adc1465049 clean up glx context code to remove legacy and avoid server segv
this cleans oyt a few bits o9f old glx context handling code that are
no longer used as well as avoids  causing server-side to crash on
tryng to set a "none" glxwindow as current. this is what cases the
nvidia server-side crashes.
2014-11-02 11:36:21 +09:00
ChunEon Park 6eb76b9eb9 evas/gl_generic: remove dead code. 2014-10-31 19:27:49 +09:00
ChunEon Park 3ffcdb67de evas/gl_common: remove dead code. 2014-10-31 19:19:15 +09:00
Chris Michael ae00e44269 ecore-evas-wayland: Fix wayland windows not showing up after 5954289c6c
Summary: Wayland windows should follow X11 windows fairly closely,
thus only set withdrawn property if they are override windows. If not,
internal dialogs do not show up in Enlightenment (wayland-only).

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 14:55:17 -04:00
Chris Michael 40247decd3 evas-gl-3d: Fix compiler warning about 'ld' may be used uninitialized
Summary: This commit fixes compiler warning:
modules/evas/engines/gl_common/evas_gl_3d.c:1322:48: warning: 'ld' may
be used uninitialized in this function [-Wmaybe-uninitialized]. We
declare 'ld' as NULL now, and check it is valid before using it.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 12:12:39 -04:00
Chris Michael cc4921a873 evas-gl-3d: Fix formatting
Summary: No functional changes

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 12:11:21 -04:00
Chris Michael 9599007a68 evas-gl-x11: Don't call gl_common_error_set if MakeContextCurrent fails
Summary: glsym_evas_gl_common_error_set used here leads to an implicit
declaration in compiler warnings. Remove the call to that function and
just print out an error message. This is a cleanup function anyway.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 12:07:48 -04:00
Chris Michael 300d20f47b Revert "evas-gl-x11: Fix copy/paste error from Coverity fix"
This reverts commit fb4ad043f6.

Revert this. This also leads to an implicit declaration of the
error_set function.
2014-10-29 12:07:03 -04:00
Chris Michael fb4ad043f6 evas-gl-x11: Fix copy/paste error from Coverity fix
Summary: In fixing a Coverity issue, I copy/pasted a call to
evas_gl_common_error_set without compiling :( Bad me !! This commit
fixes the issue (data was undefined). Since evas_gl_common_error_set can
take NULL as the data parameter, lets use that.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 12:02:26 -04:00
Stefan Schmidt 2f49ec1115 evas/gl_x11: Do not shadow another local variable. 2014-10-29 16:05:42 +01:00
Chris Michael b1bf718f1b evas-gl-x11: Check return value of glXMakeContextCurrent
Summary: Fix Coverity CID1249651 (unchecked return value)

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-29 10:28:50 -04:00
Carsten Haitzler 5954289c6c ecore_evas - ecore_evas's should start withdrawn then normal on show
this fixes initial state of an ee where you couldn't detect when the
window had been accepted by the wm (goes to normal state from
withdrawn).

@fix
2014-10-29 19:34:33 +09:00
Jean-Philippe Andre f3226f5e81 Evas GL: Fix potential crash
Welp, it looks like this crash actually happened once even though
it should not. glGetString() seems to have returned NULL somehow.
2014-10-29 15:12:53 +09:00
Carsten Haitzler e164d14208 evas - fix new issue with segv when switching to alpha win with gl
evas gl window was freed before new one was created getting shared ctx
to 0 refcount thus freeing everything there - BAD. fix. new issue in
git, not from release
2014-10-28 20:10:40 +09:00
Jean-Philippe Andre 0198fbfee4 Evas: Fix lock usage around async_current (gl preload)
Fixes Coverity:
 - CID 1039361
2014-10-28 11:19:24 +09:00
Jean-Philippe Andre 8e4dafcf28 Evas GL: Set umask before calling mkstemp
Fixes Coverity issues:
 - CID 1039609
 - CID 1039608
2014-10-28 10:54:51 +09:00
Carsten Haitzler 43acb28cdb evas - sw generic - fix osmesa to not use rgb buffers as evas doesnt know
this fixes incorrect sw osmesa rendering when no alpha cannel is used
on evas gl targets.
2014-10-27 19:52:03 +09:00
Jean-Philippe Andre 5a9d8d6f03 Evas GL: string_query returns a const char *
Why cast to/from void* in the first place?
2014-10-27 16:12:38 +09:00
Jean-Philippe Andre 3fe232cd95 Evas GL: Fix typo in an extension's name
This could potentially break applications relying on this
typo to check for the extension. The chances are very slim.
2014-10-27 16:12:38 +09:00
Carsten Haitzler 696346c467 evas gl rgba visual/rendering fix try ... again
so this is a re-try at the evas gl destination alpha fix. this is what
cedric tried, but done RIGHT. it required adding an ecore_x call to
create a window with correct visual/colormap. it requires doing
visuals totally correctly all the way from ecore_evas to the evas
gl_x11 core. nvidia drivers are very picky about visuals. i also had
to vid the egl/gles code too to do the same thing. nvidia gles/egl
drivers are also picky, mesa is not. this all requires a lot of code
changes. it's far from trivial

this isn't backported for a few reasons:

1. verify this fix doesn't break for anyone.

i tested:

nvidia glx + egl/gles
intel glx + egl/gles
radeon glx

it needs wider testing. nouveau, fglrx for starters and maybe
some other gles/egl drivers.

2. have some review time
3. time to settle before blasting to stable branches

@fix
2014-10-26 00:34:40 +09:00
Chris Michael b7e959c715 evas-gl-drm: Fix initialization from incompatible pointer type
Summary: The function prototype for eng_context_create has recently
changed in gl_common, however nobody thought it wise to update all
engines using it, so this commit fixes the function for the gl_drm
engine.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-24 08:37:51 -04:00
Chris Michael b41867cd77 evas-gl-drm: Cleanup formatting
NB: No functional changes

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-22 09:24:14 -04:00
Jean-Philippe Andre d4eb07b4bb Evas GL: Don't pass shared context for GLX with 1.1 API
Not sure if this is very relevant, since GLX does not support
GL-ES as such, anyways... We should be using the extension
GLX_EXT_create_context_es_profile to create proper contexts.

Note: GLX + OpenGL-ES 1.1 crashes at any function call on my
machine (binary bloc driver), while EGL + GLES1.1 is fine.
2014-10-22 10:44:06 +09:00
Cedric BAIL 8606eed0f5 evas: don't redefine macro in tgv saver. 2014-10-21 23:42:03 +02:00
Chris Michael 4078e0af9b evas-wayland-egl: Fix function prototype for eng_context_create
Summary: Apparently, somewhere down the line, the function prototype
for eng_context_create was changed in the EVGL_Interface, but nobody
decided to fix All engines. This commit fixes the function prototype
for evgl_eng_context_create

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-21 09:40:32 -04:00
Stefan Schmidt a7ef5bd7da Revert "evas: GL_X11 context need to always be with alpha or it will fail to change."
Need to also revert this in master. Cedric seems busy with other things and this
should not end up in 1.12  alpha1

This reverts commit 4ea75113ca.
2014-10-21 09:23:58 +02:00
Jean-Philippe Andre 904b1c5249 Evas: Fix some debug output formatting
Remove trailing newline.
2014-10-21 15:59:50 +09:00
Jean-Philippe Andre 25aaee99af Evas GL: Fix gl_x11/GLX engine
Forgot to set the TLS value after creating a new context.
No problem would show up in most cases, even in my test app.
But elementary_test GLView would just not work at all, spitting
incomplete FBO errors at me. Damn this one line was hard to find.

But introduced in df66916cd22ec6c4.
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre c17cfbd13e Evas GL: Add support for PBuffer surfaces with GLX
Not fully tested, but allows calling evas_gl_make_current, so
it works for dummy surfaces (eg. 1x1 for a render thread).
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 47ddb889ad Evas GL: Add support for OpenGL-ES 1.1 (part 3)
This introduces XPixmap usage for indirect rendering.
Of course this works only for the gl_x11 engine... and for
now only when using EGL... and only on some drivers...
damn limitations.
Direct rendering should work on more platforms (eg. some desktop
nvidia cards with the EGL drivers).
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 4315537820 Evas GL: Add support for OpenGL-ES 1.1 (part 2)
Add version param to context_create.
Add support for 1.1 contexts in the GL_X11 engine, and checks
for version in all other engines (return NULL).
Add API wrappers for all OpenGL-ES 1.1 APIs (normal and debug
modes).
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 38aa72d139 Evas GL: Fix sigsegv with recent Nvidia EGL driver
Welp, glGetString() crashes if called before eglInit... And this
piece of code is now useless because "safe native" mode is not
used anymore (safe_native is never read).

Remove all safe native-related code.
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre f30f55f9f4 Evas GL: Fix compilation for EGL/GLES
Configure with --with-opengl=es --enable-egl
Fixes runtime link dependencies
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre a0712e25e1 Evas GL: Add support for pbuffer surfaces
Supports only EGL for now :(

These pbuffer surfaces can be used to create dummy surfaces for
make_current and render threads.

@feature
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 29e7f54ea0 Evas GL: Add evas_gl_surface_query
When using EGL, this function should return the properties of
a surface. Limited to a subset of known attributes.

Right now, this function will only work fine with EGL.
GLX support or any other engine is not implemented.

@feature
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 81bf993c6c Evas GL: Add support for fence_sync and similar extensions
This should add support for the following EGL extensions:
- EGL_KHR_fence_sync
- EGL_KHR_reusable_sync (eglSignalSyncKHR)
- EGL_KHR_wait_sync (eglWaitSyncKHR)

@feature
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 6848cf40b6 Evas GL: Add evasglCreateImageForContext + import defs
evas gl CreateImage function was assuming the current context
should be used to create an image, while the equivalent EGL function
specifically requires the context to be specified.

This also imports some definitions for CreateImage.

And fixes typo in glEGLImageTargetRenderbufferStorageOES.

This adds new functions in Evas_GL_API struct. The version
number will be bumped to 2 in a later commit.

@feature
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 29e572cdfb Evas GL: Add support for client-side rotation
This is a new feature allowing direct rendering even when
the view is rotated. In that case, the application is responsible
for rotating its view and rendering it properly given the object
geometry.

This implements support for the flag
EVAS_GL_OPTIONS_CLIENT_SIDE_ROTATION

@feature
2014-10-20 12:16:08 +09:00
Jean-Philippe Andre 90b07fc42a Evas GL: Fix rotation angle get to check for DR first
direct_enabled() is not visible from the engines... but it is from
evas_gl_core which calls the engine.
2014-10-20 12:16:07 +09:00
Jean-Philippe Andre de7a8a3dab Evas GL: Add API evas_gl_rotation_get
This will be used to increase the chances of having direct
rendering (no fallback to FBO) even if the window is rotated.

The client is then responsible for handling the view rotation.

@feature
2014-10-20 12:16:07 +09:00
Jean-Philippe Andre d3ff6dfa7f Evas GL: Add support for current sfc/ctx get with osmesa 2014-10-20 12:16:07 +09:00
Jean-Philippe Andre d46a7fc172 Evas GL: Implement basic error get in software generic 2014-10-20 12:16:07 +09:00
Jean-Philippe Andre 28a76266c6 Evas GL: Fix runtime linking issues
There is some mess with gl common functions that need to be
called from the engine itself, eg. error set/get.
2014-10-20 12:16:07 +09:00
Jean-Philippe Andre 49f79f0a73 Evas GL: Skip glClear() with direct rendering & transparent color
When using direct rendering, glClear() should not do anything
if the ClearColor was (0,0,0,0). The application would indeed
expect a transparent output (so, see the widgets below the view),
but glClear would erase the pixels instead. So add a quick check
to skip glClear entirely in that specific case.
2014-10-20 12:16:07 +09:00
Jean-Philippe Andre cb5e88d20f Evas GL: Add APIs to get current surface/context
- evas_gl_current_surface_get
- evas_gl_current_context_get

@feature
2014-10-20 12:16:07 +09:00
Jean-Philippe Andre 68ca82e83f Evas GL: Add more thread safety to gl_x11 2014-10-20 12:16:07 +09:00
Jean-Philippe Andre 6e4d7151b8 Evas GL: Save EGL error codes in gl_x11 engine 2014-10-20 12:16:07 +09:00
Jean-Philippe Andre 8d6f873354 Evas GL: Add API evas_gl_error_get()
Similar in meaning to eglGetError()

@feature
2014-10-20 12:16:06 +09:00
Jean-Philippe Andre 08889de92b Evas GL: Add some thread safety
This is only the core evas gl support.
TODO: gl_x11 and other engines
2014-10-20 12:16:06 +09:00
ChunEon Park 5718763ca3 evas/gl: code refactoring.
improve code readibility.
2014-10-19 15:39:51 +09:00
Jihoon Kim 83d57bc6f8 ecore_imf/wayland: Use simple code to fix infinite loop bug related to ibus-hangul 2014-10-10 10:01:53 +09:00
Cedric BAIL 4ea75113ca evas: GL_X11 context need to always be with alpha or it will fail to change.
@fix
2014-10-09 12:20:53 +02:00
Chris Michael 15c6eab519 ecore-evas-drm: Fix formatting
NB: No functional changes, just cosmetic

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-08 11:35:17 -04:00
Chris Michael b31c66ab84 ecore-evas-drm: Set the ecore_drm_device reference in the engine data
Summary: Since we have a field inside the engine info structure to
store a reference to the Ecore_Drm_Device, then let's set it.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-08 11:33:04 -04:00
Chris Michael 6480b8b75d evas-gl-common: Fix compile for EGL due to missing GL_LINE_SMOOTH
Summary:
When compiling for EGL, GL_LINE_SMOOTH ends up not being defined so
compile breaks. This fix just checks if GL_LINE_SMOOTH is missing and
if so it defines it.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-08 09:04:21 -04:00
ChunEon Park 026e767b86 evas: support anti-alias for gl line drawing. 2014-10-08 15:47:58 +09:00
Jihoon Kim d56c2654f3 ecore_imf/wayland: fix infinite loop bug when ibus-hangul is used
When korean language was typed with ibus-hangul,
wayland immodule falled into the infinite loop.
2014-10-08 14:24:14 +09:00
Jihoon Kim 082a96b34b ecore_imf/ibus : fix bug not to show preedit string on Ubuntu 14.04
since ibus 1.5, enabled, disabled signal was deleted.
It affected bug not to show preedit string,
so code has been updated according to the change of the latest ibus 1.5.
It works well with the older ibus version
2014-10-04 13:13:46 +09:00
Jihoon Kim 7a1dc9b0df ecore_imf/scim: fix candidate word window position issue
In case application window locates in top left position,
The candidate word window provided by scim could overlap the position of entry widget when typing Chinese and Japanese.
2014-10-02 10:31:26 +09:00
Jihoon Kim 316cfd49ae ecore_imf/ibus: fix candidate word window position issue
In case application window locates in top left position,
The candidate word window provided by ibus could overlap the position of entry widget when typing Chinese and Japanese.
2014-10-02 10:09:12 +09:00
Jihoon Kim f9c43dfb8a ecore_imf/ibus: fix code formatting 2014-10-02 09:33:08 +09:00
Chris Michael f224fb24e2 ecore-evas-wayland: Add support for minimizing xdg_shell surfaces
xdg_shell protocol supports minimizing surfaces. When elm apps request
iconification, they will call ecore_evas_iconified_set which in turn
will make use of the newly added ecore_wl_window_iconified_set function.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-10-01 16:15:37 -04:00
Jihoon Kim 39136371c6 ecore_imf/ibus : provide to get surrounding text
It's important for languages such as Thai where only some sequences of characters are allowed.
2014-10-01 19:46:57 +09:00
Jihoon Kim 7b74e35659 ecore_imf/ibus: remove flag to support surrounding text
Not to provide surrounding text in ibus immodule yet.
It will fix bug that can't input vowel in Thai kedmanee layout provided by ibus-m17n
2014-10-01 17:08:36 +09:00
Carsten Haitzler bba02377e6 emotion gst backend - make note of some bugs! need fixing - cant now 2014-10-01 08:23:26 +09:00
Cedric BAIL dccbd559d4 evas: GL_X11 - add some more error message. 2014-09-30 18:31:51 +02:00
Cedric BAIL 08521b77ec ecore_evas: let's be consistent and always report an error. 2014-09-30 18:19:15 +02:00
Cedric BAIL af40a4b4e1 evas: GL_X11 - remove lef over unref. 2014-09-30 18:06:12 +02:00
Cedric BAIL ebaec0dfaf evas: GL_X11 - fix use of deleted memory by pointing to the right data. 2014-09-30 17:23:25 +02:00
Cedric BAIL 59501027c0 evas: fix gl_context to correctly match window description after a change.
This was affecting use of GL backend when having a transparent window. It
is actually a fix for a bug reported by Thanatermesis. It has been inspired
by D1229.

To reproduce the issue just do ELM_ACCEL=gl elementary_test -to "Icon transparent".
2014-09-30 16:25:46 +02:00
Jihoon Kim d059e1af95 ecore_imf/ibus: support delete-surrounding-text signal 2014-09-30 10:47:26 +09:00
Jihoon Kim dd94425ecc ecore_imf/wayland: fix memory leak occured after getting surrounding text 2014-09-30 09:32:39 +09:00
Mike Blumenkrantz 5375e154fe fix config.h inclusion across the tree 2014-09-23 15:56:46 -04:00
Chris Michael 39db828aad ecore-evas-drm: Fix calling ecore_drm_device_find twice in some cases
Summary: If no device name was passed in to ecore_drm_device_find
function, then if we fail to find the default drm device on the first
call, there is No point in calling the same function again to get the
same result.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-23 15:09:47 -04:00
Jérémy Zurcher 119134751f evas/engines: avoid redefinition of typedef Outbuf
'typedef struct _Outbuf Outbuf' is in software_generic/Evas_Engine_Software_Generic.h
that is always included
2014-09-23 11:16:47 +02:00
Jean Guyomarc'h ffb518fcdd evas: Gl_Cocoa - fix early segfault caused by unloaded symbols
Summary:
evas_gl_symbols() (introduced in commit 9a9d78d) was not dlsym()ed
which led to unloaded symbols, so NULL function pointers which were happily
dereferenced, leading to an early segfault, and therefore to a broken engine.

@fix

Reviewers: cedric, raoulh

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1440

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-09-22 14:59:27 +02:00
Jean-Philippe Andre 7242ea324a Evas: Directly load ETC2 and ETC1+Alpha formats from Eet
When loading those formats from an Eet file, software fallback was
always happening.
2014-09-19 10:29:58 +09:00
Jean-Philippe Andre a94ecda7c0 Evas DDS: Silently fail when the format is not DDS
Evas can try all image loaders sequentially and they shouldn't
complain that the file does not match their format.
2014-09-19 10:29:58 +09:00
Jean-Philippe Andre 0d9005aa0c Evas GLX: Simplify code
if (A) then B else B
2014-09-19 10:29:58 +09:00
Gwanglim Lee bcf887153e evas/gl_drm: Remove drm own_fd handling from gl_drm engine
Summary:
These are obsolete codes because evas engines no longer
has a use case for handling the drm file descriptor. And also it
is the same change as what Stefan Schmidt did to evas_drm.

Test Plan: N/A

Reviewers: devilhorns, stefan_schmidt, cedric, raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1452
2014-09-16 11:17:39 +02:00
Chris Michael 11237fd858 ecore-evas-drm: Implement ecore_evas_pointer_xy_get for drm engine
This implements ecore_evas_pointer_xy_get for the drm engine, However
this is simply using evas_pointer_output_xy_get for the moment because
I need to add ecore_drm functions for getting pointer position.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-15 11:44:10 -04:00
Chris Michael bbd6822c7c ecore-evas-drm: Fix formatting
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-15 11:23:03 -04:00
Chinmaya Panigrahi fdd501b773 Evas: fix resource leak.
Summary: Variable palpriv is going out of scope and leaks the storage it points to,
if we do not free it before exiting.

Test Plan: NA

Reviewers: seoz, raster, cedric

Subscribers: cedric, seoz

Differential Revision: https://phab.enlightenment.org/D1429

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-09-11 12:56:02 +02:00
Daniel Zaoui cabdbb2f3c Warning-- 2014-09-11 08:35:15 +03:00
Stefan Schmidt dc7910a7ef ecore_evas/drm: Clarify error message if given device is not found.
While it is bad that the given device is not found we fall back here
to the default one. Still good to mention it in the error message as
it can be confusing when we read that the device could not be found
be it still works.
2014-09-08 16:21:24 +02:00
Stefan Schmidt fd1b0053d7 evas-drm: Remove unused function prototype. 2014-09-08 16:21:23 +02:00
Stefan Schmidt 96b767ef77 evas/drm: Remove evas-drm handling of the drm fd
We now longer have a use case for opening the drm file descriptor in the evas
engine itself. This is now all handled in ecore_drm or ecore evas.
2014-09-08 15:14:42 +02:00
Stefan Schmidt 95b1b13c5e evas/drm: Remove trailing whitespace.
That one was looking at me each time I opened the file. Get away!
2014-09-05 16:26:59 +02:00
Stefan Schmidt 79660ae4ae evas/gl_drm: Follow change form evas_drm and remove tty_won and tty struct members
The evas_gl_drm engine followed the changes from evas_drm so we can safely
remove them here as well.
2014-09-05 16:15:22 +02:00
Stefan Schmidt bff3bee8a5 evas/drm: Remove now obsolete tty and own_tty struct members
We used these when expedite was using evas directly without ecore_evas.
That changed and we can now leave tty custody to ecore_evas and ecore_drm.
2014-09-05 15:55:08 +02:00
Chris Michael c3e2750408 ecore-evas-drm: Remove extra blank space in parameter
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-04 15:49:17 -04:00
Chris Michael d3a207bf9a evas-drm: Fix evas-drm picking incorrect resolution/mode for outputs
This fixes an issue where we had to hard-code the resolution in the
wl_drm module. Instead, we now properly get the current screen
resolution/mode from the drm library and use that.

NB: This is needed to fix wl_drm module in Enlightenment to setup the
proper resolution.

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-04 11:18:23 -04:00
Chris Michael 127acd0b26 evas-drm: Fix formatting
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-04 11:18:23 -04:00
Chris Michael f2bc4ff4b8 ecore-evas-drm: Remove dead comment
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-04 11:18:23 -04:00
Chris Michael e7707a859f ecore-evas-drm: Add function to return screen geometry
This adds the ecore_evas function pointer for
ecore_evas_screen_geometry_get. This will be used from the drm
compositor to return the current screen geometry.

@feature

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-09-04 11:18:23 -04:00
Gwanglim Lee 0d9f0d8ffb gl-drm: Make use of ecore_drm for handling tty
Summary:
Now, evas gl-drm engine is using ecore_drm instead of its own code to handle tty.
This patch has removed obsolete tty handling codes from engine. It is almost the same as what
Stefan Schmidt did to evas drm engine.

Test Plan: N/A

Reviewers: devilhorns, cedric, raster, stefan_schmidt

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1409
2014-09-04 13:20:17 +02:00
Gwanglim Lee a797d1a8ef gl-drm: Fix build warnings
Summary: Fix unused paramater and parentheses around assignment.

Test Plan: N/A

Reviewers: devilhorns, cedric, stefan_schmidt, raster

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1408
2014-09-04 09:58:23 +02:00
Cedric BAIL 6bb522cc6b evas: let's bet consistent and not break the build. 2014-09-04 08:54:08 +02:00
Jean Guyomarc'h c03876d611 ecore_cocoa: NSRunLoop integration
Summary: Get rid of the old NSApplicationLoad() which was aimed to be use with Carbon. Unless the NSRunLoop is strictly integrated to the ecore_main_loop() (where cocoa events would be checked when entering the ecore_main_loop) I think the poller is the only option left.

Reviewers: raster, naguirre, raoulh, stefan_schmidt, cedric

@feature

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1222

Signed-off-by: Cedric BAIL <cedric@osg.samsung.com>
2014-09-03 20:34:57 +02:00
Dmytro Dadyka 0d2f4dbc11 [Evas/evas-3d] Add shadow maps. Added two scene-API functions for enable and disable shadows on the scene. Added 6 light-API function for set and get the light projection.
Reviewers: raster, cedric, Hermet

Subscribers: raster, cedric

Differential Revision: https://phab.enlightenment.org/D1330
2014-09-03 21:19:16 +09:00
Carsten Haitzler 807a136305 emotion - gst 0.10 - fix build after volume change/fix 2014-09-03 16:57:01 +09:00
Carsten Haitzler 3c5412f728 evas - generic loaders - fix possible string overflow on decoders
fixes CID 1039580
2014-09-01 19:40:46 +09:00
Carsten Haitzler 6ed29b4425 emotion - audio volume - leave as-is on file open/init
this fixes gst and gst1 modules to leave volume be on start. generic
can't really query easily, so just set to 0.8 by default, and xine is
already just fine. do this because back-ends seems to have a habit of
setting master volume, not per-app volume.

@fix
2014-09-01 17:09:09 +09:00
Stefan Schmidt 2761b71c68 evas/engine/drm: Hold a reference to the Ecore_Drm_Device
We will need this in more places of the evas drm engine so keep a reference
in Evas_Engine_Info_Drm for later access.
2014-08-29 15:55:44 +02:00
Stefan Schmidt 5cc2a13763 evas/drm: Remove includes for TTY we no longer need here 2014-08-29 15:55:29 +02:00
Chris Michael 8eb9ae418b ecore-evas-drm: Fix misplaced #ifdef from gl_drm patch
This #ifdef does not belong here. The interface_new functions Is Still
Used for normal drm ecore_evas.

Bad Gwanglim, no cookie ;)

@fix

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-08-28 16:01:28 -04:00
Gwanglim Lee 00382bb6a6 gl-drm: Fix missing link to gbm for ecore_evas_drm and clean up build script
@fix

Summary:
This fixes following build script problems for ecore_evas_drm engine module.

1. Missing link to gbm for ecore_evas_drm if '--enable-gl-drm' option is given.
ecore_evas_drm engine is using gbm function if it builds with that config option.
To be more exact, ecore_evas_gl_drm_new_internal function needs gbm.
Thus we need to add gbm library linking '-lgbm' to ecore_evas_drm engine module
if '--enable-gl-drm' option is given. I've added this build script to
m4/ecore_check_module.m4 file.

2. Wrong gbm dependency check code in configure.ac
EFL_OPTIONAL_INTERNAL_DEPEND_PKG m4 macro function is designed for checking
dependency of efl internal libraries. Thus we should remove gbm pkg name when
configuring ecore_evas_drm engine module. It would be better to move dependency
check for gbm to m4/ecore_check_module.m4 file. And one more thing want_drm
value has to be changed to want_gl_drm in ECORE_EVAS_MODULE([gl-drm]...).

3. BUILD_ECORE_EVAS_OPENGL_DRM macro is always defined in configure.ac.
This kind of macro, BUILD_EFL_MODULE_NAME, has to be defined only if given module
is enabled. But this macro value was just defined with no test.
And it is even useless, we can use BUILD_ECORE_EVAS_GL_DRM macro which is defined
by ECORE_EVAS_MODULE([gl-drm], [${want_gl_drm}],...) function.
So I've removed that from configure.ac.

Test Plan:
1. Configure with --enable-gl-drm:
  $ ./autogen.sh --enable-drm --enable-gl-drm
2. Build:
  $ make && make install
3. Check module.so of ecore_evas_drm engine whether it has a library dependency with gbm:
  $ readelf -a $EFL_GIT/src/modules/ecore_evas/engines/drm/.libs/module.so | grep NEEDED

Reviewers: raster, stefan_schmidt, devilhorns

Reviewed By: devilhorns

Subscribers: cedric

Differential Revision: https://phab.enlightenment.org/D1379
2014-08-28 13:37:28 -04:00
Stefan Schmidt 5551567847 evas/drm: Remove rest of the tty handling which is now unused
With the move to ecore_drm for tty handling these all became unused.
Ecore_drm already takes care of setting up the SIGUSR1/2 handler and
the rest of the tty setup.

Now that this is gone evas_drm_init/shutdown have no functionality
anymore either.
2014-08-27 16:01:06 +02:00
Stefan Schmidt 9df3bb10bb evas/drm: Make sure the engine has the correct tty when called from expedite
When getting called from expedite we don't have ecore_evas in between which
normally sets things up for tty. Handle this special case here so the evas
drm engine keeps working for expedite.
2014-08-27 16:01:06 +02:00
Stefan Schmidt 9236a6d972 evas/drm: No need to check info.fd < 0 again as we just did that.
We are in a block here which already checked fro that. Remove this
and adjust indent.
2014-08-27 16:01:06 +02:00
Stefan Schmidt 92ba0c600f evas/drm: Remove obsolete tty open function
Ecore_drm handles this now for use. No need for duplicated functionality here.
2014-08-27 16:01:06 +02:00