OSDN Git Service
Nicolas Capens [Fri, 17 Jul 2015 17:28:14 +0000 (13:28 -0400)]
Add an attach debugger dialog.
Bug
15759123
Change-Id: I363524a191d319e03ce2b874cfc853c7330b684f
Reviewed-on: https://swiftshader-review.googlesource.com/3735
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 17 Jul 2015 17:17:33 +0000 (13:17 -0400)]
Reimplement Direct3D GetFunction().
Copied from old Shader::GetFunction().
Bug
22533227
Change-Id: I587a4112bc97f75c010b6f572f8f4388d5af9225
Reviewed-on: https://swiftshader-review.googlesource.com/3734
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 17 Jul 2015 15:47:57 +0000 (11:47 -0400)]
Fix D3D9 shader opcode mapping.
Bug
22533227
Change-Id: Idf969cd81fae9f5bc5f3da147ae84fe597d3afa7
Reviewed-on: https://swiftshader-review.googlesource.com/3733
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 17 Jul 2015 15:45:49 +0000 (11:45 -0400)]
Adapt D3D9 to Renderer changes.
Bug
22533227
Change-Id: Ib1b17bcace85bc6204589a48c65f60c94ffbe5cc
Reviewed-on: https://swiftshader-review.googlesource.com/3732
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 17 Jul 2015 15:09:00 +0000 (11:09 -0400)]
Add the D3D9 project to the solution.
Bug
22533227
Change-Id: I7dd953eecb169cb471aa9c1830f91b06f8bcc7ac
Reviewed-on: https://swiftshader-review.googlesource.com/3731
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 16 Jul 2015 21:40:10 +0000 (17:40 -0400)]
Add back the D3D9 code from before the April 2014 code dump.
Bug
22533227
Change-Id: Ib669fcd6a644c79b3a9e8f5dcf7da278d75cefef
Reviewed-on: https://swiftshader-review.googlesource.com/3730
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 22 Jun 2015 19:57:27 +0000 (15:57 -0400)]
Framebuffer Layer query
Added implementation for querying
GL_FRAMEBUFFER_ATTACHMENT_TEXTURE_LAYER in
GetFramebufferAttachmentParameteriv.
Change-Id: Ib25ba51bf68c9d979f80cc65ba7059366b5f1ae4
Reviewed-on: https://swiftshader-review.googlesource.com/3541
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Thu, 16 Jul 2015 15:12:38 +0000 (11:12 -0400)]
Added location to Attribute
Program now uses Attribute location.
Change-Id: I005d64509e4b1e2dd977db38b6b2c41d6ba7ddef
Reviewed-on: https://swiftshader-review.googlesource.com/3722
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 21:03:10 +0000 (17:03 -0400)]
Added missing binary related functions to Program
The spec for GetProgramiv didn't mention anything about
PROGRAM_BINARY_LENGTH, but looking at the OpenGL ES 3.0
spec, section 2.11.4 - "Program Binaries", we have:
"The number of bytes in the program binary can be queried
by calling GetProgramiv with pname PROGRAM_BINARY_LENGTH"
Change-Id: Idf652fec34fa1f3cce6cce0e7302ab8d47a6cf74
Reviewed-on: https://swiftshader-review.googlesource.com/3611
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 14:30:37 +0000 (10:30 -0400)]
Changed default buffer usage type
dEQP was expecting default buffer usage to be GL_STATIC_DRAW
instead of GL_DYNAMIC_DRAW, so it was changed accordingly.
Change-Id: I5c9e31fc0791955fd32333c1479e76fbc79951a1
Reviewed-on: https://swiftshader-review.googlesource.com/3631
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 13 Jul 2015 17:31:05 +0000 (13:31 -0400)]
Fixed Framebuffer attachment checks
Some checks in Framebuffer related functions were still
ES2 only. Made some modification to fix the checks for ES3.
Change-Id: Iaef6133179ea830dd599a5d66bc9698032085569
Reviewed-on: https://swiftshader-review.googlesource.com/3690
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Thu, 16 Jul 2015 18:52:51 +0000 (14:52 -0400)]
fwidth fix
Fixed copy-paste error in FWIDTH function
Change-Id: I7562aa29408987839334aa13c7461f69d8ae6a19
Reviewed-on: https://swiftshader-review.googlesource.com/3728
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Wed, 15 Jul 2015 20:55:56 +0000 (16:55 -0400)]
Non square matrices related fixes
- Implemented proper VariableRegisterCount (we were using row
count instead of column count to get the number of registers)
and VariableRegisterSize.
- Matrix to matrix copies now clear the correct rows of the
destination matrix when needed
- Added registerSize helper function to type to help clarify
this for matrices.
- Added missing member initializations in TType constructor
Change-Id: Ic880815515c7d12ad12e44f1392aa6892caa953f
Reviewed-on: https://swiftshader-review.googlesource.com/3718
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 19:46:32 +0000 (15:46 -0400)]
LOD should be rounded to int
The queries should round, rather than truncate, LODs to int.
Bug
20724899
Change-Id: I86ddc724545abb80687eb5132cdf8ddd410ee2d1
Reviewed-on: https://swiftshader-review.googlesource.com/3638
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 20:27:50 +0000 (16:27 -0400)]
Handling proper sampler types
Some int/uint/array types weren't properly handled by
the Program class yet, so the missing types were added.
Change-Id: I487bbbdcbf798c7430535745386139632346013f
Reviewed-on: https://swiftshader-review.googlesource.com/3610
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Greg Hartman [Mon, 6 Jul 2015 22:27:41 +0000 (15:27 -0700)]
Make the debug messages more descriptive
Change-Id: I43f1675a1c6059cc86eaf84ac768242cfc80b88f
Reviewed-on: https://swiftshader-review.googlesource.com/3652
Tested-by: Greg Hartman <ghartman@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Greg Hartman [Tue, 7 Jul 2015 17:00:48 +0000 (10:00 -0700)]
Forward declare struct Constants to fix a compile error.
This was breaking the Android build and didn't appear to be used in the code.
It was introduced with I0fe062ea826b73b2bdf28ad3ed6e72e51c576840
Change-Id: Ic2a00c3264263e5608903ee7764f9c8dd8fb2c2a
Reviewed-on: https://swiftshader-review.googlesource.com/3662
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Maxime Grégoire [Wed, 8 Jul 2015 20:43:48 +0000 (16:43 -0400)]
Implementation of glLogicOp
Bug
22375329
Change-Id: Id6684e33bf3cd37fce48e7607e6a65fe64309f72
Reviewed-on: https://swiftshader-review.googlesource.com/2764
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Maxime Grégoire <mgregoire@google.com>
Alexis Hetu [Wed, 8 Jul 2015 19:56:17 +0000 (15:56 -0400)]
Replaced some hardcoded constants
Replaced values that matched with
FRAGMENT_UNIFORM_VECTORS or
VERTEX_UNIFORM_VECTORS where appropriate.
Change-Id: I64a72b6f30a8a553ea44c268e757ee529cff59fd
Reviewed-on: https://swiftshader-review.googlesource.com/3672
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 7 Jul 2015 20:54:07 +0000 (16:54 -0400)]
Minor unary math cleanup
The unary math related functions were already
added to TParseContext, but a few sections in
the parser hadn't been converted yet.
Change-Id: Idbc96e6e91acce28310f391a50d219e39dfc185b
Reviewed-on: https://swiftshader-review.googlesource.com/3668
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 6 Jul 2015 15:38:53 +0000 (11:38 -0400)]
Completing the "length()" intrinsic function implementation
The implementation of the length() function was already added
to TParseContext::addFunctionCallOrMethod() in a previous cl,
but it was still unused because addFunctionCallOrMethod() was
always called with the 3rd argument as nullptr. This cl adds
the missing code required to get the length function working.
Change-Id: I3339ae8b60f5f577caa0a39f88c6ed0c626879b2
Reviewed-on: https://swiftshader-review.googlesource.com/3641
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Greg Hartman [Tue, 7 Jul 2015 16:32:52 +0000 (09:32 -0700)]
Add commands to the Andriod build log.
Change-Id: I045c637eda7449baeeebc0b9b863e8a9af363ec6
Reviewed-on: https://swiftshader-review.googlesource.com/3660
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Greg Hartman [Tue, 7 Jul 2015 20:05:05 +0000 (13:05 -0700)]
Treat rebinding the same image as a noop.
Bug
22321923
Change-Id: Ib32137a0ac940ab40d375e928e3334b50387c5d5
Reviewed-on: https://swiftshader-review.googlesource.com/3667
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Alexis Hetu [Fri, 3 Jul 2015 19:43:53 +0000 (15:43 -0400)]
CreateSampler should create a Sampler object by default
It should be possible to query the default parameters
of a Sampler created with glGenSamplers, so
checkSamplerAllocation() was added to make sure a
created sampler was associated to a Sampler object
where appropriate.
I also cleaned up the API a little to share validation
functions.
Change-Id: I55d95c6663d41e2566b24eb76a431dd4b4da61e3
Reviewed-on: https://swiftshader-review.googlesource.com/3637
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 7 Jul 2015 17:31:44 +0000 (13:31 -0400)]
Invariant keyword support
Added support for the invariant keyword in the parser.
Also made sure all in/out types were handled properly
in OutputASM.cpp.
Change-Id: I40f0bc9caf5bccc691aa60dfaa90bed5d1d7d238
Reviewed-on: https://swiftshader-review.googlesource.com/3663
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 7 Jul 2015 19:12:46 +0000 (15:12 -0400)]
Completed conversion of TSourceLoc into a struct
TSourceLoc was defined as an int, but is meant to be
used as a struct to carry all the information provided
by the parser, so the conversion was made in this cl.
Change-Id: I6015d11aafda96914ec7b2c37883ffbc963a08fe
Reviewed-on: https://swiftshader-review.googlesource.com/3664
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
Alexis Hetu [Wed, 8 Jul 2015 12:29:36 +0000 (08:29 -0400)]
Small named variable cleanup
- Replaced a few lines of codes in the parser by getNamedVariable
- Deleted unused commented out code in the parser
Change-Id: I34db0c971140a39cd91a32c05ebf866d5fca795b
Reviewed-on: https://swiftshader-review.googlesource.com/3670
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 7 Jul 2015 21:13:30 +0000 (17:13 -0400)]
Ternary selection cleanup
Moved the ternary selection code to TParseContext
where checks were added to make sure arrays and
structs can't use it.
Change-Id: If3c007820870276cdf540005e095d89d54949bc4
Reviewed-on: https://swiftshader-review.googlesource.com/3669
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Greg Hartman [Mon, 29 Jun 2015 18:21:17 +0000 (11:21 -0700)]
Save a log file of build commands and errors
Change-Id: I7ad7b5db84e2c33b0340943f7f2b13403e777383
Reviewed-on: https://swiftshader-review.googlesource.com/3587
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Alexis Hetu [Thu, 2 Jul 2015 14:59:51 +0000 (10:59 -0400)]
Transform feedback varyings gather operation
A few small things were missing to get the transform
feedback varyings gather operation to work properly:
- A basic implementation of
Program::gatherTransformFeedbackLinkedVaryings()
has been made as a first step.
- transformFeedbackBufferMode is now initialized in
the constructor
- transformFeedbackLinkedVaryings are now properly
reset
Also:
- Removed useless DirectX semantic information from
the LinkedVarying class
- ++it is more efficient than it++ in a loop, because
it++ create a temporary object to return the
original state of the iterator, so I made the
changes where applicable in Program.cpp.
Change-Id: I78513f185ef5ef1a17448606b5c598c22d0d217e
Reviewed-on: https://swiftshader-review.googlesource.com/3621
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 14:42:25 +0000 (10:42 -0400)]
Added more GLES 3.0 specific cases in GetFramebufferAttachmentParameteriv
These new entries will need to be updated once more internal
formats are available, but this will do for now.
Also added the possibility to query the Framebuffer 0 for GL_BACK,
GL_DEPTH and GL_STENCIL, as is allowed by OpenGL ES 3.0.
Finally, added a missing break in the GL_DEPTH_STENCIL_ATTACHMENT case.
Change-Id: Ifc32cc306c762ff58f9a9fe6608f7c19d3901c31
Reviewed-on: https://swiftshader-review.googlesource.com/3632
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 29 Jun 2015 18:31:19 +0000 (14:31 -0400)]
Proper handling of Interface Block indexing
This is a first step in handling interface blocks
properly by allowing indexing of blocks to be handled
properly. This does not include any interaction with
the Program, which will come in a following step.
No WebGL tests were injured in the making of this cl.
Change-Id: I575b08502f7f4dd63ca7b57f2ca0630367adf0de
Reviewed-on: https://swiftshader-review.googlesource.com/3589
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 20:20:11 +0000 (16:20 -0400)]
Added more info to ES3 only errors in parser
Added the same info as Angle's for ES3 only errors.
Change-Id: I2f11b34b06f8e1cc1b0a200d568c709ca35469ab
Reviewed-on: https://swiftshader-review.googlesource.com/3639
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 22:19:57 +0000 (18:19 -0400)]
Moved function creation code from glslang.y to TParseContext.
Added TParseContext::addFunctionCallOrMethod() to move function
creation functionality out of glslang.y.
Change-Id: Ia23e8c2490ba9d2bb1fcd00a1ef06eab5cf60b80
Reviewed-on: https://swiftshader-review.googlesource.com/3640
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 3 Jul 2015 18:33:14 +0000 (14:33 -0400)]
Implement alpha testing.
Change-Id: I0fe062ea826b73b2bdf28ad3ed6e72e51c576840
Reviewed-on: https://swiftshader-review.googlesource.com/3635
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 3 Jul 2015 14:57:21 +0000 (10:57 -0400)]
Return correct OpenGL ES version
Since we can create OpenGL ES 3.0 contexts locally now,
we should also be able to retrieve the correct version.
Change-Id: I9154869ddea5951946c8e23e59a00beb042fca8c
Reviewed-on: https://swiftshader-review.googlesource.com/3633
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 29 Jun 2015 17:51:16 +0000 (13:51 -0400)]
Proper block size computations
Interface blocks can now properly return their size from
TType::getElementSize() or TType::elementRegisterCount().
Change-Id: Ief69163088839784cf347160bb49fd64f1a2a395
Reviewed-on: https://swiftshader-review.googlesource.com/3584
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 22 Jun 2015 20:52:11 +0000 (16:52 -0400)]
Better encapsulation for TParseContext
Changed 15 public members of TParseContext
so that they are now private and added the
appropriate setters/getters, along with the
required code changes in the parser.
Change-Id: I0a3ea67540d165e9837a3fe8e64fda4843a3cf96
Reviewed-on: https://swiftshader-review.googlesource.com/3543
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 2 Jul 2015 21:06:53 +0000 (17:06 -0400)]
Implement user clip planes.
Bug
22123818
Change-Id: Icd26392008ce50ad822c2ab961eeb86117ca8544
Reviewed-on: https://swiftshader-review.googlesource.com/3626
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 2 Jul 2015 20:55:29 +0000 (16:55 -0400)]
Use the projection matrix to scale z.
Bug
22123818
Change-Id: I2c72e221d9d9410c32875188a5edea6ce7310f20
Reviewed-on: https://swiftshader-review.googlesource.com/3625
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 2 Jul 2015 19:33:29 +0000 (15:33 -0400)]
Eliminate the half-pixel NDC shift.
Bug
22123818
Change-Id: If9bf78d6b44ccd0662676c8896837cca8829efc8
Reviewed-on: https://swiftshader-review.googlesource.com/3624
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Thu, 2 Jul 2015 18:17:00 +0000 (14:17 -0400)]
Removing the EGL_OPENGL_ES3_BIT from Android entirely
Bug
21323928
Change-Id: I51addf7a354d3abac34807d60e8dc5fc67dddd1a
Reviewed-on: https://swiftshader-review.googlesource.com/3623
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 29 Jun 2015 21:10:50 +0000 (17:10 -0400)]
glGetInternalformativ implementation
Change-Id: Ic8e80810ee6846b66543e6a5dbdae044fdd02a99
Reviewed-on: https://swiftshader-review.googlesource.com/3600
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 15:46:58 +0000 (11:46 -0400)]
Proper usage of pixel pack buffer
The pixel pack buffer was ignored, but should be
used whenever it is set when doing a glReadPixels.
When this is the case, pixels becomes an offset.
From the GLES 3.0 spec, section 4.3.1, subsection
"Placement in Pixel Pack Buffer or Client Memory":
"If a pixel pack buffer is bound, data is an offset
into the pixel pack buffer and the pixels are
packed into the buffer relative to this offset;
otherwise, data is a pointer to a block of client
memory and the pixels are packed into the client
memory relative to the pointer"
WebGL conformance tests passed.
Change-Id: I7539f1ce705cfd2072ed679815676c0b18887272
Reviewed-on: https://swiftshader-review.googlesource.com/3604
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 17:40:32 +0000 (13:40 -0400)]
Fixed Program::getAttachedShaders
It was possible to have "count" larger than "maxCount"
since "total" was incremented regardless of whether or
not the shader was added to the "shaders" output
argument. Simplified the function to fix it.
Change-Id: I403e6c100580fb8f5f1c6fe170af1a796e936828
Reviewed-on: https://swiftshader-review.googlesource.com/3605
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 15:06:34 +0000 (11:06 -0400)]
Added missing validation to CopyBufferSubData
Missing validation for mapped buffers and overlap
was added to CopyBufferSubData.
Change-Id: If1f3f9901f039f5737d41ca46d98ce4c188274d6
Reviewed-on: https://swiftshader-review.googlesource.com/3603
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 29 Jun 2015 21:55:33 +0000 (17:55 -0400)]
glBufferSubData fix
According to the OpenGL ES 3.0 spec
(section 2.9.2 Creating Buffer Object Data Stores)
"If data is NULL, then the contents of the buffer
object’s data store are undefined."
So the function should behave the same way, perform
the same checks, but simply skip the copy.
Change-Id: If49e37a8e836618389e105b5377ff183ac3e3107
Reviewed-on: https://swiftshader-review.googlesource.com/3601
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 30 Jun 2015 15:03:03 +0000 (11:03 -0400)]
Added proper size/offset checks
glTexSubImage3D and glCopyTexSubImage3D were missing
some validity checks for size and offset parameters.
Change-Id: Iff1aa034318c1fc58f9bb433c61bd8623493604a
Reviewed-on: https://swiftshader-review.googlesource.com/3602
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 15:08:51 +0000 (11:08 -0400)]
glProgramParameteri API implementation
This function is simply used to notify the
program that the binary may be queried later
on by the application. For now, this hint is
stored in the program, but otherwise ignored,
as querying the binary is still unimplemented.
Change-Id: Ie59f21d7b803111ce6091718b84ecfbe78c03bdd
Reviewed-on: https://swiftshader-review.googlesource.com/3545
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 15:24:48 +0000 (11:24 -0400)]
Added Primitive Restart Index and Rasterizer Discard to IsEnabled
Change-Id: I63f7324139ff4f337996c14380ef2862dbd8465b
Reviewed-on: https://swiftshader-review.googlesource.com/3547
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Mon, 29 Jun 2015 17:45:30 +0000 (13:45 -0400)]
Fix for glGetActiveUniformBlockiv
glGetActiveUniformBlockiv was using the current program
instead of using the program passed as an argument to
the function, causing it to misbehave.
Change-Id: I69b640b20793bd8e7e0c4142a1ff74d0ea796747
Reviewed-on: https://swiftshader-review.googlesource.com/3583
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
Nicolas Capens [Mon, 29 Jun 2015 17:26:28 +0000 (13:26 -0400)]
Fix the light position transformation.
OpenGL transforms the light position by the model-view matrix
at the time when that position is specified.
Bug
22124687
Change-Id: Ia6bb711c9eb20348faec45c46e45ee9f6ef92112
Reviewed-on: https://swiftshader-review.googlesource.com/3524
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Mon, 29 Jun 2015 14:48:30 +0000 (10:48 -0400)]
Implement float4 transform.
Bug
22124687
Change-Id: I88ea87bbf7785d61a2ca61db2855d07c0347f719
Reviewed-on: https://swiftshader-review.googlesource.com/3582
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Mon, 15 Jun 2015 16:40:11 +0000 (12:40 -0400)]
Implement materials and lights.
Bug
22124687
Change-Id: Ic8a458962e370f372c2e97052c9c86f9b5c6dede
Reviewed-on: https://swiftshader-review.googlesource.com/3511
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 12 Jun 2015 18:34:53 +0000 (14:34 -0400)]
Fix support for colorbuffer formats in the texture env.
Bug
21766174
Change-Id: Id53882a7738fab8669d355fd2f32e420a93cbae6
Reviewed-on: https://swiftshader-review.googlesource.com/3500
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 26 Jun 2015 17:00:48 +0000 (13:00 -0400)]
Fix texture sampling buffer overrun.
Sampling byte4 data currently reads 8 bytes for unpacking purposes.
Allocate 4 more bytes to prevent reading outside the image, even
though it's unused data.
Bug
21935792
Change-Id: I162fb3f3575131cedb008f82ef5170e773719e41
Reviewed-on: https://swiftshader-review.googlesource.com/3572
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 26 Jun 2015 15:15:58 +0000 (11:15 -0400)]
Remove image size rounding to 4x4 multiple.
Bug
21935792
Surface::size() already takes into account that compressed images
need their dimensions rounding up to whole 4x4 tiles.
Change-Id: Ie6b7b5d23294e8d3c85b3b362670cfe0c569585d
Reviewed-on: https://swiftshader-review.googlesource.com/3571
Reviewed-by: Alexis Hétu <sugoi@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Greg Hartman [Thu, 11 Jun 2015 23:24:48 +0000 (16:24 -0700)]
Fix some warnings
I sheilded a MSVC pragma, silenced some classes of warnings.
One of the classes involves an overload that hides a member function. I filed a
bug to make certain that this isn't masking a coding error:
https://b.corp.google.com/issues/
22117892
Change-Id: I7090cddc78880c9ee7814aecc72cc107003dfede
Reviewed-on: https://swiftshader-review.googlesource.com/3483
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Alexis Hetu [Mon, 22 Jun 2015 19:28:54 +0000 (15:28 -0400)]
Moving format conversion functions from aggregate to unary
Change-Id: Icd05628204b831ddeefffaec2274fa6661624740
Reviewed-on: https://swiftshader-review.googlesource.com/3540
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 25 Jun 2015 19:25:29 +0000 (15:25 -0400)]
Fix vertex attribute count constant.
Change-Id: Ic0e4831bf3459d54b51e63ebe50b7394fb54e14c
Reviewed-on: https://swiftshader-review.googlesource.com/3562
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 26 Jun 2015 14:03:55 +0000 (10:03 -0400)]
Remove an unused method.
Change-Id: Id212644a19443434ca14f78555e3d159ac4266e8
Reviewed-on: https://swiftshader-review.googlesource.com/3570
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 15:18:17 +0000 (11:18 -0400)]
Adding support for GL_DEPTH_STENCIL_ATTACHMENT
ES3 supports set/get for both stencil and depth
attachments simultaneously though
GL_DEPTH_STENCIL_ATTACHMENT, so support for it
was added in FramebufferRenderbuffer and
GetFramebufferAttachmentParameteriv.
Change-Id: I09b077de1f31899a20baacbd651c65dfa9e7fc5d
Reviewed-on: https://swiftshader-review.googlesource.com/3546
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 15:28:27 +0000 (11:28 -0400)]
Added new GLES3.0 compressed format checks to TexImage2D
Change-Id: I2bfb2072028de66aa89306e51a164ba90bfb9114
Reviewed-on: https://swiftshader-review.googlesource.com/3548
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 18:47:42 +0000 (14:47 -0400)]
Fixed crash using uniforms as indices
Uniforms can now legally be used as indices in
OpenGL ES 3.0, so they now have to be handled
properly in the dynamic indexing analysis.
Change-Id: I971aa55edcbc73796c30e0acc99156b513a78b80
Reviewed-on: https://swiftshader-review.googlesource.com/3550
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 15:33:20 +0000 (11:33 -0400)]
Added proper transform feedback checks to glDrawRangeElements
It is illegal to start a new draw operation while a transform
feedback is active.
Change-Id: I5ebb01889ce5154162a51f5e6cfbc8431554c879
Reviewed-on: https://swiftshader-review.googlesource.com/3549
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 20:06:50 +0000 (16:06 -0400)]
Fixed recursion analysis
Recursion analysis was broken, because assigning
the error value UINT_MAX was then automatically
increased by 1 at the caller site, resulting in
a 0, and recursions would go undetected.
Change-Id: I8ab9990c12d827d8eac2d6084f9170096ad2aef2
Reviewed-on: https://swiftshader-review.googlesource.com/3552
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 20:37:15 +0000 (16:37 -0400)]
Fixed infinite loop crash
Writing for(;;) in a shader was crashing because
a NULL condition was dereferenced. Added the
NULL pointer check to fix the crash.
Change-Id: I2be7a4594029c928ff83221f65503636bc28f4a9
Reviewed-on: https://swiftshader-review.googlesource.com/3553
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 23 Jun 2015 14:44:07 +0000 (10:44 -0400)]
Used proper getBuffer function
There was a switch/case left that hadn't
yet been replaced by Context::getBuffer,
so I fixed that.
Change-Id: I71bca410322e1cfc130a2753d738c3b64fb271c5
Reviewed-on: https://swiftshader-review.googlesource.com/3544
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Thu, 18 Jun 2015 16:34:52 +0000 (12:34 -0400)]
Adding unsized arrays to the glsl parser
Unsized arrays declare with an empty [] without
a specified size are now supported properly in
the glsl parser.
Also moved the construction code from the parser
into TParseContext.
Change-Id: Ic7b3efeee51da1a264e26af4d7908e7d2fccebd9
Reviewed-on: https://swiftshader-review.googlesource.com/3520
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Mon, 22 Jun 2015 14:41:54 +0000 (10:41 -0400)]
Log the switch value when reaching an UNREACHABLE().
Bug
20025568
Change-Id: I37d2c7171e0704b4064e56e8ca8799f930038d87
Reviewed-on: https://swiftshader-review.googlesource.com/3481
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 16 Jun 2015 16:19:50 +0000 (12:19 -0400)]
Binary math cleanup
Moved functionality related to binary math
into TParseContext.
No WebGL tests were hurt in the making of this CL.
Change-Id: I51b9aa8f98ceedc4e4a93b4b907d264086157c18
Reviewed-on: https://swiftshader-review.googlesource.com/3512
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 19 Jun 2015 01:10:09 +0000 (21:10 -0400)]
Support for @ in the parser
Added support for @ in the parser and
replaced all instances of $N.line by
@N.
Change-Id: I7a18278ee0cd5deb90609508abbda2af656daaa4
Reviewed-on: https://swiftshader-review.googlesource.com/3526
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 16 Jun 2015 20:56:37 +0000 (13:56 -0700)]
Fix point rendering.
Change-Id: I8262fa4bc527d719680d83bf9a1b8e88bdae07f8
Reviewed-on: https://swiftshader-review.googlesource.com/3514
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Mon, 15 Jun 2015 16:09:59 +0000 (12:09 -0400)]
Fix light position transformation.
Change-Id: Ia12819357406c6ee98f0af2909d793cb62bfa62f
Reviewed-on: https://swiftshader-review.googlesource.com/3510
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Tue, 16 Jun 2015 16:43:32 +0000 (12:43 -0400)]
Replacing int by TSourceLoc for lines
Lines should be identified by a TSourceLoc object,
which is currently typedefed to an int, but should
be changed to a struct soon, so making sure the
parser functions can handle the change.
Change-Id: Iaafad862dd1078591757695bf205279e7c4202cf
Reviewed-on: https://swiftshader-review.googlesource.com/3513
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Fri, 12 Jun 2015 21:19:31 +0000 (17:19 -0400)]
Simplify int4 and float4 types.
Change-Id: Id0d55c1364fc3db05821eb6ef666aed8c5713e31
Reviewed-on: https://swiftshader-review.googlesource.com/3503
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Thu, 4 Jun 2015 21:21:22 +0000 (17:21 -0400)]
Adding switch case default keywords
This adds switch/case keywords to glsl.
This makes the shaders that include these
keywords compile, but they don't run
properly yet, partly because the "break"
statement only handles loops currently.
Change-Id: I1f52b445e1124ed3931843c46e27ecc1d9ce3d11
Reviewed-on: https://swiftshader-review.googlesource.com/3400
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
Alexis Hetu [Thu, 11 Jun 2015 21:11:06 +0000 (17:11 -0400)]
Adding Interface Blocks to glsl parser
Added code to parse interface blocks and the
corresponding layout qualifiers to the glsl parser.
Change-Id: Idfcbf08f3f877ea9641ae611e6bddd2be1ffb952
Reviewed-on: https://swiftshader-review.googlesource.com/3480
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 12 Jun 2015 19:19:20 +0000 (15:19 -0400)]
Fixed some warnings
- Changing "char*" to "const char*" when a
function can receive string literals
- Removed some unused variables and members
- Fixed some signed vs unsigned comparisons
- Added braces for safety on code like:
if(...) if(...) ... else ...
to make it:
if(...) { if(...) ... else ... }
otherwise the else is ambiguous
- Reordered some member initializations to
fit the declaration order in the class
- OutDir must end with a backslash in VS
Change-Id: I903bd7afac882090841da0c0f4ebb30db0a5dd37
Reviewed-on: https://swiftshader-review.googlesource.com/3501
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 12 Jun 2015 19:27:15 +0000 (15:27 -0400)]
Addressing a FIXME
I added a FIXME in the code because EvqFragmentOut
hadn't been added yet, since this has now been done,
I can remove the comment to address the FIXME.
Change-Id: I67f4371802eb0e30278b3eaafab238a20798ae69
Reviewed-on: https://swiftshader-review.googlesource.com/3502
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Fri, 1 May 2015 18:16:47 +0000 (14:16 -0400)]
Uniform Buffers API implementation
Implemented the necessary functions
for the API level implementation of
glBindBufferBase and glBindBufferRange.
Also cleaned up the TransformFeedback
API functions a little for uniformity
with uniform buffers.
Change-Id: Iccc835f175d4e8bc4ee030343936714b7ff224ac
Reviewed-on: https://swiftshader-review.googlesource.com/3030
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
Alexis Hetu [Thu, 11 Jun 2015 12:25:30 +0000 (08:25 -0400)]
Initializer cleanup
Cleaned up the initialer methods in the parser
and added first-class array initializers.
Passes all WebGL tests.
Change-Id: Ia73db8bfd461f36b717444a8ba4c9ec77d1cee36
Reviewed-on: https://swiftshader-review.googlesource.com/3473
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Alexis Hétu <sugoi@google.com>
Nicolas Capens [Thu, 11 Jun 2015 20:44:39 +0000 (16:44 -0400)]
Fix unintended switch case fall-through.
Bug
21766174
Change-Id: I1428bcceb2fbf6c649632112f773c3a0625e3775
Reviewed-on: https://swiftshader-review.googlesource.com/3479
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 11 Jun 2015 20:21:15 +0000 (16:21 -0400)]
Fix support for BGRA formats in the texture environment.
Bug
21766174
Change-Id: If2fbb543303db27a2a2bd13e1a75cb7f7310d6eb
Reviewed-on: https://swiftshader-review.googlesource.com/3478
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>
Alexis Hetu [Thu, 11 Jun 2015 17:06:58 +0000 (13:06 -0400)]
Eliminating warnings from SwifShader
SwiftShader had over 270 warnings and this
reduces the count to about 90, some of which
can be addressed later, since some are less
trivial to remove. The changes include:
- Making sure we don't build any project with
RTTI enabled, otherwise, we get some
vftable size mismatch warnings
- Making sure exception handling is the same
for all configurations
- Changing minus <unsigned> to the equivalent,
and valid, ~<unsigned> + 1
- Explicitly casting types to bool by adding
"!= 0" or "!= nullptr", depending on the case
- Making sure no #define overrules another one
without first doing the proper #undef of that
#define
- Removing signed VS unsigned comparisons
- Making sure WinMain is __stdcall
WebGL tests passed.
Change-Id: I8d8d80adc862633b656d7e99c8ea461924fc0ef4
Reviewed-on: https://swiftshader-review.googlesource.com/3475
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Wed, 27 May 2015 15:21:37 +0000 (11:21 -0400)]
outerProduct/transpose/determinant/inverse for const
Initial implementation of outerProduct, transpose,
determinant and inverse. This is for const objects
only. The dynamic implementation will follow. Note
that the 4x4 determinant and inverse is not optimal
(some multiplications are repeated), and will have
to be implemented properly for the dynamic case.
Change-Id: If3b38d8cfe5d2d49835ae3823ceda10e286dd9b9
Reviewed-on: https://swiftshader-review.googlesource.com/3282
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Wed, 22 Apr 2015 15:46:24 +0000 (11:46 -0400)]
New FenceSync object API implementation
- Added new FenceSync object and related
API functions implementations
- Added FenceSync to ResourceManager
- Moved Sampler to ResourceManager
Change-Id: Ia3d42b749811a4e1ed087b41f0c871beb8fdb8d4
Reviewed-on: https://swiftshader-review.googlesource.com/2931
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Wed, 10 Jun 2015 18:13:09 +0000 (14:13 -0400)]
Increasing the number of vertex texture units allowed
Technically, the rest of the code *should* already
support changing this value and all related changes
should propagate properly. This allows a few dEQP
tests that were "unsupported" to now pass.
Change-Id: Ie99e1fba88e7642be447a380b78969365194ca5f
Reviewed-on: https://swiftshader-review.googlesource.com/3461
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Alexis Hetu [Wed, 10 Jun 2015 20:03:17 +0000 (16:03 -0400)]
Transform feedback varyings API
Implemented the API functions to set and get
the varyings used for transform feedback.
Change-Id: I0d6451cfbd4a4b1b96dd9c064bb9b310b46764c4
Reviewed-on: https://swiftshader-review.googlesource.com/3462
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Greg Hartman [Thu, 11 Jun 2015 18:23:06 +0000 (11:23 -0700)]
Allow an optional supplemental commit message on builds
Change-Id: I8a9cd32b50121f6c02b78b1f97eb78d6946cd71e
Reviewed-on: https://swiftshader-review.googlesource.com/3476
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Greg Hartman <ghartman@google.com>
Alexis Hetu [Tue, 9 Jun 2015 20:15:30 +0000 (16:15 -0400)]
More ground work for Uniform blocks
Moved some of the struct / indexing code
from glslang.y to the ParserHelper class
and prepared it for uniform blocks.
Change-Id: I2d5d380f662f36f04d74783fd542c4b258d3f3a5
Reviewed-on: https://swiftshader-review.googlesource.com/3441
Tested-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 11 Jun 2015 02:51:05 +0000 (19:51 -0700)]
Compile fixes for JBMR2.
Change-Id: I121abb32d898f5887586680b52c4283ee6e58f96
Reviewed-on: https://swiftshader-review.googlesource.com/3472
Tested-by: Nicolas Capens <capn@google.com>
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Thu, 11 Jun 2015 13:53:40 +0000 (08:53 -0500)]
Fix Linux compilation.
INT_MAX is defined in limits.h
Change-Id: Ic7e223aebae594e1ed18e1185edc573114d851ff
Reviewed-on: https://swiftshader-review.googlesource.com/3474
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 21:06:31 +0000 (17:06 -0400)]
Remove unnecessary RGB565 conversion.
Bug
21716622
Change-Id: I60a90b91371276f512befb9c1b809a3c4d388eb2
Reviewed-on: https://swiftshader-review.googlesource.com/3447
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 21:01:52 +0000 (17:01 -0400)]
Fix texture uploads using different formats.
Bug
21716622
Change-Id: I3154fc0c3da5c9f2f280101e8e5840ca45eb144e
Reviewed-on: https://swiftshader-review.googlesource.com/3446
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 20:59:22 +0000 (16:59 -0400)]
Make back buffers non-lockable.
Bug
21716622
Change-Id: I041fd37d461114a52a3b3dfa57e4aee6c01e5ee5
Reviewed-on: https://swiftshader-review.googlesource.com/3445
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 20:47:29 +0000 (16:47 -0400)]
Support creating a Surface from a user pointer.
Bug
21716622
Change-Id: Ifa5940c17932066b3860ff148be8b6b2bec726c0
Reviewed-on: https://swiftshader-review.googlesource.com/3444
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 20:42:56 +0000 (16:42 -0400)]
Add support for OpenGL ES 2.0 image formats to Surface.
Bug
21716622
Change-Id: Ie416118676c984ebdd2f153b35c6f60fa616e4c7
Reviewed-on: https://swiftshader-review.googlesource.com/3443
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Tue, 9 Jun 2015 20:33:50 +0000 (16:33 -0400)]
Fix color component defaults.
Bug
21716622
Change-Id: I1e07ee9b8ccfd0bd34af9b1f1d76802f3398f7ca
Reviewed-on: https://swiftshader-review.googlesource.com/3442
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>
Nicolas Capens [Wed, 10 Jun 2015 17:52:24 +0000 (13:52 -0400)]
Lock the external buffer when dirty.
Optimize blitting by avoiding locking the internal buffer
when the external one is dirty.
Bug
21424351
Change-Id: Ib798418d0fa93ae5049102ca767dadc2806cd224
Reviewed-on: https://swiftshader-review.googlesource.com/3439
Reviewed-by: Alexis Hétu <sugoi@google.com>
Reviewed-by: Nicolas Capens <capn@google.com>
Tested-by: Nicolas Capens <capn@google.com>