Commit Graph

462 Commits

Author SHA1 Message Date
Chris Michael 3692f0905c evas-drm: Check buffer validity in swap function
@bugfix: Check (and set) buffer validity before calling
framebuffer_send. This fixes an issue where buffer was not valid,
causing next_update_get to do full Copies.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-03-05 14:12:58 +00:00
Chris Michael b117d48159 evas-drm: Don't call framebuffer set from within send function
@bugfix: We cannot call framebuffer_set from within the send function
because if we are not vsync'd then framebuffer_set would never be
called and thus the buffer would not be marked as valid, causing full
Copies to happen.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-03-05 14:12:58 +00:00
Chris Michael 1904466ebc evas-drm: Fix evas drawing delay for cedric
@bugfix: Draw to the front buffer first, instead of the back buffer.

Frenchie says this improves the "initial rendering delay" of expedite
tests. Originally, we were drawing to the back buffer first, then
flipping it onto the crtc when drawing was done. This presented a
"perceived" rendering delay when running expedite tests as it would
wait for the back buffer to be drawn before presenting it. Personally,
I think it is not good to draw directly to the front buffer first as
it may get presented "incomplete" ... but cedric says it draws fine so
we'll leave it starting on the front buffer (for now).

Signed-off-by: Chris Michael <devilhorns@comcast.net>
2014-03-03 16:07:18 +00:00
Chris Michael 886c8d55b7 evas-drm: Ddd support for setting vsync with env variable.
@feature: Add support for EVAS_DRM_VSYNC environment variable to
@feature: Add support for marking a Framebuffer as dirty.
@bugfix: Fix color mask values for evas conversion functions.
@bugfix: Start with using the Backbuffer for drawing.
@bugfix: Fix previous Slowness with evas_cache image data.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:13:17 +00:00
Chris Michael 7ca6837084 evas-drm: Add vsync/non-vsync support to evas_drm code
@feature: Add ability to render software buffers using vsync or not
@bugfix: Fix drmModeAddFB to use proper depth & bpp when adding FB
@bugfix: Fix mmap to use NULL (not 0) so that kernel assigns memory
address.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:13:17 +00:00
Chris Michael 09b69d567e evas-drm: cleanup evas_engine code for drm sw engine
@bugfix: clear the tilebuffer when we get the next redraw update.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:13:17 +00:00
Chris Michael 54680b1f97 evas-drm: cleanup outbuf structure and functions
@bugfix: this cleans up the Outbuf structure by removing unused
fields, Fixing some function declarations, and defaulting the number
of buffers to 2 (double-buffering)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:13:17 +00:00
Chris Michael aafd8e5277 evas-drm: Add flag for setting vsync to engine structure
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:13:17 +00:00
Chris Michael c52d47ba36 evas-drm: Break out plane creation code into it's own function for cleaner code
Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:12:51 +00:00
Chris Michael 62a6b32ed3 evas-drm: Start on hardware Plane support
@feature: Start on hardware Plane support
 - Add Plane structure
 - Store list of Planes in the Output buffer

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:12:31 +00:00
Chris Michael fcd4929702 evas-drm: Add field to engine info for storing the buffer manager
- Typically this will come from ecore_evas and be used by evas to
allocate hardware accelerated buffers (gbm, tbm, etc)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:11:58 +00:00
Chris Michael 8a18515c7c evas-drm: Fix opening of drm card
@feature: Add code to check if async page flipping is supported by the driver.
@bugfix: Add code to get the proper drm driver name when we init the card.
@bugfix: Use drmOpen when opening the card so that any sub-driver gets initialized.
@bugfix: Add some debug/testing code to enumerate planes.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:10:55 +00:00
Chris Michael 258ce60930 evas-drm: Call framebuffer_set earlier in the process so that the screen gets
updated sooner.

@bugfix: set framebuffer on crtc earlier in process
@bugfix: Set the rendered image's alpha flag to be equal to the output buffer's

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:10:21 +00:00
Chris Michael ccbdd2137f evas-drm: Triple buffer by default.
@feature: Triple buffer by default on drm engine

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:10:00 +00:00
Chris Michael d21ab6f597 evas-drm: Start on hardware-accel support for drm
@feature: Start on hardware acceleration support by adding EGL
structure to engine info

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:09:37 +00:00
Chris Michael b42af265be evas-drm: Add Evas Drm Engine (software only currently)
@feature: Add working Evas_Drm Engine (software only currently)

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-28 13:08:19 +00:00
Chris Michael 44e023c888 bugfix: Fix Wayland Shm engine destination calculation typo
When rotation is 0, we need to advance the destination pointer in the
X direction by a Multiple of Bits-Per-Pixel...not an addition.

