Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(794)

Unified Diff: src/core/SkBitmapProcShader.h

Issue 2195893002: Always return ImageShader, even from SkShader::MakeBitmapShader (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: update serialize-8888 ignore list: skbug.com/5595 Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/core/SkBitmapProcShader.h
diff --git a/src/core/SkBitmapProcShader.h b/src/core/SkBitmapProcShader.h
index 624034851d531ad23c09f2d3329d91a9b3382a9f..c0e6a407ce7e95985e677563327904a911011684 100644
--- a/src/core/SkBitmapProcShader.h
+++ b/src/core/SkBitmapProcShader.h
@@ -4,7 +4,6 @@
* Use of this source code is governed by a BSD-style license that can be
* found in the LICENSE file.
*/
-
#ifndef SkBitmapProcShader_DEFINED
#define SkBitmapProcShader_DEFINED
@@ -14,36 +13,7 @@
struct SkBitmapProcState;
class SkBitmapProvider;
-class SkBitmapProcShader : public SkShader {
-public:
- SkBitmapProcShader(const SkBitmap& src, TileMode tx, TileMode ty,
- const SkMatrix* localMatrix = nullptr);
-
- bool isOpaque() const override;
-
- // SkBitmapProcShader stores bitmap coordinates in a 16bit buffer, as it
- // communicates between its matrix-proc and its sampler-proc. Until we can
- // widen that, we have to reject bitmaps that are larger.
- static bool BitmapIsTooBig(const SkBitmap&);
-
- SK_TO_STRING_OVERRIDE()
- SK_DECLARE_PUBLIC_FLATTENABLE_DESERIALIZATION_PROCS(SkBitmapProcShader)
-
-#if SK_SUPPORT_GPU
- sk_sp<GrFragmentProcessor> asFragmentProcessor(const AsFPArgs&) const override;
-#endif
-
-protected:
- void flatten(SkWriteBuffer&) const override;
- size_t onContextSize(const ContextRec& rec) const override {
- return ContextSize(rec, fRawBitmap.info());
- }
- Context* onCreateContext(const ContextRec&, void* storage) const override;
- bool onIsABitmap(SkBitmap*, SkMatrix*, TileMode*) const override;
-
- SkBitmap fRawBitmap;
- uint8_t fTileModeX, fTileModeY;
-
+class SkBitmapProcLegacyShader : public SkShader {
f(malita) 2016/08/02 13:10:27 This is now just a collection of static private he
private:
friend class SkImageShader;

Powered by Google App Engine
This is Rietveld 408576698