OSDN Git Service

android-x86/external-swiftshader.git
9 years agoAdding more built-in function definitions
Alexis Hetu [Thu, 4 Jun 2015 17:04:17 +0000 (13:04 -0400)]
Adding more built-in function definitions

Defined more derivatives and texture functions
for glsl. By itself, this enables a few hundred
dEQP tests to pass for derivatives, which were
already implemented properly in some cases.

Change-Id: I84063205447ee4813409a3eb52aeb2ad79793a88
Reviewed-on: https://swiftshader-review.googlesource.com/3383
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoSupport different component orders for decoding RGB565.
Nicolas Capens [Thu, 4 Jun 2015 19:34:04 +0000 (15:34 -0400)]
Support different component orders for decoding RGB565.

Bug 21635916

Change-Id: I1216a96d17228e53155aaaf24d43365afb5cead7
Reviewed-on: https://swiftshader-review.googlesource.com/3392
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoPass the internal format to the image data loading functions.
Nicolas Capens [Thu, 4 Jun 2015 19:11:19 +0000 (15:11 -0400)]
Pass the internal format to the image data loading functions.

Bug 21635916

Change-Id: Ib6836cbc42fa4ceebf0af66b9891dde1491594c3
Reviewed-on: https://swiftshader-review.googlesource.com/3391
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoFix infinite loop when using EGL_DONT_CARE.
Nicolas Capens [Thu, 4 Jun 2015 12:59:09 +0000 (08:59 -0400)]
Fix infinite loop when using EGL_DONT_CARE.

Change-Id: I27471691cc0d0d475c089483c560ca5e00f5d64a
Reviewed-on: https://swiftshader-review.googlesource.com/3380
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoglFramebufferTextureLayer API implementation
Alexis Hetu [Wed, 29 Apr 2015 18:29:49 +0000 (14:29 -0400)]
glFramebufferTextureLayer API implementation

Implemented API level of glFramebufferTextureLayer.
All functions should now be adapted to handle level
and layer, all the way to RenderbufferTexture3D,
where layer is still unimplemented.

Change-Id: Id5fe94f998ee517ae84cb0d6e60d535cc7891fe3
Reviewed-on: https://swiftshader-review.googlesource.com/3320
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoUse the last triangle vertex for flat shading on OpenGL.
Nicolas Capens [Wed, 3 Jun 2015 20:33:02 +0000 (16:33 -0400)]
Use the last triangle vertex for flat shading on OpenGL.

Bug 21559270

Change-Id: I4c2b5eb7076cc459422fbbb397a684c19bd643c2
Reviewed-on: https://swiftshader-review.googlesource.com/3372
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoSort config IDs by smaller color component depth.
Nicolas Capens [Wed, 3 Jun 2015 18:54:38 +0000 (14:54 -0400)]
Sort config IDs by smaller color component depth.

This helps select configs without alpha component.
Also fixed handling of EGL_DONT_CARE and EGL_BUFFER_SIZE.

Bug 21538709

Change-Id: I432a71e5df2a0da19a0c38195edf6c42c2d8b9aa
Reviewed-on: https://swiftshader-review.googlesource.com/3370
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoDon't restrict format combinations on CopyTexSubImage.
Nicolas Capens [Wed, 3 Jun 2015 18:00:55 +0000 (14:00 -0400)]
Don't restrict format combinations on CopyTexSubImage.

CopyTexSubImage does not have the format combination restriction
that CopyTexImage has. The destination may have components not
present in the source image.

Bug 21610276

Change-Id: I90f4c0679ceb1061b05a404aa6ca817205b5077f
Reviewed-on: https://swiftshader-review.googlesource.com/3361
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFix choosing configs with 0 alpha bits.
Nicolas Capens [Sun, 31 May 2015 05:38:47 +0000 (01:38 -0400)]
Fix choosing configs with 0 alpha bits.

Configs with 0 alpha bits were not being stored in the set because
the sorting functor did not compare alpha and thus did not achieve
strict ordering. Having separate functors for strict comparison and
sorting by EGL rules fixes it, and also allows to control config ID
assignment. Android expects a config with alpha bits even though not
explicitly requested.

Bug 21538709

Change-Id: I76472e0eb2a8ad9ca39c6e8ce08225d0ce5cef45
Reviewed-on: https://swiftshader-review.googlesource.com/3310
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Keun Soo Yim <yim@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agogl_InstanceID implementation
Alexis Hetu [Tue, 21 Apr 2015 21:06:14 +0000 (17:06 -0400)]
gl_InstanceID implementation

I need some help connecting the dots here.
I can see a few ways of doing it, but it
isn't trivial for me to see which one
would be right. Could you tell me how the
value should go from the VertexProcessor to
being assigned a value in the actual shader.

Change-Id: Ie0bc2024f51a904ab8144c435b623cfefe8e6704
Reviewed-on: https://swiftshader-review.googlesource.com/2920
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoUpdate to RenderbufferStorage's supported format list
Alexis Hetu [Wed, 27 May 2015 20:58:29 +0000 (16:58 -0400)]
Update to RenderbufferStorage's supported format list

Added OpenGL ES 3.0 supported formats to the list
of formats supported by glRenderbufferStorage().

