| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2013 The Android Open Source Project | 2 * Copyright 2013 The Android Open Source Project |
| 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 #include "SkXfermodeImageFilter.h" | 8 #include "SkXfermodeImageFilter.h" |
| 9 #include "SkCanvas.h" | 9 #include "SkCanvas.h" |
| 10 #include "SkDevice.h" | 10 #include "SkDevice.h" |
| (...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 165 foregroundMatrix.preTranslate(SkIntToScalar(backgroundOffset.fX-foregroundOf
fset.fX), | 165 foregroundMatrix.preTranslate(SkIntToScalar(backgroundOffset.fX-foregroundOf
fset.fX), |
| 166 SkIntToScalar(backgroundOffset.fY-foregroundOf
fset.fY)); | 166 SkIntToScalar(backgroundOffset.fY-foregroundOf
fset.fY)); |
| 167 | 167 |
| 168 | 168 |
| 169 SkRect srcRect; | 169 SkRect srcRect; |
| 170 src.getBounds(&srcRect); | 170 src.getBounds(&srcRect); |
| 171 | 171 |
| 172 GrPaint paint; | 172 GrPaint paint; |
| 173 paint.addColorTextureProcessor(foregroundTex, foregroundMatrix); | 173 paint.addColorTextureProcessor(foregroundTex, foregroundMatrix); |
| 174 paint.addColorProcessor(xferProcessor)->unref(); | 174 paint.addColorProcessor(xferProcessor)->unref(); |
| 175 context->drawRect(dst->asRenderTarget(), paint, SkMatrix::I(), srcRect); | 175 context->drawRect(dst->asRenderTarget(), GrClip::WideOpen(), paint, SkMatrix
::I(), srcRect); |
| 176 | 176 |
| 177 offset->fX = backgroundOffset.fX; | 177 offset->fX = backgroundOffset.fX; |
| 178 offset->fY = backgroundOffset.fY; | 178 offset->fY = backgroundOffset.fY; |
| 179 WrapTexture(dst, src.width(), src.height(), result); | 179 WrapTexture(dst, src.width(), src.height(), result); |
| 180 return true; | 180 return true; |
| 181 } | 181 } |
| 182 | 182 |
| 183 #endif | 183 #endif |
| 184 | 184 |
| OLD | NEW |