Signed-off-by: Chris Michael <cp.michael@samsung.com>
2014-02-26 11:36:27 +00:00
Sung W. Park 2b4a7b438d evas gl: added partial rendering support for qcom extension
When running in direct rendering mode, properly support partial
rendering if the extension is properly supported.

Also, fixed the SwapBufferwWithDamage rectangle coordinate bug.
It wasn't properly y-inverted before.
2014-02-15 02:33:47 +09:00
Carsten Haitzler 93da35c5ab evas - gl - core - checke for wrong context in error check
this fixes CID 1135266
2014-02-13 19:38:13 +09:00
Carsten Haitzler 2e95690201 evas - gl x11 - fix glx texture from pixmap target rectangle mode check
even though we don't support rectangle bits in texture targets for
texture-from-pixmap the code checked and complained - problem is it
checked the wrong thing. fixes CID 1135267
2014-02-13 19:35:17 +09:00
Carsten Haitzler 153bbd8003 evas - gl core - don't access null ptr on init
this fixes CID 1135270
2014-02-13 19:19:59 +09:00
Wonsik Jung 48b95c4538 evas: software_x11 - use evas_xlib_swapper_depth_get to get buffer stride.
Summary: when image cache is created, buffer's size should use stride value.

Test Plan: Create small size window, then try to resizing that.

Reviewers: tasn, seoz, raster, cedric

Reviewed By: cedric

CC: tasn, seoz, raster, cedric

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

Signed-off-by: Cedric BAIL <cedric.bail@samsung.com>
2014-02-10 14:54:43 +09:00
Wonsik Jung 6ea0566e6c evas: add eglMakeCurrent in evas map create/free.
Summary: Ensure Evas's eglContext when several eglContexts are used.

Test Plan:
1. Native GLES application works with evas_object_image_native_surface_set
2. One Evas object works with evas map.

Reviewers: seoz, tasn, cedric

Reviewed By: cedric

CC: cedric, raster

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

Signed-off-by: Cedric BAIL <cedric.bail@samsung.com>
2014-02-10 10:40:56 +09:00
Wonsik Jung 0e04219758 Add quadruple swap mode for partial rendering
Summary: This patch is for QUADRUPLE window buffers.

Test Plan:
When enlightenment uses quadruple buffers or window system can support quadruple buffers,
application can use quadruple buffers with partial rendering

Reviewers: tasn, seoz, raster

Reviewed By: raster

CC: cedric

Differential Revision: https://phab.enlightenment.org/D527
2014-02-08 23:04:04 +09:00
Jean-Philippe Andre 0135b45c12 Evas filters: OpenGL support part 1.
Quick and dirty solution to support the OpenGL engine:
[1] Allocate CPU buffers
[2] Render text and process all effects to these buffers
[3] Push final image as an OpenGL texture.

This patch implements [1].
2014-02-07 17:33:17 +09:00
Wonsik Jung 3420eda31a evas: gl backend - ensure eng_window_use in image_content_hint_set
Summary: Ensure eng_window_use in image_content_hint_set

Test Plan:
1. make native OpenGLES application.
2. set evas object image  with evas_object_image_native_surface_set.
3. GLES Application try to call eglMakeCurrent with own eglContext, then resize evas object resize

Reviewers: Hermet, raster, cedric

Reviewed By: cedric

CC: cedric, seoz

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