Change-Id: Ifc73de17b678e2a5b782d2fe239d5442b98edd95
Reviewed-on: https://swiftshader-review.googlesource.com/3290
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoRemoving a D3D limitation from SwiftShader
Alexis Hetu [Mon, 1 Jun 2015 21:08:57 +0000 (17:08 -0400)]
Removing a D3D limitation from SwiftShader

The limitation of not being able to have
different values for stencil and stencilBack
was put in place in Angle because of a D3D
limitation, which we do not have in Swift
Shader, so I doubt we need the same limitation.

FYI, this fixes about 600 dEQP tests.

Change-Id: I74d1786c612e817fb5ef46f233751e6f2581c33f
Reviewed-on: https://swiftshader-review.googlesource.com/3321
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoouterProduct implementation
Alexis Hetu [Wed, 27 May 2015 19:18:29 +0000 (15:18 -0400)]
outerProduct implementation

outerProduct is now implemented for dynamic
variables. All outerProduct dEQP tests pass.

Change-Id: I81e29640347844bd9548030aa69ffbb2eb060fdf
Reviewed-on: https://swiftshader-review.googlesource.com/3283
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agotranspose implementation
Alexis Hetu [Wed, 27 May 2015 19:22:18 +0000 (15:22 -0400)]
transpose implementation

transpose is now implemented for dynamic
variables. All NxN transpose dEQP tests pass.
There's still an issue with some NxM matrices,
but it seems to be unrelated to this code.

Change-Id: Ie422706d0085c85fa6fc9a95dc21bb441dcddfe8
Reviewed-on: https://swiftshader-review.googlesource.com/3284
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agoFixed NxM matrix construction and minor issues
Alexis Hetu [Thu, 23 Apr 2015 15:45:35 +0000 (11:45 -0400)]
Fixed NxM matrix construction and minor issues

Fixed NxM matrix construction by
properly checking for these types in
TIntermOperator::isConstructor. Also
fixed a few areas of the code where
the secondary size wasn't properly
taken into account.

Change-Id: I646a41e37460255316f5712f1d744c3a06d8a64d
Reviewed-on: https://swiftshader-review.googlesource.com/3195
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoRemove direct references to stlport. These break the M branch.
Greg Hartman [Thu, 28 May 2015 05:16:36 +0000 (22:16 -0700)]
Remove direct references to stlport. These break the M branch.

Change-Id: I044e252115993acf91d79daae78cccbd5ea97f74
Reviewed-on: https://swiftshader-review.googlesource.com/3300
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoRemove reference to M-incompatible format
Greg Hartman [Thu, 28 May 2015 06:43:38 +0000 (23:43 -0700)]
Remove reference to M-incompatible format

Change-Id: Ia8053af04c687894dfcf3b03e2001678e194b058
Reviewed-on: https://swiftshader-review.googlesource.com/3302
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdd a fix for LLVM for late versions of clang
Greg Hartman [Thu, 28 May 2015 06:43:16 +0000 (23:43 -0700)]
Add a fix for LLVM for late versions of clang

Change-Id: Id32b0b975af8bdff31c822cf5a67792fe7f785b1
Reviewed-on: https://swiftshader-review.googlesource.com/3301
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdd a missing break.
Ping-Hao Wu [Tue, 26 May 2015 23:16:00 +0000 (16:16 -0700)]
Add a missing break.

Change-Id: I459bb15a59dbdae7619b108099f49c2a0c89ecc8
Reviewed-on: https://swiftshader-review.googlesource.com/3281
Tested-by: Ping-Hao Wu <pinghao@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFix R5G6B5 blend.
Nicolas Capens [Tue, 26 May 2015 20:36:35 +0000 (16:36 -0400)]
Fix R5G6B5 blend.

blend() unpacks to ARGB order.

Bug 20891368

Change-Id: I9a505631ee0751d4ef4b01b82c8617f155e95ca5
Reviewed-on: https://swiftshader-review.googlesource.com/3280
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoOptimize R5G6B5 conversion.
Nicolas Capens [Tue, 26 May 2015 15:20:46 +0000 (11:20 -0400)]
Optimize R5G6B5 conversion.

Bug 20891368

Change-Id: I876e4dab9ab5ba7df5887d4b184e9750f9563edc
Reviewed-on: https://swiftshader-review.googlesource.com/3261
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 framebuffer present.
Nicolas Capens [Tue, 26 May 2015 03:47:18 +0000 (23:47 -0400)]
Implement R5G6B5 framebuffer present.

Bug 20891368

Change-Id: If4b0b84d141eb16c96600b7ade98a552e5f2ad0e
Reviewed-on: https://swiftshader-review.googlesource.com/3251
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoReplace if/else with switch.
Alexis Hetu [Thu, 7 May 2015 15:41:43 +0000 (11:41 -0400)]
Replace if/else with switch.

Change-Id: I970a64ffdc18b240239092615f87a59b84c5e364
Reviewed-on: https://swiftshader-review.googlesource.com/3071
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 write masking.
Nicolas Capens [Tue, 26 May 2015 05:11:26 +0000 (01:11 -0400)]
Implement R5G6B5 write masking.

Bug 20891368

