@shopify/react-native-skia 0.1.158 → 0.1.160
Sign up to get free protection for your applications and to get access to all the features.
- package/android/CMakeLists.txt +35 -11
- package/android/build.gradle +21 -25
- package/android/cpp/jni/JniLoad.cpp +2 -0
- package/android/cpp/jni/include/JniSkiaDomView.h +89 -0
- package/android/cpp/rnskia-android/SkiaOpenGLRenderer.cpp +4 -3
- package/android/cpp/rnskia-android/SkiaOpenGLRenderer.h +4 -3
- package/android/src/main/java/com/shopify/reactnative/skia/RNSkiaPackage.java +2 -1
- package/android/src/main/java/com/shopify/reactnative/skia/SkiaDomView.java +45 -0
- package/android/src/main/java/com/shopify/reactnative/skia/SkiaDomViewManager.java +64 -0
- package/cpp/api/JsiSkHostObjects.h +6 -0
- package/cpp/api/JsiSkImageFilterFactory.h +1 -1
- package/cpp/api/JsiSkPaint.h +9 -2
- package/cpp/api/JsiSkPath.h +1 -0
- package/cpp/api/JsiSkRuntimeEffect.h +36 -36
- package/cpp/jsi/JsiHostObject.cpp +16 -28
- package/cpp/jsi/JsiHostObject.h +127 -7
- package/cpp/jsi/JsiValue.cpp +346 -0
- package/cpp/jsi/JsiValue.h +222 -0
- package/cpp/jsi/JsiValueWrapper.h +33 -5
- package/cpp/rnskia/RNSkDomView.cpp +222 -0
- package/cpp/rnskia/RNSkDomView.h +140 -0
- package/cpp/rnskia/RNSkJsView.cpp +0 -4
- package/cpp/rnskia/RNSkJsView.h +6 -4
- package/cpp/rnskia/RNSkManager.cpp +7 -0
- package/cpp/rnskia/RNSkPictureView.h +5 -8
- package/cpp/rnskia/RNSkView.h +113 -5
- package/cpp/rnskia/dom/JsiDomApi.h +167 -0
- package/cpp/rnskia/dom/base/BaseNodeProp.h +72 -0
- package/cpp/rnskia/dom/base/DerivedNodeProp.h +187 -0
- package/cpp/rnskia/dom/base/DrawingContext.cpp +227 -0
- package/cpp/rnskia/dom/base/DrawingContext.h +136 -0
- package/cpp/rnskia/dom/base/JsiDependencyManager.h +293 -0
- package/cpp/rnskia/dom/base/JsiDomDeclarationNode.h +176 -0
- package/cpp/rnskia/dom/base/JsiDomDrawingNode.h +50 -0
- package/cpp/rnskia/dom/base/JsiDomNode.h +384 -0
- package/cpp/rnskia/dom/base/JsiDomRenderNode.h +267 -0
- package/cpp/rnskia/dom/base/NodeProp.h +130 -0
- package/cpp/rnskia/dom/base/NodePropsContainer.h +119 -0
- package/cpp/rnskia/dom/nodes/JsiBackdropFilterNode.h +38 -0
- package/cpp/rnskia/dom/nodes/JsiBlendNode.h +112 -0
- package/cpp/rnskia/dom/nodes/JsiBlurMaskNode.h +78 -0
- package/cpp/rnskia/dom/nodes/JsiBoxNode.h +104 -0
- package/cpp/rnskia/dom/nodes/JsiBoxShadowNode.h +33 -0
- package/cpp/rnskia/dom/nodes/JsiCircleNode.h +38 -0
- package/cpp/rnskia/dom/nodes/JsiColorFilterNodes.h +192 -0
- package/cpp/rnskia/dom/nodes/JsiCustomDrawingNode.h +123 -0
- package/cpp/rnskia/dom/nodes/JsiDiffRectNode.h +42 -0
- package/cpp/rnskia/dom/nodes/JsiFillNode.h +22 -0
- package/cpp/rnskia/dom/nodes/JsiGlyphsNode.h +56 -0
- package/cpp/rnskia/dom/nodes/JsiGroupNode.h +26 -0
- package/cpp/rnskia/dom/nodes/JsiImageFilterNodes.h +415 -0
- package/cpp/rnskia/dom/nodes/JsiImageNode.h +34 -0
- package/cpp/rnskia/dom/nodes/JsiImageSvgNode.h +44 -0
- package/cpp/rnskia/dom/nodes/JsiLayerNode.h +64 -0
- package/cpp/rnskia/dom/nodes/JsiLineNode.h +43 -0
- package/cpp/rnskia/dom/nodes/JsiOvalNode.h +34 -0
- package/cpp/rnskia/dom/nodes/JsiPaintNode.h +79 -0
- package/cpp/rnskia/dom/nodes/JsiPatchNode.h +54 -0
- package/cpp/rnskia/dom/nodes/JsiPathEffectNodes.h +315 -0
- package/cpp/rnskia/dom/nodes/JsiPathNode.h +181 -0
- package/cpp/rnskia/dom/nodes/JsiPictureNode.h +32 -0
- package/cpp/rnskia/dom/nodes/JsiPointsNode.h +51 -0
- package/cpp/rnskia/dom/nodes/JsiRRectNode.h +34 -0
- package/cpp/rnskia/dom/nodes/JsiRectNode.h +34 -0
- package/cpp/rnskia/dom/nodes/JsiShaderNodes.h +517 -0
- package/cpp/rnskia/dom/nodes/JsiTextBlobNode.h +47 -0
- package/cpp/rnskia/dom/nodes/JsiTextNode.h +54 -0
- package/cpp/rnskia/dom/nodes/JsiTextPathNode.h +32 -0
- package/cpp/rnskia/dom/nodes/JsiVerticesNode.h +43 -0
- package/cpp/rnskia/dom/props/BezierProps.h +63 -0
- package/cpp/rnskia/dom/props/BlendModeProp.h +101 -0
- package/cpp/rnskia/dom/props/BoxShadowProps.h +62 -0
- package/cpp/rnskia/dom/props/CircleProp.h +46 -0
- package/cpp/rnskia/dom/props/ClipProp.h +62 -0
- package/cpp/rnskia/dom/props/ColorProp.h +80 -0
- package/cpp/rnskia/dom/props/DrawingProp.h +33 -0
- package/cpp/rnskia/dom/props/FontProp.h +34 -0
- package/cpp/rnskia/dom/props/GlyphsProp.h +53 -0
- package/cpp/rnskia/dom/props/ImageProps.h +173 -0
- package/cpp/rnskia/dom/props/LayerProp.h +50 -0
- package/cpp/rnskia/dom/props/MatrixProp.h +33 -0
- package/cpp/rnskia/dom/props/NumbersProp.h +63 -0
- package/cpp/rnskia/dom/props/PaintProps.h +171 -0
- package/cpp/rnskia/dom/props/PathProp.h +55 -0
- package/cpp/rnskia/dom/props/PictureProp.h +38 -0
- package/cpp/rnskia/dom/props/PointProp.h +72 -0
- package/cpp/rnskia/dom/props/PointsProp.h +83 -0
- package/cpp/rnskia/dom/props/RRectProp.h +134 -0
- package/cpp/rnskia/dom/props/RadiusProp.h +43 -0
- package/cpp/rnskia/dom/props/RectProp.h +118 -0
- package/cpp/rnskia/dom/props/StrokeProps.h +75 -0
- package/cpp/rnskia/dom/props/SvgProp.h +37 -0
- package/cpp/rnskia/dom/props/TextBlobProp.h +128 -0
- package/cpp/rnskia/dom/props/TileModeProp.h +50 -0
- package/cpp/rnskia/dom/props/TransformProp.h +80 -0
- package/cpp/rnskia/dom/props/TransformsProps.h +68 -0
- package/cpp/rnskia/dom/props/UniformsProp.h +194 -0
- package/cpp/rnskia/dom/props/VertexModeProp.h +47 -0
- package/cpp/rnskia/dom/props/VerticesProps.h +67 -0
- package/cpp/rnskia/values/RNSkReadonlyValue.h +13 -4
- package/cpp/skia/include/android/SkAndroidFrameworkUtils.h +35 -1
- package/cpp/skia/include/codec/SkAndroidCodec.h +17 -1
- package/cpp/skia/include/codec/SkCodec.h +8 -5
- package/cpp/skia/include/core/SkAnnotation.h +2 -0
- package/cpp/skia/include/core/SkBitmap.h +52 -1
- package/cpp/skia/include/core/SkBlendMode.h +2 -0
- package/cpp/skia/include/core/SkCanvas.h +52 -31
- package/cpp/skia/include/core/SkCapabilities.h +44 -0
- package/cpp/skia/include/core/SkColor.h +7 -0
- package/cpp/skia/include/core/SkColorFilter.h +37 -0
- package/cpp/skia/include/core/SkColorSpace.h +1 -1
- package/cpp/skia/include/core/SkFont.h +4 -0
- package/cpp/skia/include/core/SkFontMgr.h +3 -0
- package/cpp/skia/include/core/SkGraphics.h +9 -0
- package/cpp/skia/include/core/SkImage.h +77 -17
- package/cpp/skia/include/core/SkImageEncoder.h +5 -3
- package/cpp/skia/include/core/SkImageGenerator.h +27 -17
- package/cpp/skia/include/core/SkM44.h +1 -0
- package/cpp/skia/include/core/SkMesh.h +120 -34
- package/cpp/skia/include/core/SkMilestone.h +1 -1
- package/cpp/skia/include/core/SkOverdrawCanvas.h +2 -1
- package/cpp/skia/include/core/SkPaint.h +15 -2
- package/cpp/skia/include/core/SkPath.h +4 -0
- package/cpp/skia/include/core/SkPathBuilder.h +1 -1
- package/cpp/skia/include/core/SkPicture.h +0 -3
- package/cpp/skia/include/core/SkPictureRecorder.h +0 -2
- package/cpp/skia/include/core/SkPixmap.h +19 -0
- package/cpp/skia/include/core/SkRasterHandleAllocator.h +3 -1
- package/cpp/skia/include/core/SkRect.h +11 -4
- package/cpp/skia/include/core/SkRefCnt.h +13 -1
- package/cpp/skia/include/core/SkRegion.h +6 -0
- package/cpp/skia/include/core/SkSamplingOptions.h +8 -6
- package/cpp/skia/include/core/SkScalar.h +6 -25
- package/cpp/skia/include/core/SkShader.h +20 -12
- package/cpp/skia/include/core/SkSpan.h +51 -19
- package/cpp/skia/include/core/SkStream.h +2 -2
- package/cpp/skia/include/core/SkString.h +11 -3
- package/cpp/skia/include/core/SkSurface.h +85 -8
- package/cpp/skia/include/core/SkTextBlob.h +5 -2
- package/cpp/skia/include/core/SkTypes.h +11 -10
- package/cpp/skia/include/docs/SkPDFDocument.h +0 -5
- package/cpp/skia/include/effects/Sk1DPathEffect.h +6 -1
- package/cpp/skia/include/effects/Sk2DPathEffect.h +4 -1
- package/cpp/skia/include/effects/SkColorMatrix.h +1 -0
- package/cpp/skia/include/effects/SkColorMatrixFilter.h +5 -8
- package/cpp/skia/include/effects/SkCornerPathEffect.h +5 -1
- package/cpp/skia/include/effects/SkDashPathEffect.h +5 -1
- package/cpp/skia/include/effects/SkGradientShader.h +68 -38
- package/cpp/skia/include/effects/SkHighContrastFilter.h +5 -1
- package/cpp/skia/include/effects/SkImageFilters.h +5 -4
- package/cpp/skia/include/effects/SkLumaColorFilter.h +4 -1
- package/cpp/skia/include/effects/SkOpPathEffect.h +6 -2
- package/cpp/skia/include/effects/SkOverdrawColorFilter.h +5 -2
- package/cpp/skia/include/effects/SkRuntimeEffect.h +54 -62
- package/cpp/skia/include/effects/SkShaderMaskFilter.h +3 -1
- package/cpp/skia/include/effects/SkTableColorFilter.h +8 -21
- package/cpp/skia/include/effects/SkTableMaskFilter.h +5 -1
- package/cpp/skia/include/effects/SkTrimPathEffect.h +5 -1
- package/cpp/skia/include/encode/SkEncoder.h +17 -0
- package/cpp/skia/include/encode/SkWebpEncoder.h +17 -0
- package/cpp/skia/include/gpu/GpuTypes.h +18 -0
- package/cpp/skia/include/gpu/GrBackendSurface.h +38 -17
- package/cpp/skia/include/gpu/GrBackendSurfaceMutableState.h +6 -71
- package/cpp/skia/include/gpu/GrContextOptions.h +1 -1
- package/cpp/skia/include/gpu/GrContextThreadSafeProxy.h +10 -9
- package/cpp/skia/include/gpu/GrDirectContext.h +42 -22
- package/cpp/skia/include/gpu/GrRecordingContext.h +6 -3
- package/cpp/skia/include/gpu/GrTypes.h +11 -11
- package/cpp/skia/include/gpu/MutableTextureState.h +122 -0
- package/cpp/skia/include/gpu/gl/GrGLFunctions.h +1 -0
- package/cpp/skia/include/gpu/gl/GrGLInterface.h +1 -0
- package/cpp/skia/include/gpu/graphite/BackendTexture.h +7 -0
- package/cpp/skia/include/gpu/graphite/CombinationBuilder.h +195 -0
- package/cpp/skia/include/gpu/graphite/Context.h +47 -55
- package/cpp/skia/include/gpu/graphite/ContextOptions.h +85 -0
- package/cpp/skia/include/gpu/graphite/GraphiteTypes.h +1 -17
- package/cpp/skia/include/gpu/graphite/ImageProvider.h +61 -0
- package/cpp/skia/include/gpu/graphite/Recorder.h +87 -8
- package/cpp/skia/include/gpu/graphite/Recording.h +19 -9
- package/cpp/skia/include/gpu/graphite/TextureInfo.h +40 -8
- package/cpp/skia/include/gpu/graphite/dawn/DawnBackendContext.h +25 -0
- package/cpp/skia/include/gpu/graphite/mtl/MtlBackendContext.h +3 -2
- package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteTypes.h +69 -0
- package/cpp/skia/include/gpu/mtl/MtlMemoryAllocator.h +39 -0
- package/cpp/skia/include/gpu/vk/GrVkBackendContext.h +21 -19
- package/cpp/skia/include/gpu/vk/GrVkExtensions.h +2 -50
- package/cpp/skia/include/gpu/vk/GrVkMemoryAllocator.h +2 -127
- package/cpp/skia/include/gpu/vk/GrVkTypes.h +5 -43
- package/cpp/skia/include/gpu/vk/VulkanBackendContext.h +46 -0
- package/cpp/skia/include/gpu/vk/VulkanExtensions.h +67 -0
- package/cpp/skia/include/gpu/vk/VulkanMemoryAllocator.h +116 -0
- package/cpp/skia/include/gpu/vk/VulkanTypes.h +59 -0
- package/cpp/skia/include/pathops/SkPathOps.h +1 -1
- package/cpp/skia/include/private/SkColorData.h +10 -40
- package/cpp/skia/include/private/SkEncodedInfo.h +9 -3
- package/cpp/skia/include/private/SkFloatingPoint.h +9 -6
- package/cpp/skia/include/private/SkHalf.h +5 -52
- package/cpp/skia/include/private/SkMacros.h +1 -1
- package/cpp/skia/include/private/SkMalloc.h +4 -0
- package/cpp/skia/include/private/SkPathRef.h +10 -10
- package/cpp/skia/include/private/SkSLModifiers.h +59 -23
- package/cpp/skia/include/private/SkSLProgramKind.h +1 -0
- package/cpp/skia/include/private/SkSLSymbol.h +7 -3
- package/cpp/skia/include/private/SkStringView.h +4 -0
- package/cpp/skia/include/private/SkTArray.h +21 -7
- package/cpp/skia/include/private/SkTDArray.h +173 -285
- package/cpp/skia/include/private/SkTHash.h +33 -32
- package/cpp/skia/include/private/SkTemplates.h +24 -26
- package/cpp/skia/include/private/SkVx.h +218 -135
- package/cpp/skia/include/private/chromium/GrSlug.h +3 -65
- package/cpp/skia/include/private/chromium/SkChromeRemoteGlyphCache.h +6 -3
- package/cpp/skia/include/private/chromium/Slug.h +76 -0
- package/cpp/skia/include/private/gpu/ganesh/GrTypesPriv.h +6 -1
- package/cpp/skia/include/private/gpu/ganesh/GrVkTypesPriv.h +5 -39
- package/cpp/skia/include/private/gpu/graphite/VulkanGraphiteTypesPriv.h +63 -0
- package/cpp/skia/include/{gpu/vk/GrVkVulkan.h → private/gpu/vk/SkiaVulkan.h} +2 -2
- package/cpp/skia/include/private/gpu/vk/VulkanTypesPriv.h +57 -0
- package/cpp/skia/include/sksl/DSL.h +0 -1
- package/cpp/skia/include/sksl/DSLBlock.h +4 -18
- package/cpp/skia/include/sksl/DSLCase.h +2 -8
- package/cpp/skia/include/sksl/DSLCore.h +8 -15
- package/cpp/skia/include/sksl/DSLExpression.h +51 -142
- package/cpp/skia/include/sksl/DSLFunction.h +7 -15
- package/cpp/skia/include/sksl/DSLModifiers.h +5 -2
- package/cpp/skia/include/sksl/DSLStatement.h +4 -39
- package/cpp/skia/include/sksl/DSLSymbols.h +1 -11
- package/cpp/skia/include/sksl/DSLType.h +20 -12
- package/cpp/skia/include/sksl/DSLVar.h +56 -146
- package/cpp/skia/include/sksl/SkSLErrorReporter.h +2 -15
- package/cpp/skia/include/sksl/SkSLOperator.h +62 -59
- package/cpp/skia/include/sksl/SkSLPosition.h +2 -0
- package/cpp/skia/include/sksl/SkSLVersion.h +27 -0
- package/cpp/skia/include/svg/SkSVGCanvas.h +1 -0
- package/cpp/skia/include/utils/SkAnimCodecPlayer.h +1 -1
- package/cpp/skia/include/utils/SkBase64.h +2 -0
- package/cpp/skia/include/utils/SkCustomTypeface.h +24 -11
- package/cpp/skia/include/utils/SkEventTracer.h +12 -1
- package/cpp/skia/include/utils/SkNWayCanvas.h +11 -4
- package/cpp/skia/include/utils/SkPaintFilterCanvas.h +9 -4
- package/cpp/skia/include/utils/SkParse.h +3 -0
- package/cpp/skia/include/utils/SkShadowUtils.h +2 -0
- package/cpp/skia/include/utils/SkTextUtils.h +2 -1
- package/cpp/skia/{include/third_party → modules}/skcms/skcms.h +10 -0
- package/cpp/skia/modules/skcms/skcms_internal.h +56 -0
- package/cpp/skia/modules/skcms/src/Transform_inl.h +1609 -0
- package/cpp/skia/modules/skparagraph/include/DartTypes.h +153 -0
- package/cpp/skia/modules/skparagraph/include/FontArguments.h +46 -0
- package/cpp/skia/modules/skparagraph/include/FontCollection.h +84 -0
- package/cpp/skia/modules/skparagraph/include/Metrics.h +98 -0
- package/cpp/skia/modules/skparagraph/include/Paragraph.h +111 -0
- package/cpp/skia/modules/skparagraph/include/ParagraphBuilder.h +69 -0
- package/cpp/skia/modules/skparagraph/include/ParagraphCache.h +77 -0
- package/cpp/skia/modules/skparagraph/include/ParagraphStyle.h +143 -0
- package/cpp/skia/modules/skparagraph/include/TextShadow.h +30 -0
- package/cpp/skia/modules/skparagraph/include/TextStyle.h +352 -0
- package/cpp/skia/modules/skparagraph/include/TypefaceFontProvider.h +81 -0
- package/cpp/skia/modules/svg/include/SkSVGAttributeParser.h +1 -1
- package/cpp/skia/modules/svg/include/SkSVGTypes.h +3 -3
- package/cpp/skia/src/core/SkLRUCache.h +126 -0
- package/cpp/skia/src/core/SkTInternalLList.h +302 -0
- package/cpp/utils/RNSkTimingInfo.h +1 -0
- package/ios/RNSkia-iOS/RNSkMetalCanvasProvider.h +15 -4
- package/ios/RNSkia-iOS/RNSkMetalCanvasProvider.mm +41 -55
- package/ios/RNSkia-iOS/SkiaDomViewManager.h +8 -0
- package/ios/RNSkia-iOS/SkiaDomViewManager.mm +51 -0
- package/lib/commonjs/dom/nodes/JsiSkDOM.js +56 -56
- package/lib/commonjs/dom/nodes/JsiSkDOM.js.map +1 -1
- package/lib/commonjs/dom/nodes/RenderNode.js +1 -1
- package/lib/commonjs/dom/nodes/RenderNode.js.map +1 -1
- package/lib/commonjs/renderer/Canvas.js +24 -66
- package/lib/commonjs/renderer/Canvas.js.map +1 -1
- package/lib/commonjs/renderer/DependencyManager.js +0 -5
- package/lib/commonjs/renderer/DependencyManager.js.map +1 -1
- package/lib/commonjs/renderer/HostComponents.js.map +1 -1
- package/lib/commonjs/renderer/useCanvas.js +4 -18
- package/lib/commonjs/renderer/useCanvas.js.map +1 -1
- package/lib/commonjs/views/SkiaBaseWebView.js +15 -0
- package/lib/commonjs/views/SkiaBaseWebView.js.map +1 -1
- package/lib/commonjs/views/SkiaDomView.js +152 -0
- package/lib/commonjs/views/SkiaDomView.js.map +1 -0
- package/lib/commonjs/views/SkiaDomView.web.js +55 -0
- package/lib/commonjs/views/SkiaDomView.web.js.map +1 -0
- package/lib/commonjs/views/SkiaPictureView.js +16 -2
- package/lib/commonjs/views/SkiaPictureView.js.map +1 -1
- package/lib/commonjs/views/SkiaView.js +17 -2
- package/lib/commonjs/views/SkiaView.js.map +1 -1
- package/lib/commonjs/views/index.js +13 -0
- package/lib/commonjs/views/index.js.map +1 -1
- package/lib/commonjs/views/types.js.map +1 -1
- package/lib/module/dom/nodes/JsiSkDOM.js +56 -56
- package/lib/module/dom/nodes/JsiSkDOM.js.map +1 -1
- package/lib/module/dom/nodes/RenderNode.js +1 -1
- package/lib/module/dom/nodes/RenderNode.js.map +1 -1
- package/lib/module/renderer/Canvas.js +25 -66
- package/lib/module/renderer/Canvas.js.map +1 -1
- package/lib/module/renderer/DependencyManager.js +0 -5
- package/lib/module/renderer/DependencyManager.js.map +1 -1
- package/lib/module/renderer/HostComponents.js.map +1 -1
- package/lib/module/renderer/useCanvas.js +2 -13
- package/lib/module/renderer/useCanvas.js.map +1 -1
- package/lib/module/views/SkiaBaseWebView.js +15 -0
- package/lib/module/views/SkiaBaseWebView.js.map +1 -1
- package/lib/module/views/SkiaDomView.js +128 -0
- package/lib/module/views/SkiaDomView.js.map +1 -0
- package/lib/module/views/SkiaDomView.web.js +41 -0
- package/lib/module/views/SkiaDomView.web.js.map +1 -0
- package/lib/module/views/SkiaPictureView.js +14 -2
- package/lib/module/views/SkiaPictureView.js.map +1 -1
- package/lib/module/views/SkiaView.js +15 -2
- package/lib/module/views/SkiaView.js.map +1 -1
- package/lib/module/views/index.js +1 -0
- package/lib/module/views/index.js.map +1 -1
- package/lib/module/views/types.js.map +1 -1
- package/lib/typescript/src/dom/nodes/JsiSkDOM.d.ts +57 -64
- package/lib/typescript/src/renderer/Canvas.d.ts +5 -8
- package/lib/typescript/src/renderer/DependencyManager.d.ts +0 -2
- package/lib/typescript/src/renderer/HostComponents.d.ts +66 -3
- package/lib/typescript/src/renderer/useCanvas.d.ts +0 -6
- package/lib/typescript/src/views/SkiaBaseWebView.d.ts +4 -0
- package/lib/typescript/src/views/SkiaDomView.d.ts +31 -0
- package/lib/typescript/src/views/SkiaDomView.web.d.ts +7 -0
- package/lib/typescript/src/views/index.d.ts +1 -0
- package/lib/typescript/src/views/types.d.ts +12 -2
- package/libs/android/arm64-v8a/libskia.a +0 -0
- package/libs/android/arm64-v8a/libskottie.a +0 -0
- package/libs/android/arm64-v8a/libskparagraph.a +0 -0
- package/libs/android/arm64-v8a/libsksg.a +0 -0
- package/libs/android/arm64-v8a/libskshaper.a +0 -0
- package/libs/android/arm64-v8a/libskunicode.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/libskparagraph.a +0 -0
- package/libs/android/armeabi-v7a/libsksg.a +0 -0
- package/libs/android/armeabi-v7a/libskshaper.a +0 -0
- package/libs/android/armeabi-v7a/libskunicode.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/libskparagraph.a +0 -0
- package/libs/android/x86/libsksg.a +0 -0
- package/libs/android/x86/libskshaper.a +0 -0
- package/libs/android/x86/libskunicode.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/libskparagraph.a +0 -0
- package/libs/android/x86_64/libsksg.a +0 -0
- package/libs/android/x86_64/libskshaper.a +0 -0
- package/libs/android/x86_64/libskunicode.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/libskparagraph.xcframework/Info.plist +42 -0
- package/libs/ios/libskparagraph.xcframework/ios-arm64_arm64e/libskparagraph.a +0 -0
- package/libs/ios/libskparagraph.xcframework/ios-arm64_arm64e_x86_64-simulator/libskparagraph.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/libskunicode.xcframework/Info.plist +42 -0
- package/libs/ios/libskunicode.xcframework/ios-arm64_arm64e/libskunicode.a +0 -0
- package/libs/ios/libskunicode.xcframework/ios-arm64_arm64e_x86_64-simulator/libskunicode.a +0 -0
- 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 +5 -3
- package/react-native-skia.podspec +5 -2
- package/src/dom/nodes/JsiSkDOM.ts +170 -56
- package/src/dom/nodes/RenderNode.ts +1 -1
- package/src/renderer/Canvas.tsx +37 -57
- package/src/renderer/DependencyManager.tsx +0 -5
- package/src/renderer/HostComponents.ts +152 -1
- package/src/renderer/useCanvas.ts +1 -15
- package/src/views/SkiaBaseWebView.tsx +9 -0
- package/src/views/SkiaDomView.tsx +120 -0
- package/src/views/SkiaDomView.web.tsx +37 -0
- package/src/views/SkiaPictureView.tsx +10 -2
- package/src/views/SkiaView.tsx +11 -3
- package/src/views/index.ts +1 -0
- package/src/views/types.ts +19 -2
- package/cpp/jsi/JsiSimpleValueWrapper.h +0 -99
- package/cpp/skia/include/c/sk_canvas.h +0 -159
- package/cpp/skia/include/c/sk_colorspace.h +0 -25
- package/cpp/skia/include/c/sk_data.h +0 -65
- package/cpp/skia/include/c/sk_image.h +0 -71
- package/cpp/skia/include/c/sk_imageinfo.h +0 -62
- package/cpp/skia/include/c/sk_maskfilter.h +0 -47
- package/cpp/skia/include/c/sk_matrix.h +0 -49
- package/cpp/skia/include/c/sk_paint.h +0 -145
- package/cpp/skia/include/c/sk_path.h +0 -102
- package/cpp/skia/include/c/sk_picture.h +0 -70
- package/cpp/skia/include/c/sk_shader.h +0 -143
- package/cpp/skia/include/c/sk_surface.h +0 -73
- package/cpp/skia/include/c/sk_types.h +0 -278
- package/cpp/skia/include/gpu/graphite/SkStuff.h +0 -47
- package/cpp/skia/include/private/SkNx.h +0 -430
- package/cpp/skia/include/private/SkNx_neon.h +0 -713
- package/cpp/skia/include/private/SkNx_sse.h +0 -823
- package/cpp/skia/include/sksl/DSLRuntimeEffects.h +0 -32
- package/cpp/skia/include/sksl/DSLWrapper.h +0 -77
@@ -12,233 +12,233 @@ export class JsiSkDOM {
|
|
12
12
|
}
|
13
13
|
|
14
14
|
Layer(props) {
|
15
|
-
return new LayerNode(this.ctx, props !== null && props !== void 0 ? props : {});
|
15
|
+
return global.SkiaDomApi && global.SkiaDomApi.LayerNode ? global.SkiaDomApi.LayerNode(props !== null && props !== void 0 ? props : {}) : new LayerNode(this.ctx, props !== null && props !== void 0 ? props : {});
|
16
16
|
}
|
17
17
|
|
18
18
|
Group(props) {
|
19
|
-
return new GroupNode(this.ctx, props !== null && props !== void 0 ? props : {});
|
19
|
+
return global.SkiaDomApi && global.SkiaDomApi.GroupNode ? global.SkiaDomApi.GroupNode(props !== null && props !== void 0 ? props : {}) : new GroupNode(this.ctx, props !== null && props !== void 0 ? props : {});
|
20
20
|
}
|
21
21
|
|
22
22
|
Paint(props) {
|
23
|
-
return new PaintNode(this.ctx, props);
|
23
|
+
return global.SkiaDomApi && global.SkiaDomApi.PaintNode ? global.SkiaDomApi.PaintNode(props !== null && props !== void 0 ? props : {}) : new PaintNode(this.ctx, props);
|
24
24
|
} // Drawings
|
25
25
|
|
26
26
|
|
27
27
|
Fill(props) {
|
28
|
-
return new FillNode(this.ctx, props);
|
28
|
+
return global.SkiaDomApi && global.SkiaDomApi.FillNode ? global.SkiaDomApi.FillNode(props !== null && props !== void 0 ? props : {}) : new FillNode(this.ctx, props);
|
29
29
|
}
|
30
30
|
|
31
31
|
Image(props) {
|
32
|
-
return new ImageNode(this.ctx, props);
|
32
|
+
return global.SkiaDomApi && global.SkiaDomApi.ImageNode ? global.SkiaDomApi.ImageNode(props !== null && props !== void 0 ? props : {}) : new ImageNode(this.ctx, props);
|
33
33
|
}
|
34
34
|
|
35
35
|
Circle(props) {
|
36
|
-
return new CircleNode(this.ctx, props);
|
36
|
+
return global.SkiaDomApi && global.SkiaDomApi.CircleNode ? global.SkiaDomApi.CircleNode(props !== null && props !== void 0 ? props : {}) : new CircleNode(this.ctx, props);
|
37
37
|
}
|
38
38
|
|
39
39
|
Path(props) {
|
40
|
-
return new PathNode(this.ctx, props);
|
40
|
+
return global.SkiaDomApi && global.SkiaDomApi.PathNode ? global.SkiaDomApi.PathNode(props !== null && props !== void 0 ? props : {}) : new PathNode(this.ctx, props);
|
41
41
|
}
|
42
42
|
|
43
43
|
CustomDrawing(props) {
|
44
|
-
return new CustomDrawingNode(this.ctx, props);
|
44
|
+
return global.SkiaDomApi && global.SkiaDomApi.CustomDrawingNode ? global.SkiaDomApi.CustomDrawingNode(props !== null && props !== void 0 ? props : {}) : new CustomDrawingNode(this.ctx, props);
|
45
45
|
}
|
46
46
|
|
47
47
|
Line(props) {
|
48
|
-
return new LineNode(this.ctx, props);
|
48
|
+
return global.SkiaDomApi && global.SkiaDomApi.LineNode ? global.SkiaDomApi.LineNode(props !== null && props !== void 0 ? props : {}) : new LineNode(this.ctx, props);
|
49
49
|
}
|
50
50
|
|
51
51
|
Oval(props) {
|
52
|
-
return new OvalNode(this.ctx, props);
|
52
|
+
return global.SkiaDomApi && global.SkiaDomApi.OvalNode ? global.SkiaDomApi.OvalNode(props !== null && props !== void 0 ? props : {}) : new OvalNode(this.ctx, props);
|
53
53
|
}
|
54
54
|
|
55
55
|
Patch(props) {
|
56
|
-
return new PatchNode(this.ctx, props);
|
56
|
+
return global.SkiaDomApi && global.SkiaDomApi.PatchNode ? global.SkiaDomApi.PatchNode(props !== null && props !== void 0 ? props : {}) : new PatchNode(this.ctx, props);
|
57
57
|
}
|
58
58
|
|
59
59
|
Points(props) {
|
60
|
-
return new PointsNode(this.ctx, props);
|
60
|
+
return global.SkiaDomApi && global.SkiaDomApi.PointsNode ? global.SkiaDomApi.PointsNode(props !== null && props !== void 0 ? props : {}) : new PointsNode(this.ctx, props);
|
61
61
|
}
|
62
62
|
|
63
63
|
Rect(props) {
|
64
|
-
return new RectNode(this.ctx, props);
|
64
|
+
return global.SkiaDomApi && global.SkiaDomApi.RectNode ? global.SkiaDomApi.RectNode(props) : new RectNode(this.ctx, props);
|
65
65
|
}
|
66
66
|
|
67
67
|
RRect(props) {
|
68
|
-
return new RRectNode(this.ctx, props);
|
68
|
+
return global.SkiaDomApi && global.SkiaDomApi.RRectNode ? global.SkiaDomApi.RRectNode(props) : new RRectNode(this.ctx, props);
|
69
69
|
}
|
70
70
|
|
71
71
|
Vertices(props) {
|
72
|
-
return new VerticesNode(this.ctx, props);
|
72
|
+
return global.SkiaDomApi && global.SkiaDomApi.VerticesNode ? global.SkiaDomApi.VerticesNode(props) : new VerticesNode(this.ctx, props);
|
73
73
|
}
|
74
74
|
|
75
75
|
Text(props) {
|
76
|
-
return new TextNode(this.ctx, props);
|
76
|
+
return global.SkiaDomApi && global.SkiaDomApi.TextNode ? global.SkiaDomApi.TextNode(props) : new TextNode(this.ctx, props);
|
77
77
|
}
|
78
78
|
|
79
79
|
TextPath(props) {
|
80
|
-
return new TextPathNode(this.ctx, props);
|
80
|
+
return global.SkiaDomApi && global.SkiaDomApi.TextPathNode ? global.SkiaDomApi.TextPathNode(props) : new TextPathNode(this.ctx, props);
|
81
81
|
}
|
82
82
|
|
83
83
|
TextBlob(props) {
|
84
|
-
return new TextBlobNode(this.ctx, props);
|
84
|
+
return global.SkiaDomApi && global.SkiaDomApi.TextBlobNode ? global.SkiaDomApi.TextBlobNode(props) : new TextBlobNode(this.ctx, props);
|
85
85
|
}
|
86
86
|
|
87
87
|
Glyphs(props) {
|
88
|
-
return new GlyphsNode(this.ctx, props);
|
88
|
+
return global.SkiaDomApi && global.SkiaDomApi.GlyphsNode ? global.SkiaDomApi.GlyphsNode(props) : new GlyphsNode(this.ctx, props);
|
89
89
|
}
|
90
90
|
|
91
91
|
DiffRect(props) {
|
92
|
-
return new DiffRectNode(this.ctx, props);
|
92
|
+
return global.SkiaDomApi && global.SkiaDomApi.DiffRectNode ? global.SkiaDomApi.DiffRectNode(props) : new DiffRectNode(this.ctx, props);
|
93
93
|
}
|
94
94
|
|
95
95
|
Picture(props) {
|
96
|
-
return new PictureNode(this.ctx, props);
|
96
|
+
return global.SkiaDomApi && global.SkiaDomApi.PictureNode ? global.SkiaDomApi.PictureNode(props) : new PictureNode(this.ctx, props);
|
97
97
|
}
|
98
98
|
|
99
99
|
ImageSVG(props) {
|
100
|
-
return new ImageSVGNode(this.ctx, props);
|
100
|
+
return global.SkiaDomApi && global.SkiaDomApi.ImageSVGNode ? global.SkiaDomApi.ImageSVGNode(props) : new ImageSVGNode(this.ctx, props);
|
101
101
|
} // BlurMaskFilters
|
102
102
|
|
103
103
|
|
104
104
|
BlurMaskFilter(props) {
|
105
|
-
return new BlurMaskFilterNode(this.ctx, props);
|
105
|
+
return global.SkiaDomApi && global.SkiaDomApi.BlurMaskFilterNode ? global.SkiaDomApi.BlurMaskFilterNode(props) : new BlurMaskFilterNode(this.ctx, props);
|
106
106
|
} // ImageFilters
|
107
107
|
|
108
108
|
|
109
109
|
BlendImageFilter(props) {
|
110
|
-
return new BlendImageFilterNode(this.ctx, props);
|
110
|
+
return global.SkiaDomApi && global.SkiaDomApi.BlendImageFilterNode ? global.SkiaDomApi.BlendImageFilterNode(props) : new BlendImageFilterNode(this.ctx, props);
|
111
111
|
}
|
112
112
|
|
113
113
|
DropShadowImageFilter(props) {
|
114
|
-
return new DropShadowImageFilterNode(this.ctx, props);
|
114
|
+
return global.SkiaDomApi && global.SkiaDomApi.DropShadowImageFilterNode ? global.SkiaDomApi.DropShadowImageFilterNode(props) : new DropShadowImageFilterNode(this.ctx, props);
|
115
115
|
}
|
116
116
|
|
117
117
|
DisplacementMapImageFilter(props) {
|
118
|
-
return new DisplacementMapImageFilterNode(this.ctx, props);
|
118
|
+
return global.SkiaDomApi && global.SkiaDomApi.DisplacementMapImageFilterNode ? global.SkiaDomApi.DisplacementMapImageFilterNode(props) : new DisplacementMapImageFilterNode(this.ctx, props);
|
119
119
|
}
|
120
120
|
|
121
121
|
BlurImageFilter(props) {
|
122
|
-
return new BlurImageFilterNode(this.ctx, props);
|
122
|
+
return global.SkiaDomApi && global.SkiaDomApi.BlurImageFilterNode ? global.SkiaDomApi.BlurImageFilterNode(props) : new BlurImageFilterNode(this.ctx, props);
|
123
123
|
}
|
124
124
|
|
125
125
|
OffsetImageFilter(props) {
|
126
|
-
return new OffsetImageFilterNode(this.ctx, props);
|
126
|
+
return global.SkiaDomApi && global.SkiaDomApi.OffsetImageFilterNode ? global.SkiaDomApi.OffsetImageFilterNode(props) : new OffsetImageFilterNode(this.ctx, props);
|
127
127
|
}
|
128
128
|
|
129
129
|
MorphologyImageFilter(props) {
|
130
|
-
return new MorphologyImageFilterNode(this.ctx, props);
|
130
|
+
return global.SkiaDomApi && global.SkiaDomApi.MorphologyImageFilterNode ? global.SkiaDomApi.MorphologyImageFilterNode(props) : new MorphologyImageFilterNode(this.ctx, props);
|
131
131
|
}
|
132
132
|
|
133
133
|
RuntimeShaderImageFilter(props) {
|
134
|
-
return new RuntimeShaderImageFilterNode(this.ctx, props);
|
134
|
+
return global.SkiaDomApi && global.SkiaDomApi.RuntimeShaderImageFilterNode ? global.SkiaDomApi.RuntimeShaderImageFilterNode(props) : new RuntimeShaderImageFilterNode(this.ctx, props);
|
135
135
|
} // Color Filters
|
136
136
|
|
137
137
|
|
138
138
|
MatrixColorFilter(props) {
|
139
|
-
return new MatrixColorFilterNode(this.ctx, props);
|
139
|
+
return global.SkiaDomApi && global.SkiaDomApi.MatrixColorFilterNode ? global.SkiaDomApi.MatrixColorFilterNode(props) : new MatrixColorFilterNode(this.ctx, props);
|
140
140
|
}
|
141
141
|
|
142
142
|
BlendColorFilter(props) {
|
143
|
-
return new BlendColorFilterNode(this.ctx, props);
|
143
|
+
return global.SkiaDomApi && global.SkiaDomApi.BlendColorFilterNode ? global.SkiaDomApi.BlendColorFilterNode(props) : new BlendColorFilterNode(this.ctx, props);
|
144
144
|
}
|
145
145
|
|
146
146
|
LumaColorFilter() {
|
147
|
-
return new LumaColorFilterNode(this.ctx);
|
147
|
+
return global.SkiaDomApi && global.SkiaDomApi.LumaColorFilterNode ? global.SkiaDomApi.LumaColorFilterNode() : new LumaColorFilterNode(this.ctx);
|
148
148
|
}
|
149
149
|
|
150
150
|
LinearToSRGBGammaColorFilter() {
|
151
|
-
return new LinearToSRGBGammaColorFilterNode(this.ctx);
|
151
|
+
return global.SkiaDomApi && global.SkiaDomApi.LinearToSRGBGammaColorFilterNode ? global.SkiaDomApi.LinearToSRGBGammaColorFilterNode() : new LinearToSRGBGammaColorFilterNode(this.ctx);
|
152
152
|
}
|
153
153
|
|
154
154
|
SRGBToLinearGammaColorFilter() {
|
155
|
-
return new SRGBToLinearGammaColorFilterNode(this.ctx);
|
155
|
+
return global.SkiaDomApi && global.SkiaDomApi.SRGBToLinearGammaColorFilterNode ? global.SkiaDomApi.SRGBToLinearGammaColorFilterNode() : new SRGBToLinearGammaColorFilterNode(this.ctx);
|
156
156
|
}
|
157
157
|
|
158
158
|
LerpColorFilter(props) {
|
159
|
-
return new LerpColorFilterNode(this.ctx, props);
|
159
|
+
return global.SkiaDomApi && global.SkiaDomApi.LerpColorFilterNode ? global.SkiaDomApi.LerpColorFilterNode(props) : new LerpColorFilterNode(this.ctx, props);
|
160
160
|
} // Shaders
|
161
161
|
|
162
162
|
|
163
163
|
Shader(props) {
|
164
|
-
return new ShaderNode(this.ctx, props);
|
164
|
+
return global.SkiaDomApi && global.SkiaDomApi.ShaderNode ? global.SkiaDomApi.ShaderNode(props) : new ShaderNode(this.ctx, props);
|
165
165
|
}
|
166
166
|
|
167
167
|
ImageShader(props) {
|
168
|
-
return new ImageShaderNode(this.ctx, props);
|
168
|
+
return global.SkiaDomApi && global.SkiaDomApi.ImageShaderNode ? global.SkiaDomApi.ImageShaderNode(props) : new ImageShaderNode(this.ctx, props);
|
169
169
|
}
|
170
170
|
|
171
171
|
ColorShader(props) {
|
172
|
-
return new ColorNode(this.ctx, props);
|
172
|
+
return global.SkiaDomApi && global.SkiaDomApi.ColorShaderNode ? global.SkiaDomApi.ColorShaderNode(props) : new ColorNode(this.ctx, props);
|
173
173
|
}
|
174
174
|
|
175
175
|
SweepGradient(props) {
|
176
|
-
return new SweepGradientNode(this.ctx, props);
|
176
|
+
return global.SkiaDomApi && global.SkiaDomApi.SweepGradientNode ? global.SkiaDomApi.SweepGradientNode(props) : new SweepGradientNode(this.ctx, props);
|
177
177
|
}
|
178
178
|
|
179
179
|
Turbulence(props) {
|
180
|
-
return new TurbulenceNode(this.ctx, props);
|
180
|
+
return global.SkiaDomApi && global.SkiaDomApi.TurbulenceNode ? global.SkiaDomApi.TurbulenceNode(props) : new TurbulenceNode(this.ctx, props);
|
181
181
|
}
|
182
182
|
|
183
183
|
FractalNoise(props) {
|
184
|
-
return new FractalNoiseNode(this.ctx, props);
|
184
|
+
return global.SkiaDomApi && global.SkiaDomApi.FractalNoiseNode ? global.SkiaDomApi.FractalNoiseNode(props) : new FractalNoiseNode(this.ctx, props);
|
185
185
|
}
|
186
186
|
|
187
187
|
LinearGradient(props) {
|
188
|
-
return new LinearGradientNode(this.ctx, props);
|
188
|
+
return global.SkiaDomApi && global.SkiaDomApi.LinearGradientNode ? global.SkiaDomApi.LinearGradientNode(props) : new LinearGradientNode(this.ctx, props);
|
189
189
|
}
|
190
190
|
|
191
191
|
RadialGradient(props) {
|
192
|
-
return new RadialGradientNode(this.ctx, props);
|
192
|
+
return global.SkiaDomApi && global.SkiaDomApi.RadialGradientNode ? global.SkiaDomApi.RadialGradientNode(props) : new RadialGradientNode(this.ctx, props);
|
193
193
|
}
|
194
194
|
|
195
195
|
TwoPointConicalGradient(props) {
|
196
|
-
return new TwoPointConicalGradientNode(this.ctx, props);
|
196
|
+
return global.SkiaDomApi && global.SkiaDomApi.TwoPointConicalGradientNode ? global.SkiaDomApi.TwoPointConicalGradientNode(props) : new TwoPointConicalGradientNode(this.ctx, props);
|
197
197
|
} // Path Effects
|
198
198
|
|
199
199
|
|
200
200
|
CornerPathEffect(props) {
|
201
|
-
return new CornerPathEffectNode(this.ctx, props);
|
201
|
+
return global.SkiaDomApi && global.SkiaDomApi.CornerPathEffectNode ? global.SkiaDomApi.CornerPathEffectNode(props) : new CornerPathEffectNode(this.ctx, props);
|
202
202
|
}
|
203
203
|
|
204
204
|
DiscretePathEffect(props) {
|
205
|
-
return new DiscretePathEffectNode(this.ctx, props);
|
205
|
+
return global.SkiaDomApi && global.SkiaDomApi.DiscretePathEffectNode ? global.SkiaDomApi.DiscretePathEffectNode(props) : new DiscretePathEffectNode(this.ctx, props);
|
206
206
|
}
|
207
207
|
|
208
208
|
DashPathEffect(props) {
|
209
|
-
return new DashPathEffectNode(this.ctx, props);
|
209
|
+
return global.SkiaDomApi && global.SkiaDomApi.DashPathEffectNode ? global.SkiaDomApi.DashPathEffectNode(props) : new DashPathEffectNode(this.ctx, props);
|
210
210
|
}
|
211
211
|
|
212
212
|
Path1DPathEffect(props) {
|
213
|
-
return new Path1DPathEffectNode(this.ctx, props);
|
213
|
+
return global.SkiaDomApi && global.SkiaDomApi.Path1DPathEffectNode ? global.SkiaDomApi.Path1DPathEffectNode(props) : new Path1DPathEffectNode(this.ctx, props);
|
214
214
|
}
|
215
215
|
|
216
216
|
Path2DPathEffect(props) {
|
217
|
-
return new Path2DPathEffectNode(this.ctx, props);
|
217
|
+
return global.SkiaDomApi && global.SkiaDomApi.Path2DPathEffectNode ? global.SkiaDomApi.Path2DPathEffectNode(props) : new Path2DPathEffectNode(this.ctx, props);
|
218
218
|
}
|
219
219
|
|
220
220
|
SumPathEffect() {
|
221
|
-
return new SumPathEffectNode(this.ctx);
|
221
|
+
return global.SkiaDomApi && global.SkiaDomApi.SumPathEffectNode ? global.SkiaDomApi.SumPathEffectNode() : new SumPathEffectNode(this.ctx);
|
222
222
|
}
|
223
223
|
|
224
224
|
Line2DPathEffect(props) {
|
225
|
-
return new Line2DPathEffectNode(this.ctx, props);
|
225
|
+
return global.SkiaDomApi && global.SkiaDomApi.Line2DPathEffectNode ? global.SkiaDomApi.Line2DPathEffectNode(props) : new Line2DPathEffectNode(this.ctx, props);
|
226
226
|
}
|
227
227
|
|
228
228
|
Blend(props) {
|
229
|
-
return new BlendNode(this.ctx, props);
|
229
|
+
return global.SkiaDomApi && global.SkiaDomApi.BlendNode ? global.SkiaDomApi.BlendNode(props) : new BlendNode(this.ctx, props);
|
230
230
|
}
|
231
231
|
|
232
232
|
BackdropFilter(props) {
|
233
|
-
return new BackdropFilterNode(this.ctx, props);
|
233
|
+
return global.SkiaDomApi && global.SkiaDomApi.BackdropFilterNode ? global.SkiaDomApi.BackdropFilterNode(props) : new BackdropFilterNode(this.ctx, props);
|
234
234
|
}
|
235
235
|
|
236
236
|
Box(props) {
|
237
|
-
return new BoxNode(this.ctx, props);
|
237
|
+
return global.SkiaDomApi && global.SkiaDomApi.BoxNode ? global.SkiaDomApi.BoxNode(props) : new BoxNode(this.ctx, props);
|
238
238
|
}
|
239
239
|
|
240
240
|
BoxShadow(props) {
|
241
|
-
return new BoxShadowNode(this.ctx, props);
|
241
|
+
return global.SkiaDomApi && global.SkiaDomApi.BoxShadowNode ? global.SkiaDomApi.BoxShadowNode(props) : new BoxShadowNode(this.ctx, props);
|
242
242
|
}
|
243
243
|
|
244
244
|
}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["FillNode","ImageNode","CircleNode","PathNode","LineNode","PatchNode","PointsNode","RectNode","RRectNode","VerticesNode","TextNode","OvalNode","CustomDrawingNode","TextPathNode","TextBlobNode","GlyphsNode","DiffRectNode","PictureNode","ImageSVGNode","BackdropFilterNode","BoxNode","BoxShadowNode","BlendImageFilterNode","BlurImageFilterNode","BlurMaskFilterNode","DisplacementMapImageFilterNode","DropShadowImageFilterNode","OffsetImageFilterNode","RuntimeShaderImageFilterNode","CornerPathEffectNode","DiscretePathEffectNode","DashPathEffectNode","Path1DPathEffectNode","Path2DPathEffectNode","SumPathEffectNode","Line2DPathEffectNode","BlendNode","MatrixColorFilterNode","LumaColorFilterNode","LinearToSRGBGammaColorFilterNode","SRGBToLinearGammaColorFilterNode","BlendColorFilterNode","LerpColorFilterNode","LinearGradientNode","ShaderNode","ImageShaderNode","TwoPointConicalGradientNode","TurbulenceNode","SweepGradientNode","RadialGradientNode","FractalNoiseNode","ColorNode","MorphologyImageFilterNode","GroupNode","PaintNode","LayerNode","JsiSkDOM","constructor","ctx","Layer","props","Group","Paint","Fill","Image","Circle","Path","CustomDrawing","Line","Oval","Patch","Points","Rect","RRect","Vertices","Text","TextPath","TextBlob","Glyphs","DiffRect","Picture","ImageSVG","BlurMaskFilter","BlendImageFilter","DropShadowImageFilter","DisplacementMapImageFilter","BlurImageFilter","OffsetImageFilter","MorphologyImageFilter","RuntimeShaderImageFilter","MatrixColorFilter","BlendColorFilter","LumaColorFilter","LinearToSRGBGammaColorFilter","SRGBToLinearGammaColorFilter","LerpColorFilter","Shader","ImageShader","ColorShader","SweepGradient","Turbulence","FractalNoise","LinearGradient","RadialGradient","TwoPointConicalGradient","CornerPathEffect","DiscretePathEffect","DashPathEffect","Path1DPathEffect","Path2DPathEffect","SumPathEffect","Line2DPathEffect","Blend","BackdropFilter","Box","BoxShadow"],"sources":["JsiSkDOM.ts"],"sourcesContent":["import type {\n PathProps,\n SkDOM,\n GroupProps,\n ImageProps,\n BlurImageFilterProps,\n MatrixColorFilterProps,\n CircleProps,\n BlurMaskFilterProps,\n LinearGradientProps,\n PaintProps,\n ShaderProps,\n ImageShaderProps,\n CustomDrawingNodeProps,\n LineProps,\n OvalProps,\n PatchProps,\n PointsProps,\n RectProps,\n RoundedRectProps,\n VerticesProps,\n TextProps,\n DiffRectProps,\n OffsetImageFilterProps,\n BlendColorFilterProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n TwoPointConicalGradientProps,\n TurbulenceProps,\n SweepGradientProps,\n RadialGradientProps,\n FractalNoiseProps,\n ColorProps,\n PictureProps,\n ImageSVGProps,\n LerpColorFilterProps,\n DrawingNodeProps,\n BoxProps,\n BoxShadowProps,\n ChildrenProps,\n} from \"../types\";\nimport type {\n BlendImageFilterProps,\n BlendProps,\n DisplacementMapImageFilterProps,\n DropShadowImageFilterProps,\n MorphologyImageFilterProps,\n RuntimeShaderImageFilterProps,\n} from \"../types/ImageFilters\";\nimport type {\n CornerPathEffectProps,\n DashPathEffectProps,\n DiscretePathEffectProps,\n Line2DPathEffectProps,\n Path1DPathEffectProps,\n Path2DPathEffectProps,\n} from \"../types/PathEffects\";\n\nimport {\n FillNode,\n ImageNode,\n CircleNode,\n PathNode,\n LineNode,\n PatchNode,\n PointsNode,\n RectNode,\n RRectNode,\n VerticesNode,\n TextNode,\n OvalNode,\n CustomDrawingNode,\n TextPathNode,\n TextBlobNode,\n GlyphsNode,\n DiffRectNode,\n PictureNode,\n ImageSVGNode,\n BackdropFilterNode,\n BoxNode,\n BoxShadowNode,\n} from \"./drawings\";\nimport {\n BlendImageFilterNode,\n BlurImageFilterNode,\n BlurMaskFilterNode,\n DisplacementMapImageFilterNode,\n DropShadowImageFilterNode,\n OffsetImageFilterNode,\n RuntimeShaderImageFilterNode,\n CornerPathEffectNode,\n DiscretePathEffectNode,\n DashPathEffectNode,\n Path1DPathEffectNode,\n Path2DPathEffectNode,\n SumPathEffectNode,\n Line2DPathEffectNode,\n BlendNode,\n} from \"./paint\";\nimport {\n MatrixColorFilterNode,\n LumaColorFilterNode,\n LinearToSRGBGammaColorFilterNode,\n SRGBToLinearGammaColorFilterNode,\n BlendColorFilterNode,\n LerpColorFilterNode,\n} from \"./paint/ColorFilters\";\nimport {\n LinearGradientNode,\n ShaderNode,\n ImageShaderNode,\n TwoPointConicalGradientNode,\n TurbulenceNode,\n SweepGradientNode,\n RadialGradientNode,\n FractalNoiseNode,\n ColorNode,\n} from \"./paint/Shaders\";\nimport { MorphologyImageFilterNode } from \"./paint/ImageFilters\";\nimport { GroupNode } from \"./GroupNode\";\nimport { PaintNode } from \"./PaintNode\";\nimport type { NodeContext } from \"./Node\";\nimport { LayerNode } from \"./LayerNode\";\n\nexport class JsiSkDOM implements SkDOM {\n constructor(private ctx: NodeContext) {}\n\n Layer(props?: ChildrenProps) {\n return new LayerNode(this.ctx, props ?? {});\n }\n\n Group(props?: GroupProps) {\n return new GroupNode(this.ctx, props ?? {});\n }\n\n Paint(props: PaintProps) {\n return new PaintNode(this.ctx, props);\n }\n\n // Drawings\n Fill(props?: DrawingNodeProps) {\n return new FillNode(this.ctx, props);\n }\n\n Image(props: ImageProps) {\n return new ImageNode(this.ctx, props);\n }\n\n Circle(props: CircleProps) {\n return new CircleNode(this.ctx, props);\n }\n\n Path(props: PathProps) {\n return new PathNode(this.ctx, props);\n }\n\n CustomDrawing(props: CustomDrawingNodeProps) {\n return new CustomDrawingNode(this.ctx, props);\n }\n\n Line(props: LineProps) {\n return new LineNode(this.ctx, props);\n }\n\n Oval(props: OvalProps) {\n return new OvalNode(this.ctx, props);\n }\n\n Patch(props: PatchProps) {\n return new PatchNode(this.ctx, props);\n }\n\n Points(props: PointsProps) {\n return new PointsNode(this.ctx, props);\n }\n\n Rect(props: RectProps) {\n return new RectNode(this.ctx, props);\n }\n\n RRect(props: RoundedRectProps) {\n return new RRectNode(this.ctx, props);\n }\n\n Vertices(props: VerticesProps) {\n return new VerticesNode(this.ctx, props);\n }\n\n Text(props: TextProps) {\n return new TextNode(this.ctx, props);\n }\n\n TextPath(props: TextPathProps) {\n return new TextPathNode(this.ctx, props);\n }\n\n TextBlob(props: TextBlobProps) {\n return new TextBlobNode(this.ctx, props);\n }\n\n Glyphs(props: GlyphsProps) {\n return new GlyphsNode(this.ctx, props);\n }\n\n DiffRect(props: DiffRectProps) {\n return new DiffRectNode(this.ctx, props);\n }\n\n Picture(props: PictureProps) {\n return new PictureNode(this.ctx, props);\n }\n\n ImageSVG(props: ImageSVGProps) {\n return new ImageSVGNode(this.ctx, props);\n }\n\n // BlurMaskFilters\n BlurMaskFilter(props: BlurMaskFilterProps) {\n return new BlurMaskFilterNode(this.ctx, props);\n }\n\n // ImageFilters\n BlendImageFilter(props: BlendImageFilterProps) {\n return new BlendImageFilterNode(this.ctx, props);\n }\n\n DropShadowImageFilter(props: DropShadowImageFilterProps) {\n return new DropShadowImageFilterNode(this.ctx, props);\n }\n\n DisplacementMapImageFilter(props: DisplacementMapImageFilterProps) {\n return new DisplacementMapImageFilterNode(this.ctx, props);\n }\n\n BlurImageFilter(props: BlurImageFilterProps) {\n return new BlurImageFilterNode(this.ctx, props);\n }\n\n OffsetImageFilter(props: OffsetImageFilterProps) {\n return new OffsetImageFilterNode(this.ctx, props);\n }\n\n MorphologyImageFilter(props: MorphologyImageFilterProps) {\n return new MorphologyImageFilterNode(this.ctx, props);\n }\n\n RuntimeShaderImageFilter(props: RuntimeShaderImageFilterProps) {\n return new RuntimeShaderImageFilterNode(this.ctx, props);\n }\n\n // Color Filters\n MatrixColorFilter(props: MatrixColorFilterProps) {\n return new MatrixColorFilterNode(this.ctx, props);\n }\n\n BlendColorFilter(props: BlendColorFilterProps) {\n return new BlendColorFilterNode(this.ctx, props);\n }\n\n LumaColorFilter() {\n return new LumaColorFilterNode(this.ctx);\n }\n\n LinearToSRGBGammaColorFilter() {\n return new LinearToSRGBGammaColorFilterNode(this.ctx);\n }\n\n SRGBToLinearGammaColorFilter() {\n return new SRGBToLinearGammaColorFilterNode(this.ctx);\n }\n\n LerpColorFilter(props: LerpColorFilterProps) {\n return new LerpColorFilterNode(this.ctx, props);\n }\n\n // Shaders\n Shader(props: ShaderProps) {\n return new ShaderNode(this.ctx, props);\n }\n\n ImageShader(props: ImageShaderProps) {\n return new ImageShaderNode(this.ctx, props);\n }\n\n ColorShader(props: ColorProps) {\n return new ColorNode(this.ctx, props);\n }\n\n SweepGradient(props: SweepGradientProps) {\n return new SweepGradientNode(this.ctx, props);\n }\n\n Turbulence(props: TurbulenceProps) {\n return new TurbulenceNode(this.ctx, props);\n }\n\n FractalNoise(props: FractalNoiseProps) {\n return new FractalNoiseNode(this.ctx, props);\n }\n\n LinearGradient(props: LinearGradientProps) {\n return new LinearGradientNode(this.ctx, props);\n }\n\n RadialGradient(props: RadialGradientProps) {\n return new RadialGradientNode(this.ctx, props);\n }\n\n TwoPointConicalGradient(props: TwoPointConicalGradientProps) {\n return new TwoPointConicalGradientNode(this.ctx, props);\n }\n\n // Path Effects\n CornerPathEffect(props: CornerPathEffectProps) {\n return new CornerPathEffectNode(this.ctx, props);\n }\n\n DiscretePathEffect(props: DiscretePathEffectProps) {\n return new DiscretePathEffectNode(this.ctx, props);\n }\n\n DashPathEffect(props: DashPathEffectProps) {\n return new DashPathEffectNode(this.ctx, props);\n }\n\n Path1DPathEffect(props: Path1DPathEffectProps) {\n return new Path1DPathEffectNode(this.ctx, props);\n }\n\n Path2DPathEffect(props: Path2DPathEffectProps) {\n return new Path2DPathEffectNode(this.ctx, props);\n }\n\n SumPathEffect() {\n return new SumPathEffectNode(this.ctx);\n }\n\n Line2DPathEffect(props: Line2DPathEffectProps) {\n return new Line2DPathEffectNode(this.ctx, props);\n }\n\n Blend(props: BlendProps) {\n return new BlendNode(this.ctx, props);\n }\n\n BackdropFilter(props: ChildrenProps) {\n return new BackdropFilterNode(this.ctx, props);\n }\n\n Box(props: BoxProps) {\n return new BoxNode(this.ctx, props);\n }\n\n BoxShadow(props: BoxShadowProps) {\n return new BoxShadowNode(this.ctx, props);\n }\n}\n"],"mappings":"AA2DA,SACEA,QADF,EAEEC,SAFF,EAGEC,UAHF,EAIEC,QAJF,EAKEC,QALF,EAMEC,SANF,EAOEC,UAPF,EAQEC,QARF,EASEC,SATF,EAUEC,YAVF,EAW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ticesNode","TextNode","OvalNode","CustomDrawingNode","TextPathNode","TextBlobNode","GlyphsNode","DiffRectNode","PictureNode","ImageSVGNode","BackdropFilterNode","BoxNode","BoxShadowNode","BlendImageFilterNode","BlurImageFilterNode","BlurMaskFilterNode","DisplacementMapImageFilterNode","DropShadowImageFilterNode","OffsetImageFilterNode","RuntimeShaderImageFilterNode","CornerPathEffectNode","DiscretePathEffectNode","DashPathEffectNode","Path1DPathEffectNode","Path2DPathEffectNode","SumPathEffectNode","Line2DPathEffectNode","BlendNode","MatrixColorFilterNode","LumaColorFilterNode","LinearToSRGBGammaColorFilterNode","SRGBToLinearGammaColorFilterNode","BlendColorFilterNode","LerpColorFilterNode","LinearGradientNode","ShaderNode","ImageShaderNode","TwoPointConicalGradientNode","TurbulenceNode","SweepGradientNode","RadialGradientNode","FractalNoiseNode","ColorNode","MorphologyImageFilterNode","GroupNode","PaintNode","LayerNode","JsiSkDOM","constructor","ctx","Layer","props","global","SkiaDomApi","Group","Paint","Fill","Image","Circle","Path","CustomDrawing","Line","Oval","Patch","Points","Rect","RRect","Vertices","Text","TextPath","TextBlob","Glyphs","DiffRect","Picture","ImageSVG","BlurMaskFilter","BlendImageFilter","DropShadowImageFilter","DisplacementMapImageFilter","BlurImageFilter","OffsetImageFilter","MorphologyImageFilter","RuntimeShaderImageFilter","MatrixColorFilter","BlendColorFilter","LumaColorFilter","LinearToSRGBGammaColorFilter","SRGBToLinearGammaColorFilter","LerpColorFilter","Shader","ImageShader","ColorShader","ColorShaderNode","SweepGradient","Turbulence","FractalNoise","LinearGradient","RadialGradient","TwoPointConicalGradient","CornerPathEffect","DiscretePathEffect","DashPathEffect","Path1DPathEffect","Path2DPathEffect","SumPathEffect","Line2DPathEffect","Blend","BackdropFilter","Box","BoxShadow"],"sources":["JsiSkDOM.ts"],"sourcesContent":["import type {\n PathProps,\n SkDOM,\n GroupProps,\n ImageProps,\n BlurImageFilterProps,\n MatrixColorFilterProps,\n CircleProps,\n BlurMaskFilterProps,\n LinearGradientProps,\n PaintProps,\n ShaderProps,\n ImageShaderProps,\n CustomDrawingNodeProps,\n LineProps,\n OvalProps,\n PatchProps,\n PointsProps,\n RectProps,\n RoundedRectProps,\n VerticesProps,\n TextProps,\n DiffRectProps,\n OffsetImageFilterProps,\n BlendColorFilterProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n TwoPointConicalGradientProps,\n TurbulenceProps,\n SweepGradientProps,\n RadialGradientProps,\n FractalNoiseProps,\n ColorProps,\n PictureProps,\n ImageSVGProps,\n LerpColorFilterProps,\n DrawingNodeProps,\n BoxProps,\n BoxShadowProps,\n ChildrenProps,\n} from \"../types\";\nimport type {\n BlendImageFilterProps,\n BlendProps,\n DisplacementMapImageFilterProps,\n DropShadowImageFilterProps,\n MorphologyImageFilterProps,\n RuntimeShaderImageFilterProps,\n} from \"../types/ImageFilters\";\nimport type {\n CornerPathEffectProps,\n DashPathEffectProps,\n DiscretePathEffectProps,\n Line2DPathEffectProps,\n Path1DPathEffectProps,\n Path2DPathEffectProps,\n} from \"../types/PathEffects\";\n\nimport {\n FillNode,\n ImageNode,\n CircleNode,\n PathNode,\n LineNode,\n PatchNode,\n PointsNode,\n RectNode,\n RRectNode,\n VerticesNode,\n TextNode,\n OvalNode,\n CustomDrawingNode,\n TextPathNode,\n TextBlobNode,\n GlyphsNode,\n DiffRectNode,\n PictureNode,\n ImageSVGNode,\n BackdropFilterNode,\n BoxNode,\n BoxShadowNode,\n} from \"./drawings\";\nimport {\n BlendImageFilterNode,\n BlurImageFilterNode,\n BlurMaskFilterNode,\n DisplacementMapImageFilterNode,\n DropShadowImageFilterNode,\n OffsetImageFilterNode,\n RuntimeShaderImageFilterNode,\n CornerPathEffectNode,\n DiscretePathEffectNode,\n DashPathEffectNode,\n Path1DPathEffectNode,\n Path2DPathEffectNode,\n SumPathEffectNode,\n Line2DPathEffectNode,\n BlendNode,\n} from \"./paint\";\nimport {\n MatrixColorFilterNode,\n LumaColorFilterNode,\n LinearToSRGBGammaColorFilterNode,\n SRGBToLinearGammaColorFilterNode,\n BlendColorFilterNode,\n LerpColorFilterNode,\n} from \"./paint/ColorFilters\";\nimport {\n LinearGradientNode,\n ShaderNode,\n ImageShaderNode,\n TwoPointConicalGradientNode,\n TurbulenceNode,\n SweepGradientNode,\n RadialGradientNode,\n FractalNoiseNode,\n ColorNode,\n} from \"./paint/Shaders\";\nimport { MorphologyImageFilterNode } from \"./paint/ImageFilters\";\nimport { GroupNode } from \"./GroupNode\";\nimport { PaintNode } from \"./PaintNode\";\nimport type { NodeContext } from \"./Node\";\nimport { LayerNode } from \"./LayerNode\";\n\nexport class JsiSkDOM implements SkDOM {\n constructor(private ctx: NodeContext) {}\n\n Layer(props?: ChildrenProps) {\n return global.SkiaDomApi && global.SkiaDomApi.LayerNode\n ? global.SkiaDomApi.LayerNode(props ?? {})\n : new LayerNode(this.ctx, props ?? {});\n }\n\n Group(props?: GroupProps) {\n return global.SkiaDomApi && global.SkiaDomApi.GroupNode\n ? global.SkiaDomApi.GroupNode(props ?? {})\n : new GroupNode(this.ctx, props ?? {});\n }\n\n Paint(props: PaintProps) {\n return global.SkiaDomApi && global.SkiaDomApi.PaintNode\n ? global.SkiaDomApi.PaintNode(props ?? {})\n : new PaintNode(this.ctx, props);\n }\n\n // Drawings\n Fill(props?: DrawingNodeProps) {\n return global.SkiaDomApi && global.SkiaDomApi.FillNode\n ? global.SkiaDomApi.FillNode(props ?? {})\n : new FillNode(this.ctx, props);\n }\n\n Image(props: ImageProps) {\n return global.SkiaDomApi && global.SkiaDomApi.ImageNode\n ? global.SkiaDomApi.ImageNode(props ?? {})\n : new ImageNode(this.ctx, props);\n }\n\n Circle(props: CircleProps) {\n return global.SkiaDomApi && global.SkiaDomApi.CircleNode\n ? global.SkiaDomApi.CircleNode(props ?? {})\n : new CircleNode(this.ctx, props);\n }\n\n Path(props: PathProps) {\n return global.SkiaDomApi && global.SkiaDomApi.PathNode\n ? global.SkiaDomApi.PathNode(props ?? {})\n : new PathNode(this.ctx, props);\n }\n\n CustomDrawing(props: CustomDrawingNodeProps) {\n return global.SkiaDomApi && global.SkiaDomApi.CustomDrawingNode\n ? global.SkiaDomApi.CustomDrawingNode(props ?? {})\n : new CustomDrawingNode(this.ctx, props);\n }\n\n Line(props: LineProps) {\n return global.SkiaDomApi && global.SkiaDomApi.LineNode\n ? global.SkiaDomApi.LineNode(props ?? {})\n : new LineNode(this.ctx, props);\n }\n\n Oval(props: OvalProps) {\n return global.SkiaDomApi && global.SkiaDomApi.OvalNode\n ? global.SkiaDomApi.OvalNode(props ?? {})\n : new OvalNode(this.ctx, props);\n }\n\n Patch(props: PatchProps) {\n return global.SkiaDomApi && global.SkiaDomApi.PatchNode\n ? global.SkiaDomApi.PatchNode(props ?? {})\n : new PatchNode(this.ctx, props);\n }\n\n Points(props: PointsProps) {\n return global.SkiaDomApi && global.SkiaDomApi.PointsNode\n ? global.SkiaDomApi.PointsNode(props ?? {})\n : new PointsNode(this.ctx, props);\n }\n\n Rect(props: RectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.RectNode\n ? global.SkiaDomApi.RectNode(props)\n : new RectNode(this.ctx, props);\n }\n\n RRect(props: RoundedRectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.RRectNode\n ? global.SkiaDomApi.RRectNode(props)\n : new RRectNode(this.ctx, props);\n }\n\n Vertices(props: VerticesProps) {\n return global.SkiaDomApi && global.SkiaDomApi.VerticesNode\n ? global.SkiaDomApi.VerticesNode(props)\n : new VerticesNode(this.ctx, props);\n }\n\n Text(props: TextProps) {\n return global.SkiaDomApi && global.SkiaDomApi.TextNode\n ? global.SkiaDomApi.TextNode(props)\n : new TextNode(this.ctx, props);\n }\n\n TextPath(props: TextPathProps) {\n return global.SkiaDomApi && global.SkiaDomApi.TextPathNode\n ? global.SkiaDomApi.TextPathNode(props)\n : new TextPathNode(this.ctx, props);\n }\n\n TextBlob(props: TextBlobProps) {\n return global.SkiaDomApi && global.SkiaDomApi.TextBlobNode\n ? global.SkiaDomApi.TextBlobNode(props)\n : new TextBlobNode(this.ctx, props);\n }\n\n Glyphs(props: GlyphsProps) {\n return global.SkiaDomApi && global.SkiaDomApi.GlyphsNode\n ? global.SkiaDomApi.GlyphsNode(props)\n : new GlyphsNode(this.ctx, props);\n }\n\n DiffRect(props: DiffRectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.DiffRectNode\n ? global.SkiaDomApi.DiffRectNode(props)\n : new DiffRectNode(this.ctx, props);\n }\n\n Picture(props: PictureProps) {\n return global.SkiaDomApi && global.SkiaDomApi.PictureNode\n ? global.SkiaDomApi.PictureNode(props)\n : new PictureNode(this.ctx, props);\n }\n\n ImageSVG(props: ImageSVGProps) {\n return global.SkiaDomApi && global.SkiaDomApi.ImageSVGNode\n ? global.SkiaDomApi.ImageSVGNode(props)\n : new ImageSVGNode(this.ctx, props);\n }\n\n // BlurMaskFilters\n BlurMaskFilter(props: BlurMaskFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BlurMaskFilterNode\n ? global.SkiaDomApi.BlurMaskFilterNode(props)\n : new BlurMaskFilterNode(this.ctx, props);\n }\n\n // ImageFilters\n BlendImageFilter(props: BlendImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BlendImageFilterNode\n ? global.SkiaDomApi.BlendImageFilterNode(props)\n : new BlendImageFilterNode(this.ctx, props);\n }\n\n DropShadowImageFilter(props: DropShadowImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.DropShadowImageFilterNode\n ? global.SkiaDomApi.DropShadowImageFilterNode(props)\n : new DropShadowImageFilterNode(this.ctx, props);\n }\n\n DisplacementMapImageFilter(props: DisplacementMapImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.DisplacementMapImageFilterNode\n ? global.SkiaDomApi.DisplacementMapImageFilterNode(props)\n : new DisplacementMapImageFilterNode(this.ctx, props);\n }\n\n BlurImageFilter(props: BlurImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BlurImageFilterNode\n ? global.SkiaDomApi.BlurImageFilterNode(props)\n : new BlurImageFilterNode(this.ctx, props);\n }\n\n OffsetImageFilter(props: OffsetImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.OffsetImageFilterNode\n ? global.SkiaDomApi.OffsetImageFilterNode(props)\n : new OffsetImageFilterNode(this.ctx, props);\n }\n\n MorphologyImageFilter(props: MorphologyImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.MorphologyImageFilterNode\n ? global.SkiaDomApi.MorphologyImageFilterNode(props)\n : new MorphologyImageFilterNode(this.ctx, props);\n }\n\n RuntimeShaderImageFilter(props: RuntimeShaderImageFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.RuntimeShaderImageFilterNode\n ? global.SkiaDomApi.RuntimeShaderImageFilterNode(props)\n : new RuntimeShaderImageFilterNode(this.ctx, props);\n }\n\n // Color Filters\n MatrixColorFilter(props: MatrixColorFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.MatrixColorFilterNode\n ? global.SkiaDomApi.MatrixColorFilterNode(props)\n : new MatrixColorFilterNode(this.ctx, props);\n }\n\n BlendColorFilter(props: BlendColorFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BlendColorFilterNode\n ? global.SkiaDomApi.BlendColorFilterNode(props)\n : new BlendColorFilterNode(this.ctx, props);\n }\n\n LumaColorFilter() {\n return global.SkiaDomApi && global.SkiaDomApi.LumaColorFilterNode\n ? global.SkiaDomApi.LumaColorFilterNode()\n : new LumaColorFilterNode(this.ctx);\n }\n\n LinearToSRGBGammaColorFilter() {\n return global.SkiaDomApi &&\n global.SkiaDomApi.LinearToSRGBGammaColorFilterNode\n ? global.SkiaDomApi.LinearToSRGBGammaColorFilterNode()\n : new LinearToSRGBGammaColorFilterNode(this.ctx);\n }\n\n SRGBToLinearGammaColorFilter() {\n return global.SkiaDomApi &&\n global.SkiaDomApi.SRGBToLinearGammaColorFilterNode\n ? global.SkiaDomApi.SRGBToLinearGammaColorFilterNode()\n : new SRGBToLinearGammaColorFilterNode(this.ctx);\n }\n\n LerpColorFilter(props: LerpColorFilterProps) {\n return global.SkiaDomApi && global.SkiaDomApi.LerpColorFilterNode\n ? global.SkiaDomApi.LerpColorFilterNode(props)\n : new LerpColorFilterNode(this.ctx, props);\n }\n\n // Shaders\n Shader(props: ShaderProps) {\n return global.SkiaDomApi && global.SkiaDomApi.ShaderNode\n ? global.SkiaDomApi.ShaderNode(props)\n : new ShaderNode(this.ctx, props);\n }\n\n ImageShader(props: ImageShaderProps) {\n return global.SkiaDomApi && global.SkiaDomApi.ImageShaderNode\n ? global.SkiaDomApi.ImageShaderNode(props)\n : new ImageShaderNode(this.ctx, props);\n }\n\n ColorShader(props: ColorProps) {\n return global.SkiaDomApi && global.SkiaDomApi.ColorShaderNode\n ? global.SkiaDomApi.ColorShaderNode(props)\n : new ColorNode(this.ctx, props);\n }\n\n SweepGradient(props: SweepGradientProps) {\n return global.SkiaDomApi && global.SkiaDomApi.SweepGradientNode\n ? global.SkiaDomApi.SweepGradientNode(props)\n : new SweepGradientNode(this.ctx, props);\n }\n\n Turbulence(props: TurbulenceProps) {\n return global.SkiaDomApi && global.SkiaDomApi.TurbulenceNode\n ? global.SkiaDomApi.TurbulenceNode(props)\n : new TurbulenceNode(this.ctx, props);\n }\n\n FractalNoise(props: FractalNoiseProps) {\n return global.SkiaDomApi && global.SkiaDomApi.FractalNoiseNode\n ? global.SkiaDomApi.FractalNoiseNode(props)\n : new FractalNoiseNode(this.ctx, props);\n }\n\n LinearGradient(props: LinearGradientProps) {\n return global.SkiaDomApi && global.SkiaDomApi.LinearGradientNode\n ? global.SkiaDomApi.LinearGradientNode(props)\n : new LinearGradientNode(this.ctx, props);\n }\n\n RadialGradient(props: RadialGradientProps) {\n return global.SkiaDomApi && global.SkiaDomApi.RadialGradientNode\n ? global.SkiaDomApi.RadialGradientNode(props)\n : new RadialGradientNode(this.ctx, props);\n }\n\n TwoPointConicalGradient(props: TwoPointConicalGradientProps) {\n return global.SkiaDomApi && global.SkiaDomApi.TwoPointConicalGradientNode\n ? global.SkiaDomApi.TwoPointConicalGradientNode(props)\n : new TwoPointConicalGradientNode(this.ctx, props);\n }\n\n // Path Effects\n CornerPathEffect(props: CornerPathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.CornerPathEffectNode\n ? global.SkiaDomApi.CornerPathEffectNode(props)\n : new CornerPathEffectNode(this.ctx, props);\n }\n\n DiscretePathEffect(props: DiscretePathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.DiscretePathEffectNode\n ? global.SkiaDomApi.DiscretePathEffectNode(props)\n : new DiscretePathEffectNode(this.ctx, props);\n }\n\n DashPathEffect(props: DashPathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.DashPathEffectNode\n ? global.SkiaDomApi.DashPathEffectNode(props)\n : new DashPathEffectNode(this.ctx, props);\n }\n\n Path1DPathEffect(props: Path1DPathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.Path1DPathEffectNode\n ? global.SkiaDomApi.Path1DPathEffectNode(props)\n : new Path1DPathEffectNode(this.ctx, props);\n }\n\n Path2DPathEffect(props: Path2DPathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.Path2DPathEffectNode\n ? global.SkiaDomApi.Path2DPathEffectNode(props)\n : new Path2DPathEffectNode(this.ctx, props);\n }\n\n SumPathEffect() {\n return global.SkiaDomApi && global.SkiaDomApi.SumPathEffectNode\n ? global.SkiaDomApi.SumPathEffectNode()\n : new SumPathEffectNode(this.ctx);\n }\n\n Line2DPathEffect(props: Line2DPathEffectProps) {\n return global.SkiaDomApi && global.SkiaDomApi.Line2DPathEffectNode\n ? global.SkiaDomApi.Line2DPathEffectNode(props)\n : new Line2DPathEffectNode(this.ctx, props);\n }\n\n Blend(props: BlendProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BlendNode\n ? global.SkiaDomApi.BlendNode(props)\n : new BlendNode(this.ctx, props);\n }\n\n BackdropFilter(props: ChildrenProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BackdropFilterNode\n ? global.SkiaDomApi.BackdropFilterNode(props)\n : new BackdropFilterNode(this.ctx, props);\n }\n\n Box(props: BoxProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BoxNode\n ? global.SkiaDomApi.BoxNode(props)\n : new BoxNode(this.ctx, props);\n }\n\n BoxShadow(props: BoxShadowProps) {\n return global.SkiaDomApi && global.SkiaDomApi.BoxShadowNode\n ? global.SkiaDomApi.BoxShadowNode(props)\n : new BoxShadowNode(this.ctx, props);\n }\n}\n"],"mappings":"AA2DA,SACEA,QADF,EAEEC,SAFF,EAGEC,UAHF,EAIEC,QAJF,EAKEC,QALF,EAMEC,SANF,EAOEC,UAPF,EAQEC,QARF,EASEC,SATF,EAUEC,YAVF,EAWEC,QAXF,EAYEC,QAZF,EAaEC,iBAbF,EAcEC,YAdF,EAeEC,YAfF,EAgBEC,UAhBF,EAiBEC,YAjBF,EAkBEC,WAlBF,EAmBEC,YAnBF,EAoBEC,kBApBF,EAqBEC,OArBF,EAsBEC,aAtBF,QAuBO,YAvBP;AAwBA,SACEC,oBADF,EAEEC,mBAFF,EAGEC,kBAHF,EAIEC,8BAJF,EAKEC,yBALF,EAMEC,qBANF,EAOEC,4BAPF,EAQEC,oBARF,EASEC,sBATF,EAUEC,kBAVF,EAWEC,oBAXF,EAYEC,oBAZF,EAaEC,iBAbF,EAcEC,oBAdF,EAeEC,SAfF,QAgBO,SAhBP;AAiBA,SACEC,qBADF,EAEEC,mBAFF,EAGEC,gCAHF,EAIEC,gCAJF,EAKEC,oBALF,EAMEC,mBANF,QAOO,sBAPP;AAQA,SACEC,kBADF,EAEEC,UAFF,EAGEC,eAHF,EAIEC,2BAJF,EAKEC,cALF,EAMEC,iBANF,EAOEC,kBAPF,EAQEC,gBARF,EASEC,SATF,QAUO,iBAVP;AAWA,SAASC,yBAAT,QAA0C,sBAA1C;AACA,SAASC,SAAT,QAA0B,aAA1B;AACA,SAASC,SAAT,QAA0B,aAA1B;A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KuB,GAA9B,EAAmCE,KAAnC,CAFJ;EAGD;;EAEDuD,KAAK,CAACvD,KAAD,EAAoB;IACvB,OAAOC,MAAM,CAACC,UAAP,IAAqBD,MAAM,CAACC,UAAP,CAAkB1B,SAAvC,GACHyB,MAAM,CAACC,UAAP,CAAkB1B,SAAlB,CAA4BwB,KAA5B,CADG,GAEH,IAAIxB,SAAJ,CAAc,KAAKsB,GAAnB,EAAwBE,KAAxB,CAFJ;EAGD;;EAEDwD,cAAc,CAACxD,KAAD,EAAuB;IACnC,OAAOC,MAAM,CAACC,UAAP,IAAqBD,MAAM,CAACC,UAAP,CAAkB3C,kBAAvC,GACH0C,MAAM,CAACC,UAAP,CAAkB3C,kBAAlB,CAAqCyC,KAArC,CADG,GAEH,IAAIzC,kBAAJ,CAAuB,KAAKuC,GAA5B,EAAiCE,KAAjC,CAFJ;EAGD;;EAEDyD,GAAG,CAACzD,KAAD,EAAkB;IACnB,OAAOC,MAAM,CAACC,UAAP,IAAqBD,MAAM,CAACC,UAAP,CAAkB1C,OAAvC,GACHyC,MAAM,CAACC,UAAP,CAAkB1C,OAAlB,CAA0BwC,KAA1B,CADG,GAEH,IAAIxC,OAAJ,CAAY,KAAKsC,GAAjB,EAAsBE,KAAtB,CAFJ;EAGD;;EAED0D,SAAS,CAAC1D,KAAD,EAAwB;IAC/B,OAAOC,MAAM,CAACC,UAAP,IAAqBD,MAAM,CAACC,UAAP,CAAkBzC,aAAvC,GACHwC,MAAM,CAACC,UAAP,CAAkBzC,aAAlB,CAAgCuC,KAAhC,CADG,GAEH,IAAIvC,aAAJ,CAAkB,KAAKqC,GAAvB,EAA4BE,KAA5B,CAFJ;EAGD;;AAzVoC"}
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["StrokeCap","StrokeJoin","PaintStyle","BlendMode","ClipOp","isRRect","isPathDef","processPath","processTransformProps","JsiNode","JsiDeclarationNode","enumKey","paintProps","JsiRenderNode","constructor","ctx","type","props","matrix","Skia","Matrix","onPropChange","setProps","paintCache","setProp","key","value","hasChanged","includes","identity","clipPath","undefined","clipRect","clipRRect","computeMatrix","computeClip","addChild","child","setInvalidate","insertChildBefore","before","clip","getPaintCtx","color","strokeWidth","blendMode","style","strokeJoin","strokeCap","strokeMiter","opacity","antiAlias","Color","_children","forEach","isColorFilter","cf","materialize","colorFilter","ColorFilter","MakeCompose","isShader","shader","isPathEffect","pe","pathEffect","PathEffect","isImageFilter","filter","imageFilter","ImageFilter","isMaskFilter","maskFilter","render","parentCtx","invertClip","layer","transform","canvas","parent","paint","paintCtx","concatPaint","hasTransform","hasClip","shouldSave","op","Difference","Intersect","saveLayer","save","concat","renderNode","restore","alpha","copy","setShader","setColor","cl","getColor","setStrokeWidth","setAntiAlias","setBlendMode","setColorFilter","setImageFilter","setMaskFilter","setPathEffect","setAlphaf","setStrokeCap","setStrokeJoin","setStrokeMiter","setStyle"],"sources":["RenderNode.ts"],"sourcesContent":["import type {\n SkMatrix,\n SkRect,\n SkRRect,\n SkPath,\n SkPaint,\n} from \"../../skia/types\";\nimport {\n StrokeCap,\n StrokeJoin,\n PaintStyle,\n BlendMode,\n ClipOp,\n isRRect,\n} from \"../../skia/types\";\nimport type {\n RenderNode,\n GroupProps,\n DrawingContext,\n NodeType,\n Node,\n} from \"../types\";\n\nimport { isPathDef, processPath, processTransformProps } from \"./datatypes\";\nimport type { NodeContext } from \"./Node\";\nimport { JsiNode, JsiDeclarationNode } from \"./Node\";\nimport type { PaintContext } from \"./PaintContext\";\nimport { enumKey } from \"./datatypes/Enum\";\n\nconst paintProps = [\n \"color\",\n \"strokeWidth\",\n \"blendMode\",\n \"strokeCap\",\n \"strokeJoin\",\n \"strokeMiter\",\n \"style\",\n \"antiAlias\",\n \"opacity\",\n];\n\ninterface PaintCache {\n parent: SkPaint;\n child: SkPaint;\n}\n\nexport abstract class JsiRenderNode<P extends GroupProps>\n extends JsiNode<P>\n implements RenderNode<P>\n{\n paintCache: PaintCache | null = null;\n matrix: SkMatrix;\n clipRect?: SkRect;\n clipRRect?: SkRRect;\n clipPath?: SkPath;\n\n constructor(ctx: NodeContext, type: NodeType, props: P) {\n super(ctx, type, props);\n this.matrix = this.Skia.Matrix();\n this.onPropChange();\n }\n\n setProps(props: P) {\n super.setProps(props);\n this.onPropChange();\n this.paintCache = null;\n }\n\n setProp<K extends keyof P>(key: K, value: P[K]) {\n const hasChanged = super.setProp(key, value);\n if (hasChanged) {\n this.onPropChange();\n if (paintProps.includes(key as string)) {\n this.paintCache = null;\n }\n }\n return hasChanged;\n }\n\n protected onPropChange() {\n this.matrix.identity();\n this.clipPath = undefined;\n this.clipRect = undefined;\n this.clipRRect = undefined;\n this.computeMatrix();\n this.computeClip();\n }\n\n addChild(child: Node<unknown>) {\n if (child instanceof JsiDeclarationNode) {\n child.setInvalidate(() => (this.paintCache = null));\n }\n super.addChild(child);\n }\n\n insertChildBefore(child: Node<unknown>, before: Node<unknown>) {\n if (child instanceof JsiDeclarationNode) {\n child.setInvalidate(() => (this.paintCache = null));\n }\n super.insertChildBefore(child, before);\n }\n\n private computeClip() {\n const { clip } = this.props;\n if (clip) {\n if (isPathDef(clip)) {\n this.clipPath = processPath(this.Skia, clip);\n } else if (isRRect(clip)) {\n this.clipRRect = clip;\n } else {\n this.clipRect = clip;\n }\n }\n }\n\n private computeMatrix() {\n processTransformProps(this.matrix, this.props);\n }\n\n private getPaintCtx() {\n let ctx: PaintContext | undefined;\n const {\n color,\n strokeWidth,\n blendMode,\n style,\n strokeJoin,\n strokeCap,\n strokeMiter,\n opacity,\n antiAlias,\n } = this.props;\n if (\n color !== undefined ||\n strokeWidth !== undefined ||\n blendMode !== undefined ||\n style !== undefined ||\n strokeJoin !== undefined ||\n strokeCap !== undefined ||\n strokeMiter !== undefined ||\n opacity !== undefined ||\n antiAlias !== undefined\n ) {\n ctx = {};\n if (color !== undefined) {\n ctx.color = this.Skia.Color(color);\n }\n if (strokeWidth !== undefined) {\n ctx.strokeWidth = strokeWidth;\n }\n if (blendMode !== undefined) {\n ctx.blendMode = BlendMode[enumKey(blendMode)];\n }\n if (style !== undefined) {\n ctx.style = PaintStyle[enumKey(style)];\n }\n if (strokeJoin !== undefined) {\n ctx.strokeJoin = StrokeJoin[enumKey(strokeJoin)];\n }\n if (strokeCap !== undefined) {\n ctx.strokeCap = StrokeCap[enumKey(strokeCap)];\n }\n if (strokeMiter !== undefined) {\n ctx.strokeMiter = strokeMiter;\n }\n if (opacity !== undefined) {\n ctx.opacity = opacity;\n }\n if (antiAlias !== undefined) {\n ctx.antiAlias = antiAlias;\n }\n }\n this._children.forEach((child) => {\n if (child instanceof JsiDeclarationNode) {\n if (child.isColorFilter()) {\n ctx = ctx || {};\n const cf = child.materialize();\n ctx.colorFilter = ctx.colorFilter\n ? this.Skia.ColorFilter.MakeCompose(cf, ctx.colorFilter)\n : cf;\n } else if (child.isShader()) {\n ctx = ctx || {};\n const shader = child.materialize();\n ctx.shader = shader;\n } else if (child.isPathEffect()) {\n ctx = ctx || {};\n const pe = child.materialize();\n ctx.pathEffect = ctx.pathEffect\n ? this.Skia.PathEffect.MakeCompose(pe, ctx.pathEffect)\n : pe;\n } else if (child.isImageFilter()) {\n ctx = ctx || {};\n const filter = child.materialize();\n ctx.imageFilter = ctx.imageFilter\n ? this.Skia.ImageFilter.MakeCompose(filter, ctx.imageFilter)\n : filter;\n } else if (child.isMaskFilter()) {\n ctx = ctx || {};\n const filter = child.materialize();\n ctx.maskFilter = filter;\n }\n }\n });\n return ctx;\n }\n\n render(parentCtx: DrawingContext) {\n const { invertClip, layer, matrix, transform } = this.props;\n const { canvas } = parentCtx;\n\n const opacity =\n this.props.opacity !== undefined\n ? parentCtx.opacity * this.props.opacity\n : parentCtx.opacity;\n\n if (\n this.paintCache === null ||\n this.paintCache.parent !== parentCtx.paint\n ) {\n const paintCtx = this.getPaintCtx();\n const child = paintCtx\n ? concatPaint(parentCtx.paint, paintCtx, parentCtx.opacity)\n : parentCtx.paint;\n this.paintCache = { parent: parentCtx.paint, child };\n }\n const paint = this.paintCache.child;\n // TODO: can we only recreate a new context here if needed?\n const ctx = { ...parentCtx, opacity, paint };\n const hasTransform = matrix !== undefined || transform !== undefined;\n const hasClip =\n this.clipRect !== undefined ||\n this.clipPath !== undefined ||\n this.clipRRect !== undefined;\n const shouldSave = hasTransform || hasClip || !!layer;\n const op = invertClip ? ClipOp.Difference : ClipOp.Intersect;\n if (shouldSave) {\n if (layer) {\n if (typeof layer === \"boolean\") {\n canvas.saveLayer();\n } else {\n canvas.saveLayer(layer);\n }\n } else {\n canvas.save();\n }\n }\n\n if (this.matrix) {\n canvas.concat(this.matrix);\n }\n if (this.clipRect) {\n canvas.clipRect(this.clipRect, op, true);\n } else if (this.clipRRect) {\n canvas.clipRRect(this.clipRRect, op, true);\n } else if (this.clipPath) {\n canvas.clipPath(this.clipPath, op, true);\n }\n\n this.renderNode(ctx);\n\n if (shouldSave) {\n canvas.restore();\n }\n }\n\n abstract renderNode(ctx: DrawingContext): void;\n}\n\nconst concatPaint = (\n parent: SkPaint,\n {\n color,\n strokeWidth,\n shader,\n antiAlias,\n blendMode,\n colorFilter,\n imageFilter,\n maskFilter,\n pathEffect,\n opacity: alpha,\n strokeCap,\n strokeJoin,\n strokeMiter,\n style,\n }: PaintContext,\n opacity: number\n) => {\n const paint = parent.copy();\n if (color !== undefined) {\n paint.setShader(null);\n color[3] *= opacity;\n paint.setColor(color);\n } else {\n const cl = paint.getColor();\n cl[3] *= opacity;\n paint.setColor(cl);\n }\n if (strokeWidth !== undefined) {\n paint.setStrokeWidth(strokeWidth);\n }\n if (shader !== undefined) {\n paint.setShader(shader);\n }\n if (antiAlias !== undefined) {\n paint.setAntiAlias(antiAlias);\n }\n if (blendMode !== undefined) {\n paint.setBlendMode(blendMode);\n }\n if (colorFilter !== undefined) {\n paint.setColorFilter(colorFilter);\n }\n if (imageFilter !== undefined) {\n paint.setImageFilter(imageFilter);\n }\n if (maskFilter !== undefined) {\n paint.setMaskFilter(maskFilter);\n }\n if (pathEffect !== undefined) {\n paint.setPathEffect(pathEffect);\n }\n if (alpha !== undefined) {\n paint.setAlphaf(alpha * opacity);\n }\n if (strokeCap !== undefined) {\n paint.setStrokeCap(strokeCap);\n }\n if (strokeJoin !== undefined) {\n paint.setStrokeJoin(strokeJoin);\n }\n if (strokeMiter !== undefined) {\n paint.setStrokeMiter(strokeMiter);\n }\n if (style !== undefined) {\n paint.setStyle(style);\n }\n return paint;\n};\n"],"mappings":";;AAOA,SACEA,SADF,EAEEC,UAFF,EAGEC,UAHF,EAIEC,SAJF,EAKEC,MALF,EAMEC,OANF,QAOO,kBAPP;AAgBA,SAASC,SAAT,EAAoBC,WAApB,EAAiCC,qBAAjC,QAA8D,aAA9D;AAEA,SAASC,OAAT,EAAkBC,kBAAlB,QAA4C,QAA5C;AAEA,SAASC,OAAT,QAAwB,kBAAxB;AAEA,MAAMC,UAAU,GAAG,CACjB,OADiB,EAEjB,aAFiB,EAGjB,WAHiB,EAIjB,WAJiB,EAKjB,YALiB,EAMjB,aANiB,EAOjB,OAPiB,EAQjB,WARiB,EASjB,SATiB,CAAnB;AAiBA,OAAO,MAAeC,aAAf,SACGJ,OADH,CAGP;EAOEK,WAAW,CAACC,GAAD,EAAmBC,IAAnB,EAAmCC,KAAnC,EAA6C;IACtD,MAAMF,GAAN,EAAWC,IAAX,EAAiBC,KAAjB;;IADsD,oCANxB,IAMwB;;IAAA;;IAAA;;IAAA;;IAAA;;IAEtD,KAAKC,MAAL,GAAc,KAAKC,IAAL,CAAUC,MAAV,EAAd;IACA,KAAKC,YAAL;EACD;;EAEDC,QAAQ,CAACL,KAAD,EAAW;IACjB,MAAMK,QAAN,CAAeL,KAAf;IACA,KAAKI,YAAL;IACA,KAAKE,UAAL,GAAkB,IAAlB;EACD;;EAEDC,OAAO,CAAoBC,GAApB,EAA4BC,KAA5B,EAAyC;IAC9C,MAAMC,UAAU,GAAG,MAAMH,OAAN,CAAcC,GAAd,EAAmBC,KAAnB,CAAnB;;IACA,IAAIC,UAAJ,EAAgB;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AAIW,WAAW,KAAKtC,SAApB,EAA+B;IAC7BiD,KAAK,CAACwB,cAAN,CAAqBnC,WAArB;EACD;;EACD,IAAIG,UAAU,KAAKzC,SAAnB,EAA8B;IAC5BiD,KAAK,CAACyB,aAAN,CAAoBjC,UAApB;EACD;;EACD,IAAIP,UAAU,KAAKlC,SAAnB,EAA8B;IAC5BiD,KAAK,CAAC0B,aAAN,CAAoBzC,UAApB;EACD;;EACD,IAAI6B,KAAK,KAAK/D,SAAd,EAAyB;IACvBiD,KAAK,CAAC2B,SAAN,CAAgBb,KAAK,GAAG5C,OAAxB;EACD;;EACD,IAAIF,SAAS,KAAKjB,SAAlB,EAA6B;IAC3BiD,KAAK,CAAC4B,YAAN,CAAmB5D,SAAnB;EACD;;EACD,IAAID,UAAU,KAAKhB,SAAnB,EAA8B;IAC5BiD,KAAK,CAAC6B,aAAN,CAAoB9D,UAApB;EACD;;EACD,IAAIE,WAAW,KAAKlB,SAApB,EAA+B;IAC7BiD,KAAK,CAAC8B,cAAN,CAAqB7D,WAArB;EACD;;EACD,IAAIH,KAAK,KAAKf,SAAd,EAAyB;IACvBiD,KAAK,CAAC+B,QAAN,CAAejE,KAAf;EACD;;EACD,OAAOkC,KAAP;AACD,CAtED"}
|
1
|
+
{"version":3,"names":["StrokeCap","StrokeJoin","PaintStyle","BlendMode","ClipOp","isRRect","isPathDef","processPath","processTransformProps","JsiNode","JsiDeclarationNode","enumKey","paintProps","JsiRenderNode","constructor","ctx","type","props","matrix","Skia","Matrix","onPropChange","setProps","paintCache","setProp","key","value","hasChanged","includes","identity","clipPath","undefined","clipRect","clipRRect","computeMatrix","computeClip","addChild","child","setInvalidate","insertChildBefore","before","clip","getPaintCtx","color","strokeWidth","blendMode","style","strokeJoin","strokeCap","strokeMiter","opacity","antiAlias","Color","_children","forEach","isColorFilter","cf","materialize","colorFilter","ColorFilter","MakeCompose","isShader","shader","isPathEffect","pe","pathEffect","PathEffect","isImageFilter","filter","imageFilter","ImageFilter","isMaskFilter","maskFilter","render","parentCtx","invertClip","layer","transform","canvas","parent","paint","paintCtx","concatPaint","hasTransform","hasClip","shouldSave","op","Difference","Intersect","saveLayer","save","concat","renderNode","restore","alpha","copy","setShader","setColor","cl","getColor","setStrokeWidth","setAntiAlias","setBlendMode","setColorFilter","setImageFilter","setMaskFilter","setPathEffect","setAlphaf","setStrokeCap","setStrokeJoin","setStrokeMiter","setStyle"],"sources":["RenderNode.ts"],"sourcesContent":["import type {\n SkMatrix,\n SkRect,\n SkRRect,\n SkPath,\n SkPaint,\n} from \"../../skia/types\";\nimport {\n StrokeCap,\n StrokeJoin,\n PaintStyle,\n BlendMode,\n ClipOp,\n isRRect,\n} from \"../../skia/types\";\nimport type {\n RenderNode,\n GroupProps,\n DrawingContext,\n NodeType,\n Node,\n} from \"../types\";\n\nimport { isPathDef, processPath, processTransformProps } from \"./datatypes\";\nimport type { NodeContext } from \"./Node\";\nimport { JsiNode, JsiDeclarationNode } from \"./Node\";\nimport type { PaintContext } from \"./PaintContext\";\nimport { enumKey } from \"./datatypes/Enum\";\n\nconst paintProps = [\n \"color\",\n \"strokeWidth\",\n \"blendMode\",\n \"strokeCap\",\n \"strokeJoin\",\n \"strokeMiter\",\n \"style\",\n \"antiAlias\",\n \"opacity\",\n];\n\ninterface PaintCache {\n parent: SkPaint;\n child: SkPaint;\n}\n\nexport abstract class JsiRenderNode<P extends GroupProps>\n extends JsiNode<P>\n implements RenderNode<P>\n{\n paintCache: PaintCache | null = null;\n matrix: SkMatrix;\n clipRect?: SkRect;\n clipRRect?: SkRRect;\n clipPath?: SkPath;\n\n constructor(ctx: NodeContext, type: NodeType, props: P) {\n super(ctx, type, props);\n this.matrix = this.Skia.Matrix();\n this.onPropChange();\n }\n\n setProps(props: P) {\n super.setProps(props);\n this.onPropChange();\n this.paintCache = null;\n }\n\n setProp<K extends keyof P>(key: K, value: P[K]) {\n const hasChanged = super.setProp(key, value);\n if (hasChanged) {\n this.onPropChange();\n if (paintProps.includes(key as string)) {\n this.paintCache = null;\n }\n }\n return hasChanged;\n }\n\n protected onPropChange() {\n this.matrix.identity();\n this.clipPath = undefined;\n this.clipRect = undefined;\n this.clipRRect = undefined;\n this.computeMatrix();\n this.computeClip();\n }\n\n addChild(child: Node<unknown>) {\n if (child instanceof JsiDeclarationNode) {\n child.setInvalidate(() => (this.paintCache = null));\n }\n super.addChild(child);\n }\n\n insertChildBefore(child: Node<unknown>, before: Node<unknown>) {\n if (child instanceof JsiDeclarationNode) {\n child.setInvalidate(() => (this.paintCache = null));\n }\n super.insertChildBefore(child, before);\n }\n\n private computeClip() {\n const { clip } = this.props;\n if (clip) {\n if (isPathDef(clip)) {\n this.clipPath = processPath(this.Skia, clip);\n } else if (isRRect(clip)) {\n this.clipRRect = clip;\n } else {\n this.clipRect = clip;\n }\n }\n }\n\n private computeMatrix() {\n processTransformProps(this.matrix, this.props);\n }\n\n private getPaintCtx() {\n let ctx: PaintContext | undefined;\n const {\n color,\n strokeWidth,\n blendMode,\n style,\n strokeJoin,\n strokeCap,\n strokeMiter,\n opacity,\n antiAlias,\n } = this.props;\n if (\n color !== undefined ||\n strokeWidth !== undefined ||\n blendMode !== undefined ||\n style !== undefined ||\n strokeJoin !== undefined ||\n strokeCap !== undefined ||\n strokeMiter !== undefined ||\n opacity !== undefined ||\n antiAlias !== undefined\n ) {\n ctx = {};\n if (color !== undefined) {\n ctx.color = this.Skia.Color(color);\n }\n if (strokeWidth !== undefined) {\n ctx.strokeWidth = strokeWidth;\n }\n if (blendMode !== undefined) {\n ctx.blendMode = BlendMode[enumKey(blendMode)];\n }\n if (style !== undefined) {\n ctx.style = PaintStyle[enumKey(style)];\n }\n if (strokeJoin !== undefined) {\n ctx.strokeJoin = StrokeJoin[enumKey(strokeJoin)];\n }\n if (strokeCap !== undefined) {\n ctx.strokeCap = StrokeCap[enumKey(strokeCap)];\n }\n if (strokeMiter !== undefined) {\n ctx.strokeMiter = strokeMiter;\n }\n if (opacity !== undefined) {\n ctx.opacity = opacity;\n }\n if (antiAlias !== undefined) {\n ctx.antiAlias = antiAlias;\n }\n }\n this._children.forEach((child) => {\n if (child instanceof JsiDeclarationNode) {\n if (child.isColorFilter()) {\n ctx = ctx || {};\n const cf = child.materialize();\n ctx.colorFilter = ctx.colorFilter\n ? this.Skia.ColorFilter.MakeCompose(cf, ctx.colorFilter)\n : cf;\n } else if (child.isShader()) {\n ctx = ctx || {};\n const shader = child.materialize();\n ctx.shader = shader;\n } else if (child.isPathEffect()) {\n ctx = ctx || {};\n const pe = child.materialize();\n ctx.pathEffect = ctx.pathEffect\n ? this.Skia.PathEffect.MakeCompose(pe, ctx.pathEffect)\n : pe;\n } else if (child.isImageFilter()) {\n ctx = ctx || {};\n const filter = child.materialize();\n ctx.imageFilter = ctx.imageFilter\n ? this.Skia.ImageFilter.MakeCompose(filter, ctx.imageFilter)\n : filter;\n } else if (child.isMaskFilter()) {\n ctx = ctx || {};\n const filter = child.materialize();\n ctx.maskFilter = filter;\n }\n }\n });\n return ctx;\n }\n\n render(parentCtx: DrawingContext) {\n const { invertClip, layer, matrix, transform } = this.props;\n const { canvas } = parentCtx;\n\n const opacity =\n this.props.opacity !== undefined\n ? parentCtx.opacity * this.props.opacity\n : parentCtx.opacity;\n\n if (\n this.paintCache === null ||\n this.paintCache.parent !== parentCtx.paint\n ) {\n const paintCtx = this.getPaintCtx();\n const child = paintCtx\n ? concatPaint(parentCtx.paint, paintCtx, parentCtx.opacity)\n : parentCtx.paint;\n this.paintCache = { parent: parentCtx.paint, child };\n }\n const paint = this.paintCache.child;\n // TODO: can we only recreate a new context here if needed?\n const ctx = { ...parentCtx, opacity, paint };\n const hasTransform = matrix !== undefined || transform !== undefined;\n const hasClip =\n this.clipRect !== undefined ||\n this.clipPath !== undefined ||\n this.clipRRect !== undefined;\n const shouldSave = hasTransform || hasClip || !!layer;\n const op = invertClip ? ClipOp.Difference : ClipOp.Intersect;\n if (shouldSave) {\n if (layer) {\n if (typeof layer === \"boolean\") {\n canvas.saveLayer();\n } else {\n canvas.saveLayer(layer);\n }\n } else {\n canvas.save();\n }\n }\n\n if (this.matrix) {\n canvas.concat(this.matrix);\n }\n if (this.clipRect) {\n canvas.clipRect(this.clipRect, op, true);\n } else if (this.clipRRect) {\n canvas.clipRRect(this.clipRRect, op, true);\n } else if (this.clipPath) {\n canvas.clipPath(this.clipPath, op, true);\n }\n\n this.renderNode(ctx);\n\n if (shouldSave) {\n canvas.restore();\n }\n }\n\n abstract renderNode(ctx: DrawingContext): void;\n}\n\nconst concatPaint = (\n parent: SkPaint,\n {\n color,\n strokeWidth,\n shader,\n antiAlias,\n blendMode,\n colorFilter,\n imageFilter,\n maskFilter,\n pathEffect,\n opacity: alpha,\n strokeCap,\n strokeJoin,\n strokeMiter,\n style,\n }: PaintContext,\n opacity: number\n) => {\n const paint = parent.copy();\n if (color !== undefined) {\n paint.setShader(null);\n color[3] *= opacity;\n paint.setColor(color);\n } else {\n const cl = paint.getColor();\n cl[3] = opacity;\n paint.setColor(cl);\n }\n if (strokeWidth !== undefined) {\n paint.setStrokeWidth(strokeWidth);\n }\n if (shader !== undefined) {\n paint.setShader(shader);\n }\n if (antiAlias !== undefined) {\n paint.setAntiAlias(antiAlias);\n }\n if (blendMode !== undefined) {\n paint.setBlendMode(blendMode);\n }\n if (colorFilter !== undefined) {\n paint.setColorFilter(colorFilter);\n }\n if (imageFilter !== undefined) {\n paint.setImageFilter(imageFilter);\n }\n if (maskFilter !== undefined) {\n paint.setMaskFilter(maskFilter);\n }\n if (pathEffect !== undefined) {\n paint.setPathEffect(pathEffect);\n }\n if (alpha !== undefined) {\n paint.setAlphaf(alpha * opacity);\n }\n if (strokeCap !== undefined) {\n paint.setStrokeCap(strokeCap);\n }\n if (strokeJoin !== undefined) {\n paint.setStrokeJoin(strokeJoin);\n }\n if (strokeMiter !== undefined) {\n paint.setStrokeMiter(strokeMiter);\n }\n if (style !== undefined) {\n paint.setStyle(style);\n }\n return paint;\n};\n"],"mappings":";;AAOA,SACEA,SADF,EAEEC,UA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