@shopify/react-native-skia 0.1.196 → 0.1.199
Sign up to get free protection for your applications and to get access to all the features.
- package/android/CMakeLists.txt +32 -31
- package/android/cpp/rnskia-android/SkiaOpenGLRenderer.cpp +4 -2
- package/android/cpp/rnskia-android/SkiaOpenGLRenderer.h +3 -0
- package/cpp/api/JsiSkImage.h +1 -1
- package/cpp/api/JsiSkShaderFactory.h +4 -4
- package/cpp/api/JsiSkSurface.h +0 -1
- package/cpp/api/JsiSkSurfaceFactory.h +2 -1
- package/cpp/rnskia/RNSkView.h +20 -40
- package/cpp/rnskia/dom/nodes/JsiShaderNodes.h +2 -2
- package/cpp/rnskia/values/RNSkReadonlyValue.h +6 -7
- package/cpp/skia/include/android/SkCanvasAndroid.h +20 -0
- package/cpp/skia/include/android/SkHeifDecoder.h +43 -0
- package/cpp/skia/include/android/SkSurfaceAndroid.h +50 -0
- package/cpp/skia/include/codec/SkAvifDecoder.h +43 -0
- package/cpp/skia/include/codec/SkBmpDecoder.h +43 -0
- package/cpp/skia/include/codec/SkCodec.h +25 -1
- package/cpp/skia/include/codec/SkGifDecoder.h +43 -0
- package/cpp/skia/include/codec/SkIcoDecoder.h +43 -0
- package/cpp/skia/include/codec/SkJpegDecoder.h +43 -0
- package/cpp/skia/include/codec/SkJpegxlDecoder.h +43 -0
- package/cpp/skia/include/codec/SkPngDecoder.h +43 -0
- package/cpp/skia/include/codec/SkRawDecoder.h +49 -0
- package/cpp/skia/include/codec/SkWbmpDecoder.h +43 -0
- package/cpp/skia/include/codec/SkWebpDecoder.h +43 -0
- package/cpp/skia/include/core/SkBBHFactory.h +5 -1
- package/cpp/skia/include/core/SkBlender.h +0 -2
- package/cpp/skia/include/core/SkCanvas.h +4 -23
- package/cpp/skia/include/core/SkColorFilter.h +14 -1
- package/cpp/skia/include/core/SkColorTable.h +59 -0
- package/cpp/skia/include/core/SkContourMeasure.h +3 -0
- package/cpp/skia/include/core/SkDeferredDisplayList.h +8 -104
- package/cpp/skia/include/core/SkDeferredDisplayListRecorder.h +8 -91
- package/cpp/skia/include/core/SkDrawable.h +5 -2
- package/cpp/skia/include/core/SkGraphics.h +7 -19
- package/cpp/skia/include/core/SkImage.h +157 -249
- package/cpp/skia/include/core/SkImageGenerator.h +0 -31
- package/cpp/skia/include/core/SkMilestone.h +1 -1
- package/cpp/skia/include/core/SkPathMeasure.h +3 -3
- package/cpp/skia/include/core/SkPictureRecorder.h +1 -1
- package/cpp/skia/include/core/SkPoint.h +5 -563
- package/cpp/skia/include/core/SkPoint3.h +1 -0
- package/cpp/skia/include/core/SkPromiseImageTexture.h +4 -30
- package/cpp/skia/include/core/SkRect.h +8 -8
- package/cpp/skia/include/core/SkSamplingOptions.h +4 -2
- package/cpp/skia/include/core/SkScalar.h +1 -1
- package/cpp/skia/include/core/SkSerialProcs.h +5 -1
- package/cpp/skia/include/core/SkShader.h +14 -21
- package/cpp/skia/include/core/SkString.h +2 -0
- package/cpp/skia/include/core/SkSurface.h +169 -701
- package/cpp/skia/include/core/SkSurfaceCharacterization.h +8 -256
- package/cpp/skia/include/core/SkTiledImageUtils.h +97 -0
- package/cpp/skia/include/core/SkTypes.h +4 -2
- package/cpp/skia/include/core/SkYUVAPixmaps.h +0 -5
- package/cpp/skia/include/effects/SkGradientShader.h +10 -1
- package/cpp/skia/include/effects/SkImageFilters.h +62 -37
- package/cpp/skia/include/effects/SkPerlinNoiseShader.h +28 -29
- package/cpp/skia/include/effects/SkRuntimeEffect.h +17 -12
- package/cpp/skia/include/gpu/GrBackendSurface.h +12 -39
- package/cpp/skia/include/gpu/GrBackendSurfaceMutableState.h +6 -0
- package/cpp/skia/include/gpu/GrContextThreadSafeProxy.h +3 -3
- package/cpp/skia/include/gpu/GrDirectContext.h +103 -3
- package/cpp/skia/include/gpu/GrRecordingContext.h +10 -19
- package/cpp/skia/include/gpu/MutableTextureState.h +4 -0
- package/cpp/skia/include/gpu/ganesh/GrExternalTextureGenerator.h +54 -0
- package/cpp/skia/include/gpu/ganesh/SkImageGanesh.h +20 -76
- package/cpp/skia/include/gpu/ganesh/SkSurfaceGanesh.h +217 -0
- package/cpp/skia/include/gpu/ganesh/mtl/SkSurfaceMetal.h +73 -0
- package/cpp/skia/include/gpu/gl/GrGLTypes.h +13 -2
- package/cpp/skia/include/gpu/graphite/BackendSemaphore.h +78 -0
- package/cpp/skia/include/gpu/graphite/BackendTexture.h +1 -0
- package/cpp/skia/include/gpu/graphite/Image.h +277 -0
- package/cpp/skia/include/gpu/graphite/ImageProvider.h +1 -1
- package/cpp/skia/include/gpu/graphite/Recording.h +1 -4
- package/cpp/skia/include/gpu/graphite/Surface.h +81 -0
- package/cpp/skia/include/gpu/graphite/TextureInfo.h +5 -7
- package/cpp/skia/include/gpu/graphite/YUVABackendTextures.h +2 -2
- package/cpp/skia/include/gpu/mock/GrMockTypes.h +23 -8
- package/cpp/skia/include/ports/SkTypeface_fontations.h +21 -0
- package/cpp/skia/include/private/SkGainmapInfo.h +2 -0
- package/cpp/skia/include/private/SkGainmapShader.h +1 -0
- package/cpp/skia/include/private/SkJpegMetadataDecoder.h +19 -1
- package/cpp/skia/include/private/SkPathRef.h +13 -15
- package/cpp/skia/include/private/SkXmp.h +53 -0
- package/cpp/skia/include/private/base/SkFeatures.h +0 -4
- package/cpp/skia/include/private/base/SkFloatingPoint.h +11 -5
- package/cpp/skia/include/private/base/SkPoint_impl.h +569 -0
- package/cpp/skia/include/private/base/SkSpan_impl.h +3 -7
- package/cpp/skia/include/private/base/SkTArray.h +11 -11
- package/cpp/skia/include/private/chromium/GrDeferredDisplayList.h +120 -0
- package/cpp/skia/include/private/chromium/GrDeferredDisplayListRecorder.h +98 -0
- package/cpp/skia/include/private/chromium/GrPromiseImageTexture.h +43 -0
- package/cpp/skia/include/private/chromium/GrSurfaceCharacterization.h +215 -0
- package/cpp/skia/include/private/chromium/GrVkSecondaryCBDrawContext.h +6 -6
- package/cpp/skia/include/private/chromium/SkImageChromium.h +104 -0
- package/cpp/skia/include/private/chromium/Slug.h +7 -3
- package/cpp/skia/include/private/gpu/ganesh/GrContext_Base.h +7 -3
- package/cpp/skia/include/private/gpu/ganesh/GrGLTypesPriv.h +2 -0
- package/cpp/skia/include/private/gpu/ganesh/GrImageContext.h +3 -2
- package/cpp/skia/include/private/gpu/ganesh/GrMtlTypesPriv.h +10 -2
- package/cpp/skia/include/{gpu → private/gpu}/ganesh/GrTextureGenerator.h +2 -13
- package/cpp/skia/include/private/gpu/ganesh/GrTypesPriv.h +1 -1
- package/cpp/skia/include/private/gpu/graphite/DawnTypesPriv.h +7 -0
- package/cpp/skia/include/private/gpu/graphite/MtlGraphiteTypesPriv.h +19 -6
- package/cpp/skia/include/private/gpu/graphite/VulkanGraphiteTypesPriv.h +13 -0
- package/cpp/skia/include/third_party/vulkan/vulkan/vulkan.h +0 -1
- package/cpp/skia/include/third_party/vulkan/vulkan/vulkan_android.h +14 -1
- package/cpp/skia/include/third_party/vulkan/vulkan/vulkan_core.h +999 -79
- package/cpp/skia/modules/skcms/src/Transform_inl.h +36 -236
- package/cpp/skia/modules/skparagraph/include/Paragraph.h +2 -0
- package/cpp/skia/modules/skparagraph/include/ParagraphBuilder.h +16 -0
- package/cpp/skia/modules/skparagraph/include/TextStyle.h +6 -2
- package/cpp/skia/modules/skresources/include/SkResources.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGCircle.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGClipPath.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGContainer.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGDOM.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGDefs.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGEllipse.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFe.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeBlend.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeColorMatrix.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeComposite.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeDisplacementMap.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeFlood.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeGaussianBlur.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeImage.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeLightSource.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeLighting.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeOffset.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFeTurbulence.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGFilter.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGG.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGGradient.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGHiddenContainer.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGImage.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGLine.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGLinearGradient.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGMask.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGNode.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGPath.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGPattern.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGPoly.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGRadialGradient.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGRect.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGRenderContext.h +3 -3
- package/cpp/skia/modules/svg/include/SkSVGSVG.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGShape.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGStop.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGText.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGTransformableNode.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGTypes.h +21 -21
- package/cpp/skia/modules/svg/include/SkSVGUse.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGValue.h +2 -2
- package/cpp/skia/{include/private → src/core}/SkChecksum.h +32 -17
- package/cpp/skia/src/core/SkTHash.h +1 -1
- package/ios/RNSkia-iOS/RNSkMetalCanvasProvider.mm +3 -1
- package/ios/RNSkia-iOS/SkiaMetalRenderer.mm +3 -1
- package/lib/commonjs/renderer/Canvas.js +24 -13
- package/lib/commonjs/renderer/Canvas.js.map +1 -1
- package/lib/commonjs/skia/core/Data.d.ts +2 -2
- package/lib/commonjs/skia/core/Data.js.map +1 -1
- package/lib/commonjs/skia/core/RRect.js +5 -1
- package/lib/commonjs/skia/core/RRect.js.map +1 -1
- package/lib/commonjs/skia/core/Rect.js +32 -6
- package/lib/commonjs/skia/core/Rect.js.map +1 -1
- package/lib/commonjs/skia/types/Color.js.map +1 -1
- package/lib/commonjs/skia/types/JsiInstance.d.ts +2 -4
- package/lib/commonjs/skia/types/JsiInstance.js.map +1 -1
- package/lib/module/renderer/Canvas.js +25 -14
- package/lib/module/renderer/Canvas.js.map +1 -1
- package/lib/module/skia/core/Data.d.ts +2 -2
- package/lib/module/skia/core/Data.js.map +1 -1
- package/lib/module/skia/core/RRect.js +5 -1
- package/lib/module/skia/core/RRect.js.map +1 -1
- package/lib/module/skia/core/Rect.js +32 -6
- package/lib/module/skia/core/Rect.js.map +1 -1
- package/lib/module/skia/types/Color.js.map +1 -1
- package/lib/module/skia/types/JsiInstance.d.ts +2 -4
- package/lib/module/skia/types/JsiInstance.js.map +1 -1
- package/lib/typescript/src/skia/core/Data.d.ts +2 -2
- package/lib/typescript/src/skia/types/JsiInstance.d.ts +2 -4
- package/libs/android/arm64-v8a/libskia.a +0 -0
- package/libs/android/arm64-v8a/libskottie.a +0 -0
- package/libs/android/arm64-v8a/libsksg.a +0 -0
- package/libs/android/arm64-v8a/libsvg.a +0 -0
- package/libs/android/armeabi-v7a/libskia.a +0 -0
- package/libs/android/armeabi-v7a/libskottie.a +0 -0
- package/libs/android/armeabi-v7a/libsksg.a +0 -0
- package/libs/android/armeabi-v7a/libsvg.a +0 -0
- package/libs/android/x86/libskia.a +0 -0
- package/libs/android/x86/libskottie.a +0 -0
- package/libs/android/x86/libsksg.a +0 -0
- package/libs/android/x86/libsvg.a +0 -0
- package/libs/android/x86_64/libskia.a +0 -0
- package/libs/android/x86_64/libskottie.a +0 -0
- package/libs/android/x86_64/libsksg.a +0 -0
- package/libs/android/x86_64/libsvg.a +0 -0
- package/libs/ios/libskia.xcframework/ios-arm64_arm64e/libskia.a +0 -0
- package/libs/ios/libskia.xcframework/ios-arm64_arm64e_x86_64-simulator/libskia.a +0 -0
- package/libs/ios/libskottie.xcframework/ios-arm64_arm64e/libskottie.a +0 -0
- package/libs/ios/libskottie.xcframework/ios-arm64_arm64e_x86_64-simulator/libskottie.a +0 -0
- package/libs/ios/libsksg.xcframework/Info.plist +5 -5
- package/libs/ios/libsksg.xcframework/ios-arm64_arm64e/libsksg.a +0 -0
- package/libs/ios/libsksg.xcframework/ios-arm64_arm64e_x86_64-simulator/libsksg.a +0 -0
- package/libs/ios/libskshaper.xcframework/ios-arm64_arm64e/libskshaper.a +0 -0
- package/libs/ios/libskshaper.xcframework/ios-arm64_arm64e_x86_64-simulator/libskshaper.a +0 -0
- package/libs/ios/libsvg.xcframework/Info.plist +5 -5
- package/libs/ios/libsvg.xcframework/ios-arm64_arm64e/libsvg.a +0 -0
- package/libs/ios/libsvg.xcframework/ios-arm64_arm64e_x86_64-simulator/libsvg.a +0 -0
- package/package.json +3 -4
- package/src/renderer/Canvas.tsx +25 -19
- package/src/skia/core/Data.ts +3 -3
- package/src/skia/core/RRect.tsx +4 -2
- package/src/skia/core/Rect.ts +29 -12
- package/src/skia/types/Color.ts +1 -1
- package/src/skia/types/JsiInstance.ts +2 -5
- package/cpp/skia/include/effects/SkTableColorFilter.h +0 -29
- package/cpp/skia/include/private/SkOpts_spi.h +0 -23
- package/cpp/skia/include/private/SkSpinlock.h +0 -57
- package/cpp/skia/include/private/chromium/GrSlug.h +0 -16
- package/scripts/install-npm.js +0 -33
@@ -12,7 +12,7 @@
|
|
12
12
|
#include "modules/svg/include/SkSVGFe.h"
|
13
13
|
#include "modules/svg/include/SkSVGTypes.h"
|
14
14
|
|
15
|
-
class SkSVGFeColorMatrix final : public SkSVGFe {
|
15
|
+
class SK_API SkSVGFeColorMatrix final : public SkSVGFe {
|
16
16
|
public:
|
17
17
|
static sk_sp<SkSVGFeColorMatrix> Make() {
|
18
18
|
return sk_sp<SkSVGFeColorMatrix>(new SkSVGFeColorMatrix());
|
@@ -12,7 +12,7 @@
|
|
12
12
|
#include "modules/svg/include/SkSVGFe.h"
|
13
13
|
#include "modules/svg/include/SkSVGTypes.h"
|
14
14
|
|
15
|
-
class SkSVGFeComposite final : public SkSVGFe {
|
15
|
+
class SK_API SkSVGFeComposite final : public SkSVGFe {
|
16
16
|
public:
|
17
17
|
static sk_sp<SkSVGFeComposite> Make() {
|
18
18
|
return sk_sp<SkSVGFeComposite>(new SkSVGFeComposite());
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGFe.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGFeFlood : public SkSVGFe {
|
14
|
+
class SK_API SkSVGFeFlood : public SkSVGFe {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGFeFlood> Make() { return sk_sp<SkSVGFeFlood>(new SkSVGFeFlood()); }
|
17
17
|
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGFe.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGFeImage : public SkSVGFe {
|
14
|
+
class SK_API SkSVGFeImage : public SkSVGFe {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGFeImage> Make() { return sk_sp<SkSVGFeImage>(new SkSVGFeImage()); }
|
17
17
|
|
@@ -12,7 +12,7 @@
|
|
12
12
|
#include "modules/svg/include/SkSVGHiddenContainer.h"
|
13
13
|
#include "modules/svg/include/SkSVGTypes.h"
|
14
14
|
|
15
|
-
class SkSVGFeLightSource : public SkSVGHiddenContainer {
|
15
|
+
class SK_API SkSVGFeLightSource : public SkSVGHiddenContainer {
|
16
16
|
public:
|
17
17
|
void appendChild(sk_sp<SkSVGNode>) final {
|
18
18
|
SkDebugf("cannot append child nodes to an SVG light source.\n");
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGFe.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGFeOffset : public SkSVGFe {
|
14
|
+
class SK_API SkSVGFeOffset : public SkSVGFe {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGFeOffset> Make() { return sk_sp<SkSVGFeOffset>(new SkSVGFeOffset()); }
|
17
17
|
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGFe.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGFeTurbulence : public SkSVGFe {
|
14
|
+
class SK_API SkSVGFeTurbulence : public SkSVGFe {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGFeTurbulence> Make() {
|
17
17
|
return sk_sp<SkSVGFeTurbulence>(new SkSVGFeTurbulence());
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGHiddenContainer.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGFilter final : public SkSVGHiddenContainer {
|
14
|
+
class SK_API SkSVGFilter final : public SkSVGHiddenContainer {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGFilter> Make() { return sk_sp<SkSVGFilter>(new SkSVGFilter()); }
|
17
17
|
|
@@ -16,7 +16,7 @@ class SkMatrix;
|
|
16
16
|
class SkSVGRenderContext;
|
17
17
|
class SkSVGStop;
|
18
18
|
|
19
|
-
class SkSVGGradient : public SkSVGHiddenContainer {
|
19
|
+
class SK_API SkSVGGradient : public SkSVGHiddenContainer {
|
20
20
|
public:
|
21
21
|
SVG_ATTR(Href, SkSVGIRI, SkSVGIRI())
|
22
22
|
SVG_ATTR(GradientTransform, SkSVGTransformType, SkSVGTransformType(SkMatrix::I()))
|
@@ -15,7 +15,7 @@ namespace skresources {
|
|
15
15
|
class ResourceProvider;
|
16
16
|
}
|
17
17
|
|
18
|
-
class SkSVGImage final : public SkSVGTransformableNode {
|
18
|
+
class SK_API SkSVGImage final : public SkSVGTransformableNode {
|
19
19
|
public:
|
20
20
|
static sk_sp<SkSVGImage> Make() {
|
21
21
|
return sk_sp<SkSVGImage>(new SkSVGImage());
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGGradient.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGLinearGradient final : public SkSVGGradient {
|
14
|
+
class SK_API SkSVGLinearGradient final : public SkSVGGradient {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGLinearGradient> Make() {
|
17
17
|
return sk_sp<SkSVGLinearGradient>(new SkSVGLinearGradient());
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGHiddenContainer.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGMask final : public SkSVGHiddenContainer {
|
14
|
+
class SK_API SkSVGMask final : public SkSVGHiddenContainer {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGMask> Make() {
|
17
17
|
return sk_sp<SkSVGMask>(new SkSVGMask());
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "include/core/SkPath.h"
|
12
12
|
#include "modules/svg/include/SkSVGShape.h"
|
13
13
|
|
14
|
-
class SkSVGPath final : public SkSVGShape {
|
14
|
+
class SK_API SkSVGPath final : public SkSVGShape {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGPath> Make() { return sk_sp<SkSVGPath>(new SkSVGPath()); }
|
17
17
|
|
@@ -13,7 +13,7 @@
|
|
13
13
|
|
14
14
|
class SkSVGRenderContext;
|
15
15
|
|
16
|
-
class SkSVGPattern final : public SkSVGHiddenContainer {
|
16
|
+
class SK_API SkSVGPattern final : public SkSVGHiddenContainer {
|
17
17
|
public:
|
18
18
|
static sk_sp<SkSVGPattern> Make() {
|
19
19
|
return sk_sp<SkSVGPattern>(new SkSVGPattern());
|
@@ -12,7 +12,7 @@
|
|
12
12
|
#include "modules/svg/include/SkSVGShape.h"
|
13
13
|
|
14
14
|
// Handles <polygon> and <polyline> elements.
|
15
|
-
class SkSVGPoly final : public SkSVGShape {
|
15
|
+
class SK_API SkSVGPoly final : public SkSVGShape {
|
16
16
|
public:
|
17
17
|
static sk_sp<SkSVGPoly> MakePolygon() {
|
18
18
|
return sk_sp<SkSVGPoly>(new SkSVGPoly(SkSVGTag::kPolygon));
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "modules/svg/include/SkSVGGradient.h"
|
12
12
|
#include "modules/svg/include/SkSVGTypes.h"
|
13
13
|
|
14
|
-
class SkSVGRadialGradient final : public SkSVGGradient {
|
14
|
+
class SK_API SkSVGRadialGradient final : public SkSVGGradient {
|
15
15
|
public:
|
16
16
|
static sk_sp<SkSVGRadialGradient> Make() {
|
17
17
|
return sk_sp<SkSVGRadialGradient>(new SkSVGRadialGradient());
|
@@ -24,7 +24,7 @@
|
|
24
24
|
class SkCanvas;
|
25
25
|
class SkSVGLength;
|
26
26
|
|
27
|
-
class SkSVGLengthContext {
|
27
|
+
class SK_API SkSVGLengthContext {
|
28
28
|
public:
|
29
29
|
SkSVGLengthContext(const SkSize& viewport, SkScalar dpi = 90)
|
30
30
|
: fViewport(viewport), fDPI(dpi) {}
|
@@ -47,7 +47,7 @@ private:
|
|
47
47
|
SkScalar fDPI;
|
48
48
|
};
|
49
49
|
|
50
|
-
struct SkSVGPresentationContext {
|
50
|
+
struct SK_API SkSVGPresentationContext {
|
51
51
|
SkSVGPresentationContext();
|
52
52
|
SkSVGPresentationContext(const SkSVGPresentationContext&) = default;
|
53
53
|
SkSVGPresentationContext& operator=(const SkSVGPresentationContext&) = default;
|
@@ -58,7 +58,7 @@ struct SkSVGPresentationContext {
|
|
58
58
|
SkSVGPresentationAttributes fInherited;
|
59
59
|
};
|
60
60
|
|
61
|
-
class SkSVGRenderContext {
|
61
|
+
class SK_API SkSVGRenderContext {
|
62
62
|
public:
|
63
63
|
// Captures data required for object bounding box resolution.
|
64
64
|
struct OBBScope {
|
@@ -13,7 +13,7 @@
|
|
13
13
|
#include "modules/svg/include/SkSVGTransformableNode.h"
|
14
14
|
#include "modules/svg/include/SkSVGTypes.h"
|
15
15
|
|
16
|
-
class SkSVGTextContext;
|
16
|
+
class SK_API SkSVGTextContext;
|
17
17
|
|
18
18
|
// Base class for text-rendering nodes.
|
19
19
|
class SkSVGTextFragment : public SkSVGTransformableNode {
|
@@ -11,7 +11,7 @@
|
|
11
11
|
#include "include/core/SkMatrix.h"
|
12
12
|
#include "modules/svg/include/SkSVGNode.h"
|
13
13
|
|
14
|
-
class SkSVGTransformableNode : public SkSVGNode {
|
14
|
+
class SK_API SkSVGTransformableNode : public SkSVGNode {
|
15
15
|
public:
|
16
16
|
void setTransform(const SkSVGTransformType& t) { fTransform = t; }
|
17
17
|
|
@@ -113,7 +113,7 @@ private:
|
|
113
113
|
std::optional<T> fValue;
|
114
114
|
};
|
115
115
|
|
116
|
-
class SkSVGLength {
|
116
|
+
class SK_API SkSVGLength {
|
117
117
|
public:
|
118
118
|
enum class Unit {
|
119
119
|
kUnknown,
|
@@ -149,7 +149,7 @@ private:
|
|
149
149
|
};
|
150
150
|
|
151
151
|
// https://www.w3.org/TR/SVG11/linking.html#IRIReference
|
152
|
-
class SkSVGIRI {
|
152
|
+
class SK_API SkSVGIRI {
|
153
153
|
public:
|
154
154
|
enum class Type {
|
155
155
|
kLocal,
|
@@ -174,7 +174,7 @@ private:
|
|
174
174
|
};
|
175
175
|
|
176
176
|
// https://www.w3.org/TR/SVG11/types.html#InterfaceSVGColor
|
177
|
-
class SkSVGColor {
|
177
|
+
class SK_API SkSVGColor {
|
178
178
|
public:
|
179
179
|
enum class Type {
|
180
180
|
kCurrentColor,
|
@@ -221,7 +221,7 @@ private:
|
|
221
221
|
sk_sp<RefCntVars> fVars;
|
222
222
|
};
|
223
223
|
|
224
|
-
class SkSVGPaint {
|
224
|
+
class SK_API SkSVGPaint {
|
225
225
|
public:
|
226
226
|
enum class Type {
|
227
227
|
kNone,
|
@@ -261,7 +261,7 @@ private:
|
|
261
261
|
};
|
262
262
|
|
263
263
|
// <funciri> | none (used for clip/mask/filter properties)
|
264
|
-
class SkSVGFuncIRI {
|
264
|
+
class SK_API SkSVGFuncIRI {
|
265
265
|
public:
|
266
266
|
enum class Type {
|
267
267
|
kNone,
|
@@ -291,7 +291,7 @@ enum class SkSVGLineCap {
|
|
291
291
|
kSquare,
|
292
292
|
};
|
293
293
|
|
294
|
-
class SkSVGLineJoin {
|
294
|
+
class SK_API SkSVGLineJoin {
|
295
295
|
public:
|
296
296
|
enum class Type {
|
297
297
|
kMiter,
|
@@ -315,7 +315,7 @@ private:
|
|
315
315
|
Type fType;
|
316
316
|
};
|
317
317
|
|
318
|
-
class SkSVGSpreadMethod {
|
318
|
+
class SK_API SkSVGSpreadMethod {
|
319
319
|
public:
|
320
320
|
// These values must match Skia's SkShader::TileMode enum.
|
321
321
|
enum class Type {
|
@@ -339,7 +339,7 @@ private:
|
|
339
339
|
Type fType;
|
340
340
|
};
|
341
341
|
|
342
|
-
class SkSVGFillRule {
|
342
|
+
class SK_API SkSVGFillRule {
|
343
343
|
public:
|
344
344
|
enum class Type {
|
345
345
|
kNonZero,
|
@@ -367,7 +367,7 @@ private:
|
|
367
367
|
Type fType;
|
368
368
|
};
|
369
369
|
|
370
|
-
class SkSVGVisibility {
|
370
|
+
class SK_API SkSVGVisibility {
|
371
371
|
public:
|
372
372
|
enum class Type {
|
373
373
|
kVisible,
|
@@ -391,7 +391,7 @@ private:
|
|
391
391
|
Type fType;
|
392
392
|
};
|
393
393
|
|
394
|
-
class SkSVGDashArray {
|
394
|
+
class SK_API SkSVGDashArray {
|
395
395
|
public:
|
396
396
|
enum class Type {
|
397
397
|
kNone,
|
@@ -422,7 +422,7 @@ private:
|
|
422
422
|
std::vector<SkSVGLength> fDashArray;
|
423
423
|
};
|
424
424
|
|
425
|
-
class SkSVGStopColor {
|
425
|
+
class SK_API SkSVGStopColor {
|
426
426
|
public:
|
427
427
|
enum class Type {
|
428
428
|
kColor,
|
@@ -451,7 +451,7 @@ private:
|
|
451
451
|
SkSVGColorType fColor;
|
452
452
|
};
|
453
453
|
|
454
|
-
class SkSVGObjectBoundingBoxUnits {
|
454
|
+
class SK_API SkSVGObjectBoundingBoxUnits {
|
455
455
|
public:
|
456
456
|
enum class Type {
|
457
457
|
kUserSpaceOnUse,
|
@@ -474,7 +474,7 @@ private:
|
|
474
474
|
Type fType;
|
475
475
|
};
|
476
476
|
|
477
|
-
class SkSVGFontFamily {
|
477
|
+
class SK_API SkSVGFontFamily {
|
478
478
|
public:
|
479
479
|
enum class Type {
|
480
480
|
kFamily,
|
@@ -500,7 +500,7 @@ private:
|
|
500
500
|
SkString fFamily;
|
501
501
|
};
|
502
502
|
|
503
|
-
class SkSVGFontStyle {
|
503
|
+
class SK_API SkSVGFontStyle {
|
504
504
|
public:
|
505
505
|
enum class Type {
|
506
506
|
kNormal,
|
@@ -523,7 +523,7 @@ private:
|
|
523
523
|
Type fType;
|
524
524
|
};
|
525
525
|
|
526
|
-
class SkSVGFontSize {
|
526
|
+
class SK_API SkSVGFontSize {
|
527
527
|
public:
|
528
528
|
enum class Type {
|
529
529
|
kLength,
|
@@ -549,7 +549,7 @@ private:
|
|
549
549
|
SkSVGLength fSize;
|
550
550
|
};
|
551
551
|
|
552
|
-
class SkSVGFontWeight {
|
552
|
+
class SK_API SkSVGFontWeight {
|
553
553
|
public:
|
554
554
|
enum class Type {
|
555
555
|
k100,
|
@@ -582,7 +582,7 @@ private:
|
|
582
582
|
Type fType;
|
583
583
|
};
|
584
584
|
|
585
|
-
struct SkSVGPreserveAspectRatio {
|
585
|
+
struct SK_API SkSVGPreserveAspectRatio {
|
586
586
|
enum Align : uint8_t {
|
587
587
|
// These values are chosen such that bits [0,1] encode X alignment, and
|
588
588
|
// bits [2,3] encode Y alignment.
|
@@ -608,7 +608,7 @@ struct SkSVGPreserveAspectRatio {
|
|
608
608
|
Scale fScale = kMeet;
|
609
609
|
};
|
610
610
|
|
611
|
-
class SkSVGTextAnchor {
|
611
|
+
class SK_API SkSVGTextAnchor {
|
612
612
|
public:
|
613
613
|
enum class Type {
|
614
614
|
kStart,
|
@@ -632,7 +632,7 @@ private:
|
|
632
632
|
};
|
633
633
|
|
634
634
|
// https://www.w3.org/TR/SVG11/filters.html#FilterPrimitiveInAttribute
|
635
|
-
class SkSVGFeInputType {
|
635
|
+
class SK_API SkSVGFeInputType {
|
636
636
|
public:
|
637
637
|
enum class Type {
|
638
638
|
kSourceGraphic,
|
@@ -685,7 +685,7 @@ enum class SkSVGFeCompositeOperator {
|
|
685
685
|
kArithmetic,
|
686
686
|
};
|
687
687
|
|
688
|
-
class SkSVGFeTurbulenceBaseFrequency {
|
688
|
+
class SK_API SkSVGFeTurbulenceBaseFrequency {
|
689
689
|
public:
|
690
690
|
SkSVGFeTurbulenceBaseFrequency() : fFreqX(0), fFreqY(0) {}
|
691
691
|
SkSVGFeTurbulenceBaseFrequency(SkSVGNumberType freqX, SkSVGNumberType freqY)
|
@@ -699,7 +699,7 @@ private:
|
|
699
699
|
SkSVGNumberType fFreqY;
|
700
700
|
};
|
701
701
|
|
702
|
-
struct SkSVGFeTurbulenceType {
|
702
|
+
struct SK_API SkSVGFeTurbulenceType {
|
703
703
|
enum Type {
|
704
704
|
kFractalNoise,
|
705
705
|
kTurbulence,
|
@@ -15,7 +15,7 @@
|
|
15
15
|
* Implements support for <use> (reference) elements.
|
16
16
|
* (https://www.w3.org/TR/SVG11/struct.html#UseElement)
|
17
17
|
*/
|
18
|
-
class SkSVGUse final : public SkSVGTransformableNode {
|
18
|
+
class SK_API SkSVGUse final : public SkSVGTransformableNode {
|
19
19
|
public:
|
20
20
|
static sk_sp<SkSVGUse> Make() { return sk_sp<SkSVGUse>(new SkSVGUse()); }
|
21
21
|
|
@@ -15,7 +15,7 @@
|
|
15
15
|
#include "include/private/base/SkNoncopyable.h"
|
16
16
|
#include "modules/svg/include/SkSVGTypes.h"
|
17
17
|
|
18
|
-
class SkSVGValue : public SkNoncopyable {
|
18
|
+
class SK_API SkSVGValue : public SkNoncopyable {
|
19
19
|
public:
|
20
20
|
enum class Type {
|
21
21
|
kColor,
|
@@ -47,7 +47,7 @@ private:
|
|
47
47
|
};
|
48
48
|
|
49
49
|
template <typename T, SkSVGValue::Type ValueType>
|
50
|
-
class SkSVGWrapperValue final : public SkSVGValue {
|
50
|
+
class SK_API SkSVGWrapperValue final : public SkSVGValue {
|
51
51
|
public:
|
52
52
|
static constexpr Type TYPE = ValueType;
|
53
53
|
|
@@ -10,27 +10,23 @@
|
|
10
10
|
|
11
11
|
#include "include/core/SkString.h"
|
12
12
|
#include "include/core/SkTypes.h"
|
13
|
-
#include "include/private/
|
14
|
-
#include "include/private/base/SkTLogic.h"
|
13
|
+
#include "include/private/base/SkAPI.h"
|
15
14
|
|
16
15
|
#include <string>
|
17
16
|
#include <string_view>
|
18
17
|
#include <type_traits>
|
19
18
|
|
20
|
-
|
21
|
-
|
22
|
-
|
23
|
-
|
24
|
-
SkChecksum(const SkChecksum&) = delete;
|
25
|
-
SkChecksum& operator=(const SkChecksum&) = delete;
|
26
|
-
|
19
|
+
/**
|
20
|
+
* Our hash functions are exposed as SK_SPI (e.g. SkParagraph)
|
21
|
+
*/
|
22
|
+
namespace SkChecksum {
|
27
23
|
/**
|
28
24
|
* uint32_t -> uint32_t hash, useful for when you're about to truncate this hash but you
|
29
25
|
* suspect its low bits aren't well mixed.
|
30
26
|
*
|
31
27
|
* This is the Murmur3 finalizer.
|
32
28
|
*/
|
33
|
-
static uint32_t Mix(uint32_t hash) {
|
29
|
+
static inline uint32_t Mix(uint32_t hash) {
|
34
30
|
hash ^= hash >> 16;
|
35
31
|
hash *= 0x85ebca6b;
|
36
32
|
hash ^= hash >> 13;
|
@@ -45,13 +41,32 @@ public:
|
|
45
41
|
*
|
46
42
|
* This version is 2-lines cheaper than Mix, but seems to be sufficient for the font cache.
|
47
43
|
*/
|
48
|
-
static uint32_t CheapMix(uint32_t hash) {
|
44
|
+
static inline uint32_t CheapMix(uint32_t hash) {
|
49
45
|
hash ^= hash >> 16;
|
50
46
|
hash *= 0x85ebca6b;
|
51
47
|
hash ^= hash >> 16;
|
52
48
|
return hash;
|
53
49
|
}
|
54
|
-
|
50
|
+
|
51
|
+
/**
|
52
|
+
* This is a fast, high-quality 32-bit hash. We make no guarantees about this remaining stable
|
53
|
+
* over time, or being consistent across devices.
|
54
|
+
*
|
55
|
+
* For now, this is a 64-bit wyhash, truncated to 32-bits.
|
56
|
+
* See: https://github.com/wangyi-fudan/wyhash
|
57
|
+
*/
|
58
|
+
uint32_t SK_SPI Hash32(const void* data, size_t bytes, uint32_t seed = 0);
|
59
|
+
|
60
|
+
/**
|
61
|
+
* This is a fast, high-quality 64-bit hash. We make no guarantees about this remaining stable
|
62
|
+
* over time, or being consistent across devices.
|
63
|
+
*
|
64
|
+
* For now, this is a 64-bit wyhash.
|
65
|
+
* See: https://github.com/wangyi-fudan/wyhash
|
66
|
+
*/
|
67
|
+
uint64_t SK_SPI Hash64(const void* data, size_t bytes, uint64_t seed = 0);
|
68
|
+
|
69
|
+
} // namespace SkChecksum
|
55
70
|
|
56
71
|
// SkGoodHash should usually be your first choice in hashing data.
|
57
72
|
// It should be both reasonably fast and high quality.
|
@@ -65,19 +80,19 @@ struct SkGoodHash {
|
|
65
80
|
template <typename K>
|
66
81
|
std::enable_if_t<std::has_unique_object_representations<K>::value && sizeof(K) != 4, uint32_t>
|
67
82
|
operator()(const K& k) const {
|
68
|
-
return
|
83
|
+
return SkChecksum::Hash32(&k, sizeof(K));
|
69
84
|
}
|
70
85
|
|
71
86
|
uint32_t operator()(const SkString& k) const {
|
72
|
-
return
|
87
|
+
return SkChecksum::Hash32(k.c_str(), k.size());
|
73
88
|
}
|
74
89
|
|
75
90
|
uint32_t operator()(const std::string& k) const {
|
76
|
-
return
|
91
|
+
return SkChecksum::Hash32(k.c_str(), k.size());
|
77
92
|
}
|
78
93
|
|
79
94
|
uint32_t operator()(std::string_view k) const {
|
80
|
-
return
|
95
|
+
return SkChecksum::Hash32(k.data(), k.size());
|
81
96
|
}
|
82
97
|
};
|
83
98
|
|
@@ -95,7 +110,7 @@ struct SkGoodHash {
|
|
95
110
|
template <typename K>
|
96
111
|
struct SkForceDirectHash {
|
97
112
|
uint32_t operator()(const K& k) const {
|
98
|
-
return
|
113
|
+
return SkChecksum::Hash32(&k, sizeof(K));
|
99
114
|
}
|
100
115
|
};
|
101
116
|
|