History log of /frameworks/native/opengl/libs/EGL/egl_object.h
Revision Date Author Comments (<<< Hide modified files) (Show modified files >>>)
3aa75f95f23df87cf74ddefe0d3f90b1484ff95e 20-May-2016 Jesse Hall <jessehall@google.com> Ensure memory ordering around libagl and EGL refcount operations

The android_atomic_inc/android_atomic_dec functions don't impose
sufficient memory ordering. Using them for object refcounting could
allow an object to be destroyed prior to writes by a different thread
being visible.

Bug: 28820690
Change-Id: Ie018091035174255a22ebc52852528cdaec2d648
/frameworks/native/opengl/libs/EGL/egl_object.h
ae8cf0bb295d3f74e103dee9136a49f38447e9b8 02-May-2016 Pablo Ceballos <pceballos@google.com> EGL: Disconnect native window in eglDestroySurface

Bug 27455025

Change-Id: I7549a3acb724e749925a8249feb180088aec7f3c
/frameworks/native/opengl/libs/EGL/egl_object.h
1a5c4deed3e33efd7f286a570cf88fbd2d861010 25-Apr-2016 Pablo Ceballos <pceballos@google.com> Revert "EGL: Ensure surfaces are disconnected when destroyed"

This reverts commit 541de498ec7356c5e4af92500cf2fb8fc707fd50.

Bug 28295465

Change-Id: If81ed4a5a73a9612579b58291c37c7830ea1f7db
/frameworks/native/opengl/libs/EGL/egl_object.h
541de498ec7356c5e4af92500cf2fb8fc707fd50 10-Apr-2016 Pablo Ceballos <pceballos@google.com> EGL: Ensure surfaces are disconnected when destroyed

When eglDestroySurface is called, remove all references to the surface
in all contexts. This ensures that the surface is disconnected
immediately.

Bug 27455025

Change-Id: I0edaf039d320dc40122657db32abdc418665841a
/frameworks/native/opengl/libs/EGL/egl_object.h
eacd31f41ef1851bb420c65552b1aed6b74abe29 03-Feb-2016 Dan Albert <danalbert@google.com> Clean up warnings in EGL.

Bug: http://b/26936282
Change-Id: I059628332d638f080a5236eed62cf0afa1d4d6ba
/frameworks/native/opengl/libs/EGL/egl_object.h
edfe72ed6738d3798c5384b7aec8ab73af549d79 22-May-2015 Alistair Strachan <alistair.strachan@imgtec.com> Fix EGL shim extension injection for GL ES 3 drivers.

The Android EGL shim injects GL_EXT_debug_marker into the ES driver
EXTENSIONS string for the OpenGL ES 1.x and 2.0/3.0/3.1 drivers if
the extension is not already provided. This feature is used by
GLES_trace.

In Open GL ES 3.0 it became possible to query an indexed version of
the EXTENSIONS string via GetStringi(). NUM_EXTENSIONS Gets were
also added to the specification (taken from Open GL).

If the shim does not have to inject the extension, then there is no
problem, as glGetString() and glGetStringi() / NUM_EXTENSIONS will
be consistent. However, if the Android EGL shim injects the
extension, NUM_EXTENSIONS and GetStringi() will report one less
extension than is really available.

Consistency between these methods is tested by the dEQP framework
with the dEQP-GLES3.functional.state_query.string.extensions test.
If the driver does not provide GL_EXT_debug_marker, this test
fails.

This change wraps all of the affected entry points so that the
wrapped driver extensions are never visible directly to dEQP,
eliminating the inconsistency.
/frameworks/native/opengl/libs/EGL/egl_object.h
4774338bd0ad1ebe42c311fd0c72f13786b5c800 08-Feb-2013 Jesse Hall <jessehall@google.com> Add ES3 support to libGLESv2 and tracing tools

Since ES3 is backwards compatible with ES2, a new wrapper isn't
necessary, and the Khronos implementation guidelines recommend
supporting both versions with the same library.

Change-Id: If9bb02be60ce01cc5fe25d1f40c4e7f37244ebf6
/frameworks/native/opengl/libs/EGL/egl_object.h
258385978c517a47626161b1e644c48bcee28de1 06-Apr-2012 Jesse Hall <jessehall@google.com> Hibernate the EGL implementation when idle

If the EGL implementation supports the EGL_IMG_hibernate_process
extension, use it to hibernate (and hopefully release memory or other
resources) when the process isn't actively using EGL or OpenGL ES. The
idleness heuristic used in this change is:

(a) Wake up when entering any EGL API call, and remain awake for the
duration of the call.
(b) Do not hibernate when any window surface exists; this means the
application is very likely in the foreground.
(c) Do not hibernate while any context is made current to a thread.
The app may be using a client API without the EGL layer knowing,
so it is not safe to hibernate.
(d) Only check these conditions and attempt to hibernate after a
window surface is destroyed or a thread's context is detached. By
not attempting to hibernate at the end of every EGL call, we avoid
some transient wakeups/hibernate cycles when the app is mostly idle,
or is starting to become active but hasn't created its window
surface yet.

On a Galaxy Nexus, hibernating frees 1567 VM pages from the process.
Both hibernating and waking can take anywhere from 30ms to over 100ms
-- measurements have been very inconsistent.

