Commit Graph

17 Commits

Author SHA1 Message Date
Jeff Davidson bca4262dac Revert "Update protobuf library from 2.3 to 2.6."
This reverts commit a42cdf1690.

Change-Id: I8f75e6fcc921041ebdfd35c4724134fcb2c739c6
2015-01-12 20:00:33 +00:00
Jeff Davidson a42cdf1690 Update protobuf library from 2.3 to 2.6.
Remove generated cpp/h files for gltrace.proto as we can use the build
system to generate these dynamically.

Change-Id: I949d32fb5126f1c05e2a6ed48f6636a4a9b15a48
2015-01-08 16:12:02 -08:00
Jesse Hall fca1b54031 opengl: Regenerate code with ES 3.1 and new extensions
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: I3f45a7ef5367c70e54ce6b36a8c030ae11033434
2014-05-21 15:32:23 -07:00
Jesse Hall 3703f7f014 opengl: Update GLES headers and generate *.in from registry XML
Import GLES headers from Khronos SVN r26322:
https://cvs.khronos.org/svn/repos/registry/trunk/public/gles/api

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 for a list.

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: I902517c23354e14f9c63b1584db286d682315bb5
2014-05-21 14:58:00 -07:00
Jesse Hall 0b96e6c44b Revert "opengl: Generate *.in from registry XML"
This reverts commit 4a73962c69.

Change-Id: I1fa5cbe4d0b86f6df69d616157b3fec68d706d7a
2014-05-20 21:38:44 +00:00
Jesse Hall 4a73962c69 opengl: Generate *.in from registry XML
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
2014-05-19 12:54:05 -07:00
Jesse Hall 4c0596f4cc Rationalize GLES2/3 .in files.
We weren't using gl2_api.in, since gl3_api.in was a superset. And
gl3ext_api.in was empty, and Khronos has decided to keep it that way
(any GLES2/3/... extensions will be in gl2ext.h).

Since libGLES2.so will have all future backwards-compatible GLES APIs,
it makes sense to just use gl2_api.in and gl2ext_api.in to build its
contents. This changes renames gl3_api.in to gl2_api.in and updates
uses of it, and removes gl3ext_api.in and references.

Bug: 15028495
Change-Id: I0745eda27ec91ee625f03e957e4fdb22035dd781
2014-05-17 19:31:48 -07:00
Siva Velusamy 39177b4103 GLES_trace: fix compile errors on 64 bit architectures
GLES_trace passes some pointers back to the host. Encode them
using int64's rather than int32's

This fix requires an update to the host tool to look at pointers
as 64 bit, and if not found, then fall back to 32 bit integers.

Change-Id: I11ff2ca51290f05913c1b9143cecee1caf015543
2014-01-28 17:38:32 -08:00
Jesse Hall 4774338bd0 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
2013-02-12 16:36:53 -08:00
Jesse Hall d58974c6b2 Regenerate API/trace files for constness change
Change-Id: I45836219fc0e97607d83d458de9babb44f4c7534
2013-02-11 16:12:49 -08:00
Andrew Hsieh 300ad09822 Fix return type of glGetAttribLocation and glGetUniformLocation
from int to GLint.

See:
   http://www.khronos.org/opengles/sdk/docs/man/xhtml/glGetAttribLocation.xml
   http://www.khronos.org/opengles/sdk/docs/man/xhtml/glGetUniformLocation.xml

Change-Id: I4a9f8e9e34b8c3cca239ae84bfe8f3cdfd94802a
2012-11-06 14:39:08 -08:00
Siva Velusamy 9801142afb gltrace: Make code 64-bit safe.
Currently, the trace API passes the pointers that need to be
patched up via 32 bit integers. Such code will not be 64 bit safe.
This patch sends all pointers in a separate array of pointers
for the fixup calls to read from.

Change-Id: If975333f11a6f6f9a74fba57de328affaed452a5
2012-02-27 12:08:47 -08:00
Siva Velusamy 05df4504e5 gltrace: Trace thread time and wall clock time.
For each gl function, trace both the thread and wall clock
times.

Change-Id: I32b6caa67fa50bf915dab89b3c5021ee82e28d55
2012-02-17 11:09:47 -08:00
Mathias Agopian 3127260614 update GLES headers and add support for corresponding new extensions.
Change-Id: I554d9659113b4721b748ee5c1a3b1ca82b11d75e
2012-01-28 20:41:35 -08:00
Siva Velusamy 56ac6ff9bd gltrace: add start time & duration to each traced call.
Change-Id: Idfec8f715f6000594b6381cbfdee9fdf6d89f484
2012-01-04 11:38:37 -08:00
Siva Velusamy 93a826f78f gltrace: transport buffering and context management
This patch adds two improvements:
1. Protobuf messages are buffered and sent in chunks.
2. Multiple EGL contexts are handled properly: Corresponding
to each EGLContext, a GLTraceContext with a unique ID is created.
On eglMakeCurrent, the appropriate GLTraceContext is set and is
used while tracing subsequent GL Calls in that thread.

Change-Id: I34076376d3e5af205c87c7396ea47659844abd6e
2012-01-04 11:38:37 -08:00
Siva Velusamy 0469dd6d55 glestrace: Framework for GLES tracing library
This patch provides a framework for tracing GLES 1.0 and 2.0
functions. It is missing a lot of features, but here are the
things it accomplishes:

- Stop building the glesv2dbg library, and build the
    glestrace library instead.
- Replace the hooks for glesv2dbg with the ones for glestrace.
- Add the basics for the trace library. Currently, this
    traces all GL functions, but not all required data is
    sent for all the functions.  As a result, it will not
    be possible to reconstruct the entire GL state on the
    host side.

The files gltrace.pb.* and gltrace_api.* are both generated
using the tools/genapi.py script.

Change-Id: Id60a468f7278657f008bc6ea1df01f9bdfecfdd3
2011-12-02 15:30:17 -08:00