Change-Id: Ie4e153330c0a422c849953caf02b199df860b8f0
Reviewed-on: https://swiftshader-review.googlesource.com/3256
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 raster operations.
Nicolas Capens [Tue, 26 May 2015 04:18:01 +0000 (00:18 -0400)]
Implement R5G6B5 raster operations.

Bug 20891368

Change-Id: I1ca80709b945b4b7f7b82ad7b08d4a6f6d7da9b8
Reviewed-on: https://swiftshader-review.googlesource.com/3254
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoCompute clear colors where they'll be used.
Nicolas Capens [Tue, 26 May 2015 14:56:05 +0000 (10:56 -0400)]
Compute clear colors where they'll be used.

Change-Id: I54ee6018980088d8820e35483f4be7bbf974b7ef
Reviewed-on: https://swiftshader-review.googlesource.com/3260
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 clear.
Nicolas Capens [Mon, 25 May 2015 21:11:04 +0000 (17:11 -0400)]
Implement R5G6B5 clear.

Bug 20891368

Change-Id: I5c283589c1fb08003194e668c66ade4d0fe36842
Reviewed-on: https://swiftshader-review.googlesource.com/3250
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement Concatenate() and Insert() for Int2.
Nicolas Capens [Thu, 14 May 2015 03:40:44 +0000 (23:40 -0400)]
Implement Concatenate() and Insert() for Int2.

Change-Id: I2f5bbf0cab904a9500a6219bd6a218cb877611fa
Reviewed-on: https://swiftshader-review.googlesource.com/3142
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoRemove redundant/unreachable code.
Nicolas Capens [Thu, 14 May 2015 00:23:04 +0000 (20:23 -0400)]
Remove redundant/unreachable code.

Change-Id: Id69a6e7c9fcf5de559101028ba912aed7725ca77
Reviewed-on: https://swiftshader-review.googlesource.com/3119
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 to 4.12 normalization.
Nicolas Capens [Tue, 26 May 2015 18:05:36 +0000 (14:05 -0400)]
Implement R5G6B5 to 4.12 normalization.

Bug 20891368

Change-Id: I492a3420facefed5a0ff7e469da54fd67bd68092
Reviewed-on: https://swiftshader-review.googlesource.com/3115
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement R5G6B5 texel fetch.
Nicolas Capens [Tue, 12 May 2015 19:16:06 +0000 (15:16 -0400)]
Implement R5G6B5 texel fetch.

Bug 20891368

Change-Id: I9e45baa999eef62452c8ee467b1be69998f74187
Reviewed-on: https://swiftshader-review.googlesource.com/3091
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoAdd utility function for 16-bit texture formats.
Nicolas Capens [Wed, 13 May 2015 21:39:44 +0000 (17:39 -0400)]
Add utility function for 16-bit texture formats.

Bug 20891368

Change-Id: I6fb0ed00b903fe86c3b5c730842d28e9c212e04e
Reviewed-on: https://swiftshader-review.googlesource.com/3100
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoAdd 6-bit and 5-bit sRGB conversion.
Nicolas Capens [Wed, 13 May 2015 20:48:18 +0000 (16:48 -0400)]
Add 6-bit and 5-bit sRGB conversion.

Bug 20891368

Change-Id: I3b7066f20f0e669dc1d3abe9222654318ae3b011
Reviewed-on: https://swiftshader-review.googlesource.com/3114
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoMatch parameter order between float and integer sampling.
Nicolas Capens [Tue, 12 May 2015 19:40:20 +0000 (15:40 -0400)]
Match parameter order between float and integer sampling.

Change-Id: I86333f0f4d8a9e180a2f7f902d865b664eb836eb
Reviewed-on: https://swiftshader-review.googlesource.com/3102
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoEliminate unnecessary casts.
Nicolas Capens [Sun, 29 Mar 2015 15:19:59 +0000 (11:19 -0400)]
Eliminate unnecessary casts.

Change-Id: I7db8aa80460d80975898dc941a34c26179539cf6
Reviewed-on: https://swiftshader-review.googlesource.com/2743
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoFix matrix mangled name
Alexis Hetu [Tue, 26 May 2015 18:34:54 +0000 (14:34 -0400)]
Fix matrix mangled name

NxM matrices weren't mangled properly,
since only the nominal size was taken
into account, not the secondary size,
in the mangled name.

Change-Id: I94f4d8e1909cce085e8748bbe5355c5f17b0e7c2
Reviewed-on: https://swiftshader-review.googlesource.com/3271
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoInterpret integer color and normal coordinates as normalized.
Nicolas Capens [Mon, 25 May 2015 19:57:03 +0000 (15:57 -0400)]
Interpret integer color and normal coordinates as normalized.

Bug 21278131

Change-Id: Ieef56c20684906037345960d015a5662fe25551e
Reviewed-on: https://swiftshader-review.googlesource.com/3240
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplemented matrix transpose
Alexis Hetu [Thu, 21 May 2015 14:47:04 +0000 (10:47 -0400)]
Implemented matrix transpose

Implemented matrix transpose for
uniform matrices. Also found and
fixed a minor issue in OutputASM
which was causing a bad GL error.

