| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 * Copyright 2011 Google Inc. | 3 * Copyright 2011 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 | 9 |
| 10 #include "GrRenderTarget.h" | 10 #include "GrRenderTarget.h" |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 // we're not acctually adding one. | 98 // we're not acctually adding one. |
| 99 return true; | 99 return true; |
| 100 } | 100 } |
| 101 fRenderTarget->fStencilAttachment = stencil; | 101 fRenderTarget->fStencilAttachment = stencil; |
| 102 if (!fRenderTarget->completeStencilAttachment()) { | 102 if (!fRenderTarget->completeStencilAttachment()) { |
| 103 SkSafeSetNull(fRenderTarget->fStencilAttachment); | 103 SkSafeSetNull(fRenderTarget->fStencilAttachment); |
| 104 return false; | 104 return false; |
| 105 } | 105 } |
| 106 return true; | 106 return true; |
| 107 } | 107 } |
| 108 |
| 109 int GrRenderTargetPriv::getEffectiveSampleCount(const GrStencilSettings& stencil
) const { |
| 110 return fRenderTarget->getGpu()->getMultisampleSpecs(fRenderTarget, stencil).
fEffectiveSampleCnt; |
| 111 } |
| 112 |
| 113 uint16_t GrRenderTargetPriv::getSamplePatternID(const GrStencilSettings& stencil
) const { |
| 114 SkASSERT(fRenderTarget->getGpu()->caps()->sampleLocationsSupport()); |
| 115 return fRenderTarget->getGpu()->getMultisampleSpecs(fRenderTarget, stencil).
fSamplePatternID; |
| 116 } |
| 117 |
| 118 const SkPoint* GrRenderTargetPriv::getSampleLocations(const GrStencilSettings& s
tencil) const { |
| 119 SkASSERT(fRenderTarget->getGpu()->caps()->sampleLocationsSupport()); |
| 120 return fRenderTarget->getGpu()->getMultisampleSpecs(fRenderTarget, stencil).
fSampleLocations; |
| 121 } |
| OLD | NEW |