Signed-off-by: Cedric BAIL <cedric.bail@samsung.com>
2014-02-07 12:18:16 +09:00
Carsten Haitzler 93fd2263fc evas gl - fix egl/gles build after alpha4 change for fonts 2014-01-13 07:02:24 +09:00
Carsten Haitzler 86a97efeea evas - fonts - move to using 4bit and rel 4 bit compressed font glyphs
this changes the internal encoding of font glyphs in evas to use 4bit
uncompressed if small, or 4bit rle (run length encoded) if larger.
this caves at least 50% of memory on fonts - and more if bigger. with
large fonts (40-80pixel size) we can save in the region of 80% of
memory used for glyphs. this also happesn to allow speedups in
rendering too.
2014-01-13 05:15:32 +09:00
Carsten Haitzler f21b0ee6c3 evas gl - prefer alpha4 format for font textures if possible (save memory)
if alpha4 is possible (desktopgl) then use it for fonts as this should
cut memory in half for them and possibly speed things up due to less
memory bandwidth needed
2014-01-13 05:15:32 +09:00
Carsten Haitzler ee9f80f246 comment out unreachable code
fixes CID 1132633
2014-01-10 19:04:32 +09:00
Carsten Haitzler 3de45a2c4b evas gl - comment out unreachable code
fixes CID 1132634
2014-01-10 19:00:54 +09:00
Carsten Haitzler e8c13118eb fix mingw build for setuid fix/checks 2014-01-08 22:06:41 +09:00
Carsten Haitzler b95ef3801f setuid safeness - ensure if an app that is setuid doesn't do bad things
this makes efl ignore certain env vars for thnigs and entirely removes
user modules (that no one ever used) etc. etc. to ensure that *IF* an
app is setuid, there isn't a priv escalation path that is easy.
2014-01-08 19:46:23 +09:00
Carsten Haitzler e9783c3caf evas - gl-x11 engine - put in guessed blacklist of yinvert extn for intel mesa 2014-01-07 16:28:46 +09:00
Carsten Haitzler 2373e1f636 evas - gl-x11 remove +x bit on src file! 2013-12-30 18:27:06 +09:00
Carsten Haitzler acf7dfa579 evas - gl engine - glerr should be off by default for performance
stable release - cherry-pick me!
2013-12-27 17:32:15 +09:00
Carsten Haitzler 153a744e67 evas gl engine - ensure on texture delete we never leave a cur tex id dangling 2013-12-26 21:04:25 +09:00
Vostokov Sergey 36a52ca062 evas - gl-x11 engine - don't re-init engine window on rotate
this puts rotationc hanges in the same class as resizes for evas gl
x11 engine info updates and doesnt re-create the engine window data on
rotate.
2013-12-26 19:19:15 +09:00
Daniel Juyung Seo 76d8532b54 efl: Unified eina critical manro to CRI.
Being annoyed by different types of eina critical macros - CRI, CRIT,
 CRITICAL -, I concluded to unify them to one. Discussed on IRC and
 finally, CRI was chosen to meet the consistency with other macros -
 ERR, WRN, INF, DBG - in terms of the number of characters.
If there is any missing bits, please let me know.
2013-12-26 12:27:13 +09:00
Dennis Schridde ff4cbfbc25 evas: fix a segfault in _draw_thread_font_draw, caused by the missing initialisation of a struct field
CC: cedric

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

Signed-off-by: Cedric BAIL <cedric.bail@samsung.com>
2013-12-26 10:32:48 +09:00
Carsten Haitzler 5dfe3789f2 evas - fb engine - fix mem leak if ioctl fails on fb mode
this fixes CID 1137852
2013-12-15 11:25:56 +09:00
Carsten Haitzler d3caca21e5 evas - software-x11 - fill in unused struct members to avoid uninitialized
this shoudl fix CID 1039548 (missed other memmbers before) and if
valgrind ever sees this now it won't complain either.
2013-12-15 11:12:47 +09:00
Carsten Haitzler 611714649b evas - silence coverity in code
fixes CID 1039549 and CID 1039548 - though it isn't a bug, but means
it should not come back in coverity.
2013-12-13 21:26:05 +09:00
Carsten Haitzler 6a75806e54 evas - evas gl - fix realloc failure case to handle it properly
patched shader string realloc failure not handled right - could leak
patched string and p.
2013-12-11 22:44:42 +09:00
Carsten Haitzler f3d1db0fba evas - evas_gl - fix shader patch to not free static strings
parsing problem with opengl_strtok() which would free the previous
token "p", but in some cases it would be a const string. this should
fix CID 1039653
2013-12-11 22:40:15 +09:00
Carsten Haitzler 97a491dd90 evas - gl - ifdef out unused var with non-gles build 2013-12-11 18:26:45 +09:00
Carsten Haitzler 24c6424670 evas - gl - use snprintf for safety (never likely anyway, so code was fine) 2013-12-11 18:25:29 +09:00
Jean-Philippe Andre ce166ec223 Evas: Fix crash in GL engine(s) during preload cancel
In my config, running terminology with the GL engine and under
cserve2, some image could not be loaded. The tex argument
in evas_gl_preload_target_[un]register was NULL, leading to
an immediate crash.
2013-12-09 17:28:02 +09:00
Rafael Antognolli 5966a730cd evas/wayland_shm: Don't use a global var to store the sent buffer.
When an Ecore_Evas is hidden, it will destroy the buffer swapper. When
it's shown again, it will try to attach a new buffer, that can be same
buffer. If that global var is still pointing to the old buffer, it can
match to it again and avoid sending a new buffer. So, just put this sent
buffer var in the buffer swapper, and it will get set to NULL when the
swapper is destroyed and created again.

This should fix an intermitent problem of ecore_evas_show() not always
working after an ecore_evas_hide() on the wayland_shm engine.
2013-12-02 13:24:56 -02:00
Stanislav Vorobiov 9e3b778acb evas - fix gl egl textrue from pixmap support y invert query extension
Instead of hardcoding yinvert=1 we should query for
EGL_NOK_texture_from_pixmap extension and if it's present
use EGL_Y_INVERTED_NOK value
2013-11-29 19:09:17 +09:00