Change-Id: I2d6c603770548c60e56d417b240ca276ec33ba45
Reviewed-on: https://swiftshader-review.googlesource.com/3191
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoGL_HALF_FLOAT vs GL_HALF_FLOAT_OES
Alexis Hetu [Thu, 21 May 2015 15:45:03 +0000 (11:45 -0400)]
GL_HALF_FLOAT vs GL_HALF_FLOAT_OES

GL_HALF_FLOAT and GL_HALF_FLOAT_OES
do not have the same value, so to
be able to support GL_HALF_FLOAT
(in OpenGL ES 3.0) the same way we
used to support GL_HALF_FLOAT_OES
(in OpenGL ES 2.0), a few spots in
the code need to handle both cases.

Change-Id: I1fa60c51c65d693f5cc45124cd71411320f24014
Reviewed-on: https://swiftshader-review.googlesource.com/3192
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoUpdate validation for GL_COMBINE.
Nicolas Capens [Fri, 22 May 2015 21:34:45 +0000 (17:34 -0400)]
Update validation for GL_COMBINE.

Bug 21278131

Change-Id: I9542d396cb7ea10b8ce2b5ef2050606e68cdffb9
Reviewed-on: https://swiftshader-review.googlesource.com/3233
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement GL_COMBINE.
Nicolas Capens [Mon, 25 May 2015 14:01:46 +0000 (10:01 -0400)]
Implement GL_COMBINE.

Bug 21278131

Change-Id: If0cf8aa09b582e0252c4cedd73426764fd4dff53
Reviewed-on: https://swiftshader-review.googlesource.com/3232
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoAdd state for GL_COMBINE.
Nicolas Capens [Fri, 22 May 2015 20:50:22 +0000 (16:50 -0400)]
Add state for GL_COMBINE.

Bug 21278131

Change-Id: I0590b67be5fad5690739b8ebaa9245cba4187b40
Reviewed-on: https://swiftshader-review.googlesource.com/3231
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement predefined texture functions.
Nicolas Capens [Fri, 22 May 2015 20:32:40 +0000 (16:32 -0400)]
Implement predefined texture functions.

Bug 21278131

Change-Id: I16f27aeaf530f7672e4f60ea379ec82450cc5243
Reviewed-on: https://swiftshader-review.googlesource.com/3230
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoFix auto generating mipmaps for incomplete textures.
Nicolas Capens [Fri, 22 May 2015 18:38:39 +0000 (14:38 -0400)]
Fix auto generating mipmaps for incomplete textures.

Bug 21278131

Change-Id: I1969f40ab4cb5e475c9c0a4e5f7d4238a3deb7be
Reviewed-on: https://swiftshader-review.googlesource.com/3220
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Ping-Hao Wu <pinghao@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoImplement GL_GENERATE_MIPMAP.
Nicolas Capens [Thu, 21 May 2015 20:32:44 +0000 (16:32 -0400)]
Implement GL_GENERATE_MIPMAP.

Bug 21278131

Change-Id: I6252b84f0fd810496475a6e19c9f131bb69d977f
Reviewed-on: https://swiftshader-review.googlesource.com/3194
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement GL_PERSPECTIVE_CORRECTION_HINT.
Nicolas Capens [Thu, 21 May 2015 20:31:15 +0000 (16:31 -0400)]
Implement GL_PERSPECTIVE_CORRECTION_HINT.

Bug 21278131

Change-Id: I370d9498778ac23c70cdb521aedaf4600bacca15
Reviewed-on: https://swiftshader-review.googlesource.com/3193
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement several OpenGL ES 1.1 functions with fixed-point parameters.
Nicolas Capens [Fri, 22 May 2015 04:40:51 +0000 (00:40 -0400)]
Implement several OpenGL ES 1.1 functions with fixed-point parameters.

Bug 21278131

Change-Id: I008863c5289e1396765d70eb40b9cfb6cd0e43c5
Reviewed-on: https://swiftshader-review.googlesource.com/3211
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoImplement glPointSize for OpenGL ES 1.1.
Nicolas Capens [Fri, 22 May 2015 04:16:01 +0000 (00:16 -0400)]
Implement glPointSize for OpenGL ES 1.1.

Bug 21278131

Change-Id: I36c2ac37d8f999d4fa9dbf3eecb73f3537380cba
Reviewed-on: https://swiftshader-review.googlesource.com/3210
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoUse llvm-ss static lib in EGLlib.so
Keun Soo Yim [Wed, 20 May 2015 18:09:15 +0000 (11:09 -0700)]
Use llvm-ss static lib in EGLlib.so

Change-Id: I4610a2a9e5e28b3ea3922eb0266ad26382041cb4
Reviewed-on: https://swiftshader-review.googlesource.com/3180
Reviewed-by: Nicolas Capens <capn@google.com>
Reviewed-by: Keun Soo Yim <yim@google.com>
Tested-by: Keun Soo Yim <yim@google.com>
9 years agoRemove tracing of memory allocations.
Nicolas Capens [Thu, 30 Apr 2015 00:32:04 +0000 (17:32 -0700)]
Remove tracing of memory allocations.

Change-Id: Ia906e27d2ded0cafb1c597a369e7a5fe58b0bae1
Reviewed-on: https://swiftshader-review.googlesource.com/3020
Reviewed-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoDo not allow GLES 3.0 on Android
Alexis Hetu [Wed, 20 May 2015 16:58:27 +0000 (12:58 -0400)]
Do not allow GLES 3.0 on Android