Change-Id: Ib555f5d9d069aefccca06e8173a89625b5f32d7e
/frameworks/native/opengl/libs/EGL/egl_object.h
b29e5e8c2682ae145e8c56d9afb061f8da7f854c 05-Apr-2012 Jesse Hall <jessehall@google.com> Increment/decrement a counter around EGL calls

This is in preparation for a change that will hibernate the underlying
EGL when idle. Instead of a bare egl_display_t*, get_display() now
returns a egl_display_ptr, which acts like a smart pointer. The
"wakecount" counter managed by the smart pointer isn't used for
anything in this change. It will be used to make sure we don't
hibernate when any thread is in an EGL call, without having to hold a
mutex for the duration of the call.

Change-Id: Iee52f3549a51162efc3800e1195d3f76bba2f2ce
/frameworks/native/opengl/libs/EGL/egl_object.h
7c0441ac271f4e00a2d63eb3048c037ebffa90b9 15-Feb-2012 Mathias Agopian <mathias@google.com> Don't wrap EGLImageKHR and EGLSyncKHR anymore

this simplify our EGL wrapper implementation a lot.
This wrapping is no longer needed now that we can only
support a single underlaying EGL implementation.

Change-Id: I8213df7ac69daac447f1fe6e37044b78aac4e9a9
/frameworks/native/opengl/libs/EGL/egl_object.h
ada798b7ca7cabc255aa159964b64975e7fdb2df 14-Feb-2012 Mathias Agopian <mathias@google.com> remove multiplexing of multiple EGL implementation

from now on, the system can only have one EGL
implementation. this means the software and h/w renderer
cannot be used at the same time on a device. Of course, the
h/w renderer is always prefered; in its absence we
default to the software renderer.

Change-Id: Ib579f58055dd0ce4c4a99144131efa11c16ca3d3
/frameworks/native/opengl/libs/EGL/egl_object.h
48d438d05f14c2f4bd83ae89f520368cd49122df 29-Jan-2012 Mathias Agopian <mathias@google.com> add support for GL_EXT_debug_marker

This extension is always added to the GL_EXTENSIONS
extension string for the current GL context, regardless
of if it's supported by the h/w driver.

The extension itself will be handled by GLES_trace (eventually),
when GLES_trace is not enabled, it'll result to a no-op.

If the h/w implementation has this extension, we'll call that version
instead of our dummy version.

Change-Id: Ie5dd3387c4d45cd5ed5f03b73bda6045620a96bc
/frameworks/native/opengl/libs/EGL/egl_object.h
e6f43ddce78d6846af12550ff9193c5c6fe5844b 06-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGE(_IF) to (IF_)ALOGE(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/#/c/157220

Bug: 5449033
Change-Id: Ic9c19d30693bd56755f55906127cd6bd7126096c
/frameworks/native/opengl/libs/EGL/egl_object.h
32397c1cd3327905173b36baa6fd1c579bc328ff 06-Jan-2012 Steve Block <steveblock@google.com> Rename (IF_)LOGW(_IF) to (IF_)ALOGW(_IF) DO NOT MERGE

See https://android-git.corp.google.com/g/157065

Bug: 5449033
Change-Id: I00a4b904f9449e6f93b7fd35eac28640d7929e69
/frameworks/native/opengl/libs/EGL/egl_object.h
f0480de37492597a5c5cf1e6f8346f1467e3a552 14-Nov-2011 Mathias Agopian <mathias@google.com> fix crash when validating an invalid EGL objects

the code that validated EGL objects dereferenced the object
to access its EGLDisplay -- needed for validation (!).
This was wrong for two reasons, first we dereferenced the object
before validating it (potentially leading to a crash), secondly
we didn't validate that the object existed in the right EGLDisplay.

We now use the EGLDisplay passed by the user API.

Change-Id: I66f9e851d4f8507892a6b1fee3065f124c4e7138
/frameworks/native/opengl/libs/EGL/egl_object.h
06649fece4d97a89c6b197a570b6012e9ad9d228 16-Sep-2011 Mathias Agopian <mathias@google.com> cleanup: fix typos in logs

Change-Id: Ib5744564a873ea2b84100174673dc4d3ae109fcf
/frameworks/native/opengl/libs/EGL/egl_object.h
9f24fd020e387d57cb05d58f26985baa44571b85 24-Aug-2011 Jamie Gennis <jgennis@google.com> EGL: move disconnect to surface dtor

This change moves the call to native_window_api_disconnect from
eglDestroySurface to the egl_surface_t destructor. The egl_surface_t
can outlive the external EGLSurface if eglDestroySurface is called while
the surface is made current on a thread.

Change-Id: I0df6117a5633c2a19935fe356579abdd76fc471f
/frameworks/native/opengl/libs/EGL/egl_object.h
5b287a6ea8dfac7ab3e03ae1e98f9e2214cbae09 17-May-2011 Mathias Agopian <mathias@google.com> eglTerminate() now actually frees up all active egl objects

as specified by the EGL specification, terminated objects's
handles become invalid, the objects themselves are destroyed
when they're not current to some thread.

Change-Id: Id3a4a5736a5bbc3926a9ae8385d43772edb88eeb
/frameworks/native/opengl/libs/EGL/egl_object.h
518ec112f468eb67bf681b3eec896d7bfb4ff98d 14-May-2011 Mathias Agopian <mathias@google.com> refactor EGL source code

no changes is functionality. split various objects into their own files.
make egl_display objec's lock internal.
/frameworks/native/opengl/libs/EGL/egl_object.h