Both EGL14 and EGLExt have the same initialization codes for
EGL14.EGL_NO_SURFACE, EGL14.EGL_NO_CONTEXT and EGL14.EGL_NO_DISPLAY.
Since EGLExt is initialized later, they are overwritten by EGLExt's
initialization codes.
Therefore, EGL_NO_SURFACE returned by methods in EGL14 is not
actually EGL14.EGL_NO_SURFACE object and it makes several problems in
handling error cases.
For instance, "Let's fish" game application cannot be run on L.
To solve the problem, this patch makes EGL14.EGL_NO_SURFACE,
EGL14.EGL_NO_CONTEXT and EGL14.EGL_NO_DISPLAY initialized just once.
Change-Id: Icce878164ff0b715ad2b5a2cd038a9616c7cf1e9
The code currently being generated by glgen is not the cleanest, but
we would like to get core/jni onto -Werror. Thus add pragmas turning
off warnings locally to the C headers.
Also fix signed-comparison in two functions.
Longer term TODO: Emit clean code.
Change-Id: Iee8582f8c0c1de076d64851d3b6ca467afd5bc43
Enable ES 3.1 generation in glgen.py, and regenerate everything to add
support for that as well as these new extensions in the registry:
- EXT_copy_image
- EXT_draw_buffers_indexed
- EXT_geometry_shader
- EXT_gpu_shader5
- EXT_primitive_bounding_box
- EXT_shader_implicit_conversions
- EXT_shader_io_blocks
- EXT_tessellation_shader
- EXT_texture_border_clamp
- EXT_texture_buffer
- EXT_texture_cube_map_array
- EXT_texture_view
Bug: 15028495
Change-Id: I35acb473cba2433b9aeb95d1b8bfbdcfadf22532
This extension hasn't been published yet, so it isn't in the public
registry. That will change before the next platform release to AOSP.
Bug: 15028495
Change-Id: Iadafe0f776b5b9be4f81c4279a89c57ae02293e4
There are many non-functional whitespace and parameter name changes
included here. These were introduced upstream when converting from the
old .spec registry to the new XML registry.
There are also some new extensions added. Unfortunately there isn't a
version of the XML that matches the headers the previous versions of
the *.in files were generated from, so I can't separate out the
non-functional changes from the new extensions (other than temporarily
hacking them out of the XML). See below.
Finally, I had to hack the official glext.h. Khronos hasn't updated
the official GLES1 headers since switching to the XML registry, and
there is one critical difference: a "const void**" parameter in the
official header is "const void* const*" in the registry. I changed the
header to avoid build errors with code generated from the registry.
Dependencies on the *.in files required manually updating some
GLES_trace/ files as well:
- gltrace_api.{h,cpp} must be manually re-generated using
tools/genapi.py.
- New GL prototypes must be manually added to gltrace.proto.
- gltrace.pb.{h,cpp} must be regenerated using aprotoc (see dev.make)
New GLES extensions in libs/GLES_CM/glext_api.in:
- GL_OES_byte_coordinates
- GL_EXT_map_buffer_range
- GL_APPLE_copy_texture_levels
- GL_APPLE_sync
New GLES2 extensions in libs/GLES2/gl2ext_api.in:
- GL_KHR_blend_equation_advanced
- GL_KHR_debug
- GL_OES_sample_shading
- GL_OES_texture_storage_multisample_2d_array
- GL_EXT_disjoint_timer_query
- GL_EXT_draw_buffers
- GL_EXT_draw_instanced
- GL_EXT_instanced_arrays
- GL_EXT_map_buffer_range
- GL_EXT_map_buffer_range
- GL_EXT_multiview_draw_buffers
- GL_EXT_separate_shader_objects
- GL_ANGLE_instanced_arrays
- GL_ANGLE_translated_shader_source
- GL_APPLE_copy_texture_levels
- GL_APPLE_sync
- GL_INTEL_performance_query
- GL_NV_blend_equation_advanced
- GL_NV_copy_buffer
- GL_NV_draw_instanced
- GL_NV_framebuffer_blit
- GL_NV_framebuffer_multisample
- GL_NV_instanced_arrays
- GL_NV_non_square_matrices
Bug: 15028495
Change-Id: Ib3fa700a146adf7f1487a93e459b1e6df0dcdc42
Someone fixed these in the generated code, so re-generating even with
no other changes caused diffs. Better to just fix it at the source.
Bug: 15028495
Change-Id: I248f9796d4e3d904c4c0dc15be5f8de231df7285
EGLObjectHandle.<init>(int) and int EGLObjectHandle.getHandle()
have now been deprecated and replaced with variants that take
and return java longs.
bug: 13181704
Change-Id: Ie88e591c288d6de5655364b4cd673f61cce68d7d
This will allow eglGetDisplay(int) to work on both 32-bit
and 64-bit systems when EGL_DEFAULT_DISPLAY is passed as
a parameter.
Change-Id: I0d7e9ca5410b0dd893eacc02aac40956908e4f25
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
EGL classes in frameworks/base have to be updated to support
64-bit platforms. Key changes in the EGL classes include
[x] EGLObjectHandle class - EGLObjectHandle class has two public
methods (constructor and getHandle) that assume handles are
32-bit. They have not been changed. Instead, two new hidden
methods (EGLObjectHandle(long) and getNativeHandle) have been
added.
[x] EG14 class - Two public methods eglGetDisplay and
eglCreatePbufferFromClientBuffer assume that handles are 32-bit.
They have been changed to throw unsupported operation exception
on non 32-bit machines. Two new methods eglGetDisplay(long)
and eglCreatePbufferFromClientBuffer(...long buffer..) have
been added to support 64-bit handles.
To allow the above changes in frameworks/base EGL classes,
corresponding code generation mechanism in frameworks/native has
been updated.
Change-Id: I5d0a62e10c20ccf05f610d6608b8dfb6414b5116
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Patch from synergydev with commit-id 01994c79 changed
core/jni/com_google_android_gles_jni_GLImpl.cpp in the
frameworks/base. However the corresponding code snippet
in frameworks/native was not updated. This patch addresses
the issue.
Change-Id: I89c3d88de832efc8cbbe682c8a7ff7dfbef99db3
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
Patch from Takeshi Aimi with commit-id f9337377 changed
core/jni/android_opengl_EGL14.cpp in the frameworks/base.
However the corresponding code snippet in frameworks/
native was not updated. This patch addresses the issue.
Change-Id: I40bcc43d36d7ab4e0db4a73556a4f7480c7431c1
Signed-off-by: Ashok Bhat <ashok.bhat@arm.com>
They were replaced with correct bindings a while back, but the
broken methods weren't hidden.
Also, pick up two changes that were made to the generated code
rather than the source.
Bug 6006380
Change-Id: Ibfe9a5f2e13e745f8d82116d1b4d8c2d025ac830
this means they only have access to the consumer end of
the interface. we had a lot of code that assumed consumers
where holding a BufferQueue (i.e.: both ends), so most of
this change is untangling in fix that
Bug: 9265647
Change-Id: Ic2e2596ee14c7535f51bf26d9a897a0fc036d22c
Make it faster and correcter.
Also, fixed the "gen" script to update the static/egl/*.java files
as part of doing an update. Altered the "git" lines to change
directories before invoking git -- necessary because we're now
split between frameworks/base and frameworks/native.
Bug 9204146
Change-Id: Ie60504b1932349e6f2c9d3868dee6a645ef2b36e
Initially populated with EGL_ANDROID_presentation_time (moved from the
EGL14 class) and the ES-relevant parts of EGL_KHR_create_context.
Bug: 8678160
Change-Id: Ifed2ee3da264ca701ae1f4b309a0758f7fcc3acc
The getarray() function checks to see if there's enough room in
the buffer, but it's using a byte count for the available size
and a possibly non-byte count for the space required. Dividing
down by the unit size corrects the problem.
Bug 8713753
Change-Id: Id42c0df65c3233dcc5f76d05e229f7d40d4c1f99
Updating the generator to handle GLvoid*/java.nio.Buffer return values
probably wouldn't be too hard, but this is the only function that
needs it currently.
Bug: 8566953
Change-Id: I359a951136ab479ab576ce2e5a2881b937b7e8c9
Just a search-and-replace on the glGetActiveAttrib special-case, since
they have the same signature and parameter handling.
Bug: 8566953
Change-Id: I40834d6f32bf9ecb39718df29036aa2d1bbfa07a
Some of these are new ES3 functions, some are existing ES2 functions
that can now use the new pixel pack/unpack buffer bindings.
glDrawElementsInstanced needs a special case since the pointer/offset
arg isn't the last one like the generator assumes.
Bug: 8566953
Change-Id: I638a36b0a31aefcb5bfee6f4d049348223045103