Prevented the creation of an
OpenGL ES 3.0 Context on Android.

Bug 21323928

Change-Id: I61a0972f772c8e66b57b267e1d596847063927a8
Reviewed-on: https://swiftshader-review.googlesource.com/3176
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Greg Hartman <ghartman@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoBreak the link to the swiftshader source after the build
Greg Hartman [Wed, 20 May 2015 08:12:23 +0000 (01:12 -0700)]
Break the link to the swiftshader source after the build

Change-Id: Id047cf6f7efcb9d5497fba9ee2f765f35cdce512
Reviewed-on: https://swiftshader-review.googlesource.com/3174
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdded type checking for Mod and bitwise ops
Alexis Hetu [Wed, 13 May 2015 20:37:50 +0000 (16:37 -0400)]
Added type checking for Mod and bitwise ops

Added type checking and bitwise logic in a
few cases for Mod and bitwise operators for
TIntermediate, TIntermBinary and
TIntermConstantUnion.

Change-Id: Ic6ac624fd8d6d9f407f1b8fac40ae31f54a6c7da
Reviewed-on: https://swiftshader-review.googlesource.com/3113
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoglClearBuffer implementation
Alexis Hetu [Wed, 29 Apr 2015 19:53:26 +0000 (15:53 -0400)]
glClearBuffer implementation

Implemented glClearBuffer* functions.
Right now, all colors are represented
as floats internally, but should that
change, and integer types be supported,
we'd be able to remove the casts to
float here.

Change-Id: Ie785858d77ce7ac03b78fca9e43ac922c15e76e0
Reviewed-on: https://swiftshader-review.googlesource.com/3004
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdding unsigned int support for uniforms
Alexis Hetu [Tue, 12 May 2015 19:18:37 +0000 (15:18 -0400)]
Adding unsigned int support for uniforms

Added unsigned int uniforms related
functions and entries where appropriate
to enable it.

Change-Id: Ia3086817a25e6736cee9ba3d58d97bc8eaf520a3
Reviewed-on: https://swiftshader-review.googlesource.com/3101
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdding NxM matrices uniform support
Alexis Hetu [Tue, 12 May 2015 21:13:56 +0000 (17:13 -0400)]
Adding NxM matrices uniform support

Added NxM matrices related functions
and entries to Program and utilities.

Change-Id: I5839c21cb3a9dc469fca4c553a0b5f97e0ad48bf
Reviewed-on: https://swiftshader-review.googlesource.com/3105
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoImplement glClearColorx()
Ping-Hao Wu [Tue, 19 May 2015 06:45:36 +0000 (23:45 -0700)]
Implement glClearColorx()

Change-Id: Icd89b98b35c3450be81c6cccbc1c071ee20de2e4
Reviewed-on: https://swiftshader-review.googlesource.com/3170
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFix a NULL delete via reference bug in LLVM
Greg Hartman [Mon, 18 May 2015 21:13:26 +0000 (14:13 -0700)]
Fix a NULL delete via reference bug in LLVM

Change-Id: Ie189a528f6f92b7b8b9023d6dcc829130f2f14ec
Reviewed-on: https://swiftshader-review.googlesource.com/3161
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoTurn off tracing on the release build
Greg Hartman [Mon, 18 May 2015 07:42:50 +0000 (00:42 -0700)]
Turn off tracing on the release build

Change-Id: I5e850a2c874a4273d5b85897379f3e16ba00b276
Reviewed-on: https://swiftshader-review.googlesource.com/3160
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoFixes for JBMR1
Greg Hartman [Fri, 15 May 2015 18:47:05 +0000 (11:47 -0700)]
Fixes for JBMR1

Remove references to JBMR2+ HAL pixel formats. We don't support them anyway.
Link EGL against LLVM. This happens because there are some dependencies in
the android_top libraries. I suspect it's happening because we link per-file,
not per-function.

Change-Id: Ibc37d3fcbe9967fcffdaa35e07d4cc654c13d46e
Reviewed-on: https://swiftshader-review.googlesource.com/3150
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAnalyze the shader for define instructions.
Nicolas Capens [Fri, 15 May 2015 19:24:08 +0000 (15:24 -0400)]
Analyze the shader for define instructions.

This eliminates the need to specify if shaders can contain defined
constant values in the front-end using a global variable.

Change-Id: If7802a2743c0afa650a2631cd7945c8b3d7cf645
Reviewed-on: https://swiftshader-review.googlesource.com/3152
Reviewed-by: Greg Hartman <ghartman@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoSuppress unused parameter warnings
Greg Hartman [Fri, 15 May 2015 18:44:11 +0000 (11:44 -0700)]
Suppress unused parameter warnings

Change-Id: Ibb3fc68726fbea174ce1c499bcca2a9b6cfbfd5d
Reviewed-on: https://swiftshader-review.googlesource.com/3149
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdd automatic commit to the build process
Greg Hartman [Thu, 14 May 2015 23:20:46 +0000 (16:20 -0700)]
Add automatic commit to the build process

Also update the script name.

