Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(512)

Side by Side Diff: gpu/command_buffer/client/gles2_implementation_impl_autogen.h

Issue 2268993003: [Command Buffer] Coding style: FrameBuffer -> Framebuffer to be comformant (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: code rebase Created 4 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 // This file is auto-generated from 5 // This file is auto-generated from
6 // gpu/command_buffer/build_gles2_cmd_buffer.py 6 // gpu/command_buffer/build_gles2_cmd_buffer.py
7 // It's formatted by clang-format using chromium coding style: 7 // It's formatted by clang-format using chromium coding style:
8 // clang-format -i -style=chromium filename 8 // clang-format -i -style=chromium filename
9 // DO NOT EDIT! 9 // DO NOT EDIT!
10 10
(...skipping 60 matching lines...) Expand 10 before | Expand all | Expand 10 after
71 SetGLError(GL_INVALID_OPERATION, "BindBufferRange", "buffer reserved id"); 71 SetGLError(GL_INVALID_OPERATION, "BindBufferRange", "buffer reserved id");
72 return; 72 return;
73 } 73 }
74 BindBufferRangeHelper(target, index, buffer, offset, size); 74 BindBufferRangeHelper(target, index, buffer, offset, size);
75 CheckGLError(); 75 CheckGLError();
76 } 76 }
77 77
78 void GLES2Implementation::BindFramebuffer(GLenum target, GLuint framebuffer) { 78 void GLES2Implementation::BindFramebuffer(GLenum target, GLuint framebuffer) {
79 GPU_CLIENT_SINGLE_THREAD_CHECK(); 79 GPU_CLIENT_SINGLE_THREAD_CHECK();
80 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glBindFramebuffer(" 80 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glBindFramebuffer("
81 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 81 << GLES2Util::GetStringFramebufferTarget(target) << ", "
82 << framebuffer << ")"); 82 << framebuffer << ")");
83 if (IsFramebufferReservedId(framebuffer)) { 83 if (IsFramebufferReservedId(framebuffer)) {
84 SetGLError(GL_INVALID_OPERATION, "BindFramebuffer", 84 SetGLError(GL_INVALID_OPERATION, "BindFramebuffer",
85 "framebuffer reserved id"); 85 "framebuffer reserved id");
86 return; 86 return;
87 } 87 }
88 BindFramebufferHelper(target, framebuffer); 88 BindFramebufferHelper(target, framebuffer);
89 CheckGLError(); 89 CheckGLError();
90 } 90 }
91 91
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after
192 << GLES2Util::GetStringSrcBlendFactor(srcAlpha) << ", " 192 << GLES2Util::GetStringSrcBlendFactor(srcAlpha) << ", "
193 << GLES2Util::GetStringDstBlendFactor(dstAlpha) << ")"); 193 << GLES2Util::GetStringDstBlendFactor(dstAlpha) << ")");
194 helper_->BlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha); 194 helper_->BlendFuncSeparate(srcRGB, dstRGB, srcAlpha, dstAlpha);
195 CheckGLError(); 195 CheckGLError();
196 } 196 }
197 197
198 GLenum GLES2Implementation::CheckFramebufferStatus(GLenum target) { 198 GLenum GLES2Implementation::CheckFramebufferStatus(GLenum target) {
199 GPU_CLIENT_SINGLE_THREAD_CHECK(); 199 GPU_CLIENT_SINGLE_THREAD_CHECK();
200 TRACE_EVENT0("gpu", "GLES2Implementation::CheckFramebufferStatus"); 200 TRACE_EVENT0("gpu", "GLES2Implementation::CheckFramebufferStatus");
201 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glCheckFramebufferStatus(" 201 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glCheckFramebufferStatus("
202 << GLES2Util::GetStringFrameBufferTarget(target) << ")"); 202 << GLES2Util::GetStringFramebufferTarget(target) << ")");
203 typedef cmds::CheckFramebufferStatus::Result Result; 203 typedef cmds::CheckFramebufferStatus::Result Result;
204 Result* result = GetResultAs<Result*>(); 204 Result* result = GetResultAs<Result*>();
205 if (!result) { 205 if (!result) {
206 return GL_FRAMEBUFFER_UNSUPPORTED; 206 return GL_FRAMEBUFFER_UNSUPPORTED;
207 } 207 }
208 *result = 0; 208 *result = 0;
209 helper_->CheckFramebufferStatus(target, GetResultShmId(), 209 helper_->CheckFramebufferStatus(target, GetResultShmId(),
210 GetResultShmOffset()); 210 GetResultShmOffset());
211 WaitForCmd(); 211 WaitForCmd();
212 GLenum result_value = *result; 212 GLenum result_value = *result;
(...skipping 475 matching lines...) Expand 10 before | Expand all | Expand 10 after
688 return reinterpret_cast<GLsync>(client_id); 688 return reinterpret_cast<GLsync>(client_id);
689 } 689 }
690 690
691 void GLES2Implementation::FramebufferRenderbuffer(GLenum target, 691 void GLES2Implementation::FramebufferRenderbuffer(GLenum target,
692 GLenum attachment, 692 GLenum attachment,
693 GLenum renderbuffertarget, 693 GLenum renderbuffertarget,
694 GLuint renderbuffer) { 694 GLuint renderbuffer) {
695 GPU_CLIENT_SINGLE_THREAD_CHECK(); 695 GPU_CLIENT_SINGLE_THREAD_CHECK();
696 GPU_CLIENT_LOG( 696 GPU_CLIENT_LOG(
697 "[" << GetLogPrefix() << "] glFramebufferRenderbuffer(" 697 "[" << GetLogPrefix() << "] glFramebufferRenderbuffer("
698 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 698 << GLES2Util::GetStringFramebufferTarget(target) << ", "
699 << GLES2Util::GetStringAttachment(attachment) << ", " 699 << GLES2Util::GetStringAttachment(attachment) << ", "
700 << GLES2Util::GetStringRenderBufferTarget(renderbuffertarget) << ", " 700 << GLES2Util::GetStringRenderBufferTarget(renderbuffertarget) << ", "
701 << renderbuffer << ")"); 701 << renderbuffer << ")");
702 helper_->FramebufferRenderbuffer(target, attachment, renderbuffertarget, 702 helper_->FramebufferRenderbuffer(target, attachment, renderbuffertarget,
703 renderbuffer); 703 renderbuffer);
704 CheckGLError(); 704 CheckGLError();
705 } 705 }
706 706
707 void GLES2Implementation::FramebufferTexture2D(GLenum target, 707 void GLES2Implementation::FramebufferTexture2D(GLenum target,
708 GLenum attachment, 708 GLenum attachment,
709 GLenum textarget, 709 GLenum textarget,
710 GLuint texture, 710 GLuint texture,
711 GLint level) { 711 GLint level) {
712 GPU_CLIENT_SINGLE_THREAD_CHECK(); 712 GPU_CLIENT_SINGLE_THREAD_CHECK();
713 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFramebufferTexture2D(" 713 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFramebufferTexture2D("
714 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 714 << GLES2Util::GetStringFramebufferTarget(target) << ", "
715 << GLES2Util::GetStringAttachment(attachment) << ", " 715 << GLES2Util::GetStringAttachment(attachment) << ", "
716 << GLES2Util::GetStringTextureTarget(textarget) << ", " 716 << GLES2Util::GetStringTextureTarget(textarget) << ", "
717 << texture << ", " << level << ")"); 717 << texture << ", " << level << ")");
718 helper_->FramebufferTexture2D(target, attachment, textarget, texture, level); 718 helper_->FramebufferTexture2D(target, attachment, textarget, texture, level);
719 CheckGLError(); 719 CheckGLError();
720 } 720 }
721 721
722 void GLES2Implementation::FramebufferTextureLayer(GLenum target, 722 void GLES2Implementation::FramebufferTextureLayer(GLenum target,
723 GLenum attachment, 723 GLenum attachment,
724 GLuint texture, 724 GLuint texture,
725 GLint level, 725 GLint level,
726 GLint layer) { 726 GLint layer) {
727 GPU_CLIENT_SINGLE_THREAD_CHECK(); 727 GPU_CLIENT_SINGLE_THREAD_CHECK();
728 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFramebufferTextureLayer(" 728 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFramebufferTextureLayer("
729 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 729 << GLES2Util::GetStringFramebufferTarget(target) << ", "
730 << GLES2Util::GetStringAttachment(attachment) << ", " 730 << GLES2Util::GetStringAttachment(attachment) << ", "
731 << texture << ", " << level << ", " << layer << ")"); 731 << texture << ", " << level << ", " << layer << ")");
732 helper_->FramebufferTextureLayer(target, attachment, texture, level, layer); 732 helper_->FramebufferTextureLayer(target, attachment, texture, level, layer);
733 CheckGLError(); 733 CheckGLError();
734 } 734 }
735 735
736 void GLES2Implementation::FrontFace(GLenum mode) { 736 void GLES2Implementation::FrontFace(GLenum mode) {
737 GPU_CLIENT_SINGLE_THREAD_CHECK(); 737 GPU_CLIENT_SINGLE_THREAD_CHECK();
738 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFrontFace(" 738 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glFrontFace("
739 << GLES2Util::GetStringFaceMode(mode) << ")"); 739 << GLES2Util::GetStringFaceMode(mode) << ")");
(...skipping 247 matching lines...) Expand 10 before | Expand all | Expand 10 after
987 CheckGLError(); 987 CheckGLError();
988 } 988 }
989 void GLES2Implementation::GetFramebufferAttachmentParameteriv(GLenum target, 989 void GLES2Implementation::GetFramebufferAttachmentParameteriv(GLenum target,
990 GLenum attachment, 990 GLenum attachment,
991 GLenum pname, 991 GLenum pname,
992 GLint* params) { 992 GLint* params) {
993 GPU_CLIENT_SINGLE_THREAD_CHECK(); 993 GPU_CLIENT_SINGLE_THREAD_CHECK();
994 GPU_CLIENT_VALIDATE_DESTINATION_INITALIZATION(GLint, params); 994 GPU_CLIENT_VALIDATE_DESTINATION_INITALIZATION(GLint, params);
995 GPU_CLIENT_LOG("[" << GetLogPrefix() 995 GPU_CLIENT_LOG("[" << GetLogPrefix()
996 << "] glGetFramebufferAttachmentParameteriv(" 996 << "] glGetFramebufferAttachmentParameteriv("
997 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 997 << GLES2Util::GetStringFramebufferTarget(target) << ", "
998 << GLES2Util::GetStringAttachmentQuery(attachment) << ", " 998 << GLES2Util::GetStringAttachmentQuery(attachment) << ", "
999 << GLES2Util::GetStringFrameBufferParameter(pname) << ", " 999 << GLES2Util::GetStringFramebufferParameter(pname) << ", "
1000 << static_cast<const void*>(params) << ")"); 1000 << static_cast<const void*>(params) << ")");
1001 TRACE_EVENT0("gpu", 1001 TRACE_EVENT0("gpu",
1002 "GLES2Implementation::GetFramebufferAttachmentParameteriv"); 1002 "GLES2Implementation::GetFramebufferAttachmentParameteriv");
1003 if (GetFramebufferAttachmentParameterivHelper(target, attachment, pname, 1003 if (GetFramebufferAttachmentParameterivHelper(target, attachment, pname,
1004 params)) { 1004 params)) {
1005 return; 1005 return;
1006 } 1006 }
1007 typedef cmds::GetFramebufferAttachmentParameteriv::Result Result; 1007 typedef cmds::GetFramebufferAttachmentParameteriv::Result Result;
1008 Result* result = GetResultAs<Result*>(); 1008 Result* result = GetResultAs<Result*>();
1009 if (!result) { 1009 if (!result) {
(...skipping 450 matching lines...) Expand 10 before | Expand all | Expand 10 after
1460 << GLES2Util::GetStringHintMode(mode) << ")"); 1460 << GLES2Util::GetStringHintMode(mode) << ")");
1461 helper_->Hint(target, mode); 1461 helper_->Hint(target, mode);
1462 CheckGLError(); 1462 CheckGLError();
1463 } 1463 }
1464 1464
1465 void GLES2Implementation::InvalidateFramebuffer(GLenum target, 1465 void GLES2Implementation::InvalidateFramebuffer(GLenum target,
1466 GLsizei count, 1466 GLsizei count,
1467 const GLenum* attachments) { 1467 const GLenum* attachments) {
1468 GPU_CLIENT_SINGLE_THREAD_CHECK(); 1468 GPU_CLIENT_SINGLE_THREAD_CHECK();
1469 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glInvalidateFramebuffer(" 1469 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glInvalidateFramebuffer("
1470 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 1470 << GLES2Util::GetStringFramebufferTarget(target) << ", "
1471 << count << ", " << static_cast<const void*>(attachments) 1471 << count << ", " << static_cast<const void*>(attachments)
1472 << ")"); 1472 << ")");
1473 GPU_CLIENT_LOG_CODE_BLOCK({ 1473 GPU_CLIENT_LOG_CODE_BLOCK({
1474 for (GLsizei i = 0; i < count; ++i) { 1474 for (GLsizei i = 0; i < count; ++i) {
1475 GPU_CLIENT_LOG(" " << i << ": " << attachments[0 + i * 1]); 1475 GPU_CLIENT_LOG(" " << i << ": " << attachments[0 + i * 1]);
1476 } 1476 }
1477 }); 1477 });
1478 if (count < 0) { 1478 if (count < 0) {
1479 SetGLError(GL_INVALID_VALUE, "glInvalidateFramebuffer", "count < 0"); 1479 SetGLError(GL_INVALID_VALUE, "glInvalidateFramebuffer", "count < 0");
1480 return; 1480 return;
1481 } 1481 }
1482 helper_->InvalidateFramebufferImmediate(target, count, attachments); 1482 helper_->InvalidateFramebufferImmediate(target, count, attachments);
1483 CheckGLError(); 1483 CheckGLError();
1484 } 1484 }
1485 1485
1486 void GLES2Implementation::InvalidateSubFramebuffer(GLenum target, 1486 void GLES2Implementation::InvalidateSubFramebuffer(GLenum target,
1487 GLsizei count, 1487 GLsizei count,
1488 const GLenum* attachments, 1488 const GLenum* attachments,
1489 GLint x, 1489 GLint x,
1490 GLint y, 1490 GLint y,
1491 GLsizei width, 1491 GLsizei width,
1492 GLsizei height) { 1492 GLsizei height) {
1493 GPU_CLIENT_SINGLE_THREAD_CHECK(); 1493 GPU_CLIENT_SINGLE_THREAD_CHECK();
1494 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glInvalidateSubFramebuffer(" 1494 GPU_CLIENT_LOG("[" << GetLogPrefix() << "] glInvalidateSubFramebuffer("
1495 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 1495 << GLES2Util::GetStringFramebufferTarget(target) << ", "
1496 << count << ", " << static_cast<const void*>(attachments) 1496 << count << ", " << static_cast<const void*>(attachments)
1497 << ", " << x << ", " << y << ", " << width << ", " 1497 << ", " << x << ", " << y << ", " << width << ", "
1498 << height << ")"); 1498 << height << ")");
1499 GPU_CLIENT_LOG_CODE_BLOCK({ 1499 GPU_CLIENT_LOG_CODE_BLOCK({
1500 for (GLsizei i = 0; i < count; ++i) { 1500 for (GLsizei i = 0; i < count; ++i) {
1501 GPU_CLIENT_LOG(" " << i << ": " << attachments[0 + i * 1]); 1501 GPU_CLIENT_LOG(" " << i << ": " << attachments[0 + i * 1]);
1502 } 1502 }
1503 }); 1503 });
1504 if (count < 0) { 1504 if (count < 0) {
1505 SetGLError(GL_INVALID_VALUE, "glInvalidateSubFramebuffer", "count < 0"); 1505 SetGLError(GL_INVALID_VALUE, "glInvalidateSubFramebuffer", "count < 0");
(...skipping 1382 matching lines...) Expand 10 before | Expand all | Expand 10 after
2888 2888
2889 void GLES2Implementation::FramebufferTexture2DMultisampleEXT(GLenum target, 2889 void GLES2Implementation::FramebufferTexture2DMultisampleEXT(GLenum target,
2890 GLenum attachment, 2890 GLenum attachment,
2891 GLenum textarget, 2891 GLenum textarget,
2892 GLuint texture, 2892 GLuint texture,
2893 GLint level, 2893 GLint level,
2894 GLsizei samples) { 2894 GLsizei samples) {
2895 GPU_CLIENT_SINGLE_THREAD_CHECK(); 2895 GPU_CLIENT_SINGLE_THREAD_CHECK();
2896 GPU_CLIENT_LOG("[" << GetLogPrefix() 2896 GPU_CLIENT_LOG("[" << GetLogPrefix()
2897 << "] glFramebufferTexture2DMultisampleEXT(" 2897 << "] glFramebufferTexture2DMultisampleEXT("
2898 << GLES2Util::GetStringFrameBufferTarget(target) << ", " 2898 << GLES2Util::GetStringFramebufferTarget(target) << ", "
2899 << GLES2Util::GetStringAttachment(attachment) << ", " 2899 << GLES2Util::GetStringAttachment(attachment) << ", "
2900 << GLES2Util::GetStringTextureTarget(textarget) << ", " 2900 << GLES2Util::GetStringTextureTarget(textarget) << ", "
2901 << texture << ", " << level << ", " << samples << ")"); 2901 << texture << ", " << level << ", " << samples << ")");
2902 if (samples < 0) { 2902 if (samples < 0) {
2903 SetGLError(GL_INVALID_VALUE, "glFramebufferTexture2DMultisampleEXT", 2903 SetGLError(GL_INVALID_VALUE, "glFramebufferTexture2DMultisampleEXT",
2904 "samples < 0"); 2904 "samples < 0");
2905 return; 2905 return;
2906 } 2906 }
2907 helper_->FramebufferTexture2DMultisampleEXT(target, attachment, textarget, 2907 helper_->FramebufferTexture2DMultisampleEXT(target, attachment, textarget,
2908 texture, level, samples); 2908 texture, level, samples);
(...skipping 572 matching lines...) Expand 10 before | Expand all | Expand 10 after
3481 << ", " << static_cast<const void*>(transform) << ")"); 3481 << ", " << static_cast<const void*>(transform) << ")");
3482 size_t count = 16; 3482 size_t count = 16;
3483 for (size_t ii = 0; ii < count; ++ii) 3483 for (size_t ii = 0; ii < count; ++ii)
3484 GPU_CLIENT_LOG("value[" << ii << "]: " << transform[ii]); 3484 GPU_CLIENT_LOG("value[" << ii << "]: " << transform[ii]);
3485 helper_->UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate( 3485 helper_->UniformMatrix4fvStreamTextureMatrixCHROMIUMImmediate(
3486 location, transpose, transform); 3486 location, transpose, transform);
3487 CheckGLError(); 3487 CheckGLError();
3488 } 3488 }
3489 3489
3490 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_IMPL_AUTOGEN_H_ 3490 #endif // GPU_COMMAND_BUFFER_CLIENT_GLES2_IMPLEMENTATION_IMPL_AUTOGEN_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/build_gles2_cmd_buffer.py ('k') | gpu/command_buffer/cmd_buffer_functions.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698