OLD | NEW |
1 | 1 |
2 /* | 2 /* |
3 * Copyright 2010 Google Inc. | 3 * Copyright 2010 Google Inc. |
4 * | 4 * |
5 * Use of this source code is governed by a BSD-style license that can be | 5 * Use of this source code is governed by a BSD-style license that can be |
6 * found in the LICENSE file. | 6 * found in the LICENSE file. |
7 */ | 7 */ |
8 | 8 |
9 #include "GrDrawTarget.h" | 9 #include "GrDrawTarget.h" |
10 | 10 |
(...skipping 1047 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1058 } | 1058 } |
1059 } else { | 1059 } else { |
1060 #ifdef SK_DEBUG | 1060 #ifdef SK_DEBUG |
1061 //SkDebugf("No dev bounds when conservative draw bounds are requested.\n
"); | 1061 //SkDebugf("No dev bounds when conservative draw bounds are requested.\n
"); |
1062 #endif | 1062 #endif |
1063 } | 1063 } |
1064 | 1064 |
1065 return true; | 1065 return true; |
1066 } | 1066 } |
1067 | 1067 |
| 1068 void GrDrawTarget::PipelineInfo::getQuickDrawBounds(SkIRect* outBounds) const { |
| 1069 if (fHasDrawBounds) { |
| 1070 fDrawBounds.roundOut(outBounds); |
| 1071 } else { |
| 1072 GrRenderTarget* rt = fPipelineBuilder->getRenderTarget(); |
| 1073 *outBounds = SkIRect::MakeWH(rt->width(), rt->height()); |
| 1074 } |
| 1075 } |
| 1076 |
1068 /////////////////////////////////////////////////////////////////////////////// | 1077 /////////////////////////////////////////////////////////////////////////////// |
1069 | 1078 |
1070 void GrDrawTargetCaps::reset() { | 1079 void GrDrawTargetCaps::reset() { |
1071 fMipMapSupport = false; | 1080 fMipMapSupport = false; |
1072 fNPOTTextureTileSupport = false; | 1081 fNPOTTextureTileSupport = false; |
1073 fTwoSidedStencilSupport = false; | 1082 fTwoSidedStencilSupport = false; |
1074 fStencilWrapOpsSupport = false; | 1083 fStencilWrapOpsSupport = false; |
1075 fShaderDerivativeSupport = false; | 1084 fShaderDerivativeSupport = false; |
1076 fGeometryShaderSupport = false; | 1085 fGeometryShaderSupport = false; |
1077 fDualSourceBlendingSupport = false; | 1086 fDualSourceBlendingSupport = false; |
(...skipping 201 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1279 GrPipelineBuilder::AutoRestoreFragmentProcessors* a
rfp, | 1288 GrPipelineBuilder::AutoRestoreFragmentProcessors* a
rfp, |
1280 GrPipelineBuilder::AutoRestoreStencil* ars, | 1289 GrPipelineBuilder::AutoRestoreStencil* ars, |
1281 GrScissorState* scissorState, | 1290 GrScissorState* scissorState, |
1282 const SkRect* devBounds) { | 1291 const SkRect* devBounds) { |
1283 return fClipMaskManager.setupClipping(pipelineBuilder, | 1292 return fClipMaskManager.setupClipping(pipelineBuilder, |
1284 arfp, | 1293 arfp, |
1285 ars, | 1294 ars, |
1286 scissorState, | 1295 scissorState, |
1287 devBounds); | 1296 devBounds); |
1288 } | 1297 } |
OLD | NEW |