Change-Id: I5d0a1012262eb61658d7d4a5e32a19aefff10ece
Reviewed-on: https://swiftshader-review.googlesource.com/3146
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoFix texture unit enable/disable and binding prioritization.
Nicolas Capens [Fri, 15 May 2015 16:10:47 +0000 (12:10 -0400)]
Fix texture unit enable/disable and binding prioritization.

Bug 21194513

Change-Id: I487a7e07aa936b8613200fae319fe09b86e81cb1
Reviewed-on: https://swiftshader-review.googlesource.com/3148
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoFix texture coordinate transformations on OpenGL.
Nicolas Capens [Thu, 14 May 2015 22:17:14 +0000 (18:17 -0400)]
Fix texture coordinate transformations on OpenGL.

Add a texture coordinate generation mode to always use
4-component homogeneous texture coordinates on OpenGL.

Bug 21187909

Change-Id: I58714404002102f4138add454cf5a8c0aecfb062
Reviewed-on: https://swiftshader-review.googlesource.com/3145
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Maxime Grégoire <mgregoire@google.com>
Tested-by: Maxime Grégoire <mgregoire@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoRemove the stripped libraries to save space.
Greg Hartman [Thu, 14 May 2015 00:36:22 +0000 (17:36 -0700)]
Remove the stripped libraries to save space.

Change-Id: Id94ea39742b69bb24c655381e537affccd9ca5c5
Reviewed-on: https://swiftshader-review.googlesource.com/3140
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoImprove log messages on unsupported formats
Greg Hartman [Wed, 13 May 2015 18:32:46 +0000 (11:32 -0700)]
Improve log messages on unsupported formats

Change-Id: Idb24d792f8a50ca9a560a8a2d7b23e1053afaf5e
Reviewed-on: https://swiftshader-review.googlesource.com/3118
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoImprove advice for attaching the debugger
Greg Hartman [Wed, 13 May 2015 22:23:54 +0000 (15:23 -0700)]
Improve advice for attaching the debugger

Change-Id: I6ca5697a8b672a1e20bcb7999cf4d9ba544f9558
Reviewed-on: https://swiftshader-review.googlesource.com/3117
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdded handling of a few more types of variable
Alexis Hetu [Mon, 4 May 2015 20:51:06 +0000 (16:51 -0400)]
Added handling of a few more types of variable

Added a few missing types:
- Unsigned ints and vectors
- Signed and unsigned int samplers
- 2D Array samplers

Change-Id: I052f7da3b2cb24c5cd2bdd1cf1e3b3a2b0ee0a50
Reviewed-on: https://swiftshader-review.googlesource.com/3042
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAvoid NULL pointer exceptions when blitting without a buffer
Greg Hartman [Wed, 13 May 2015 03:57:51 +0000 (20:57 -0700)]
Avoid NULL pointer exceptions when blitting without a buffer

Change-Id: Ic670895f50ff3aa12fb0963e321541b21e886e12
Reviewed-on: https://swiftshader-review.googlesource.com/3110
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoAdding bitwise operators to parser
Alexis Hetu [Wed, 13 May 2015 15:28:22 +0000 (11:28 -0400)]
Adding bitwise operators to parser

Added ~, %, &, |, ^, <<, >>,
      %=, &=, |=, ^=, <<=, >>=
to the parser and related enums.

Change-Id: Ic95b2362ec3a066ea5285b195bdcda9b6853fd3f
Reviewed-on: https://swiftshader-review.googlesource.com/3120
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agoFix library names on JB release.
Greg Hartman [Tue, 12 May 2015 23:16:09 +0000 (16:16 -0700)]
Fix library names on JB release.

Change-Id: Ifa68f6d3bd77454f04f28b20bce97e4bcf0f7a74
Reviewed-on: https://swiftshader-review.googlesource.com/3106
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoTexture2DArray binding function
Alexis Hetu [Mon, 11 May 2015 20:32:19 +0000 (16:32 -0400)]
Texture2DArray binding function

Texture2DArray textures can now be bound properly.

Change-Id: I3516b67c266feaede3e63c30615bd9f2891c0f1b
Reviewed-on: https://swiftshader-review.googlesource.com/3083
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdding unsigned int types to parser
Alexis Hetu [Tue, 12 May 2015 19:58:09 +0000 (15:58 -0400)]
Adding unsigned int types to parser

Added unsigned in and unsigned vectors
to parser.

Change-Id: Ic904f723c5db33d2d2bf432344d8abc3db966c1f
Reviewed-on: https://swiftshader-review.googlesource.com/3103
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoGL_SRC_ALPHA_SATURATE for OpenGL ES 3.0
Alexis Hetu [Tue, 12 May 2015 20:06:30 +0000 (16:06 -0400)]
GL_SRC_ALPHA_SATURATE for OpenGL ES 3.0

GL_SRC_ALPHA_SATURATE can now be used as
a dst type.

Change-Id: I48764a8fb8900d418de3180cf1a485871582e931
Reviewed-on: https://swiftshader-review.googlesource.com/3104
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoUse the correct internal format for swaps.
Nicolas Capens [Mon, 11 May 2015 21:03:19 +0000 (17:03 -0400)]
Use the correct internal format for swaps.

