| Index: src/gpu/effects/GrYUVtoRGBEffect.cpp
|
| diff --git a/src/gpu/effects/GrYUVtoRGBEffect.cpp b/src/gpu/effects/GrYUVtoRGBEffect.cpp
|
| index 92acab3725da4ac8763d7b664630c0fbc6afb614..a46cb920777ca99d174ad7c2c56d482555ab869e 100644
|
| --- a/src/gpu/effects/GrYUVtoRGBEffect.cpp
|
| +++ b/src/gpu/effects/GrYUVtoRGBEffect.cpp
|
| @@ -17,9 +17,9 @@ namespace {
|
|
|
| class YUVtoRGBEffect : public GrFragmentProcessor {
|
| public:
|
| - static GrFragmentProcessor* Create(GrTexture* yTexture, GrTexture* uTexture,
|
| - GrTexture* vTexture, const SkISize sizes[3],
|
| - SkYUVColorSpace colorSpace) {
|
| + static GrFragmentProcessor* Create(GrProcessorDataManager* procDataManager, GrTexture* yTexture,
|
| + GrTexture* uTexture, GrTexture* vTexture,
|
| + const SkISize sizes[3], SkYUVColorSpace colorSpace) {
|
| SkScalar w[3], h[3];
|
| w[0] = SkIntToScalar(sizes[0].fWidth) / SkIntToScalar(yTexture->width());
|
| h[0] = SkIntToScalar(sizes[0].fHeight) / SkIntToScalar(yTexture->height());
|
| @@ -40,7 +40,7 @@ public:
|
| (sizes[2].fHeight != sizes[0].fHeight)) ?
|
| GrTextureParams::kBilerp_FilterMode :
|
| GrTextureParams::kNone_FilterMode;
|
| - return SkNEW_ARGS(YUVtoRGBEffect, (yTexture, uTexture, vTexture, yuvMatrix,
|
| + return SkNEW_ARGS(YUVtoRGBEffect, (procDataManager, yTexture, uTexture, vTexture, yuvMatrix,
|
| uvFilterMode, colorSpace));
|
| }
|
|
|
| @@ -110,9 +110,9 @@ public:
|
| }
|
|
|
| private:
|
| - YUVtoRGBEffect(GrTexture* yTexture, GrTexture* uTexture, GrTexture* vTexture,
|
| - const SkMatrix yuvMatrix[3], GrTextureParams::FilterMode uvFilterMode,
|
| - SkYUVColorSpace colorSpace)
|
| + YUVtoRGBEffect(GrProcessorDataManager*, GrTexture* yTexture, GrTexture* uTexture,
|
| + GrTexture* vTexture, const SkMatrix yuvMatrix[3],
|
| + GrTextureParams::FilterMode uvFilterMode, SkYUVColorSpace colorSpace)
|
| : fYTransform(kLocal_GrCoordSet, yuvMatrix[0], yTexture, GrTextureParams::kNone_FilterMode)
|
| , fYAccess(yTexture)
|
| , fUTransform(kLocal_GrCoordSet, yuvMatrix[1], uTexture, uvFilterMode)
|
| @@ -166,8 +166,9 @@ const GrGLfloat YUVtoRGBEffect::GLProcessor::kRec601ConversionMatrix[16] = {
|
| //////////////////////////////////////////////////////////////////////////////
|
|
|
| GrFragmentProcessor*
|
| -GrYUVtoRGBEffect::Create(GrTexture* yTexture, GrTexture* uTexture, GrTexture* vTexture,
|
| - const SkISize sizes[3], SkYUVColorSpace colorSpace) {
|
| - SkASSERT(yTexture && uTexture && vTexture && sizes);
|
| - return YUVtoRGBEffect::Create(yTexture, uTexture, vTexture, sizes, colorSpace);
|
| +GrYUVtoRGBEffect::Create(GrProcessorDataManager* procDataManager, GrTexture* yTexture,
|
| + GrTexture* uTexture, GrTexture* vTexture, const SkISize sizes[3],
|
| + SkYUVColorSpace colorSpace) {
|
| + SkASSERT(procDataManager && yTexture && uTexture && vTexture && sizes);
|
| + return YUVtoRGBEffect::Create(procDataManager, yTexture, uTexture, vTexture, sizes, colorSpace);
|
| }
|
|
|