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

Side by Side Diff: src/gpu/gl/GrGpuGL.cpp

Issue 678073005: Patch to remove constant attributes (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: rebase Created 6 years, 1 month 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 | « src/gpu/gl/GrGpuGL.h ('k') | src/gpu/gl/GrGpuGL_program.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 8
9 #include "GrGpuGL.h" 9 #include "GrGpuGL.h"
10 #include "GrGLStencilBuffer.h" 10 #include "GrGLStencilBuffer.h"
(...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after
335 if (this->glCaps().unpackFlipYSupport()) { 335 if (this->glCaps().unpackFlipYSupport()) {
336 GL_CALL(PixelStorei(GR_GL_UNPACK_FLIP_Y, GR_GL_FALSE)); 336 GL_CALL(PixelStorei(GR_GL_UNPACK_FLIP_Y, GR_GL_FALSE));
337 } 337 }
338 if (this->glCaps().packFlipYSupport()) { 338 if (this->glCaps().packFlipYSupport()) {
339 GL_CALL(PixelStorei(GR_GL_PACK_REVERSE_ROW_ORDER, GR_GL_FALSE)); 339 GL_CALL(PixelStorei(GR_GL_PACK_REVERSE_ROW_ORDER, GR_GL_FALSE));
340 } 340 }
341 } 341 }
342 342
343 if (resetBits & kProgram_GrGLBackendState) { 343 if (resetBits & kProgram_GrGLBackendState) {
344 fHWProgramID = 0; 344 fHWProgramID = 0;
345 fSharedGLProgramState.invalidate();
346 } 345 }
347 } 346 }
348 347
349 namespace { 348 namespace {
350 349
351 GrSurfaceOrigin resolve_origin(GrSurfaceOrigin origin, bool renderTarget) { 350 GrSurfaceOrigin resolve_origin(GrSurfaceOrigin origin, bool renderTarget) {
352 // By default, GrRenderTargets are GL's normal orientation so that they 351 // By default, GrRenderTargets are GL's normal orientation so that they
353 // can be drawn to by the outside world without the client having 352 // can be drawn to by the outside world without the client having
354 // to render upside down. 353 // to render upside down.
355 if (kDefault_GrSurfaceOrigin == origin) { 354 if (kDefault_GrSurfaceOrigin == origin) {
(...skipping 2254 matching lines...) Expand 10 before | Expand all | Expand 10 after
2610 this->setVertexArrayID(gpu, 0); 2609 this->setVertexArrayID(gpu, 0);
2611 } 2610 }
2612 int attrCount = gpu->glCaps().maxVertexAttributes(); 2611 int attrCount = gpu->glCaps().maxVertexAttributes();
2613 if (fDefaultVertexArrayAttribState.count() != attrCount) { 2612 if (fDefaultVertexArrayAttribState.count() != attrCount) {
2614 fDefaultVertexArrayAttribState.resize(attrCount); 2613 fDefaultVertexArrayAttribState.resize(attrCount);
2615 } 2614 }
2616 attribState = &fDefaultVertexArrayAttribState; 2615 attribState = &fDefaultVertexArrayAttribState;
2617 } 2616 }
2618 return attribState; 2617 return attribState;
2619 } 2618 }
OLDNEW
« no previous file with comments | « src/gpu/gl/GrGpuGL.h ('k') | src/gpu/gl/GrGpuGL_program.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698