Change-Id: If0aedc86a1f6492eb8174744f9ca6c3eea24e729
Reviewed-on: https://swiftshader-review.googlesource.com/3090
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoFix setting the source format before using it.
Nicolas Capens [Mon, 11 May 2015 19:15:32 +0000 (15:15 -0400)]
Fix setting the source format before using it.

Change-Id: I47b82f0e10e572943c31df521b1b74492ba6318e
Reviewed-on: https://swiftshader-review.googlesource.com/3081
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoChange GceFrameBufferConfig::getInstance() to return a const&
Greg Hartman [Mon, 11 May 2015 20:12:42 +0000 (13:12 -0700)]
Change GceFrameBufferConfig::getInstance() to return a const&

Coincides with I08dcfe8da032f03a556454199a2d66d29837571d
on the Android-GCE end.

Change-Id: I7d24a7eadaa3f0a69f8baf34af0cfea24447594f
Reviewed-on: https://swiftshader-review.googlesource.com/3082
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoPrinting sizes properly
Alexis Hetu [Mon, 11 May 2015 20:42:43 +0000 (16:42 -0400)]
Printing sizes properly

Sizes weren't getting printed properly
because of their type. In this case,
primarySize, for example, is an
unsigned char, so it gets printed as if
it were a character instead of a number.
Changing it to "primarySize + '0'" also
fails, because then the result of the
operator+ gets interpreted as an int.
To get it to work, I would need either
something like:
static_cast<char>(primarySize + '0')
or
static_cast<int>(primarySize)
I chose the latter.

Change-Id: Ib0718a7a86ef4314f886b653526240aa788fb3df
Reviewed-on: https://swiftshader-review.googlesource.com/3084
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agoPixel store parameters
Alexis Hetu [Thu, 23 Apr 2015 20:19:53 +0000 (16:19 -0400)]
Pixel store parameters

Adding the missing pixel store
parameters needed to use some
tests. Added the UnpackInfo
structure to minimize function
signature changes while sending
all unpack parameters to
loadImageData().

Change-Id: I86b660697ae726f902923066a9defe6d3a88860f
Reviewed-on: https://swiftshader-review.googlesource.com/2943
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoTexture2DArray skeleton
Alexis Hetu [Wed, 15 Apr 2015 15:45:56 +0000 (11:45 -0400)]
Texture2DArray skeleton

Added basic class / enums / function skeletons
for Texture2DArray. No sampling code has been
added to SamplerCore for Texture2DArray yet.

Change-Id: I78bc1fdec069005d2b3b6f6b1ba41db8c278f74b
Reviewed-on: https://swiftshader-review.googlesource.com/2852
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agoMultiple color attachments
Alexis Hetu [Thu, 16 Apr 2015 20:27:42 +0000 (16:27 -0400)]
Multiple color attachments

Adding multiple color attachments to
Framebuffer objects. This cl allows
setting multiple draw buffers, but
there is currently no code exercising
that path. These will connected
properly to a shader's multiple
outputs later.

Change-Id: I41d4eadc4518d0b9c1468802c32e622df591e860
Reviewed-on: https://swiftshader-review.googlesource.com/2881
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoglGet, 64b version
Alexis Hetu [Thu, 16 Apr 2015 17:14:04 +0000 (13:14 -0400)]
glGet, 64b version

Implemented glGetInteger[64i_v,64v], which
is very similar to the 32b version, except
it has a 64b output argument.

Change-Id: I1874109da419b82b2499f4d82d9c46ab44381d65
Reviewed-on: https://swiftshader-review.googlesource.com/2864
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdded preprocessor definitions for the architecture details of the DLLs
Maxime Grégoire [Fri, 1 May 2015 20:11:22 +0000 (16:11 -0400)]
Added preprocessor definitions for the architecture details of the DLLs

Change-Id: I473d9f83cceb53247c407a5c7e30acd8346c6b40
Reviewed-on: https://swiftshader-review.googlesource.com/3033
Tested-by: Maxime Grégoire <mgregoire@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFix rendering to a destroyed gralloc buffer.
Nicolas Capens [Fri, 8 May 2015 16:59:44 +0000 (12:59 -0400)]
Fix rendering to a destroyed gralloc buffer.

Wait for draw calls that use the Android native image to finish before
dereferencing the buffer and potentially destroying it.

Bug 20885669

Change-Id: I1c8f56e5065ad4c77d7b950feec4505c2e109a47
Reviewed-on: https://swiftshader-review.googlesource.com/3074
Reviewed-by: Greg Hartman <ghartman@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoConnect AndroidNativeImage lock calls to the sw::Surface
Greg Hartman [Thu, 7 May 2015 05:20:20 +0000 (22:20 -0700)]
Connect AndroidNativeImage lock calls to the sw::Surface

Change-Id: Ic2a4e0ed2844a412122ce2ba3ee6f9f774025eed
Reviewed-on: https://swiftshader-review.googlesource.com/3070
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoUse global libX11 symbols when present.
Nicolas Capens [Wed, 6 May 2015 23:41:43 +0000 (19:41 -0400)]
Use global libX11 symbols when present.

Bug 20754549

