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

Side by Side Diff: gpu/command_buffer/service/gles2_cmd_decoder_autogen.h

Issue 458333003: Work around NVIDIA driver issue with glLineWidth(NaN) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@lkgr
Patch Set: Created 6 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
« no previous file with comments | « gpu/command_buffer/service/gles2_cmd_decoder.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 1348 matching lines...) Expand 10 before | Expand all | Expand 10 after
1359 error::Error GLES2DecoderImpl::HandleLineWidth( 1359 error::Error GLES2DecoderImpl::HandleLineWidth(
1360 uint32_t immediate_data_size, 1360 uint32_t immediate_data_size,
1361 const gles2::cmds::LineWidth& c) { 1361 const gles2::cmds::LineWidth& c) {
1362 GLfloat width = static_cast<GLfloat>(c.width); 1362 GLfloat width = static_cast<GLfloat>(c.width);
1363 if (width <= 0.0f) { 1363 if (width <= 0.0f) {
1364 LOCAL_SET_GL_ERROR(GL_INVALID_VALUE, "LineWidth", "width out of range"); 1364 LOCAL_SET_GL_ERROR(GL_INVALID_VALUE, "LineWidth", "width out of range");
1365 return error::kNoError; 1365 return error::kNoError;
1366 } 1366 }
1367 if (state_.line_width != width) { 1367 if (state_.line_width != width) {
1368 state_.line_width = width; 1368 state_.line_width = width;
1369 if (base::IsNaN(width)) {
1370 width = 1.0f;
1371 }
1369 glLineWidth(width); 1372 glLineWidth(width);
1370 } 1373 }
1371 return error::kNoError; 1374 return error::kNoError;
1372 } 1375 }
1373 1376
1374 error::Error GLES2DecoderImpl::HandleLinkProgram( 1377 error::Error GLES2DecoderImpl::HandleLinkProgram(
1375 uint32_t immediate_data_size, 1378 uint32_t immediate_data_size,
1376 const gles2::cmds::LinkProgram& c) { 1379 const gles2::cmds::LinkProgram& c) {
1377 GLuint program = c.program; 1380 GLuint program = c.program;
1378 DoLinkProgram(program); 1381 DoLinkProgram(program);
(...skipping 1547 matching lines...) Expand 10 before | Expand all | Expand 10 after
2926 state_.ignore_cached_state) { 2929 state_.ignore_cached_state) {
2927 framebuffer_state_.clear_state_dirty = true; 2930 framebuffer_state_.clear_state_dirty = true;
2928 } 2931 }
2929 return false; 2932 return false;
2930 default: 2933 default:
2931 NOTREACHED(); 2934 NOTREACHED();
2932 return false; 2935 return false;
2933 } 2936 }
2934 } 2937 }
2935 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_AUTOGEN_H_ 2938 #endif // GPU_COMMAND_BUFFER_SERVICE_GLES2_CMD_DECODER_AUTOGEN_H_
OLDNEW
« no previous file with comments | « gpu/command_buffer/service/gles2_cmd_decoder.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698