Export effects classes with SK_API.
authortfarina@chromium.org <tfarina@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>
Fri, 12 Oct 2012 14:41:39 +0000 (14:41 +0000)
committertfarina@chromium.org <tfarina@chromium.org@2bbb7eff-a529-9590-31e7-b0007b416f81>
Fri, 12 Oct 2012 14:41:39 +0000 (14:41 +0000)
So this works in shared_library build in chromium.

This issue was raised up in the following chromium-dev thread:
https://groups.google.com/a/chromium.org/forum/?hl=en&fromgroups=#!topic/chromium-dev/Z6qzEw8MwVY

R=epoger@google.com,tomhudson@google.com

Review URL: https://codereview.appspot.com/6601065

git-svn-id: http://skia.googlecode.com/svn/trunk@5914 2bbb7eff-a529-9590-31e7-b0007b416f81

28 files changed:
include/effects/Sk1DPathEffect.h
include/effects/Sk2DPathEffect.h
include/effects/SkArithmeticMode.h
include/effects/SkAvoidXfermode.h
include/effects/SkBitmapSource.h
include/effects/SkBlendImageFilter.h
include/effects/SkBlurDrawLooper.h
include/effects/SkBlurImageFilter.h
include/effects/SkBlurMaskFilter.h
include/effects/SkColorFilterImageFilter.h
include/effects/SkColorMatrix.h
include/effects/SkColorMatrixFilter.h
include/effects/SkCornerPathEffect.h
include/effects/SkDashPathEffect.h
include/effects/SkDiscretePathEffect.h
include/effects/SkDrawExtraPathEffect.h
include/effects/SkEmbossMaskFilter.h
include/effects/SkKernel33MaskFilter.h
include/effects/SkLayerDrawLooper.h
include/effects/SkLayerRasterizer.h
include/effects/SkMatrixConvolutionImageFilter.h
include/effects/SkPaintFlagsDrawFilter.h
include/effects/SkPixelXorXfermode.h
include/effects/SkPorterDuff.h
include/effects/SkStippleMaskFilter.h
include/effects/SkTableMaskFilter.h
include/effects/SkTestImageFilters.h
include/effects/SkTransparentShader.h

index 9fad1ef..6624b4b 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef Sk1DPathEffect_DEFINED
 #define Sk1DPathEffect_DEFINED
 
@@ -15,8 +13,8 @@
 
 class SkPathMeasure;
 
