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

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

Issue 14671017: Remove assert that is no longer valid. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 years, 7 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | 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 /* 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 459 matching lines...) Expand 10 before | Expand all | Expand 10 after
470 return texture; 470 return texture;
471 } 471 }
472 472
473 GrRenderTarget* GrGpuGL::onWrapBackendRenderTarget(const GrBackendRenderTargetDe sc& desc) { 473 GrRenderTarget* GrGpuGL::onWrapBackendRenderTarget(const GrBackendRenderTargetDe sc& desc) {
474 GrGLRenderTarget::Desc glDesc; 474 GrGLRenderTarget::Desc glDesc;
475 glDesc.fConfig = desc.fConfig; 475 glDesc.fConfig = desc.fConfig;
476 glDesc.fRTFBOID = static_cast<GrGLuint>(desc.fRenderTargetHandle); 476 glDesc.fRTFBOID = static_cast<GrGLuint>(desc.fRenderTargetHandle);
477 glDesc.fMSColorRenderbufferID = 0; 477 glDesc.fMSColorRenderbufferID = 0;
478 glDesc.fTexFBOID = GrGLRenderTarget::kUnresolvableFBOID; 478 glDesc.fTexFBOID = GrGLRenderTarget::kUnresolvableFBOID;
479 glDesc.fSampleCnt = desc.fSampleCnt; 479 glDesc.fSampleCnt = desc.fSampleCnt;
480 glDesc.fIsWrapped = true; 480 glDesc.fIsWrapped = true;
robertphillips 2013/05/14 19:22:15 I don't think we should delete the copy of 'fOrigi
bsalomon 2013/05/14 19:34:56 take a look at the next line: glDesc.fOrigin = res
481 glDesc.fOrigin = desc.fOrigin;
482 if (glDesc.fRTFBOID == 0) {
483 GrAssert(desc.fOrigin == kBottomLeft_GrSurfaceOrigin);
484 }
485 481
486 glDesc.fOrigin = resolve_origin(desc.fOrigin, true); 482 glDesc.fOrigin = resolve_origin(desc.fOrigin, true);
487 GrGLIRect viewport; 483 GrGLIRect viewport;
488 viewport.fLeft = 0; 484 viewport.fLeft = 0;
489 viewport.fBottom = 0; 485 viewport.fBottom = 0;
490 viewport.fWidth = desc.fWidth; 486 viewport.fWidth = desc.fWidth;
491 viewport.fHeight = desc.fHeight; 487 viewport.fHeight = desc.fHeight;
492 488
493 GrRenderTarget* tgt = SkNEW_ARGS(GrGLRenderTarget, 489 GrRenderTarget* tgt = SkNEW_ARGS(GrGLRenderTarget,
494 (this, glDesc, viewport)); 490 (this, glDesc, viewport));
(...skipping 2012 matching lines...) Expand 10 before | Expand all | Expand 10 after
2507 this->setVertexArrayID(gpu, 0); 2503 this->setVertexArrayID(gpu, 0);
2508 } 2504 }
2509 int attrCount = gpu->glCaps().maxVertexAttributes(); 2505 int attrCount = gpu->glCaps().maxVertexAttributes();
2510 if (fDefaultVertexArrayAttribState.count() != attrCount) { 2506 if (fDefaultVertexArrayAttribState.count() != attrCount) {
2511 fDefaultVertexArrayAttribState.resize(attrCount); 2507 fDefaultVertexArrayAttribState.resize(attrCount);
2512 } 2508 }
2513 attribState = &fDefaultVertexArrayAttribState; 2509 attribState = &fDefaultVertexArrayAttribState;
2514 } 2510 }
2515 return attribState; 2511 return attribState;
2516 } 2512 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698