Change-Id: I029310192d638a2769bf6e2d2950717d6a4c484b
Reviewed-on: https://swiftshader-review.googlesource.com/3050
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
9 years agoEnhance the vendor script to build the libraries
Greg Hartman [Wed, 6 May 2015 01:18:59 +0000 (18:18 -0700)]
Enhance the vendor script to build the libraries

Change-Id: I9e018591dc04ad1b79634f5d3164ae3d8ca13cfd
Reviewed-on: https://swiftshader-review.googlesource.com/3060
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoFix pairing of gralloc locks and unlocks to avoid reference leaks
Greg Hartman [Wed, 6 May 2015 01:20:05 +0000 (18:20 -0700)]
Fix pairing of gralloc locks and unlocks to avoid reference leaks

Change-Id: Ic6dfa9f565154602d540286d5feb091349f794bf
Reviewed-on: https://swiftshader-review.googlesource.com/3061
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoMakefile updates to productionize the release
Greg Hartman [Thu, 30 Apr 2015 22:44:11 +0000 (15:44 -0700)]
Makefile updates to productionize the release

Change-Id: I9b043641f2c978d50cc4ae6492dff74ad5f006d6
Reviewed-on: https://swiftshader-review.googlesource.com/3019
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoRemove gralloc
Greg Hartman [Wed, 29 Apr 2015 21:25:32 +0000 (14:25 -0700)]
Remove gralloc

Change-Id: Iba39815f809388367d8297739c80fb5d1605900b
Reviewed-on: https://swiftshader-review.googlesource.com/3011
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoRemoved useless memcpy operations
Alexis Hetu [Mon, 4 May 2015 19:59:52 +0000 (15:59 -0400)]
Removed useless memcpy operations

Loading RGBA8 was apparently copying each
line "width" times, which is pretty bad.
Fixed that by removing the useless loop.

Change-Id: Icf38232e422eb33f77b9df499e4137ea8f53abd3
Reviewed-on: https://swiftshader-review.googlesource.com/3040
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdded missing query type
Alexis Hetu [Fri, 1 May 2015 19:38:40 +0000 (15:38 -0400)]
Added missing query type

OpenGL ES 3.0 has a new type of query,
GL_TRANSFORM_FEEDBACK_PRIMITIVES_WRITTEN,
so it was added where appropriate.

Change-Id: I0f1f1c8e3cfc1cf82cb413ae2e77dacd57d85d92
Reviewed-on: https://swiftshader-review.googlesource.com/3032
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoAdded a few missing entries in getIntegerv
Alexis Hetu [Thu, 30 Apr 2015 20:37:37 +0000 (16:37 -0400)]
Added a few missing entries in getIntegerv

A few small things could be added:
- Max Texture3D size
- Max Texture2DArray layers
- VertexArray name

Change-Id: I9e6580cefff7ea3a04b189a4c73a3ffd017453ce
Reviewed-on: https://swiftshader-review.googlesource.com/3018
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoUpdate checks for compressed formats
Alexis Hetu [Thu, 30 Apr 2015 20:28:25 +0000 (16:28 -0400)]
Update checks for compressed formats

New compressed formats were introduced
in Open GL ES 3.0 and these have to be
checked for properly.

Change-Id: I88c5c7478e5358c22b4ffce8939d1adb926ce9df
Reviewed-on: https://swiftshader-review.googlesource.com/3017
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFixed error in TexImage2D
Alexis Hetu [Fri, 1 May 2015 19:15:24 +0000 (15:15 -0400)]
Fixed error in TexImage2D

Corrected small mistake in type.

Change-Id: Ib96b5dfca7fc843c83c3f15a64f141769555d9aa
Reviewed-on: https://swiftshader-review.googlesource.com/3031
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoDetect undersize buffers being delivered by ANativeWindow
Greg Hartman [Thu, 30 Apr 2015 04:37:52 +0000 (21:37 -0700)]
Detect undersize buffers being delivered by ANativeWindow

Change-Id: I02f328e7a2ad46877d00d5bc1de1439bebb23802
Reviewed-on: https://swiftshader-review.googlesource.com/3012
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
9 years agoPreprocessor definitions for libGL x64
Maxime Grégoire [Wed, 29 Apr 2015 17:17:49 +0000 (13:17 -0400)]
Preprocessor definitions for libGL x64

Change-Id: Ic50ce5e9a3a72c04a1894a76d34d2fd020a693e8
Reviewed-on: https://swiftshader-review.googlesource.com/3002
Tested-by: Maxime Grégoire <mgregoire@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
9 years agoFixed element array buffer name crash
Alexis Hetu [Wed, 29 Apr 2015 15:28:28 +0000 (11:28 -0400)]
Fixed element array buffer name crash

Added missing NULL pointer check

Bug 20676373

Change-Id: Ia99cac8e6abb4157441d8ff1741b5d81981a1270
Reviewed-on: https://swiftshader-review.googlesource.com/3000
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
9 years agoDispatch GLESv2 entry functions to avoid resolving to the same symbol.
Nicolas Capens [Wed, 29 Apr 2015 00:18:42 +0000 (17:18 -0700)]
Dispatch GLESv2 entry functions to avoid resolving to the same symbol.

Bug 18752589

Change-Id: I39ddf9a6146c174e4af3cc620f812b0f284877c2
Reviewed-on: https://swiftshader-review.googlesource.com/2981
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>