OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "gpu/blink/webgraphicscontext3d_impl.h" | 5 #include "gpu/blink/webgraphicscontext3d_impl.h" |
6 | 6 |
7 #include "base/atomicops.h" | 7 #include "base/atomicops.h" |
8 #include "base/lazy_instance.h" | 8 #include "base/lazy_instance.h" |
9 #include "base/logging.h" | 9 #include "base/logging.h" |
10 #include "gpu/GLES2/gl2extchromium.h" | 10 #include "gpu/GLES2/gl2extchromium.h" |
(...skipping 130 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
141 gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9); \ | 141 gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9); \ |
142 } | 142 } |
143 | 143 |
144 #define DELEGATE_TO_GL_9R(name, glname, t1, t2, t3, t4, t5, t6, t7, t8, \ | 144 #define DELEGATE_TO_GL_9R(name, glname, t1, t2, t3, t4, t5, t6, t7, t8, \ |
145 t9, rt) \ | 145 t9, rt) \ |
146 rt WebGraphicsContext3DImpl::name(t1 a1, t2 a2, t3 a3, t4 a4, t5 a5, \ | 146 rt WebGraphicsContext3DImpl::name(t1 a1, t2 a2, t3 a3, t4 a4, t5 a5, \ |
147 t6 a6, t7 a7, t8 a8, t9 a9) { \ | 147 t6 a6, t7 a7, t8 a8, t9 a9) { \ |
148 return gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9); \ | 148 return gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9); \ |
149 } | 149 } |
150 | 150 |
| 151 #define DELEGATE_TO_GL_10(name, glname, t1, t2, t3, t4, t5, t6, t7, t8, \ |
| 152 t9, t10) \ |
| 153 void WebGraphicsContext3DImpl::name(t1 a1, t2 a2, t3 a3, t4 a4, t5 a5, \ |
| 154 t6 a6, t7 a7, t8 a8, t9 a9, \ |
| 155 t10 a10) { \ |
| 156 gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10); \ |
| 157 } |
| 158 |
| 159 #define DELEGATE_TO_GL_11(name, glname, t1, t2, t3, t4, t5, t6, t7, t8, \ |
| 160 t9, t10, t11) \ |
| 161 void WebGraphicsContext3DImpl::name(t1 a1, t2 a2, t3 a3, t4 a4, t5 a5, \ |
| 162 t6 a6, t7 a7, t8 a8, t9 a9, t10 a10,\ |
| 163 t11 a11) { \ |
| 164 gl_->glname(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10, a11); \ |
| 165 } |
| 166 |
151 WebGraphicsContext3DImpl::WebGraphicsContext3DImpl() | 167 WebGraphicsContext3DImpl::WebGraphicsContext3DImpl() |
152 : initialized_(false), | 168 : initialized_(false), |
153 initialize_failed_(false), | 169 initialize_failed_(false), |
154 context_lost_callback_(0), | 170 context_lost_callback_(0), |
155 context_lost_reason_(GL_NO_ERROR), | 171 context_lost_reason_(GL_NO_ERROR), |
156 error_message_callback_(0), | 172 error_message_callback_(0), |
157 gl_(NULL), | 173 gl_(NULL), |
158 flush_id_(0) { | 174 flush_id_(0) { |
159 } | 175 } |
160 | 176 |
(...skipping 541 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
702 WGC3Duint index, WGC3Dint size, WGC3Denum type, WGC3Dboolean normalized, | 718 WGC3Duint index, WGC3Dint size, WGC3Denum type, WGC3Dboolean normalized, |
703 WGC3Dsizei stride, WGC3Dintptr offset) { | 719 WGC3Dsizei stride, WGC3Dintptr offset) { |
704 gl_->VertexAttribPointer( | 720 gl_->VertexAttribPointer( |
705 index, size, type, normalized, stride, | 721 index, size, type, normalized, stride, |
706 reinterpret_cast<void*>(static_cast<intptr_t>(offset))); | 722 reinterpret_cast<void*>(static_cast<intptr_t>(offset))); |
707 } | 723 } |
708 | 724 |
709 DELEGATE_TO_GL_4(viewport, Viewport, | 725 DELEGATE_TO_GL_4(viewport, Viewport, |
710 WGC3Dint, WGC3Dint, WGC3Dsizei, WGC3Dsizei) | 726 WGC3Dint, WGC3Dint, WGC3Dsizei, WGC3Dsizei) |
711 | 727 |
712 DELEGATE_TO_GL_2(genBuffers, GenBuffers, WGC3Dsizei, WebGLId*); | |
713 | |
714 DELEGATE_TO_GL_2(genFramebuffers, GenFramebuffers, WGC3Dsizei, WebGLId*); | |
715 | |
716 DELEGATE_TO_GL_2(genRenderbuffers, GenRenderbuffers, WGC3Dsizei, WebGLId*); | |
717 | |
718 DELEGATE_TO_GL_2(genTextures, GenTextures, WGC3Dsizei, WebGLId*); | |
719 | |
720 DELEGATE_TO_GL_2(deleteBuffers, DeleteBuffers, WGC3Dsizei, WebGLId*); | |
721 | |
722 DELEGATE_TO_GL_2(deleteFramebuffers, DeleteFramebuffers, WGC3Dsizei, WebGLId*); | |
723 | |
724 DELEGATE_TO_GL_2(deleteRenderbuffers, DeleteRenderbuffers, WGC3Dsizei, | |
725 WebGLId*); | |
726 | |
727 DELEGATE_TO_GL_2(deleteTextures, DeleteTextures, WGC3Dsizei, WebGLId*); | |
728 | |
729 WebGLId WebGraphicsContext3DImpl::createBuffer() { | 728 WebGLId WebGraphicsContext3DImpl::createBuffer() { |
730 GLuint o; | 729 GLuint o; |
731 gl_->GenBuffers(1, &o); | 730 gl_->GenBuffers(1, &o); |
732 return o; | 731 return o; |
733 } | 732 } |
734 | 733 |
735 WebGLId WebGraphicsContext3DImpl::createFramebuffer() { | 734 WebGLId WebGraphicsContext3DImpl::createFramebuffer() { |
736 GLuint o = 0; | 735 GLuint o = 0; |
737 gl_->GenFramebuffers(1, &o); | 736 gl_->GenFramebuffers(1, &o); |
738 return o; | 737 return o; |
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
967 DELEGATE_TO_GL_1(destroyImageCHROMIUM, DestroyImageCHROMIUM, WGC3Duint); | 966 DELEGATE_TO_GL_1(destroyImageCHROMIUM, DestroyImageCHROMIUM, WGC3Duint); |
968 | 967 |
969 DELEGATE_TO_GL_6(framebufferTexture2DMultisampleEXT, | 968 DELEGATE_TO_GL_6(framebufferTexture2DMultisampleEXT, |
970 FramebufferTexture2DMultisampleEXT, | 969 FramebufferTexture2DMultisampleEXT, |
971 WGC3Denum, WGC3Denum, WGC3Denum, WebGLId, WGC3Dint, WGC3Dsizei) | 970 WGC3Denum, WGC3Denum, WGC3Denum, WebGLId, WGC3Dint, WGC3Dsizei) |
972 | 971 |
973 DELEGATE_TO_GL_5(renderbufferStorageMultisampleEXT, | 972 DELEGATE_TO_GL_5(renderbufferStorageMultisampleEXT, |
974 RenderbufferStorageMultisampleEXT, WGC3Denum, WGC3Dsizei, | 973 RenderbufferStorageMultisampleEXT, WGC3Denum, WGC3Dsizei, |
975 WGC3Denum, WGC3Dsizei, WGC3Dsizei) | 974 WGC3Denum, WGC3Dsizei, WGC3Dsizei) |
976 | 975 |
| 976 DELEGATE_TO_GL_1(beginTransformFeedback, BeginTransformFeedback, WGC3Denum) |
| 977 DELEGATE_TO_GL_3(bindBufferBase, BindBufferBase, WGC3Denum, WGC3Duint, |
| 978 WGC3Duint) |
| 979 DELEGATE_TO_GL_5(bindBufferRange, BindBufferRange, WGC3Denum, WGC3Duint, |
| 980 WGC3Duint, WGC3Dintptr, WGC3Dsizeiptr) |
| 981 DELEGATE_TO_GL_2(bindSampler, BindSampler, WGC3Duint, WebGLId) |
| 982 DELEGATE_TO_GL_2(bindTransformFeedback, BindTransformFeedback, WGC3Denum, |
| 983 WebGLId) |
| 984 DELEGATE_TO_GL_4(clearBufferfi, ClearBufferfi, WGC3Denum, WGC3Dint, WGC3Dfloat, |
| 985 WGC3Dint) |
| 986 DELEGATE_TO_GL_3(clearBufferfv, ClearBufferfv, WGC3Denum, WGC3Dint, |
| 987 const WGC3Dfloat *) |
| 988 DELEGATE_TO_GL_3(clearBufferiv, ClearBufferiv, WGC3Denum, WGC3Dint, |
| 989 const WGC3Dint *) |
| 990 DELEGATE_TO_GL_3(clearBufferuiv, ClearBufferuiv, WGC3Denum, WGC3Dint, |
| 991 const WGC3Duint *) |
| 992 //DELEGATE_TO_GL_3R(clientWaitSync, ClientWaitSync, WebGLId, WGC3Dbitfield, |
| 993 // WGC3Duint64, WGC3Denum) |
| 994 //DELEGATE_TO_GL_9(compressedTexImage3D, CompressedTexImage3D, WGC3Denum, |
| 995 // WGC3Dint, WGC3Denum, WGC3Dsizei, WGC3Dsizei, WGC3Dsizei, |
| 996 // WGC3Dint, WGC3Dsizei, const void *) |
| 997 //DELEGATE_TO_GL_11(compressedTexSubImage3D, CompressedTexSubImage3D, WGC3Denum, |
| 998 // WGC3Dint, WGC3Dint, WGC3Dint, WGC3Dint, WGC3Dsizei, |
| 999 // WGC3Dsizei, WGC3Dsizei, WGC3Denum, WGC3Dsizei, const void *) |
| 1000 DELEGATE_TO_GL_5(copyBufferSubData, CopyBufferSubData, WGC3Denum, WGC3Denum, |
| 1001 WGC3Dintptr, WGC3Dintptr, WGC3Dsizeiptr) |
| 1002 DELEGATE_TO_GL_9(copyTexSubImage3D, CopyTexSubImage3D, WGC3Denum, WGC3Dint, |
| 1003 WGC3Dint, WGC3Dint, WGC3Dint, WGC3Dint, WGC3Dint, WGC3Dsizei, |
| 1004 WGC3Dsizei) |
| 1005 WebGLId WebGraphicsContext3DImpl::createSampler() { |
| 1006 GLuint sampler; |
| 1007 gl_->GenSamplers(1, &sampler); |
| 1008 return sampler; |
| 1009 } |
| 1010 WebGLId WebGraphicsContext3DImpl::createTransformFeedback() { |
| 1011 GLuint tf; |
| 1012 gl_->GenTransformFeedbacks(1, &tf); |
| 1013 return tf; |
| 1014 } |
| 1015 void WebGraphicsContext3DImpl::deleteSampler(WebGLId sampler) { |
| 1016 gl_->DeleteSamplers(1, &sampler); |
| 1017 } |
| 1018 //DELEGATE_TO_GL_1(deleteSync, DeleteSync, WebGLId) |
| 1019 void WebGraphicsContext3DImpl::deleteTransformFeedback(WebGLId tf) { |
| 1020 gl_->DeleteTransformFeedbacks(1, &tf); |
| 1021 } |
| 1022 DELEGATE_TO_GL(endTransformFeedback, EndTransformFeedback) |
| 1023 //DELEGATE_TO_GL_2R(fenceSync, FenceSync, WGC3Denum, WGC3Dbitfield, WebGLId) |
| 1024 DELEGATE_TO_GL_5(framebufferTextureLayer, FramebufferTextureLayer, WGC3Denum, |
| 1025 WGC3Denum, WGC3Duint, WGC3Dint, WGC3Dint) |
| 1026 DELEGATE_TO_GL_5(getActiveUniformBlockName, GetActiveUniformBlockName, |
| 1027 WGC3Duint, WGC3Duint, WGC3Dsizei, WGC3Dsizei *, WGC3Dchar *) |
| 1028 DELEGATE_TO_GL_4(getActiveUniformBlockiv, GetActiveUniformBlockiv, WGC3Duint, |
| 1029 WGC3Duint, WGC3Denum, WGC3Dint *) |
| 1030 //DELEGATE_TO_GL_5(getActiveUniformsiv, GetActiveUniformsiv, WGC3Duint, |
| 1031 // WGC3Dsizei, const WGC3Duint *, WGC3Denum, WGC3Dint *) |
| 1032 DELEGATE_TO_GL_2R(getFragDataLocation, GetFragDataLocation, WGC3Duint, |
| 1033 const WGC3Dchar *, WGC3Dint) |
| 1034 DELEGATE_TO_GL_5(getInternalformativ, GetInternalformativ, WGC3Denum, WGC3Denum, |
| 1035 WGC3Denum, WGC3Dsizei, WGC3Dint *) |
| 1036 DELEGATE_TO_GL_3(getSamplerParameterfv, GetSamplerParameterfv, WGC3Duint, |
| 1037 WGC3Denum, WGC3Dfloat *) |
| 1038 DELEGATE_TO_GL_3(getSamplerParameteriv, GetSamplerParameteriv, WGC3Duint, |
| 1039 WGC3Denum, WGC3Dint *) |
| 1040 //DELEGATE_TO_GL_7(getTransformFeedbackVarying, GetTransformFeedbackVarying, |
| 1041 // WGC3Duint, WGC3Duint, WGC3Dsizei, WGC3Dsizei *, WGC3Dsizei *, |
| 1042 // WGC3Denum *, WGC3Dchar *) |
| 1043 DELEGATE_TO_GL_2R(getUniformBlockIndex, GetUniformBlockIndex, WGC3Duint, |
| 1044 const WGC3Dchar *, WGC3Duint) |
| 1045 //DELEGATE_TO_GL_4(getUniformIndices, GetUniformIndices, WGC3Duint, WGC3Dsizei, |
| 1046 // const WGC3Dchar *const*, WGC3Duint *) |
| 1047 //DELEGATE_TO_GL_3(getUniformuiv, GetUniformuiv, WGC3Duint, WGC3Dint, |
| 1048 // WGC3Duint *) |
| 1049 //DELEGATE_TO_GL_3(getVertexAttribIiv, GetVertexAttribIiv, WGC3Duint, |
| 1050 // WGC3Denum, WGC3Dint *) |
| 1051 //DELEGATE_TO_GL_3(getVertexAttribIuiv, GetVertexAttribIuiv, WGC3Duint, |
| 1052 // WGC3Denum, WGC3Duint *) |
| 1053 DELEGATE_TO_GL_3(invalidateFramebuffer, InvalidateFramebuffer, WGC3Denum, |
| 1054 WGC3Dsizei, const WGC3Denum *) |
| 1055 DELEGATE_TO_GL_7(invalidateSubFramebuffer, InvalidateSubFramebuffer, WGC3Denum, |
| 1056 WGC3Dsizei, const WGC3Denum *, WGC3Dint, WGC3Dint, WGC3Dsizei, |
| 1057 WGC3Dsizei) |
| 1058 DELEGATE_TO_GL_1R(isSampler, IsSampler, WebGLId, WGC3Dboolean) |
| 1059 //DELEGATE_TO_GL_1R(isSync, IsSync, WebGLId, WGC3Dboolean) |
| 1060 DELEGATE_TO_GL_1R(isTransformFeedback, IsTransformFeedback, WGC3Duint, |
| 1061 WGC3Dboolean) |
| 1062 DELEGATE_TO_GL(pauseTransformFeedback, PauseTransformFeedback) |
| 1063 //DELEGATE_TO_GL_3(programParameteri, ProgramParameteri, WGC3Duint, WGC3Denum, |
| 1064 // WGC3Dint) |
| 1065 DELEGATE_TO_GL_1(readBuffer, ReadBuffer, WGC3Denum) |
| 1066 DELEGATE_TO_GL(resumeTransformFeedback, ResumeTransformFeedback) |
| 1067 DELEGATE_TO_GL_3(samplerParameterf, SamplerParameterf, WGC3Duint, WGC3Denum, |
| 1068 WGC3Dfloat) |
| 1069 DELEGATE_TO_GL_3(samplerParameterfv, SamplerParameterfv, WGC3Duint, WGC3Denum, |
| 1070 const WGC3Dfloat *) |
| 1071 DELEGATE_TO_GL_3(samplerParameteri, SamplerParameteri, WGC3Duint, WGC3Denum, |
| 1072 WGC3Dint) |
| 1073 DELEGATE_TO_GL_3(samplerParameteriv, SamplerParameteriv, WGC3Duint, WGC3Denum, |
| 1074 const WGC3Dint *) |
| 1075 DELEGATE_TO_GL_10(texImage3D, TexImage3D, WGC3Denum, WGC3Dint, WGC3Dint, |
| 1076 WGC3Dsizei, WGC3Dsizei, WGC3Dsizei, WGC3Dint, WGC3Denum, |
| 1077 WGC3Denum, const void *) |
| 1078 DELEGATE_TO_GL_6(texStorage3D, TexStorage3D, WGC3Denum, WGC3Dsizei, WGC3Denum, |
| 1079 WGC3Dsizei, WGC3Dsizei, WGC3Dsizei) |
| 1080 DELEGATE_TO_GL_11(texSubImage3D, TexSubImage3D, WGC3Denum, WGC3Dint, WGC3Dint, |
| 1081 WGC3Dint, WGC3Dint, WGC3Dsizei, WGC3Dsizei, WGC3Dsizei, |
| 1082 WGC3Denum, WGC3Denum, const void *) |
| 1083 DELEGATE_TO_GL_4(transformFeedbackVaryings, TransformFeedbackVaryings, |
| 1084 WGC3Duint, WGC3Dsizei, const WGC3Dchar *const*, WGC3Denum) |
| 1085 DELEGATE_TO_GL_2(uniform1ui, Uniform1ui, WGC3Dint, WGC3Duint) |
| 1086 DELEGATE_TO_GL_3(uniform1uiv, Uniform1uiv, WGC3Dint, WGC3Dsizei, |
| 1087 const WGC3Duint *) |
| 1088 DELEGATE_TO_GL_3(uniform2ui, Uniform2ui, WGC3Dint, WGC3Duint, WGC3Duint) |
| 1089 DELEGATE_TO_GL_3(uniform2uiv, Uniform2uiv, WGC3Dint, WGC3Dsizei, |
| 1090 const WGC3Duint *) |
| 1091 DELEGATE_TO_GL_4(uniform3ui, Uniform3ui, WGC3Dint, WGC3Duint, WGC3Duint, |
| 1092 WGC3Duint) |
| 1093 DELEGATE_TO_GL_3(uniform3uiv, Uniform3uiv, WGC3Dint, WGC3Dsizei, |
| 1094 const WGC3Duint *) |
| 1095 DELEGATE_TO_GL_5(uniform4ui, Uniform4ui, WGC3Dint, WGC3Duint, WGC3Duint, |
| 1096 WGC3Duint, WGC3Duint) |
| 1097 DELEGATE_TO_GL_3(uniform4uiv, Uniform4uiv, WGC3Dint, WGC3Dsizei, |
| 1098 const WGC3Duint *) |
| 1099 DELEGATE_TO_GL_3(uniformBlockBinding, UniformBlockBinding, WGC3Duint, WGC3Duint, |
| 1100 WGC3Duint) |
| 1101 DELEGATE_TO_GL_4(uniformMatrix2x3fv, UniformMatrix2x3fv, WGC3Dint, WGC3Dsizei, |
| 1102 WGC3Dboolean, const WGC3Dfloat*) |
| 1103 DELEGATE_TO_GL_4(uniformMatrix2x4fv, UniformMatrix2x4fv, WGC3Dint, WGC3Dsizei, |
| 1104 WGC3Dboolean, const WGC3Dfloat*) |
| 1105 DELEGATE_TO_GL_4(uniformMatrix3x2fv, UniformMatrix3x2fv, WGC3Dint, WGC3Dsizei, |
| 1106 WGC3Dboolean, const WGC3Dfloat*) |
| 1107 DELEGATE_TO_GL_4(uniformMatrix3x4fv, UniformMatrix3x4fv, WGC3Dint, WGC3Dsizei, |
| 1108 WGC3Dboolean, const WGC3Dfloat*) |
| 1109 DELEGATE_TO_GL_4(uniformMatrix4x2fv, UniformMatrix4x2fv, WGC3Dint, WGC3Dsizei, |
| 1110 WGC3Dboolean, const WGC3Dfloat*) |
| 1111 DELEGATE_TO_GL_4(uniformMatrix4x3fv, UniformMatrix4x3fv, WGC3Dint, WGC3Dsizei, |
| 1112 WGC3Dboolean, const WGC3Dfloat*) |
| 1113 DELEGATE_TO_GL_5(vertexAttribI4i, VertexAttribI4i, WGC3Duint, WGC3Dint, |
| 1114 WGC3Dint, WGC3Dint, WGC3Dint) |
| 1115 DELEGATE_TO_GL_2(vertexAttribI4iv, VertexAttribI4iv, WGC3Duint, |
| 1116 const WGC3Dint *) |
| 1117 DELEGATE_TO_GL_5(vertexAttribI4ui, VertexAttribI4ui, WGC3Duint, WGC3Duint, |
| 1118 WGC3Duint, WGC3Duint, WGC3Duint) |
| 1119 DELEGATE_TO_GL_2(vertexAttribI4uiv, VertexAttribI4uiv, WGC3Duint, |
| 1120 const WGC3Duint *) |
| 1121 void WebGraphicsContext3DImpl::vertexAttribIPointer( |
| 1122 WGC3Duint index, WGC3Dint size, WGC3Denum type, WGC3Dsizei stride, |
| 1123 WGC3Dintptr offset) { |
| 1124 gl_->VertexAttribIPointer( |
| 1125 index, size, type, stride, |
| 1126 reinterpret_cast<void*>(static_cast<intptr_t>(offset))); |
| 1127 } |
| 1128 //DELEGATE_TO_GL_3(waitSync, WaitSync, WebGLId, WGC3Dbitfield, WGC3Duint64) |
| 1129 |
977 GrGLInterface* WebGraphicsContext3DImpl::createGrGLInterface() { | 1130 GrGLInterface* WebGraphicsContext3DImpl::createGrGLInterface() { |
978 return skia_bindings::CreateCommandBufferSkiaGLBinding(); | 1131 return skia_bindings::CreateCommandBufferSkiaGLBinding(); |
979 } | 1132 } |
980 | 1133 |
981 ::gpu::gles2::GLES2ImplementationErrorMessageCallback* | 1134 ::gpu::gles2::GLES2ImplementationErrorMessageCallback* |
982 WebGraphicsContext3DImpl::getErrorMessageCallback() { | 1135 WebGraphicsContext3DImpl::getErrorMessageCallback() { |
983 if (!client_error_message_callback_) { | 1136 if (!client_error_message_callback_) { |
984 client_error_message_callback_.reset( | 1137 client_error_message_callback_.reset( |
985 new WebGraphicsContext3DErrorMessageCallback(this)); | 1138 new WebGraphicsContext3DErrorMessageCallback(this)); |
986 } | 1139 } |
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1026 output_attribs->depth_size = attributes.depth ? 24 : 0; | 1179 output_attribs->depth_size = attributes.depth ? 24 : 0; |
1027 output_attribs->stencil_size = attributes.stencil ? 8 : 0; | 1180 output_attribs->stencil_size = attributes.stencil ? 8 : 0; |
1028 output_attribs->samples = attributes.antialias ? 4 : 0; | 1181 output_attribs->samples = attributes.antialias ? 4 : 0; |
1029 output_attribs->sample_buffers = attributes.antialias ? 1 : 0; | 1182 output_attribs->sample_buffers = attributes.antialias ? 1 : 0; |
1030 output_attribs->fail_if_major_perf_caveat = | 1183 output_attribs->fail_if_major_perf_caveat = |
1031 attributes.failIfMajorPerformanceCaveat; | 1184 attributes.failIfMajorPerformanceCaveat; |
1032 output_attribs->bind_generates_resource = false; | 1185 output_attribs->bind_generates_resource = false; |
1033 } | 1186 } |
1034 | 1187 |
1035 } // namespace gpu_blink | 1188 } // namespace gpu_blink |
OLD | NEW |