-//  This class is not exported to java.
-class Sk1DPathEffect : public SkPathEffect {
+// This class is not exported to java.
+class SK_API Sk1DPathEffect : public SkPathEffect {
 public:
     virtual bool filterPath(SkPath* dst, const SkPath& src, SkStrokeRec*) SK_OVERRIDE;
 
@@ -36,7 +34,7 @@ private:
     typedef SkPathEffect INHERITED;
 };
 
-class SkPath1DPathEffect : public Sk1DPathEffect {
+class SK_API SkPath1DPathEffect : public Sk1DPathEffect {
 public:
     enum Style {
         kTranslate_Style,   // translate the shape to each position
@@ -76,5 +74,4 @@ private:
     typedef Sk1DPathEffect INHERITED;
 };
 
-
 #endif
index 7000755..feb0da6 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef Sk2DPathEffect_DEFINED
 #define Sk2DPathEffect_DEFINED
 
@@ -14,7 +12,7 @@
 #include "SkPathEffect.h"
 #include "SkMatrix.h"
 
-class Sk2DPathEffect : public SkPathEffect {
+class SK_API Sk2DPathEffect : public SkPathEffect {
 public:
     Sk2DPathEffect(const SkMatrix& mat);
 
@@ -58,7 +56,7 @@ private:
     typedef SkPathEffect INHERITED;
 };
 
-class SkLine2DPathEffect : public Sk2DPathEffect {
+class SK_API SkLine2DPathEffect : public Sk2DPathEffect {
 public:
     SkLine2DPathEffect(SkScalar width, const SkMatrix& matrix)
     : Sk2DPathEffect(matrix), fWidth(width) {}
@@ -80,7 +78,7 @@ private:
     typedef Sk2DPathEffect INHERITED;
 };
 
-class SkPath2DPathEffect : public Sk2DPathEffect {
+class SK_API SkPath2DPathEffect : public Sk2DPathEffect {
 public:
     /**
      *  Stamp the specified path to fill the shape, using the matrix to define
@@ -102,5 +100,4 @@ private:
     typedef Sk2DPathEffect INHERITED;
 };
 
-
 #endif
index 70d660f..87da333 100644 (file)
@@ -10,7 +10,7 @@
 
 #include "SkXfermode.h"
 
-class SkArithmeticMode : public SkXfermode {
+class SK_API SkArithmeticMode : public SkXfermode {
 public:
     /**
      *  result = clamp[k1 * src * dst + k2 * src + k3 * dst + k4]
@@ -27,4 +27,3 @@ public:
 };
 
 #endif
-
index 298ce5b..1be2679 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkAvoidXfermode_DEFINED
 #define SkAvoidXfermode_DEFINED
 
@@ -17,7 +15,7 @@
     This xfermode will draw the src everywhere except on top of the specified
     color.
 */
-class SkAvoidXfermode : public SkXfermode {
+class SK_API SkAvoidXfermode : public SkXfermode {
 public:
     enum Mode {
         kAvoidColor_Mode,   //!< draw everywhere except on the opColor
index 5e07e9e..138987e 100644 (file)
@@ -5,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkBitmapSource_DEFINED
 #define SkBitmapSource_DEFINED
 
@@ -30,4 +29,3 @@ private:
 };
 
 #endif
-
index ff528ad..c16186f 100644 (file)
@@ -5,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkBlendImageFilter_DEFINED
 #define SkBlendImageFilter_DEFINED
 
@@ -49,4 +48,3 @@ private:
 };
 
 #endif
-
index 0f400cd..fa730e3 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2008 The Android Open Source Project
  *
index eeafbb9..757fee5 100644 (file)
@@ -5,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkBlurImageFilter_DEFINED
 #define SkBlurImageFilter_DEFINED
 
@@ -34,4 +33,3 @@ private:
 };
 
 #endif
-
index 500e6d6..2ab321a 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkBlurMaskFilter_DEFINED
 #define SkBlurMaskFilter_DEFINED
 
@@ -61,4 +59,3 @@ private:
 };
 
 #endif
-
index 73b3fa9..f519291 100755 (executable)
@@ -12,7 +12,7 @@
 
 class SkColorFilter;
 
-class SkColorFilterImageFilter : public SkSingleInputImageFilter {
+class SK_API SkColorFilterImageFilter : public SkSingleInputImageFilter {
 public:
     SkColorFilterImageFilter(SkColorFilter* cf, SkImageFilter* input = NULL);
     virtual ~SkColorFilterImageFilter();
index a92f588..ff02d9d 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2007 The Android Open Source Project
  *
@@ -6,13 +5,12 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkColorMatrix_DEFINED
 #define SkColorMatrix_DEFINED
 
 #include "SkScalar.h"
 
-class SkColorMatrix {
+class SK_API SkColorMatrix {
 public:
     SkScalar    fMat[20];
 
index 07bd967..005781f 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2007 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkColorMatrixFilter_DEFINED
 #define SkColorMatrixFilter_DEFINED
 
index 6c43b6c..88afea3 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkCornerPathEffect_DEFINED
 #define SkCornerPathEffect_DEFINED
 
@@ -42,4 +40,3 @@ private:
 };
 
 #endif
-
index ddac9cf..0397466 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkDashPathEffect_DEFINED
 #define SkDashPathEffect_DEFINED
 
@@ -65,4 +63,3 @@ private:
 };
 
 #endif
-
index a2934de..6705748 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkDiscretePathEffect_DEFINED
 #define SkDiscretePathEffect_DEFINED
 
@@ -16,7 +14,7 @@
 
     This path effect chops a path into discrete segments, and randomly displaces them.
 */
-class SkDiscretePathEffect : public SkPathEffect {
+class SK_API SkDiscretePathEffect : public SkPathEffect {
 public:
     /** Break the path into segments of segLength length, and randomly move the endpoints
         away from the original path by a maximum of deviation.
@@ -39,4 +37,3 @@ private:
 };
 
 #endif
-
index c7611f0..392a46b 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2008 The Android Open Source Project
  *
@@ -6,10 +5,11 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SK_DRAW_EXTRA_PATH_EFFECT_H
 #define SK_DRAW_EXTRA_PATH_EFFECT_H
+
 class SkAnimator;
+
 void InitializeSkExtraPathEffects(SkAnimator* animator);
-#endif
 
+#endif
index dc5f99e..96c25b2 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkEmbossMaskFilter_DEFINED
 #define SkEmbossMaskFilter_DEFINED
 
@@ -16,7 +14,7 @@
 
     This mask filter creates a 3D emboss look, by specifying a light and blur amount.
 */
-class SkEmbossMaskFilter : public SkMaskFilter {
+class SK_API SkEmbossMaskFilter : public SkMaskFilter {
 public:
     struct Light {
         SkScalar    fDirection[3];  // x,y,z
@@ -48,4 +46,3 @@ private:
 };
 
 #endif
-
index cfe1265..41e73c9 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2008 The Android Open Source Project
  *
@@ -6,13 +5,12 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkKernel33MaskFilter_DEFINED
 #define SkKernel33MaskFilter_DEFINED
 
 #include "SkMaskFilter.h"
 
-class SkKernel33ProcMaskFilter : public SkMaskFilter {
+class SK_API SkKernel33ProcMaskFilter : public SkMaskFilter {
 public:
     SkKernel33ProcMaskFilter(unsigned percent256 = 256)
         : fPercent256(percent256) {}
@@ -35,7 +33,7 @@ private:
 
 ///////////////////////////////////////////////////////////////////////////////
 
-class SkKernel33MaskFilter : public SkKernel33ProcMaskFilter {
+class SK_API SkKernel33MaskFilter : public SkKernel33ProcMaskFilter {
 public:
     SkKernel33MaskFilter(const int coeff[3][3], int shift, int percent256 = 256)
             : SkKernel33ProcMaskFilter(percent256) {
index d347de7..5196af0 100644 (file)
@@ -1,10 +1,10 @@
-
 /*
  * Copyright 2011 Google Inc.
  *
  * Use of this source code is governed by a BSD-style license that can be
  * found in the LICENSE file.
  */
+
 #ifndef SkLayerDrawLooper_DEFINED
 #define SkLayerDrawLooper_DEFINED
 
@@ -133,5 +133,4 @@ private:
     typedef SkDrawLooper INHERITED;
 };
 
-
 #endif
index f3149e6..7a1ef74 100644 (file)
@@ -16,7 +16,7 @@
 
 class SkPaint;
 
-class SkLayerRasterizer : public SkRasterizer {
+class SK_API SkLayerRasterizer : public SkRasterizer {
 public:
             SkLayerRasterizer();
     virtual ~SkLayerRasterizer();
index f6e96f2..f7440cd 100644 (file)
@@ -19,7 +19,7 @@
     effects such as sharpening, blurring, edge detection, etc.
  */
 
-class SkMatrixConvolutionImageFilter : public SkSingleInputImageFilter {
+class SK_API SkMatrixConvolutionImageFilter : public SkSingleInputImageFilter {
 public:
     /*! \enum TileMode */
     enum TileMode {
index 775cb91..fbf1807 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2008 The Android Open Source Project
  *
@@ -6,13 +5,12 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkPaintFlagsDrawFilter_DEFINED
 #define SkPaintFlagsDrawFilter_DEFINED
 
 #include "SkDrawFilter.h"
 
-class SkPaintFlagsDrawFilter : public SkDrawFilter {
+class SK_API SkPaintFlagsDrawFilter : public SkDrawFilter {
 public:
     SkPaintFlagsDrawFilter(uint32_t clearFlags, uint32_t setFlags);
 
@@ -25,4 +23,3 @@ private:
 };
 
 #endif
-
index e991108..53f1210 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2007 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkPixelXorXfermode_DEFINED
 #define SkPixelXorXfermode_DEFINED
 
@@ -17,7 +15,7 @@
     this proc *always* returns an opaque color (alpha == 255). Thus it is
     not really usefull for operating on blended colors.
 */
-class SkPixelXorXfermode : public SkXfermode {
+class SK_API SkPixelXorXfermode : public SkXfermode {
 public:
     SkPixelXorXfermode(SkColor opColor) : fOpColor(opColor) {}
 
index 8308f3c..1bba171 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkPorterDuff_DEFINED
 #define SkPorterDuff_DEFINED
 
@@ -17,7 +15,7 @@ class SkXfermode;
 
 /** DEPRECATED - use SkXfermode::Mode instead
  */
-class SkPorterDuff {
+class SK_API SkPorterDuff {
 public:
     /** List of predefined xfermodes. In general, the algebra for the modes
         uses the following symbols:
@@ -81,4 +79,3 @@ public:
 };
 
 #endif
-
index 9acd5e5..b5d162e 100644 (file)
@@ -11,9 +11,9 @@
 #include "SkMaskFilter.h"
 
 /**
- * Simple MaskFilter that creates a screen door stipple pattern
+ * Simple MaskFilter that creates a screen door stipple pattern.
  */
-class SkStippleMaskFilter : public SkMaskFilter {
+class SK_API SkStippleMaskFilter : public SkMaskFilter {
 public:
     SkStippleMaskFilter() : INHERITED() {
     }
index 656eaba..c407b40 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,7 +5,6 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkTableMaskFilter_DEFINED
 #define SkTableMaskFilter_DEFINED
 
@@ -18,7 +16,7 @@
     Applies a table lookup on each of the alpha values in the mask.
     Helper methods create some common tables (e.g. gamma, clipping)
  */
-class SkTableMaskFilter : public SkMaskFilter {
+class SK_API SkTableMaskFilter : public SkMaskFilter {
 public:
     SkTableMaskFilter();
     SkTableMaskFilter(const uint8_t table[256]);
@@ -64,4 +62,3 @@ private:
 };
 
 #endif
-
index c31a439..5174856 100755 (executable)
@@ -1,11 +1,10 @@
-
 #ifndef _SkTestImageFilters_h
 #define _SkTestImageFilters_h
 
 #include "SkImageFilter.h"
 #include "SkPoint.h"
 
-class SkOffsetImageFilter : public SkImageFilter {
+class SK_API SkOffsetImageFilter : public SkImageFilter {
 public:
     SkOffsetImageFilter(SkScalar dx, SkScalar dy) : INHERITED(0) {
         fOffset.set(dx, dy);
@@ -27,7 +26,7 @@ private:
     typedef SkImageFilter INHERITED;
 };
 
-class SkComposeImageFilter : public SkImageFilter {
+class SK_API SkComposeImageFilter : public SkImageFilter {
 public:
     SkComposeImageFilter(SkImageFilter* outer, SkImageFilter* inner) : INHERITED(2, outer, inner) {}
     virtual ~SkComposeImageFilter();
@@ -47,7 +46,7 @@ private:
 
 #include "SkXfermode.h"
 
-class SkMergeImageFilter : public SkImageFilter {
+class SK_API SkMergeImageFilter : public SkImageFilter {
 public:
     SkMergeImageFilter(SkImageFilter* first, SkImageFilter* second,
                        SkXfermode::Mode = SkXfermode::kSrcOver_Mode);
@@ -82,7 +81,7 @@ private:
 ///////////////////////////////////////////////////////////////////////////////
 
 // Fun mode that scales down (only) and then scales back up to look pixelated
-class SkDownSampleImageFilter : public SkImageFilter {
+class SK_API SkDownSampleImageFilter : public SkImageFilter {
 public:
     SkDownSampleImageFilter(SkScalar scale) : INHERITED(0), fScale(scale) {}
 
index 20bb51a..74187f7 100644 (file)
@@ -1,4 +1,3 @@
-
 /*
  * Copyright 2006 The Android Open Source Project
  *
@@ -6,20 +5,19 @@
  * found in the LICENSE file.
  */
 
-
 #ifndef SkTransparentShader_DEFINED
 #define SkTransparentShader_DEFINED
 
 #include "SkShader.h"
 
-class SkTransparentShader : public SkShader {
+class SK_API SkTransparentShader : public SkShader {
 public:
     SkTransparentShader() {}
 
     virtual uint32_t getFlags() SK_OVERRIDE;
-    virtual bool    setContext( const SkBitmap& device,
-                                const SkPaint& paint,
-                                const SkMatrix& matrix) SK_OVERRIDE;
+    virtual bool    setContext(const SkBitmap& device,
+                               const SkPaint& paint,
+                               const SkMatrix& matrix) SK_OVERRIDE;
     virtual void    shadeSpan(int x, int y, SkPMColor[], int count) SK_OVERRIDE;
     virtual void    shadeSpan16(int x, int y, uint16_t span[], int count) SK_OVERRIDE;
 
@@ -36,4 +34,3 @@ private:
 };
 
 #endif
-