@shopify/react-native-skia 2.0.0-next.2 → 2.0.0-next.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/android/build.gradle +14 -10
- package/cpp/api/JsiSkCanvas.h +45 -2
- package/cpp/api/recorder/Drawings.h +31 -2
- package/cpp/api/recorder/Shaders.h +40 -0
- package/cpp/skia/include/codec/SkCodec.h +39 -1
- package/cpp/skia/include/config/SkUserConfig.h +1 -10
- package/cpp/skia/include/core/SkCanvas.h +8 -4
- package/cpp/skia/include/core/SkContourMeasure.h +2 -2
- package/cpp/skia/include/core/SkMilestone.h +1 -1
- package/cpp/skia/include/core/SkPaint.h +8 -5
- package/cpp/skia/include/core/SkStream.h +8 -3
- package/cpp/skia/include/core/SkTextBlob.h +9 -9
- package/cpp/skia/include/core/SkTypeface.h +4 -6
- package/cpp/skia/include/core/SkTypes.h +5 -0
- package/cpp/skia/include/docs/SkPDFDocument.h +47 -2
- package/cpp/skia/include/docs/SkPDFJpegHelpers.h +41 -0
- package/cpp/skia/include/effects/SkRuntimeEffect.h +5 -1
- package/cpp/skia/include/effects/SkTableMaskFilter.h +4 -0
- package/cpp/skia/include/gpu/graphite/BackendTexture.h +0 -2
- package/cpp/skia/include/gpu/graphite/ContextOptions.h +17 -0
- package/cpp/skia/include/gpu/graphite/GraphiteTypes.h +21 -18
- package/cpp/skia/include/gpu/graphite/PrecompileContext.h +24 -0
- package/cpp/skia/include/gpu/graphite/TextureInfo.h +87 -42
- package/cpp/skia/include/gpu/graphite/YUVABackendTextures.h +13 -4
- package/cpp/skia/include/gpu/graphite/dawn/DawnBackendContext.h +9 -0
- package/cpp/skia/include/gpu/graphite/dawn/DawnGraphiteTypes.h +166 -0
- package/cpp/skia/include/gpu/graphite/dawn/DawnTypes.h +3 -141
- package/cpp/skia/include/gpu/graphite/dawn/DawnUtils.h +2 -21
- package/cpp/skia/include/gpu/graphite/mtl/MtlBackendContext.h +4 -0
- package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteTypes.h +30 -6
- package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteTypesUtils.h +4 -42
- package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteTypes_cpp.h +50 -0
- package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteUtils.h +2 -20
- package/cpp/skia/include/gpu/graphite/precompile/Precompile.h +14 -4
- package/cpp/skia/include/gpu/graphite/precompile/PrecompileShader.h +14 -6
- package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteContext.h +31 -0
- package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteTypes.h +36 -14
- package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteUtils.h +3 -21
- package/cpp/skia/include/ports/SkTypeface_fontations.h +3 -0
- package/cpp/skia/include/private/SkJpegMetadataDecoder.h +7 -0
- package/cpp/skia/include/private/base/SkAnySubclass.h +6 -0
- package/cpp/skia/include/private/chromium/SkPMColor.h +38 -0
- package/cpp/skia/modules/skparagraph/include/Paragraph.h +2 -2
- package/cpp/skia/modules/skunicode/include/SkUnicode.h +10 -6
- package/cpp/skia/modules/svg/include/SkSVGDOM.h +1 -3
- package/cpp/skia/src/base/SkTInternalLList.h +1 -1
- package/cpp/skia/src/core/SkLRUCache.h +6 -3
- package/lib/commonjs/external/reanimated/textures.d.ts +2 -4
- package/lib/commonjs/external/reanimated/textures.js +8 -15
- package/lib/commonjs/external/reanimated/textures.js.map +1 -1
- package/lib/commonjs/renderer/Canvas.d.ts +1 -2
- package/lib/commonjs/renderer/Canvas.js.map +1 -1
- package/lib/commonjs/sksg/HostConfig.js +2 -1
- package/lib/commonjs/sksg/HostConfig.js.map +1 -1
- package/lib/commonjs/sksg/Recorder/Player.d.ts +1 -1
- package/lib/commonjs/sksg/Recorder/Player.js.map +1 -1
- package/lib/commonjs/sksg/Recorder/commands/Box.js +2 -2
- package/lib/commonjs/sksg/Recorder/commands/Box.js.map +1 -1
- package/lib/commonjs/sksg/Recorder/commands/Drawing.d.ts +1 -3
- package/lib/commonjs/sksg/Recorder/commands/Drawing.js +1 -58
- package/lib/commonjs/sksg/Recorder/commands/Drawing.js.map +1 -1
- package/lib/module/external/reanimated/textures.d.ts +2 -4
- package/lib/module/external/reanimated/textures.js +7 -12
- package/lib/module/external/reanimated/textures.js.map +1 -1
- package/lib/module/renderer/Canvas.d.ts +1 -2
- package/lib/module/renderer/Canvas.js.map +1 -1
- package/lib/module/sksg/HostConfig.js +2 -1
- package/lib/module/sksg/HostConfig.js.map +1 -1
- package/lib/module/sksg/Recorder/Player.d.ts +1 -1
- package/lib/module/sksg/Recorder/Player.js.map +1 -1
- package/lib/module/sksg/Recorder/commands/Box.js +2 -2
- package/lib/module/sksg/Recorder/commands/Box.js.map +1 -1
- package/lib/module/sksg/Recorder/commands/Drawing.d.ts +1 -3
- package/lib/module/sksg/Recorder/commands/Drawing.js +2 -58
- package/lib/module/sksg/Recorder/commands/Drawing.js.map +1 -1
- package/lib/typescript/lib/commonjs/external/reanimated/textures.d.ts +1 -3
- package/lib/typescript/lib/commonjs/sksg/HostConfig.d.ts +1 -1
- package/lib/typescript/lib/commonjs/sksg/Recorder/commands/Drawing.d.ts +0 -1
- package/lib/typescript/lib/module/external/reanimated/textures.d.ts +1 -3
- package/lib/typescript/lib/module/sksg/HostConfig.d.ts +1 -1
- package/lib/typescript/lib/module/sksg/Recorder/commands/Drawing.d.ts +0 -1
- package/lib/typescript/src/external/reanimated/textures.d.ts +2 -4
- package/lib/typescript/src/renderer/Canvas.d.ts +1 -2
- package/lib/typescript/src/sksg/Recorder/Player.d.ts +1 -1
- package/lib/typescript/src/sksg/Recorder/commands/Drawing.d.ts +1 -3
- 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_icu.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_icu.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_icu.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_icu.a +0 -0
- package/libs/android/x86_64/libsvg.a +0 -0
- package/libs/apple/libskia.xcframework/Info.plist +15 -15
- package/libs/apple/libskia.xcframework/ios-arm64_arm64e/libskia.a +0 -0
- package/libs/apple/libskia.xcframework/ios-arm64_arm64e_x86_64-simulator/libskia.a +0 -0
- package/libs/apple/libskia.xcframework/macos-arm64_x86_64/libskia.a +0 -0
- package/libs/apple/libskia.xcframework/tvos-arm64_arm64e/libskia.a +0 -0
- package/libs/apple/libskia.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskia.a +0 -0
- package/libs/apple/libskottie.xcframework/Info.plist +7 -7
- package/libs/apple/libskottie.xcframework/ios-arm64_arm64e/libskottie.a +0 -0
- package/libs/apple/libskottie.xcframework/ios-arm64_arm64e_x86_64-simulator/libskottie.a +0 -0
- package/libs/apple/libskottie.xcframework/macos-arm64_x86_64/libskottie.a +0 -0
- package/libs/apple/libskottie.xcframework/tvos-arm64_arm64e/libskottie.a +0 -0
- package/libs/apple/libskottie.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskottie.a +0 -0
- package/libs/apple/libskparagraph.xcframework/Info.plist +13 -13
- package/libs/apple/libskparagraph.xcframework/ios-arm64_arm64e/libskparagraph.a +0 -0
- package/libs/apple/libskparagraph.xcframework/ios-arm64_arm64e_x86_64-simulator/libskparagraph.a +0 -0
- package/libs/apple/libskparagraph.xcframework/macos-arm64_x86_64/libskparagraph.a +0 -0
- package/libs/apple/libskparagraph.xcframework/tvos-arm64_arm64e/libskparagraph.a +0 -0
- package/libs/apple/libskparagraph.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskparagraph.a +0 -0
- package/libs/apple/libsksg.xcframework/Info.plist +13 -13
- package/libs/apple/libsksg.xcframework/ios-arm64_arm64e/libsksg.a +0 -0
- package/libs/apple/libsksg.xcframework/ios-arm64_arm64e_x86_64-simulator/libsksg.a +0 -0
- package/libs/apple/libsksg.xcframework/macos-arm64_x86_64/libsksg.a +0 -0
- package/libs/apple/libsksg.xcframework/tvos-arm64_arm64e/libsksg.a +0 -0
- package/libs/apple/libsksg.xcframework/tvos-arm64_arm64e_x86_64-simulator/libsksg.a +0 -0
- package/libs/apple/libskshaper.xcframework/Info.plist +14 -14
- package/libs/apple/libskshaper.xcframework/ios-arm64_arm64e/libskshaper.a +0 -0
- package/libs/apple/libskshaper.xcframework/ios-arm64_arm64e_x86_64-simulator/libskshaper.a +0 -0
- package/libs/apple/libskshaper.xcframework/macos-arm64_x86_64/libskshaper.a +0 -0
- package/libs/apple/libskshaper.xcframework/tvos-arm64_arm64e/libskshaper.a +0 -0
- package/libs/apple/libskshaper.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskshaper.a +0 -0
- package/libs/apple/libskunicode_core.xcframework/Info.plist +12 -12
- package/libs/apple/libskunicode_core.xcframework/ios-arm64_arm64e/libskunicode_core.a +0 -0
- package/libs/apple/libskunicode_core.xcframework/ios-arm64_arm64e_x86_64-simulator/libskunicode_core.a +0 -0
- package/libs/apple/libskunicode_core.xcframework/macos-arm64_x86_64/libskunicode_core.a +0 -0
- package/libs/apple/libskunicode_core.xcframework/tvos-arm64_arm64e/libskunicode_core.a +0 -0
- package/libs/apple/libskunicode_core.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskunicode_core.a +0 -0
- package/libs/apple/libskunicode_libgrapheme.xcframework/Info.plist +15 -15
- package/libs/apple/libskunicode_libgrapheme.xcframework/ios-arm64_arm64e/libskunicode_libgrapheme.a +0 -0
- package/libs/apple/libskunicode_libgrapheme.xcframework/ios-arm64_arm64e_x86_64-simulator/libskunicode_libgrapheme.a +0 -0
- package/libs/apple/libskunicode_libgrapheme.xcframework/macos-arm64_x86_64/libskunicode_libgrapheme.a +0 -0
- package/libs/apple/libskunicode_libgrapheme.xcframework/tvos-arm64_arm64e/libskunicode_libgrapheme.a +0 -0
- package/libs/apple/libskunicode_libgrapheme.xcframework/tvos-arm64_arm64e_x86_64-simulator/libskunicode_libgrapheme.a +0 -0
- package/libs/apple/libsvg.xcframework/Info.plist +8 -8
- package/libs/apple/libsvg.xcframework/ios-arm64_arm64e/libsvg.a +0 -0
- package/libs/apple/libsvg.xcframework/ios-arm64_arm64e_x86_64-simulator/libsvg.a +0 -0
- package/libs/apple/libsvg.xcframework/macos-arm64_x86_64/libsvg.a +0 -0
- package/libs/apple/libsvg.xcframework/tvos-arm64_arm64e/libsvg.a +0 -0
- package/libs/apple/libsvg.xcframework/tvos-arm64_arm64e_x86_64-simulator/libsvg.a +0 -0
- package/package.json +3 -3
- package/src/__tests__/snapshots/box/box-shadow-opacity.png +0 -0
- package/src/__tests__/snapshots/platform-buffer.png +0 -0
- package/src/__tests__/snapshots/screens/snapshot2-android-ci.png +0 -0
- package/src/external/reanimated/textures.tsx +12 -20
- package/src/renderer/Canvas.tsx +1 -1
- package/src/renderer/__tests__/e2e/Box.spec.tsx +22 -0
- package/src/renderer/__tests__/e2e/NativeBuffer.spec.tsx +2 -0
- package/src/sksg/HostConfig.ts +2 -1
- package/src/sksg/Recorder/Player.ts +1 -1
- package/src/sksg/Recorder/commands/Box.ts +2 -2
- package/src/sksg/Recorder/commands/Drawing.ts +0 -65
- package/cpp/skia/include/core/SkColorPriv.h +0 -165
- package/cpp/skia/include/private/SkColorData.h +0 -385
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"names":["deflate","enumKey","fitRects","inflate","NodeType","processCircle","processColor","processPath","processRect","processRRect","saturate","BlendMode","BlurStyle","ClipOp","FillType","FilterMode","isCubicSampling","isRRect","MipmapMode","PointMode","VertexMode","materialize","drawLine","ctx","props","p1","p2","canvas","x","y","paint","drawOval","rect","Skia","drawBox","children","box","defaultBox","opacity","getAlphaf","RRectXY","shadows","map","node","type","BoxShadow","filter","n","shadow","inner","color","blur","spread","dx","dy","lPaint","Paint","setColor","setAlphaf","setMaskFilter","MaskFilter","MakeBlur","Normal","drawRRect","delta","Point","Math","abs","save","clipRRect","Intersect","outer","drawDRRect","restore","drawImage","image","sampling","_props$fit","fit","src","dst","width","height","drawImageRectCubic","B","C","_sampling$filter","_sampling$mipmap","drawImageRectOptions","Linear","mipmap","None","drawPoints","points","mode","drawVertices","textures","colors","indices","blendMode","vertexMode","Triangles","vertices","MakeVertices","c","undefined","defaultBlendMode","DstOver","SrcOver","blend","drawDiffRect","drawTextPath","path","font","initialOffset","text","ids","getGlyphIDs","widths","getGlyphWidths","rsx","meas","ContourMeasureIter","cont","next","dist","i","length","substring","p","t","getPosTan","adjustedX","adjustedY","push","RSXform","derived","TextBlob","MakeFromRSXform","drawTextBlob","drawText","drawPatch","texture","patch","pos","c2","c1","drawPath","start","trimStart","end","trimEnd","fillType","stroke","pathProps","hasStartOffset","hasEndOffset","hasStrokeOptions","hasFillType","willMutatePath","pristinePath","copy","setFillType","trim","drawRect","blob","drawGlyphs","glyphs","reduce","acc","glyph","id","positions","drawImageSVG","svg","translate","drawSvg","drawParagraph","paragraph","layout","drawPicture","picture","drawAtlas","sprites","transforms","drawCircle","r","drawFill","_props","drawPaint"],"sources":["Drawing.ts"],"sourcesContent":["import {\n deflate,\n enumKey,\n fitRects,\n inflate,\n NodeType,\n processCircle,\n processColor,\n processPath,\n processRect,\n processRRect,\n} from \"../../../dom/nodes\";\nimport type {\n AtlasProps,\n BoxProps,\n BoxShadowProps,\n CircleProps,\n DiffRectProps,\n DrawingNodeProps,\n GlyphsProps,\n ImageProps,\n ImageSVGProps,\n LineProps,\n OvalProps,\n ParagraphProps,\n PatchProps,\n PathProps,\n PictureProps,\n PointsProps,\n RectProps,\n RoundedRectProps,\n TextBlobProps,\n TextPathProps,\n TextProps,\n VerticesProps,\n} from \"../../../dom/types\";\nimport { saturate } from \"../../../renderer/processors\";\nimport type { SkPoint, SkRSXform } from \"../../../skia/types\";\nimport {\n BlendMode,\n BlurStyle,\n ClipOp,\n FillType,\n FilterMode,\n isCubicSampling,\n isRRect,\n MipmapMode,\n PointMode,\n VertexMode,\n} from \"../../../skia/types\";\nimport type { Node } from \"../../Node\";\nimport { materialize } from \"../../utils\";\nimport type { DrawingContext } from \"../DrawingContext\";\n\nexport const drawLine = (ctx: DrawingContext, props: LineProps) => {\n \"worklet\";\n const { p1, p2 } = props;\n ctx.canvas.drawLine(p1.x, p1.y, p2.x, p2.y, ctx.paint);\n};\n\nexport const drawOval = (ctx: DrawingContext, props: OvalProps) => {\n \"worklet\";\n const rect = processRect(ctx.Skia, props);\n ctx.canvas.drawOval(rect, ctx.paint);\n};\n\nexport const drawBox = (\n ctx: DrawingContext,\n props: BoxProps,\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n children: Node<any>[]\n) => {\n \"worklet\";\n const { paint, Skia, canvas } = ctx;\n const { box: defaultBox } = props;\n const opacity = paint.getAlphaf();\n const box = isRRect(defaultBox) ? defaultBox : Skia.RRectXY(defaultBox, 0, 0);\n const shadows = children\n .map((node) => {\n if (node.type === NodeType.BoxShadow) {\n return materialize(node.props);\n }\n return null;\n })\n .filter((n): n is BoxShadowProps => n !== null);\n shadows\n .filter((shadow) => !shadow.inner)\n .map((shadow) => {\n const { color = \"black\", blur, spread = 0, dx = 0, dy = 0 } = shadow;\n const lPaint = Skia.Paint();\n lPaint.setColor(processColor(Skia, color));\n lPaint.setAlphaf(paint.getAlphaf() * opacity);\n lPaint.setMaskFilter(\n Skia.MaskFilter.MakeBlur(BlurStyle.Normal, blur, true)\n );\n canvas.drawRRect(inflate(Skia, box, spread, spread, dx, dy), lPaint);\n });\n\n canvas.drawRRect(box, paint);\n\n shadows\n .filter((shadow) => shadow.inner)\n .map((shadow) => {\n const { color = \"black\", blur, spread = 0, dx = 0, dy = 0 } = shadow;\n const delta = Skia.Point(10 + Math.abs(dx), 10 + Math.abs(dy));\n canvas.save();\n canvas.clipRRect(box, ClipOp.Intersect, false);\n const lPaint = Skia.Paint();\n lPaint.setColor(processColor(Skia, color));\n lPaint.setAlphaf(paint.getAlphaf() * opacity);\n\n lPaint.setMaskFilter(\n Skia.MaskFilter.MakeBlur(BlurStyle.Normal, blur, true)\n );\n const inner = deflate(Skia, box, spread, spread, dx, dy);\n const outer = inflate(Skia, box, delta.x, delta.y);\n canvas.drawDRRect(outer, inner, lPaint);\n canvas.restore();\n });\n};\n\nexport const drawImage = (ctx: DrawingContext, props: ImageProps) => {\n \"worklet\";\n const { image, sampling } = props;\n if (image) {\n const fit = props.fit ?? \"contain\";\n const rect = processRect(ctx.Skia, props);\n const { src, dst } = fitRects(\n fit,\n {\n x: 0,\n y: 0,\n width: image.width(),\n height: image.height(),\n },\n rect\n );\n if (sampling && isCubicSampling(sampling)) {\n ctx.canvas.drawImageRectCubic(\n image,\n src,\n dst,\n sampling.B,\n sampling.C,\n ctx.paint\n );\n } else {\n ctx.canvas.drawImageRectOptions(\n image,\n src,\n dst,\n sampling?.filter ?? FilterMode.Linear,\n sampling?.mipmap ?? MipmapMode.None,\n ctx.paint\n );\n }\n }\n};\n\nexport const drawPoints = (ctx: DrawingContext, props: PointsProps) => {\n \"worklet\";\n const { points, mode } = props;\n ctx.canvas.drawPoints(PointMode[enumKey(mode)], points, ctx.paint);\n};\n\nexport const drawVertices = (ctx: DrawingContext, props: VerticesProps) => {\n \"worklet\";\n const { mode, textures, colors, indices, blendMode } = props;\n const vertexMode = mode ? VertexMode[enumKey(mode)] : VertexMode.Triangles;\n const vertices = ctx.Skia.MakeVertices(\n vertexMode,\n props.vertices,\n textures,\n colors ? colors.map((c) => processColor(ctx.Skia, c)) : undefined,\n indices\n );\n const defaultBlendMode = colors ? BlendMode.DstOver : BlendMode.SrcOver;\n const blend = blendMode ? BlendMode[enumKey(blendMode)] : defaultBlendMode;\n\n ctx.canvas.drawVertices(vertices, blend, ctx.paint);\n};\n\nexport const drawDiffRect = (ctx: DrawingContext, props: DiffRectProps) => {\n \"worklet\";\n const { outer, inner } = props;\n ctx.canvas.drawDRRect(outer, inner, ctx.paint);\n};\n\nexport const drawTextPath = (ctx: DrawingContext, props: TextPathProps) => {\n \"worklet\";\n const path = processPath(ctx.Skia, props.path);\n const { font, initialOffset } = props;\n if (font) {\n let { text } = props;\n const ids = font.getGlyphIDs(text);\n const widths = font.getGlyphWidths(ids);\n const rsx: SkRSXform[] = [];\n const meas = ctx.Skia.ContourMeasureIter(path, false, 1);\n let cont = meas.next();\n let dist = initialOffset;\n for (let i = 0; i < text.length && cont; i++) {\n const width = widths[i];\n dist += width / 2;\n if (dist > cont.length()) {\n // jump to next contour\n cont = meas.next();\n if (!cont) {\n // We have come to the end of the path - terminate the string\n // right here.\n text = text.substring(0, i);\n break;\n }\n dist = width / 2;\n }\n // Gives us the (x, y) coordinates as well as the cos/sin of the tangent\n // line at that position.\n const [p, t] = cont.getPosTan(dist);\n const adjustedX = p.x - (width / 2) * t.x;\n const adjustedY = p.y - (width / 2) * t.y;\n rsx.push(ctx.Skia.RSXform(t.x, t.y, adjustedX, adjustedY));\n dist += width / 2;\n }\n const derived = ctx.Skia.TextBlob.MakeFromRSXform(text, rsx, font);\n ctx.canvas.drawTextBlob(derived, 0, 0, ctx.paint);\n }\n};\n\nexport const drawText = (ctx: DrawingContext, props: TextProps) => {\n \"worklet\";\n const { text, x, y, font } = props;\n if (font != null) {\n ctx.canvas.drawText(text, x, y, ctx.paint, font);\n }\n};\n\nexport const drawPatch = (ctx: DrawingContext, props: PatchProps) => {\n \"worklet\";\n const { texture, blendMode, patch } = props;\n const defaultBlendMode = props.colors ? BlendMode.DstOver : BlendMode.SrcOver;\n const mode = blendMode ? BlendMode[enumKey(blendMode)] : defaultBlendMode;\n // Patch requires a path with the following constraints:\n // M tl\n // C c1 c2 br\n // C c1 c2 bl\n // C c1 c2 tl (the redundant point in the last command is removed)\n\n const points = [\n patch[0].pos,\n patch[0].c2,\n patch[1].c1,\n patch[1].pos,\n patch[1].c2,\n patch[2].c1,\n patch[2].pos,\n patch[2].c2,\n patch[3].c1,\n patch[3].pos,\n patch[3].c2,\n patch[0].c1,\n ];\n const colors = props.colors\n ? props.colors.map((c) => processColor(ctx.Skia, c))\n : undefined;\n ctx.canvas.drawPatch(points, colors, texture, mode, ctx.paint);\n};\n\nexport const drawPath = (ctx: DrawingContext, props: PathProps) => {\n \"worklet\";\n const {\n start: trimStart,\n end: trimEnd,\n fillType,\n stroke,\n ...pathProps\n } = props;\n const start = saturate(trimStart);\n const end = saturate(trimEnd);\n const hasStartOffset = start !== 0;\n const hasEndOffset = end !== 1;\n const hasStrokeOptions = stroke !== undefined;\n const hasFillType = !!fillType;\n const willMutatePath =\n hasStartOffset || hasEndOffset || hasStrokeOptions || hasFillType;\n const pristinePath = processPath(ctx.Skia, pathProps.path);\n const path = willMutatePath ? pristinePath.copy() : pristinePath;\n if (hasFillType) {\n path.setFillType(FillType[enumKey(fillType)]);\n }\n if (hasStrokeOptions) {\n path.stroke(stroke);\n }\n if (hasStartOffset || hasEndOffset) {\n path.trim(start, end, false);\n }\n ctx.canvas.drawPath(path, ctx.paint);\n};\n\nexport const drawRect = (ctx: DrawingContext, props: RectProps) => {\n \"worklet\";\n const derived = processRect(ctx.Skia, props);\n ctx.canvas.drawRect(derived, ctx.paint);\n};\n\nexport const drawRRect = (ctx: DrawingContext, props: RoundedRectProps) => {\n \"worklet\";\n const derived = processRRect(ctx.Skia, props);\n ctx.canvas.drawRRect(derived, ctx.paint);\n};\n\nexport const drawTextBlob = (ctx: DrawingContext, props: TextBlobProps) => {\n \"worklet\";\n const { blob, x, y } = props;\n ctx.canvas.drawTextBlob(blob, x, y, ctx.paint);\n};\n\ninterface ProcessedGlyphs {\n glyphs: number[];\n positions: SkPoint[];\n}\n\nexport const drawGlyphs = (ctx: DrawingContext, props: GlyphsProps) => {\n \"worklet\";\n const derived = props.glyphs.reduce<ProcessedGlyphs>(\n (acc, glyph) => {\n const { id, pos } = glyph;\n acc.glyphs.push(id);\n acc.positions.push(pos);\n return acc;\n },\n { glyphs: [], positions: [] }\n );\n const { glyphs, positions } = derived;\n const { x, y, font } = props;\n if (font) {\n ctx.canvas.drawGlyphs(glyphs, positions, x, y, font, ctx.paint);\n }\n};\n\nexport const drawImageSVG = (ctx: DrawingContext, props: ImageSVGProps) => {\n \"worklet\";\n const { canvas } = ctx;\n const { svg } = props;\n const { x, y, width, height } = props.rect\n ? props.rect\n : { x: props.x, y: props.y, width: props.width, height: props.height };\n if (svg === null) {\n return;\n }\n canvas.save();\n if (x && y) {\n canvas.translate(x, y);\n }\n canvas.drawSvg(svg, width, height);\n canvas.restore();\n};\n\nexport const drawParagraph = (ctx: DrawingContext, props: ParagraphProps) => {\n \"worklet\";\n const { paragraph, x, y, width } = props;\n if (paragraph) {\n paragraph.layout(width);\n paragraph.paint(ctx.canvas, x, y);\n }\n};\n\nexport const drawPicture = (ctx: DrawingContext, props: PictureProps) => {\n \"worklet\";\n const { picture } = props;\n ctx.canvas.drawPicture(picture);\n};\n\nexport const drawAtlas = (ctx: DrawingContext, props: AtlasProps) => {\n \"worklet\";\n const { image, sprites, transforms, colors, blendMode, sampling } = props;\n const blend = blendMode ? BlendMode[enumKey(blendMode)] : undefined;\n if (image) {\n ctx.canvas.drawAtlas(\n image,\n sprites,\n transforms,\n ctx.paint,\n blend,\n colors,\n sampling\n );\n }\n};\n\nexport const drawCircle = (ctx: DrawingContext, props: CircleProps) => {\n \"worklet\";\n const { c } = processCircle(props);\n const { r } = props;\n ctx.canvas.drawCircle(c.x, c.y, r, ctx.paint);\n};\n\nexport const drawFill = (ctx: DrawingContext, _props: DrawingNodeProps) => {\n \"worklet\";\n ctx.canvas.drawPaint(ctx.paint);\n};\n"],"mappings":"AAAA,SACEA,OAAO,EACPC,OAAO,EACPC,QAAQ,EACRC,OAAO,EACPC,QAAQ,EACRC,aAAa,EACbC,YAAY,EACZC,WAAW,EACXC,WAAW,EACXC,YAAY,QACP,oBAAoB;AAyB3B,SAASC,QAAQ,QAAQ,8BAA8B;AAEvD,SACEC,SAAS,EACTC,SAAS,EACTC,MAAM,EACNC,QAAQ,EACRC,UAAU,EACVC,eAAe,EACfC,OAAO,EACPC,UAAU,EACVC,SAAS,EACTC,UAAU,QACL,qBAAqB;AAE5B,SAASC,WAAW,QAAQ,aAAa;AAGzC,OAAO,MAAMC,QAAQ,GAAGA,CAACC,GAAmB,EAAEC,KAAgB,KAAK;EACjE,SAAS;;EACT,MAAM;IAAEC,EAAE;IAAEC;EAAG,CAAC,GAAGF,KAAK;EACxBD,GAAG,CAACI,MAAM,CAACL,QAAQ,CAACG,EAAE,CAACG,CAAC,EAAEH,EAAE,CAACI,CAAC,EAAEH,EAAE,CAACE,CAAC,EAAEF,EAAE,CAACG,CAAC,EAAEN,GAAG,CAACO,KAAK,CAAC;AACxD,CAAC;AAED,OAAO,MAAMC,QAAQ,GAAGA,CAACR,GAAmB,EAAEC,KAAgB,KAAK;EACjE,SAAS;;EACT,MAAMQ,IAAI,GAAGxB,WAAW,CAACe,GAAG,CAACU,IAAI,EAAET,KAAK,CAAC;EACzCD,GAAG,CAACI,MAAM,CAACI,QAAQ,CAACC,IAAI,EAAET,GAAG,CAACO,KAAK,CA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AM,EACNrB,QACF,CAAC;EACH;AACF,CAAC;AAED,OAAO,MAAM6G,UAAU,GAAGA,CAAClK,GAAmB,EAAEC,KAAkB,KAAK;EACrE,SAAS;;EACT,MAAM;IAAEgF;EAAE,CAAC,GAAGnG,aAAa,CAACmB,KAAK,CAAC;EAClC,MAAM;IAAEkK;EAAE,CAAC,GAAGlK,KAAK;EACnBD,GAAG,CAACI,MAAM,CAAC8J,UAAU,CAACjF,CAAC,CAAC5E,CAAC,EAAE4E,CAAC,CAAC3E,CAAC,EAAE6J,CAAC,EAAEnK,GAAG,CAACO,KAAK,CAAC;AAC/C,CAAC;AAED,OAAO,MAAM6J,QAAQ,GAAGA,CAACpK,GAAmB,EAAEqK,MAAwB,KAAK;EACzE,SAAS;;EACTrK,GAAG,CAACI,MAAM,CAACkK,SAAS,CAACtK,GAAG,CAACO,KAAK,CAAC;AACjC,CAAC","ignoreList":[]}
|
1
|
+
{"version":3,"names":["enumKey","fitRects","processCircle","processColor","processPath","processRect","processRRect","saturate","BlendMode","FillType","FilterMode","isCubicSampling","MipmapMode","PointMode","VertexMode","drawLine","ctx","props","p1","p2","canvas","x","y","paint","drawOval","rect","Skia","drawImage","image","sampling","_props$fit","fit","src","dst","width","height","drawImageRectCubic","B","C","_sampling$filter","_sampling$mipmap","drawImageRectOptions","filter","Linear","mipmap","None","drawPoints","points","mode","drawVertices","textures","colors","indices","blendMode","vertexMode","Triangles","vertices","MakeVertices","map","c","undefined","defaultBlendMode","DstOver","SrcOver","blend","drawDiffRect","outer","inner","drawDRRect","drawTextPath","path","font","initialOffset","text","ids","getGlyphIDs","widths","getGlyphWidths","rsx","meas","ContourMeasureIter","cont","next","dist","i","length","substring","p","t","getPosTan","adjustedX","adjustedY","push","RSXform","derived","TextBlob","MakeFromRSXform","drawTextBlob","drawText","drawPatch","texture","patch","pos","c2","c1","drawPath","start","trimStart","end","trimEnd","fillType","stroke","pathProps","hasStartOffset","hasEndOffset","hasStrokeOptions","hasFillType","willMutatePath","pristinePath","copy","setFillType","trim","drawRect","drawRRect","blob","drawGlyphs","glyphs","reduce","acc","glyph","id","positions","drawImageSVG","svg","save","translate","drawSvg","restore","drawParagraph","paragraph","layout","drawPicture","picture","drawAtlas","sprites","transforms","drawCircle","r","drawFill","_props","drawPaint"],"sources":["Drawing.ts"],"sourcesContent":["import {\n enumKey,\n fitRects,\n processCircle,\n processColor,\n processPath,\n processRect,\n processRRect,\n} from \"../../../dom/nodes\";\nimport type {\n AtlasProps,\n CircleProps,\n DiffRectProps,\n DrawingNodeProps,\n GlyphsProps,\n ImageProps,\n ImageSVGProps,\n LineProps,\n OvalProps,\n ParagraphProps,\n PatchProps,\n PathProps,\n PictureProps,\n PointsProps,\n RectProps,\n RoundedRectProps,\n TextBlobProps,\n TextPathProps,\n TextProps,\n VerticesProps,\n} from \"../../../dom/types\";\nimport { saturate } from \"../../../renderer/processors\";\nimport type { SkPoint, SkRSXform } from \"../../../skia/types\";\nimport {\n BlendMode,\n FillType,\n FilterMode,\n isCubicSampling,\n MipmapMode,\n PointMode,\n VertexMode,\n} from \"../../../skia/types\";\nimport type { DrawingContext } from \"../DrawingContext\";\n\nexport const drawLine = (ctx: DrawingContext, props: LineProps) => {\n \"worklet\";\n const { p1, p2 } = props;\n ctx.canvas.drawLine(p1.x, p1.y, p2.x, p2.y, ctx.paint);\n};\n\nexport const drawOval = (ctx: DrawingContext, props: OvalProps) => {\n \"worklet\";\n const rect = processRect(ctx.Skia, props);\n ctx.canvas.drawOval(rect, ctx.paint);\n};\n\nexport const drawImage = (ctx: DrawingContext, props: ImageProps) => {\n \"worklet\";\n const { image, sampling } = props;\n if (image) {\n const fit = props.fit ?? \"contain\";\n const rect = processRect(ctx.Skia, props);\n const { src, dst } = fitRects(\n fit,\n {\n x: 0,\n y: 0,\n width: image.width(),\n height: image.height(),\n },\n rect\n );\n if (sampling && isCubicSampling(sampling)) {\n ctx.canvas.drawImageRectCubic(\n image,\n src,\n dst,\n sampling.B,\n sampling.C,\n ctx.paint\n );\n } else {\n ctx.canvas.drawImageRectOptions(\n image,\n src,\n dst,\n sampling?.filter ?? FilterMode.Linear,\n sampling?.mipmap ?? MipmapMode.None,\n ctx.paint\n );\n }\n }\n};\n\nexport const drawPoints = (ctx: DrawingContext, props: PointsProps) => {\n \"worklet\";\n const { points, mode } = props;\n ctx.canvas.drawPoints(PointMode[enumKey(mode)], points, ctx.paint);\n};\n\nexport const drawVertices = (ctx: DrawingContext, props: VerticesProps) => {\n \"worklet\";\n const { mode, textures, colors, indices, blendMode } = props;\n const vertexMode = mode ? VertexMode[enumKey(mode)] : VertexMode.Triangles;\n const vertices = ctx.Skia.MakeVertices(\n vertexMode,\n props.vertices,\n textures,\n colors ? colors.map((c) => processColor(ctx.Skia, c)) : undefined,\n indices\n );\n const defaultBlendMode = colors ? BlendMode.DstOver : BlendMode.SrcOver;\n const blend = blendMode ? BlendMode[enumKey(blendMode)] : defaultBlendMode;\n\n ctx.canvas.drawVertices(vertices, blend, ctx.paint);\n};\n\nexport const drawDiffRect = (ctx: DrawingContext, props: DiffRectProps) => {\n \"worklet\";\n const { outer, inner } = props;\n ctx.canvas.drawDRRect(outer, inner, ctx.paint);\n};\n\nexport const drawTextPath = (ctx: DrawingContext, props: TextPathProps) => {\n \"worklet\";\n const path = processPath(ctx.Skia, props.path);\n const { font, initialOffset } = props;\n if (font) {\n let { text } = props;\n const ids = font.getGlyphIDs(text);\n const widths = font.getGlyphWidths(ids);\n const rsx: SkRSXform[] = [];\n const meas = ctx.Skia.ContourMeasureIter(path, false, 1);\n let cont = meas.next();\n let dist = initialOffset;\n for (let i = 0; i < text.length && cont; i++) {\n const width = widths[i];\n dist += width / 2;\n if (dist > cont.length()) {\n // jump to next contour\n cont = meas.next();\n if (!cont) {\n // We have come to the end of the path - terminate the string\n // right here.\n text = text.substring(0, i);\n break;\n }\n dist = width / 2;\n }\n // Gives us the (x, y) coordinates as well as the cos/sin of the tangent\n // line at that position.\n const [p, t] = cont.getPosTan(dist);\n const adjustedX = p.x - (width / 2) * t.x;\n const adjustedY = p.y - (width / 2) * t.y;\n rsx.push(ctx.Skia.RSXform(t.x, t.y, adjustedX, adjustedY));\n dist += width / 2;\n }\n const derived = ctx.Skia.TextBlob.MakeFromRSXform(text, rsx, font);\n ctx.canvas.drawTextBlob(derived, 0, 0, ctx.paint);\n }\n};\n\nexport const drawText = (ctx: DrawingContext, props: TextProps) => {\n \"worklet\";\n const { text, x, y, font } = props;\n if (font != null) {\n ctx.canvas.drawText(text, x, y, ctx.paint, font);\n }\n};\n\nexport const drawPatch = (ctx: DrawingContext, props: PatchProps) => {\n \"worklet\";\n const { texture, blendMode, patch } = props;\n const defaultBlendMode = props.colors ? BlendMode.DstOver : BlendMode.SrcOver;\n const mode = blendMode ? BlendMode[enumKey(blendMode)] : defaultBlendMode;\n // Patch requires a path with the following constraints:\n // M tl\n // C c1 c2 br\n // C c1 c2 bl\n // C c1 c2 tl (the redundant point in the last command is removed)\n\n const points = [\n patch[0].pos,\n patch[0].c2,\n patch[1].c1,\n patch[1].pos,\n patch[1].c2,\n patch[2].c1,\n patch[2].pos,\n patch[2].c2,\n patch[3].c1,\n patch[3].pos,\n patch[3].c2,\n patch[0].c1,\n ];\n const colors = props.colors\n ? props.colors.map((c) => processColor(ctx.Skia, c))\n : undefined;\n ctx.canvas.drawPatch(points, colors, texture, mode, ctx.paint);\n};\n\nexport const drawPath = (ctx: DrawingContext, props: PathProps) => {\n \"worklet\";\n const {\n start: trimStart,\n end: trimEnd,\n fillType,\n stroke,\n ...pathProps\n } = props;\n const start = saturate(trimStart);\n const end = saturate(trimEnd);\n const hasStartOffset = start !== 0;\n const hasEndOffset = end !== 1;\n const hasStrokeOptions = stroke !== undefined;\n const hasFillType = !!fillType;\n const willMutatePath =\n hasStartOffset || hasEndOffset || hasStrokeOptions || hasFillType;\n const pristinePath = processPath(ctx.Skia, pathProps.path);\n const path = willMutatePath ? pristinePath.copy() : pristinePath;\n if (hasFillType) {\n path.setFillType(FillType[enumKey(fillType)]);\n }\n if (hasStrokeOptions) {\n path.stroke(stroke);\n }\n if (hasStartOffset || hasEndOffset) {\n path.trim(start, end, false);\n }\n ctx.canvas.drawPath(path, ctx.paint);\n};\n\nexport const drawRect = (ctx: DrawingContext, props: RectProps) => {\n \"worklet\";\n const derived = processRect(ctx.Skia, props);\n ctx.canvas.drawRect(derived, ctx.paint);\n};\n\nexport const drawRRect = (ctx: DrawingContext, props: RoundedRectProps) => {\n \"worklet\";\n const derived = processRRect(ctx.Skia, props);\n ctx.canvas.drawRRect(derived, ctx.paint);\n};\n\nexport const drawTextBlob = (ctx: DrawingContext, props: TextBlobProps) => {\n \"worklet\";\n const { blob, x, y } = props;\n ctx.canvas.drawTextBlob(blob, x, y, ctx.paint);\n};\n\ninterface ProcessedGlyphs {\n glyphs: number[];\n positions: SkPoint[];\n}\n\nexport const drawGlyphs = (ctx: DrawingContext, props: GlyphsProps) => {\n \"worklet\";\n const derived = props.glyphs.reduce<ProcessedGlyphs>(\n (acc, glyph) => {\n const { id, pos } = glyph;\n acc.glyphs.push(id);\n acc.positions.push(pos);\n return acc;\n },\n { glyphs: [], positions: [] }\n );\n const { glyphs, positions } = derived;\n const { x, y, font } = props;\n if (font) {\n ctx.canvas.drawGlyphs(glyphs, positions, x, y, font, ctx.paint);\n }\n};\n\nexport const drawImageSVG = (ctx: DrawingContext, props: ImageSVGProps) => {\n \"worklet\";\n const { canvas } = ctx;\n const { svg } = props;\n const { x, y, width, height } = props.rect\n ? props.rect\n : { x: props.x, y: props.y, width: props.width, height: props.height };\n if (svg === null) {\n return;\n }\n canvas.save();\n if (x && y) {\n canvas.translate(x, y);\n }\n canvas.drawSvg(svg, width, height);\n canvas.restore();\n};\n\nexport const drawParagraph = (ctx: DrawingContext, props: ParagraphProps) => {\n \"worklet\";\n const { paragraph, x, y, width } = props;\n if (paragraph) {\n paragraph.layout(width);\n paragraph.paint(ctx.canvas, x, y);\n }\n};\n\nexport const drawPicture = (ctx: DrawingContext, props: PictureProps) => {\n \"worklet\";\n const { picture } = props;\n ctx.canvas.drawPicture(picture);\n};\n\nexport const drawAtlas = (ctx: DrawingContext, props: AtlasProps) => {\n \"worklet\";\n const { image, sprites, transforms, colors, blendMode, sampling } = props;\n const blend = blendMode ? BlendMode[enumKey(blendMode)] : undefined;\n if (image) {\n ctx.canvas.drawAtlas(\n image,\n sprites,\n transforms,\n ctx.paint,\n blend,\n colors,\n sampling\n );\n }\n};\n\nexport const drawCircle = (ctx: DrawingContext, props: CircleProps) => {\n \"worklet\";\n const { c } = processCircle(props);\n const { r } = props;\n ctx.canvas.drawCircle(c.x, c.y, r, ctx.paint);\n};\n\nexport const drawFill = (ctx: DrawingContext, _props: DrawingNodeProps) => {\n \"worklet\";\n ctx.canvas.drawPaint(ctx.paint);\n};\n"],"mappings":"AAAA,SACEA,OAAO,EACPC,QAAQ,EACRC,aAAa,EACbC,YAAY,EACZC,WAAW,EACXC,WAAW,EACXC,YAAY,QACP,oBAAoB;AAuB3B,SAASC,QAAQ,QAAQ,8BAA8B;AAEvD,SACEC,SAAS,EACTC,QAAQ,EACRC,UAAU,EACVC,eAAe,EACfC,UAAU,EACVC,SAAS,EACTC,UAAU,QACL,qBAAqB;AAG5B,OAAO,MAAMC,QAAQ,GAAGA,CAACC,GAAmB,EAAEC,KAAgB,KAAK;EACjE,SAAS;;EACT,MAAM;IAAEC,EAAE;IAAEC;EAAG,CAAC,GAAGF,KAAK;EACxBD,GAAG,CAACI,MAAM,CAACL,QAAQ,CAACG,EAAE,CAACG,CAAC,EAAEH,EAAE,CAACI,CAAC,EAAEH,EAAE,CAACE,CAAC,EAAEF,EAAE,CAACG,CAAC,EAAEN,GAAG,CAACO,KAAK,CAAC;AACxD,CAAC;AAED,OAAO,MAAMC,QAAQ,GAAGA,CAACR,GAAmB,EAAEC,KAAgB,KAAK;EACjE,SAAS;;EACT,MAAMQ,IAAI,GAAGpB,WAAW,CAACW,GAAG,CAACU,IAAI,EAAET,KAAK,CAAC;EACzCD,GAAG,CAACI,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AK,CAAC;AAC/C,CAAC;AAED,OAAO,MAAM6H,QAAQ,GAAGA,CAACpI,GAAmB,EAAEqI,MAAwB,KAAK;EACzE,SAAS;;EACTrI,GAAG,CAACI,MAAM,CAACkI,SAAS,CAACtI,GAAG,CAACO,KAAK,CAAC;AACjC,CAAC","ignoreList":[]}
|
@@ -1,6 +1,4 @@
|
|
1
1
|
export const __esModule: boolean;
|
2
|
-
export function useTexture(element: any, size: any): any;
|
3
|
-
export function useTextureAsValue(element: any, size: any): any;
|
4
|
-
export function useTextureValueFromPicture(picture: any, size: any): any;
|
2
|
+
export function useTexture(element: any, size: any, deps: any): any;
|
5
3
|
export function usePictureAsTexture(picture: any, size: any): any;
|
6
4
|
export function useImageAsTexture(source: any): any;
|
@@ -20,7 +20,7 @@ export namespace sksgHostConfig {
|
|
20
20
|
function finalizeInitialChildren(parentInstance: any, _type: any, _props: any, _rootContainerInstance: any, _hostContext: any): boolean;
|
21
21
|
function commitMount(): void;
|
22
22
|
function prepareForCommit(_container: any): null;
|
23
|
-
function resetAfterCommit(
|
23
|
+
function resetAfterCommit(container: any): void;
|
24
24
|
function getPublicInstance(node: any): any;
|
25
25
|
function commitTextUpdate(_textInstance: any, _oldText: any, _newText: any): void;
|
26
26
|
function clearContainer(_container: any): void;
|
@@ -1,7 +1,6 @@
|
|
1
1
|
export const __esModule: boolean;
|
2
2
|
export function drawLine(ctx: any, props: any): void;
|
3
3
|
export function drawOval(ctx: any, props: any): void;
|
4
|
-
export function drawBox(ctx: any, props: any, children: any): void;
|
5
4
|
export function drawImage(ctx: any, props: any): void;
|
6
5
|
export function drawPoints(ctx: any, props: any): void;
|
7
6
|
export function drawVertices(ctx: any, props: any): void;
|
@@ -1,5 +1,3 @@
|
|
1
|
-
export function useTexture(element: any, size: any): any;
|
2
|
-
export function useTextureAsValue(element: any, size: any): any;
|
3
|
-
export function useTextureValueFromPicture(picture: any, size: any): any;
|
1
|
+
export function useTexture(element: any, size: any, deps: any): any;
|
4
2
|
export function usePictureAsTexture(picture: any, size: any): any;
|
5
3
|
export function useImageAsTexture(source: any): any;
|
@@ -20,7 +20,7 @@ export namespace sksgHostConfig {
|
|
20
20
|
function finalizeInitialChildren(parentInstance: any, _type: any, _props: any, _rootContainerInstance: any, _hostContext: any): boolean;
|
21
21
|
function commitMount(): void;
|
22
22
|
function prepareForCommit(_container: any): null;
|
23
|
-
function resetAfterCommit(
|
23
|
+
function resetAfterCommit(container: any): void;
|
24
24
|
function getPublicInstance(node: any): any;
|
25
25
|
function commitTextUpdate(_textInstance: any, _oldText: any, _newText: any): void;
|
26
26
|
function clearContainer(_container: any): void;
|
@@ -1,6 +1,5 @@
|
|
1
1
|
export function drawLine(ctx: any, props: any): void;
|
2
2
|
export function drawOval(ctx: any, props: any): void;
|
3
|
-
export function drawBox(ctx: any, props: any, children: any): void;
|
4
3
|
export function drawImage(ctx: any, props: any): void;
|
5
4
|
export function drawPoints(ctx: any, props: any): void;
|
6
5
|
export function drawVertices(ctx: any, props: any): void;
|
@@ -1,8 +1,6 @@
|
|
1
|
-
import type { ReactElement } from "react";
|
1
|
+
import type { DependencyList, ReactElement } from "react";
|
2
2
|
import type { SharedValue } from "react-native-reanimated";
|
3
3
|
import type { DataSourceParam, SkImage, SkPicture, SkSize } from "../../skia/types";
|
4
|
-
export declare const useTexture: (element: ReactElement, size: SkSize) => SharedValue<SkImage | null>;
|
5
|
-
export declare const useTextureAsValue: (element: ReactElement, size: SkSize) => SharedValue<SkImage | null>;
|
6
|
-
export declare const useTextureValueFromPicture: (picture: SkPicture | null, size: SkSize) => SharedValue<SkImage | null>;
|
4
|
+
export declare const useTexture: (element: ReactElement, size: SkSize, deps?: DependencyList) => SharedValue<SkImage | null>;
|
7
5
|
export declare const usePictureAsTexture: (picture: SkPicture | null, size: SkSize) => SharedValue<SkImage | null>;
|
8
6
|
export declare const useImageAsTexture: (source: DataSourceParam) => SharedValue<SkImage | null>;
|
@@ -3,7 +3,7 @@ import React from "react";
|
|
3
3
|
import type { ViewProps } from "react-native";
|
4
4
|
import type { SharedValue } from "react-native-reanimated";
|
5
5
|
import type { SkImage, SkRect, SkSize } from "../skia/types";
|
6
|
-
interface CanvasRef extends FC<CanvasProps> {
|
6
|
+
export interface CanvasRef extends FC<CanvasProps> {
|
7
7
|
makeImageSnapshot(rect?: SkRect): SkImage;
|
8
8
|
makeImageSnapshotAsync(rect?: SkRect): Promise<SkImage>;
|
9
9
|
redraw(): void;
|
@@ -17,4 +17,3 @@ export interface CanvasProps extends ViewProps {
|
|
17
17
|
ref?: React.Ref<CanvasRef>;
|
18
18
|
}
|
19
19
|
export declare const Canvas: ({ debug, opaque, children, onSize, onLayout: _onLayout, ref, ...viewProps }: CanvasProps) => React.JSX.Element;
|
20
|
-
export {};
|
@@ -1,9 +1,7 @@
|
|
1
|
-
import type { AtlasProps,
|
2
|
-
import type { Node } from "../../Node";
|
1
|
+
import type { AtlasProps, CircleProps, DiffRectProps, DrawingNodeProps, GlyphsProps, ImageProps, ImageSVGProps, LineProps, OvalProps, ParagraphProps, PatchProps, PathProps, PictureProps, PointsProps, RectProps, RoundedRectProps, TextBlobProps, TextPathProps, TextProps, VerticesProps } from "../../../dom/types";
|
3
2
|
import type { DrawingContext } from "../DrawingContext";
|
4
3
|
export declare const drawLine: (ctx: DrawingContext, props: LineProps) => void;
|
5
4
|
export declare const drawOval: (ctx: DrawingContext, props: OvalProps) => void;
|
6
|
-
export declare const drawBox: (ctx: DrawingContext, props: BoxProps, children: Node<any>[]) => void;
|
7
5
|
export declare const drawImage: (ctx: DrawingContext, props: ImageProps) => void;
|
8
6
|
export declare const drawPoints: (ctx: DrawingContext, props: PointsProps) => void;
|
9
7
|
export declare const drawVertices: (ctx: DrawingContext, props: VerticesProps) => void;
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -8,73 +8,73 @@
|
|
8
8
|
<key>BinaryPath</key>
|
9
9
|
<string>libskia.a</string>
|
10
10
|
<key>LibraryIdentifier</key>
|
11
|
-
<string>
|
11
|
+
<string>tvos-arm64_arm64e_x86_64-simulator</string>
|
12
12
|
<key>LibraryPath</key>
|
13
13
|
<string>libskia.a</string>
|
14
14
|
<key>SupportedArchitectures</key>
|
15
15
|
<array>
|
16
16
|
<string>arm64</string>
|
17
|
+
<string>arm64e</string>
|
17
18
|
<string>x86_64</string>
|
18
19
|
</array>
|
19
20
|
<key>SupportedPlatform</key>
|
20
|
-
<string>
|
21
|
+
<string>tvos</string>
|
22
|
+
<key>SupportedPlatformVariant</key>
|
23
|
+
<string>simulator</string>
|
21
24
|
</dict>
|
22
25
|
<dict>
|
23
26
|
<key>BinaryPath</key>
|
24
27
|
<string>libskia.a</string>
|
25
28
|
<key>LibraryIdentifier</key>
|
26
|
-
<string>
|
29
|
+
<string>tvos-arm64_arm64e</string>
|
27
30
|
<key>LibraryPath</key>
|
28
31
|
<string>libskia.a</string>
|
29
32
|
<key>SupportedArchitectures</key>
|
30
33
|
<array>
|
31
34
|
<string>arm64</string>
|
32
35
|
<string>arm64e</string>
|
33
|
-
<string>x86_64</string>
|
34
36
|
</array>
|
35
37
|
<key>SupportedPlatform</key>
|
36
|
-
<string>
|
37
|
-
<key>SupportedPlatformVariant</key>
|
38
|
-
<string>simulator</string>
|
38
|
+
<string>tvos</string>
|
39
39
|
</dict>
|
40
40
|
<dict>
|
41
41
|
<key>BinaryPath</key>
|
42
42
|
<string>libskia.a</string>
|
43
43
|
<key>LibraryIdentifier</key>
|
44
|
-
<string>
|
44
|
+
<string>macos-arm64_x86_64</string>
|
45
45
|
<key>LibraryPath</key>
|
46
46
|
<string>libskia.a</string>
|
47
47
|
<key>SupportedArchitectures</key>
|
48
48
|
<array>
|
49
49
|
<string>arm64</string>
|
50
|
-
<string>arm64e</string>
|
51
50
|
<string>x86_64</string>
|
52
51
|
</array>
|
53
52
|
<key>SupportedPlatform</key>
|
54
|
-
<string>
|
55
|
-
<key>SupportedPlatformVariant</key>
|
56
|
-
<string>simulator</string>
|
53
|
+
<string>macos</string>
|
57
54
|
</dict>
|
58
55
|
<dict>
|
59
56
|
<key>BinaryPath</key>
|
60
57
|
<string>libskia.a</string>
|
61
58
|
<key>LibraryIdentifier</key>
|
62
|
-
<string>ios-
|
59
|
+
<string>ios-arm64_arm64e_x86_64-simulator</string>
|
63
60
|
<key>LibraryPath</key>
|
64
61
|
<string>libskia.a</string>
|
65
62
|
<key>SupportedArchitectures</key>
|
66
63
|
<array>
|
67
64
|
<string>arm64</string>
|
68
65
|
<string>arm64e</string>
|
66
|
+
<string>x86_64</string>
|
69
67
|
</array>
|
70
68
|
<key>SupportedPlatform</key>
|
71
69
|
<string>ios</string>
|
70
|
+
<key>SupportedPlatformVariant</key>
|
71
|
+
<string>simulator</string>
|
72
72
|
</dict>
|
73
73
|
<dict>
|
74
74
|
<key>BinaryPath</key>
|
75
75
|
<string>libskia.a</string>
|
76
76
|
<key>LibraryIdentifier</key>
|
77
|
-
<string>
|
77
|
+
<string>ios-arm64_arm64e</string>
|
78
78
|
<key>LibraryPath</key>
|
79
79
|
<string>libskia.a</string>
|
80
80
|
<key>SupportedArchitectures</key>
|
@@ -83,7 +83,7 @@
|
|
83
83
|
<string>arm64e</string>
|
84
84
|
</array>
|
85
85
|
<key>SupportedPlatform</key>
|
86
|
-
<string>
|
86
|
+
<string>ios</string>
|
87
87
|
</dict>
|
88
88
|
</array>
|
89
89
|
<key>CFBundlePackageType</key>
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -8,19 +8,16 @@
|
|
8
8
|
<key>BinaryPath</key>
|
9
9
|
<string>libskottie.a</string>
|
10
10
|
<key>LibraryIdentifier</key>
|
11
|
-
<string>
|
11
|
+
<string>tvos-arm64_arm64e</string>
|
12
12
|
<key>LibraryPath</key>
|
13
13
|
<string>libskottie.a</string>
|
14
14
|
<key>SupportedArchitectures</key>
|
15
15
|
<array>
|
16
16
|
<string>arm64</string>
|
17
17
|
<string>arm64e</string>
|
18
|
-
<string>x86_64</string>
|
19
18
|
</array>
|
20
19
|
<key>SupportedPlatform</key>
|
21
|
-
<string>
|
22
|
-
<key>SupportedPlatformVariant</key>
|
23
|
-
<string>simulator</string>
|
20
|
+
<string>tvos</string>
|
24
21
|
</dict>
|
25
22
|
<dict>
|
26
23
|
<key>BinaryPath</key>
|
@@ -74,16 +71,19 @@
|
|
74
71
|
<key>BinaryPath</key>
|
75
72
|
<string>libskottie.a</string>
|
76
73
|
<key>LibraryIdentifier</key>
|
77
|
-
<string>
|
74
|
+
<string>ios-arm64_arm64e_x86_64-simulator</string>
|
78
75
|
<key>LibraryPath</key>
|
79
76
|
<string>libskottie.a</string>
|
80
77
|
<key>SupportedArchitectures</key>
|
81
78
|
<array>
|
82
79
|
<string>arm64</string>
|
83
80
|
<string>arm64e</string>
|
81
|
+
<string>x86_64</string>
|
84
82
|
</array>
|
85
83
|
<key>SupportedPlatform</key>
|
86
|
-
<string>
|
84
|
+
<string>ios</string>
|
85
|
+
<key>SupportedPlatformVariant</key>
|
86
|
+
<string>simulator</string>
|
87
87
|
</dict>
|
88
88
|
</array>
|
89
89
|
<key>CFBundlePackageType</key>
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -8,25 +8,22 @@
|
|
8
8
|
<key>BinaryPath</key>
|
9
9
|
<string>libskparagraph.a</string>
|
10
10
|
<key>LibraryIdentifier</key>
|
11
|
-
<string>
|
11
|
+
<string>macos-arm64_x86_64</string>
|
12
12
|
<key>LibraryPath</key>
|
13
13
|
<string>libskparagraph.a</string>
|
14
14
|
<key>SupportedArchitectures</key>
|
15
15
|
<array>
|
16
16
|
<string>arm64</string>
|
17
|
-
<string>arm64e</string>
|
18
17
|
<string>x86_64</string>
|
19
18
|
</array>
|
20
19
|
<key>SupportedPlatform</key>
|
21
|
-
<string>
|
22
|
-
<key>SupportedPlatformVariant</key>
|
23
|
-
<string>simulator</string>
|
20
|
+
<string>macos</string>
|
24
21
|
</dict>
|
25
22
|
<dict>
|
26
23
|
<key>BinaryPath</key>
|
27
24
|
<string>libskparagraph.a</string>
|
28
25
|
<key>LibraryIdentifier</key>
|
29
|
-
<string>
|
26
|
+
<string>tvos-arm64_arm64e</string>
|
30
27
|
<key>LibraryPath</key>
|
31
28
|
<string>libskparagraph.a</string>
|
32
29
|
<key>SupportedArchitectures</key>
|
@@ -35,13 +32,13 @@
|
|
35
32
|
<string>arm64e</string>
|
36
33
|
</array>
|
37
34
|
<key>SupportedPlatform</key>
|
38
|
-
<string>
|
35
|
+
<string>tvos</string>
|
39
36
|
</dict>
|
40
37
|
<dict>
|
41
38
|
<key>BinaryPath</key>
|
42
39
|
<string>libskparagraph.a</string>
|
43
40
|
<key>LibraryIdentifier</key>
|
44
|
-
<string>
|
41
|
+
<string>ios-arm64_arm64e</string>
|
45
42
|
<key>LibraryPath</key>
|
46
43
|
<string>libskparagraph.a</string>
|
47
44
|
<key>SupportedArchitectures</key>
|
@@ -50,28 +47,31 @@
|
|
50
47
|
<string>arm64e</string>
|
51
48
|
</array>
|
52
49
|
<key>SupportedPlatform</key>
|
53
|
-
<string>
|
50
|
+
<string>ios</string>
|
54
51
|
</dict>
|
55
52
|
<dict>
|
56
53
|
<key>BinaryPath</key>
|
57
54
|
<string>libskparagraph.a</string>
|
58
55
|
<key>LibraryIdentifier</key>
|
59
|
-
<string>
|
56
|
+
<string>tvos-arm64_arm64e_x86_64-simulator</string>
|
60
57
|
<key>LibraryPath</key>
|
61
58
|
<string>libskparagraph.a</string>
|
62
59
|
<key>SupportedArchitectures</key>
|
63
60
|
<array>
|
64
61
|
<string>arm64</string>
|
62
|
+
<string>arm64e</string>
|
65
63
|
<string>x86_64</string>
|
66
64
|
</array>
|
67
65
|
<key>SupportedPlatform</key>
|
68
|
-
<string>
|
66
|
+
<string>tvos</string>
|
67
|
+
<key>SupportedPlatformVariant</key>
|
68
|
+
<string>simulator</string>
|
69
69
|
</dict>
|
70
70
|
<dict>
|
71
71
|
<key>BinaryPath</key>
|
72
72
|
<string>libskparagraph.a</string>
|
73
73
|
<key>LibraryIdentifier</key>
|
74
|
-
<string>
|
74
|
+
<string>ios-arm64_arm64e_x86_64-simulator</string>
|
75
75
|
<key>LibraryPath</key>
|
76
76
|
<string>libskparagraph.a</string>
|
77
77
|
<key>SupportedArchitectures</key>
|
@@ -81,7 +81,7 @@
|
|
81
81
|
<string>x86_64</string>
|
82
82
|
</array>
|
83
83
|
<key>SupportedPlatform</key>
|
84
|
-
<string>
|
84
|
+
<string>ios</string>
|
85
85
|
<key>SupportedPlatformVariant</key>
|
86
86
|
<string>simulator</string>
|
87
87
|
</dict>
|
Binary file
|
package/libs/apple/libskparagraph.xcframework/ios-arm64_arm64e_x86_64-simulator/libskparagraph.a
CHANGED
Binary file
|
Binary file
|
Binary file
|