diff options
Diffstat (limited to 'include/effects/SkRectShaderImageFilter.h')
-rw-r--r-- | include/effects/SkRectShaderImageFilter.h | 16 |
1 files changed, 11 insertions, 5 deletions
diff --git a/include/effects/SkRectShaderImageFilter.h b/include/effects/SkRectShaderImageFilter.h index 5ad11c104c..9a2913c03b 100644 --- a/include/effects/SkRectShaderImageFilter.h +++ b/include/effects/SkRectShaderImageFilter.h @@ -15,12 +15,18 @@ class SkShader; class SK_API SkRectShaderImageFilter : public SkImageFilter { public: - /** - * The SkShader object will have its refcnt increased as it becomes a member of the - * SkRectShaderImageFilter object returned by this function. It cannot be NULL. - * The region parameter is used to specify on which region the shader is applied. + /** Create a new image filter which fills the given rectangle with pixels + * produced by the given SkShader. If no rectangle is specified, an output + * is produced with the same bounds as the input primitive (even though + * the input primitive's pixels are not used for processing). + * @param s Shader to call for processing. Cannot be NULL. Will be + * ref'ed by the new image filter. + * @param rect Rectangle of output pixels in which to apply the shader. + * If NULL or a given crop edge is not specified, the source + * primitive's bounds are used instead. */ - static SkRectShaderImageFilter* Create(SkShader* s, const SkRect& rect); + /* DEPRECATED */ static SkRectShaderImageFilter* Create(SkShader* s, const SkRect& rect); + static SkRectShaderImageFilter* Create(SkShader* s, const CropRect* rect = NULL); virtual ~SkRectShaderImageFilter(); SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkRectShaderImageFilter) |