@shopify/react-native-skia 2.11.0-next.2 → 2.11.0

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.
Files changed (343) hide show
  1. package/cpp/api/recorder/Convertor.h +57 -9
  2. package/cpp/api/third_party/SkottieUtils.cpp +1 -1
  3. package/cpp/skia/include/android/SkAndroidFrameworkUtils.h +0 -2
  4. package/cpp/skia/include/android/vk/AndroidVulkanMemoryAllocator.h +1 -1
  5. package/cpp/skia/include/codec/SkAndroidCodec.h +1 -1
  6. package/cpp/skia/include/codec/SkAvifDecoder.h +1 -1
  7. package/cpp/skia/include/codec/SkBmpDecoder.h +1 -1
  8. package/cpp/skia/include/codec/SkBmpRustDecoder.h +42 -0
  9. package/cpp/skia/include/codec/SkCodec.h +3 -2
  10. package/cpp/skia/include/codec/SkGifDecoder.h +1 -1
  11. package/cpp/skia/include/codec/SkIcoDecoder.h +1 -1
  12. package/cpp/skia/include/codec/SkJpegDecoder.h +1 -1
  13. package/cpp/skia/include/codec/SkJpegxlDecoder.h +1 -1
  14. package/cpp/skia/include/codec/SkPixmapUtils.h +1 -1
  15. package/cpp/skia/include/codec/SkPngDecoder.h +1 -1
  16. package/cpp/skia/include/codec/SkPngRustDecoder.h +1 -1
  17. package/cpp/skia/include/codec/SkRawDecoder.h +1 -1
  18. package/cpp/skia/include/codec/SkWbmpDecoder.h +1 -1
  19. package/cpp/skia/include/codec/SkWebpDecoder.h +1 -1
  20. package/cpp/skia/include/core/SkBitmap.h +3 -3
  21. package/cpp/skia/include/core/SkCPUContext.h +1 -1
  22. package/cpp/skia/include/core/SkCPURecorder.h +2 -3
  23. package/cpp/skia/include/core/SkCanvas.h +23 -15
  24. package/cpp/skia/include/core/SkColor.h +2 -2
  25. package/cpp/skia/include/core/SkColorFilter.h +1 -1
  26. package/cpp/skia/include/core/SkColorSpace.h +2 -2
  27. package/cpp/skia/include/core/SkColorTable.h +1 -1
  28. package/cpp/skia/include/core/SkContourMeasure.h +1 -1
  29. package/cpp/skia/include/core/SkData.h +1 -1
  30. package/cpp/skia/include/core/SkDataTable.h +2 -2
  31. package/cpp/skia/include/core/SkDocument.h +1 -1
  32. package/cpp/skia/include/core/SkDrawable.h +1 -1
  33. package/cpp/skia/include/core/SkFont.h +2 -2
  34. package/cpp/skia/include/core/SkFontMetrics.h +1 -1
  35. package/cpp/skia/include/core/SkFontMgr.h +1 -1
  36. package/cpp/skia/include/core/SkFontScanner.h +3 -3
  37. package/cpp/skia/include/core/SkFontStyle.h +1 -1
  38. package/cpp/skia/include/core/SkGraphics.h +1 -1
  39. package/cpp/skia/include/core/SkImage.h +1 -1
  40. package/cpp/skia/include/core/SkImageFilter.h +1 -1
  41. package/cpp/skia/include/core/SkImageGenerator.h +1 -1
  42. package/cpp/skia/include/core/SkImageInfo.h +4 -4
  43. package/cpp/skia/include/core/SkMatrix.h +3 -3
  44. package/cpp/skia/include/core/SkMesh.h +2 -2
  45. package/cpp/skia/include/core/SkMilestone.h +1 -1
  46. package/cpp/skia/include/core/SkOverdrawCanvas.h +1 -1
  47. package/cpp/skia/include/core/SkPaint.h +4 -4
  48. package/cpp/skia/include/core/SkPath.h +5 -23
  49. package/cpp/skia/include/core/SkPathBuilder.h +4 -2
  50. package/cpp/skia/include/core/SkPathMeasure.h +1 -1
  51. package/cpp/skia/include/core/SkPictureRecorder.h +1 -1
  52. package/cpp/skia/include/core/SkPixelRef.h +3 -5
  53. package/cpp/skia/include/core/SkPixmap.h +7 -2
  54. package/cpp/skia/include/core/SkPoint.h +555 -5
  55. package/cpp/skia/include/core/SkPoint3.h +2 -2
  56. package/cpp/skia/include/core/SkRRect.h +9 -1
  57. package/cpp/skia/include/core/SkRSXform.h +1 -1
  58. package/cpp/skia/include/core/SkRecorder.h +2 -3
  59. package/cpp/skia/include/core/SkRect.h +3 -3
  60. package/cpp/skia/include/core/SkRefCnt.h +1 -1
  61. package/cpp/skia/include/core/SkRegion.h +4 -4
  62. package/cpp/skia/include/core/SkScalar.h +2 -3
  63. package/cpp/skia/include/core/SkSerialProcs.h +1 -1
  64. package/cpp/skia/include/core/SkShader.h +1 -1
  65. package/cpp/skia/include/core/SkSize.h +1 -1
  66. package/cpp/skia/include/core/SkSpan.h +165 -4
  67. package/cpp/skia/include/core/SkStream.h +2 -2
  68. package/cpp/skia/include/core/SkStrikeRef.h +16 -0
  69. package/cpp/skia/include/core/SkString.h +2 -2
  70. package/cpp/skia/include/core/SkStrokeRec.h +1 -1
  71. package/cpp/skia/include/core/SkSurfaceProps.h +1 -1
  72. package/cpp/skia/include/core/SkSwizzle.h +1 -1
  73. package/cpp/skia/include/core/SkTextBlob.h +2 -2
  74. package/cpp/skia/include/core/SkTiledImageUtils.h +1 -1
  75. package/cpp/skia/include/core/SkTypeface.h +8 -2
  76. package/cpp/skia/include/core/SkTypes.h +6 -6
  77. package/cpp/skia/include/core/SkUnPreMultiply.h +1 -1
  78. package/cpp/skia/include/core/SkVertices.h +1 -1
  79. package/cpp/skia/include/core/SkYUVAPixmaps.h +1 -1
  80. package/cpp/skia/include/docs/SkPDFDocument.h +9 -3
  81. package/cpp/skia/include/effects/SkGradient.h +1 -1
  82. package/cpp/skia/include/effects/SkPerlinNoiseShader.h +1 -1
  83. package/cpp/skia/include/effects/SkRuntimeEffect.h +4 -4
  84. package/cpp/skia/include/encode/SkEncoder.h +3 -3
  85. package/cpp/skia/include/encode/SkICC.h +1 -1
  86. package/cpp/skia/include/encode/SkJpegEncoder.h +1 -1
  87. package/cpp/skia/include/encode/SkPngEncoder.h +1 -1
  88. package/cpp/skia/include/encode/SkPngRustEncoder.h +16 -1
  89. package/cpp/skia/include/encode/SkWebpEncoder.h +1 -1
  90. package/cpp/skia/include/gpu/GpuTypes.h +1 -1
  91. package/cpp/skia/include/gpu/MutableTextureState.h +1 -1
  92. package/cpp/skia/include/gpu/ganesh/GrBackendSemaphore.h +2 -2
  93. package/cpp/skia/include/gpu/ganesh/GrBackendSurface.h +3 -3
  94. package/cpp/skia/include/gpu/ganesh/GrDriverBugWorkaroundsAutogen.h +39 -37
  95. package/cpp/skia/include/gpu/ganesh/GrExternalTextureGenerator.h +1 -1
  96. package/cpp/skia/include/gpu/ganesh/GrRecordingContext.h +3 -2
  97. package/cpp/skia/include/gpu/ganesh/GrTypes.h +1 -1
  98. package/cpp/skia/include/gpu/ganesh/SkImageGanesh.h +1 -1
  99. package/cpp/skia/include/gpu/ganesh/SkMeshGanesh.h +1 -1
  100. package/cpp/skia/include/gpu/ganesh/SkSurfaceGanesh.h +1 -1
  101. package/cpp/skia/include/gpu/ganesh/d3d/GrD3DBackendSemaphore.h +1 -1
  102. package/cpp/skia/include/gpu/ganesh/d3d/GrD3DBackendSurface.h +1 -1
  103. package/cpp/skia/include/gpu/ganesh/d3d/GrD3DDirectContext.h +1 -1
  104. package/cpp/skia/include/gpu/ganesh/gl/GrGLAssembleInterface.h +1 -1
  105. package/cpp/skia/include/gpu/ganesh/gl/GrGLBackendSurface.h +1 -1
  106. package/cpp/skia/include/gpu/ganesh/gl/GrGLConfig.h +1 -1
  107. package/cpp/skia/include/gpu/ganesh/gl/GrGLDirectContext.h +1 -1
  108. package/cpp/skia/include/gpu/ganesh/gl/GrGLExtensions.h +2 -2
  109. package/cpp/skia/include/gpu/ganesh/gl/GrGLFunctions.h +1 -1
  110. package/cpp/skia/include/gpu/ganesh/gl/GrGLMakeWebGLInterface.h +1 -1
  111. package/cpp/skia/include/gpu/ganesh/gl/epoxy/GrGLMakeEpoxyEGLInterface.h +1 -1
  112. package/cpp/skia/include/gpu/ganesh/gl/glx/GrGLMakeGLXInterface.h +1 -1
  113. package/cpp/skia/include/gpu/ganesh/gl/ios/GrGLMakeIOSInterface.h +1 -1
  114. package/cpp/skia/include/gpu/ganesh/gl/mac/GrGLMakeMacInterface.h +1 -1
  115. package/cpp/skia/include/gpu/ganesh/gl/win/GrGLMakeWinInterface.h +1 -1
  116. package/cpp/skia/include/gpu/ganesh/mock/GrMockBackendSurface.h +1 -1
  117. package/cpp/skia/include/gpu/ganesh/mock/GrMockTypes.h +1 -1
  118. package/cpp/skia/include/gpu/ganesh/mtl/GrMtlBackendSemaphore.h +1 -1
  119. package/cpp/skia/include/gpu/ganesh/mtl/GrMtlBackendSurface.h +1 -1
  120. package/cpp/skia/include/gpu/ganesh/mtl/GrMtlDirectContext.h +1 -1
  121. package/cpp/skia/include/gpu/ganesh/vk/GrVkBackendSemaphore.h +1 -1
  122. package/cpp/skia/include/gpu/ganesh/vk/GrVkBackendSurface.h +1 -1
  123. package/cpp/skia/include/gpu/ganesh/vk/GrVkDirectContext.h +1 -1
  124. package/cpp/skia/include/gpu/graphite/BackendSemaphore.h +2 -2
  125. package/cpp/skia/include/gpu/graphite/BackendTexture.h +2 -2
  126. package/cpp/skia/include/gpu/graphite/Context.h +3 -3
  127. package/cpp/skia/include/gpu/graphite/ContextOptions.h +8 -2
  128. package/cpp/skia/include/gpu/graphite/PersistentPipelineStorage.h +1 -1
  129. package/cpp/skia/include/gpu/graphite/PrecompileContext.h +16 -2
  130. package/cpp/skia/include/gpu/graphite/Recorder.h +8 -7
  131. package/cpp/skia/include/gpu/graphite/Recording.h +6 -4
  132. package/cpp/skia/include/gpu/graphite/TextureInfo.h +2 -2
  133. package/cpp/skia/include/gpu/graphite/dawn/DawnGraphiteTypes.h +1 -1
  134. package/cpp/skia/include/gpu/graphite/mtl/MtlBackendContext.h +1 -1
  135. package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteTypes.h +1 -1
  136. package/cpp/skia/include/gpu/graphite/mtl/MtlGraphiteTypes_cpp.h +1 -1
  137. package/cpp/skia/include/gpu/graphite/precompile/PaintOptions.h +2 -2
  138. package/cpp/skia/include/gpu/graphite/precompile/PrecompileImageFilter.h +1 -1
  139. package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteContext.h +1 -1
  140. package/cpp/skia/include/gpu/vk/VulkanBackendContext.h +1 -1
  141. package/cpp/skia/include/gpu/vk/VulkanExtensions.h +3 -3
  142. package/cpp/skia/include/gpu/vk/VulkanMutableTextureState.h +1 -1
  143. package/cpp/skia/include/gpu/vk/VulkanPreferredFeatures.h +1 -1
  144. package/cpp/skia/include/gpu/vk/VulkanTypes.h +1 -1
  145. package/cpp/skia/include/pathops/SkPathOps.h +2 -2
  146. package/cpp/skia/include/ports/SkImageGeneratorCG.h +2 -2
  147. package/cpp/skia/include/ports/SkImageGeneratorWIC.h +2 -2
  148. package/cpp/skia/include/private/{base/SingleOwner.h → SingleOwner.h} +5 -5
  149. package/cpp/skia/include/private/{base/SkAPI.h → SkAPI.h} +1 -1
  150. package/cpp/skia/include/private/{base/SkAlign.h → SkAlign.h} +1 -1
  151. package/cpp/skia/include/private/{base/SkAnySubclass.h → SkAnySubclass.h} +1 -1
  152. package/cpp/skia/include/private/{base/SkAssert.h → SkAssert.h} +4 -4
  153. package/cpp/skia/include/private/{base/SkAttributes.h → SkAttributes.h} +2 -2
  154. package/cpp/skia/include/private/{base/SkContainers.h → SkContainers.h} +3 -3
  155. package/cpp/skia/include/private/{base/SkDebug.h → SkDebug.h} +3 -3
  156. package/cpp/skia/include/private/{base/SkDeque.h → SkDeque.h} +1 -1
  157. package/cpp/skia/include/private/SkEncodedInfo.h +2 -2
  158. package/cpp/skia/include/private/SkEnumBitMask.h +92 -0
  159. package/cpp/skia/include/private/SkExif.h +1 -1
  160. package/cpp/skia/include/private/{base/SkFixed.h → SkFixed.h} +4 -4
  161. package/cpp/skia/include/private/{base/SkFloatingPoint.h → SkFloatingPoint.h} +2 -2
  162. package/cpp/skia/include/private/SkGainmapShader.h +1 -1
  163. package/cpp/skia/include/private/SkHdrMetadata.h +1 -1
  164. package/cpp/skia/include/private/SkIDChangeListener.h +3 -3
  165. package/cpp/skia/include/private/{base/SkLoadUserConfig.h → SkLoadUserConfig.h} +2 -2
  166. package/cpp/skia/include/private/{base/SkLog.h → SkLog.h} +4 -4
  167. package/cpp/skia/include/private/{base/SkMacros.h → SkMacros.h} +1 -1
  168. package/cpp/skia/include/private/{base/SkMalloc.h → SkMalloc.h} +1 -1
  169. package/cpp/skia/include/private/{base/SkMath.h → SkMath.h} +2 -2
  170. package/cpp/skia/include/private/{base/SkMutex.h → SkMutex.h} +5 -5
  171. package/cpp/skia/include/private/{base/SkNoncopyable.h → SkNoncopyable.h} +1 -1
  172. package/cpp/skia/include/private/{base/SkOnce.h → SkOnce.h} +1 -1
  173. package/cpp/skia/include/private/SkPathRef.h +4 -4
  174. package/cpp/skia/include/private/SkPixelStorage.h +20 -5
  175. package/cpp/skia/include/private/{base/SkSafe32.h → SkSafe32.h} +2 -2
  176. package/cpp/skia/include/private/{base/SkSemaphore.h → SkSemaphore.h} +3 -3
  177. package/cpp/skia/include/private/{base/SkTArray.h → SkTArray.h} +10 -11
  178. package/cpp/skia/include/private/{base/SkTDArray.h → SkTDArray.h} +4 -4
  179. package/cpp/skia/include/private/{base/SkTFitsIn.h → SkTFitsIn.h} +0 -2
  180. package/cpp/skia/include/private/{base/SkTLogic.h → SkTLogic.h} +1 -1
  181. package/cpp/skia/include/private/{base/SkTemplates.h → SkTemplates.h} +5 -6
  182. package/cpp/skia/include/private/{base/SkThreadAnnotations.h → SkThreadAnnotations.h} +1 -1
  183. package/cpp/skia/include/private/{base/SkThreadID.h → SkThreadID.h} +2 -2
  184. package/cpp/skia/include/private/{base/SkTo.h → SkTo.h} +2 -2
  185. package/cpp/skia/include/private/{base/SkTypeTraits.h → SkTypeTraits.h} +20 -0
  186. package/cpp/skia/include/private/SkXmp.h +1 -1
  187. package/cpp/skia/include/private/chromium/GrDeferredDisplayList.h +1 -1
  188. package/cpp/skia/include/private/chromium/GrSurfaceCharacterization.h +1 -1
  189. package/cpp/skia/include/private/chromium/SkChromeRemoteGlyphCache.h +1 -1
  190. package/cpp/skia/include/private/chromium/SkCodecsICCProfileChromium.h +1 -1
  191. package/cpp/skia/include/private/chromium/SkExifChromium.h +1 -1
  192. package/cpp/skia/include/private/chromium/SkImageChromium.h +1 -1
  193. package/cpp/skia/include/private/chromium/SkPMColor.h +1 -1
  194. package/cpp/skia/include/private/chromium/Slug.h +1 -1
  195. package/cpp/skia/include/private/gpu/ganesh/GrContext_Base.h +1 -1
  196. package/cpp/skia/include/private/gpu/ganesh/GrImageContext.h +2 -2
  197. package/cpp/skia/include/private/gpu/ganesh/GrTextureGenerator.h +1 -1
  198. package/cpp/skia/include/private/gpu/ganesh/GrTypesPriv.h +4 -4
  199. package/cpp/skia/include/utils/SkCamera.h +1 -1
  200. package/cpp/skia/include/utils/SkNWayCanvas.h +1 -1
  201. package/cpp/skia/include/utils/SkPaintFilterCanvas.h +1 -1
  202. package/cpp/skia/modules/jsonreader/SkJSONReader.cpp +6 -6
  203. package/cpp/skia/modules/jsonreader/SkJSONReader.h +2 -2
  204. package/cpp/skia/modules/skottie/include/SkottieProperty.h +1 -1
  205. package/cpp/skia/modules/skottie/include/SlotManager.h +2 -2
  206. package/cpp/skia/modules/skottie/include/TextShaper.h +1 -1
  207. package/cpp/skia/modules/skottie/src/text/Font.h +1 -1
  208. package/cpp/skia/modules/skparagraph/include/ParagraphCache.h +1 -1
  209. package/cpp/skia/modules/skparagraph/include/TypefaceFontProvider.h +1 -1
  210. package/cpp/skia/modules/skresources/include/SkResources.h +1 -1
  211. package/cpp/skia/modules/sksg/include/SkSGNode.h +1 -1
  212. package/cpp/skia/modules/sksg/include/SkSGRect.h +1 -1
  213. package/cpp/skia/modules/sksg/include/SkSGRenderEffect.h +1 -1
  214. package/cpp/skia/modules/skunicode/include/SkUnicode.h +3 -3
  215. package/cpp/skia/modules/svg/include/SkSVGAttributeParser.h +1 -1
  216. package/cpp/skia/modules/svg/include/SkSVGCircle.h +1 -1
  217. package/cpp/skia/modules/svg/include/SkSVGClipPath.h +1 -1
  218. package/cpp/skia/modules/svg/include/SkSVGContainer.h +2 -2
  219. package/cpp/skia/modules/svg/include/SkSVGDOM.h +1 -1
  220. package/cpp/skia/modules/svg/include/SkSVGEllipse.h +1 -1
  221. package/cpp/skia/modules/svg/include/SkSVGFe.h +1 -1
  222. package/cpp/skia/modules/svg/include/SkSVGFeBlend.h +1 -1
  223. package/cpp/skia/modules/svg/include/SkSVGFeColorMatrix.h +1 -1
  224. package/cpp/skia/modules/svg/include/SkSVGFeComponentTransfer.h +1 -1
  225. package/cpp/skia/modules/svg/include/SkSVGFeComposite.h +1 -1
  226. package/cpp/skia/modules/svg/include/SkSVGFeDisplacementMap.h +1 -1
  227. package/cpp/skia/modules/svg/include/SkSVGFeFlood.h +1 -1
  228. package/cpp/skia/modules/svg/include/SkSVGFeGaussianBlur.h +1 -1
  229. package/cpp/skia/modules/svg/include/SkSVGFeImage.h +1 -1
  230. package/cpp/skia/modules/svg/include/SkSVGFeLightSource.h +2 -2
  231. package/cpp/skia/modules/svg/include/SkSVGFeLighting.h +1 -1
  232. package/cpp/skia/modules/svg/include/SkSVGFeMerge.h +1 -1
  233. package/cpp/skia/modules/svg/include/SkSVGFeOffset.h +1 -1
  234. package/cpp/skia/modules/svg/include/SkSVGFeTurbulence.h +1 -1
  235. package/cpp/skia/modules/svg/include/SkSVGFilter.h +1 -1
  236. package/cpp/skia/modules/svg/include/SkSVGGradient.h +2 -2
  237. package/cpp/skia/modules/svg/include/SkSVGImage.h +2 -2
  238. package/cpp/skia/modules/svg/include/SkSVGLine.h +1 -1
  239. package/cpp/skia/modules/svg/include/SkSVGLinearGradient.h +1 -1
  240. package/cpp/skia/modules/svg/include/SkSVGMask.h +1 -1
  241. package/cpp/skia/modules/svg/include/SkSVGNode.h +1 -1
  242. package/cpp/skia/modules/svg/include/SkSVGPath.h +1 -1
  243. package/cpp/skia/modules/svg/include/SkSVGPattern.h +1 -1
  244. package/cpp/skia/modules/svg/include/SkSVGPoly.h +1 -1
  245. package/cpp/skia/modules/svg/include/SkSVGRadialGradient.h +1 -1
  246. package/cpp/skia/modules/svg/include/SkSVGRect.h +1 -1
  247. package/cpp/skia/modules/svg/include/SkSVGRenderContext.h +1 -1
  248. package/cpp/skia/modules/svg/include/SkSVGSVG.h +1 -1
  249. package/cpp/skia/modules/svg/include/SkSVGShape.h +1 -1
  250. package/cpp/skia/modules/svg/include/SkSVGStop.h +1 -1
  251. package/cpp/skia/modules/svg/include/SkSVGText.h +1 -1
  252. package/cpp/skia/modules/svg/include/SkSVGTransformableNode.h +1 -1
  253. package/cpp/skia/modules/svg/include/SkSVGUse.h +1 -1
  254. package/cpp/skia/modules/svg/include/SkSVGValue.h +1 -1
  255. package/cpp/skia/src/{base → core}/SkArenaAlloc.h +5 -5
  256. package/cpp/skia/src/{base → core}/SkAutoLocaleSetter.h +1 -1
  257. package/cpp/skia/src/core/SkChecksum.h +1 -1
  258. package/cpp/skia/src/core/SkLRUCache.h +1 -1
  259. package/cpp/skia/src/{base → core}/SkMathPriv.h +3 -3
  260. package/cpp/skia/src/core/SkTHash.h +1 -1
  261. package/cpp/skia/src/{base → core}/SkTInternalLList.h +3 -3
  262. package/cpp/skia/src/{base → core}/SkTLazy.h +1 -1
  263. package/cpp/skia/src/{base → core}/SkUTF.h +1 -1
  264. package/lib/commonjs/renderer/processors/Animations/Animations.d.ts +27 -1
  265. package/lib/commonjs/renderer/processors/Animations/Animations.js +28 -0
  266. package/lib/commonjs/renderer/processors/Animations/Animations.js.map +1 -1
  267. package/lib/commonjs/sksg/Recorder/Core.js +8 -1
  268. package/lib/commonjs/sksg/Recorder/Core.js.map +1 -1
  269. package/lib/commonjs/sksg/Recorder/ReanimatedRecorder.js +8 -0
  270. package/lib/commonjs/sksg/Recorder/ReanimatedRecorder.js.map +1 -1
  271. package/lib/commonjs/sksg/Recorder/Recorder.d.ts +1 -1
  272. package/lib/commonjs/sksg/Recorder/Recorder.js +4 -0
  273. package/lib/commonjs/sksg/Recorder/Recorder.js.map +1 -1
  274. package/lib/commonjs/sksg/utils.d.ts +4 -0
  275. package/lib/commonjs/sksg/utils.js +14 -1
  276. package/lib/commonjs/sksg/utils.js.map +1 -1
  277. package/lib/module/renderer/processors/Animations/Animations.d.ts +27 -1
  278. package/lib/module/renderer/processors/Animations/Animations.js +21 -0
  279. package/lib/module/renderer/processors/Animations/Animations.js.map +1 -1
  280. package/lib/module/sksg/Recorder/Core.js +8 -1
  281. package/lib/module/sksg/Recorder/Core.js.map +1 -1
  282. package/lib/module/sksg/Recorder/ReanimatedRecorder.js +9 -1
  283. package/lib/module/sksg/Recorder/ReanimatedRecorder.js.map +1 -1
  284. package/lib/module/sksg/Recorder/Recorder.d.ts +1 -1
  285. package/lib/module/sksg/Recorder/Recorder.js +5 -1
  286. package/lib/module/sksg/Recorder/Recorder.js.map +1 -1
  287. package/lib/module/sksg/utils.d.ts +4 -0
  288. package/lib/module/sksg/utils.js +12 -0
  289. package/lib/module/sksg/utils.js.map +1 -1
  290. package/lib/typescript/lib/commonjs/renderer/processors/Animations/Animations.d.ts +22 -0
  291. package/lib/typescript/lib/commonjs/sksg/utils.d.ts +1 -0
  292. package/lib/typescript/lib/module/mock/index.d.ts +4 -0
  293. package/lib/typescript/lib/module/renderer/processors/Animations/Animations.d.ts +4 -0
  294. package/lib/typescript/lib/module/renderer/processors/Animations/index.d.ts +1 -1
  295. package/lib/typescript/lib/module/sksg/utils.d.ts +1 -0
  296. package/lib/typescript/src/renderer/processors/Animations/Animations.d.ts +27 -1
  297. package/lib/typescript/src/sksg/Recorder/Recorder.d.ts +1 -1
  298. package/lib/typescript/src/sksg/utils.d.ts +4 -0
  299. package/package.json +9 -9
  300. package/src/renderer/processors/Animations/Animations.ts +34 -1
  301. package/src/sksg/Recorder/Core.ts +11 -1
  302. package/src/sksg/Recorder/ReanimatedRecorder.ts +10 -1
  303. package/src/sksg/Recorder/Recorder.ts +7 -3
  304. package/src/sksg/utils.ts +18 -0
  305. package/cpp/dawn/include/dawn/dawn_proc.h +0 -53
  306. package/cpp/dawn/include/dawn/dawn_proc_table.h +0 -330
  307. package/cpp/dawn/include/dawn/dawn_thread_dispatch_proc.h +0 -47
  308. package/cpp/dawn/include/dawn/dawn_version.h +0 -41
  309. package/cpp/dawn/include/dawn/native/D3D11Backend.h +0 -65
  310. package/cpp/dawn/include/dawn/native/D3D12Backend.h +0 -86
  311. package/cpp/dawn/include/dawn/native/D3DBackend.h +0 -56
  312. package/cpp/dawn/include/dawn/native/DawnNative.h +0 -369
  313. package/cpp/dawn/include/dawn/native/MetalBackend.h +0 -56
  314. package/cpp/dawn/include/dawn/native/NullBackend.h +0 -39
  315. package/cpp/dawn/include/dawn/native/OpenGLBackend.h +0 -89
  316. package/cpp/dawn/include/dawn/native/VulkanBackend.h +0 -183
  317. package/cpp/dawn/include/dawn/native/WebGPUBackend.h +0 -49
  318. package/cpp/dawn/include/dawn/native/dawn_native_export.h +0 -49
  319. package/cpp/dawn/include/dawn/platform/DawnPlatform.h +0 -210
  320. package/cpp/dawn/include/dawn/platform/dawn_platform_export.h +0 -49
  321. package/cpp/dawn/include/dawn/replay/Replay.h +0 -99
  322. package/cpp/dawn/include/dawn/replay/dawn_replay_export.h +0 -49
  323. package/cpp/dawn/include/dawn/webgpu_cpp_print.h +0 -2844
  324. package/cpp/dawn/include/tint/tint.h +0 -90
  325. package/cpp/dawn/include/webgpu/webgpu.h +0 -4987
  326. package/cpp/dawn/include/webgpu/webgpu_cpp.h +0 -10080
  327. package/cpp/dawn/include/webgpu/webgpu_cpp_chained_struct.h +0 -57
  328. package/cpp/dawn/include/webgpu/webgpu_enum_class_bitmasks.h +0 -161
  329. package/cpp/dawn/include/webgpu/webgpu_glfw.h +0 -88
  330. package/cpp/skia/include/gpu/graphite/vk/VulkanGraphiteUtils.h +0 -10
  331. package/cpp/skia/include/private/base/README.md +0 -4
  332. package/cpp/skia/include/private/base/SkPoint_impl.h +0 -560
  333. package/cpp/skia/include/private/base/SkSpan_impl.h +0 -158
  334. package/cpp/skia/src/gpu/graphite/ContextOptionsPriv.h +0 -45
  335. package/cpp/skia/src/gpu/graphite/ResourceTypes.h +0 -360
  336. package/cpp/skia/src/gpu/graphite/TextureProxyView.h +0 -105
  337. package/libs/.graphite +0 -1
  338. /package/cpp/skia/include/private/{base/SkASAN.h → SkASAN.h} +0 -0
  339. /package/cpp/skia/include/private/{base/SkAlignedStorage.h → SkAlignedStorage.h} +0 -0
  340. /package/cpp/skia/include/private/{base/SkCPUTypes.h → SkCPUTypes.h} +0 -0
  341. /package/cpp/skia/include/private/{base/SkFeatures.h → SkFeatures.h} +0 -0
  342. /package/cpp/skia/include/private/{base/SkLogPriority.h → SkLogPriority.h} +0 -0
  343. /package/cpp/skia/include/private/{base/SkTPin.h → SkTPin.h} +0 -0
@@ -9,7 +9,7 @@
9
9
  #define SkSVGFeOffset_DEFINED
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
  #include "modules/svg/include/SkSVGFe.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
@@ -9,7 +9,7 @@
9
9
  #define SkSVGFeTurbulence_DEFINED
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
  #include "modules/svg/include/SkSVGFe.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
@@ -9,7 +9,7 @@
9
9
  #define SkSVGFilter_DEFINED
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
  #include "modules/svg/include/SkSVGHiddenContainer.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,8 +12,8 @@
12
12
  #include "include/core/SkMatrix.h"
13
13
  #include "include/core/SkRefCnt.h"
14
14
  #include "include/core/SkScalar.h"
15
- #include "include/private/base/SkAPI.h"
16
- #include "include/private/base/SkTArray.h"
15
+ #include "include/private/SkAPI.h"
16
+ #include "include/private/SkTArray.h"
17
17
  #include "modules/svg/include/SkSVGHiddenContainer.h"
18
18
  #include "modules/svg/include/SkSVGNode.h"
19
19
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,8 +12,8 @@
12
12
  #include "include/core/SkPath.h"
13
13
  #include "include/core/SkRect.h"
14
14
  #include "include/core/SkRefCnt.h"
15
- #include "include/private/base/SkAPI.h"
16
- #include "include/private/base/SkDebug.h"
15
+ #include "include/private/SkAPI.h"
16
+ #include "include/private/SkDebug.h"
17
17
  #include "modules/svg/include/SkSVGNode.h"
18
18
  #include "modules/svg/include/SkSVGTransformableNode.h"
19
19
  #include "modules/svg/include/SkSVGTypes.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkPath.h"
12
12
  #include "include/core/SkPathTypes.h"
13
13
  #include "include/core/SkRefCnt.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGNode.h"
16
16
  #include "modules/svg/include/SkSVGShape.h"
17
17
  #include "modules/svg/include/SkSVGTypes.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkColor.h"
12
12
  #include "include/core/SkRefCnt.h"
13
13
  #include "include/core/SkScalar.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGGradient.h"
16
16
  #include "modules/svg/include/SkSVGNode.h"
17
17
  #include "modules/svg/include/SkSVGTypes.h"
@@ -10,7 +10,7 @@
10
10
 
11
11
  #include "include/core/SkRect.h"
12
12
  #include "include/core/SkRefCnt.h"
13
- #include "include/private/base/SkAPI.h"
13
+ #include "include/private/SkAPI.h"
14
14
  #include "modules/svg/include/SkSVGHiddenContainer.h"
15
15
  #include "modules/svg/include/SkSVGNode.h"
16
16
  #include "modules/svg/include/SkSVGTypes.h"
@@ -10,7 +10,7 @@
10
10
 
11
11
  #include "include/core/SkRect.h"
12
12
  #include "include/core/SkRefCnt.h"
13
- #include "include/private/base/SkAPI.h"
13
+ #include "include/private/SkAPI.h"
14
14
  #include "modules/svg/include/SkSVGAttribute.h"
15
15
  #include "modules/svg/include/SkSVGAttributeParser.h"
16
16
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,7 +12,7 @@
12
12
  #include "include/core/SkPathTypes.h"
13
13
  #include "include/core/SkRect.h"
14
14
  #include "include/core/SkRefCnt.h"
15
- #include "include/private/base/SkAPI.h"
15
+ #include "include/private/SkAPI.h"
16
16
  #include "modules/svg/include/SkSVGNode.h"
17
17
  #include "modules/svg/include/SkSVGShape.h"
18
18
 
@@ -9,7 +9,7 @@
9
9
  #define SkSVGPattern_DEFINED
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
  #include "modules/svg/include/SkSVGHiddenContainer.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,7 +12,7 @@
12
12
  #include "include/core/SkPathTypes.h"
13
13
  #include "include/core/SkRect.h"
14
14
  #include "include/core/SkRefCnt.h"
15
- #include "include/private/base/SkAPI.h"
15
+ #include "include/private/SkAPI.h"
16
16
  #include "modules/svg/include/SkSVGNode.h"
17
17
  #include "modules/svg/include/SkSVGShape.h"
18
18
  #include "modules/svg/include/SkSVGTypes.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkColor.h"
12
12
  #include "include/core/SkRefCnt.h"
13
13
  #include "include/core/SkScalar.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGGradient.h"
16
16
  #include "modules/svg/include/SkSVGNode.h"
17
17
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,7 +12,7 @@
12
12
  #include "include/core/SkPathTypes.h"
13
13
  #include "include/core/SkRect.h"
14
14
  #include "include/core/SkRefCnt.h"
15
- #include "include/private/base/SkAPI.h"
15
+ #include "include/private/SkAPI.h"
16
16
  #include "modules/svg/include/SkSVGNode.h"
17
17
  #include "modules/svg/include/SkSVGShape.h"
18
18
  #include "modules/svg/include/SkSVGTypes.h"
@@ -23,8 +23,8 @@
23
23
  #include "modules/svg/include/SkSVGIDMapper.h"
24
24
  #include "modules/svg/include/SkSVGNode.h"
25
25
  #include "modules/svg/include/SkSVGTypes.h"
26
- #include "src/base/SkTLazy.h"
27
26
  #include "src/core/SkTHash.h"
27
+ #include "src/core/SkTLazy.h"
28
28
 
29
29
  #include <cstddef>
30
30
  #include <cstdint>
@@ -10,7 +10,7 @@
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
12
  #include "include/core/SkSize.h"
13
- #include "include/private/base/SkAPI.h"
13
+ #include "include/private/SkAPI.h"
14
14
  #include "modules/svg/include/SkSVGContainer.h"
15
15
  #include "modules/svg/include/SkSVGNode.h"
16
16
  #include "modules/svg/include/SkSVGTypes.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkPathTypes.h"
12
12
  #include "include/core/SkRect.h"
13
13
  #include "include/core/SkRefCnt.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGTransformableNode.h"
16
16
 
17
17
  class SkCanvas;
@@ -9,7 +9,7 @@
9
9
  #define SkSVGStop_DEFINED
10
10
 
11
11
  #include "include/core/SkRefCnt.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
  #include "modules/svg/include/SkSVGHiddenContainer.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkPath.h"
12
12
  #include "include/core/SkRect.h"
13
13
  #include "include/core/SkRefCnt.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGNode.h"
16
16
  #include "modules/svg/include/SkSVGTransformableNode.h"
17
17
  #include "modules/svg/include/SkSVGTypes.h"
@@ -10,7 +10,7 @@
10
10
 
11
11
  #include "include/core/SkMatrix.h"
12
12
  #include "include/core/SkPath.h"
13
- #include "include/private/base/SkAPI.h"
13
+ #include "include/private/SkAPI.h"
14
14
  #include "modules/svg/include/SkSVGNode.h"
15
15
  #include "modules/svg/include/SkSVGTypes.h"
16
16
  #include "modules/svg/include/SkSVGValue.h"
@@ -11,7 +11,7 @@
11
11
  #include "include/core/SkPath.h"
12
12
  #include "include/core/SkRect.h"
13
13
  #include "include/core/SkRefCnt.h"
14
- #include "include/private/base/SkAPI.h"
14
+ #include "include/private/SkAPI.h"
15
15
  #include "modules/svg/include/SkSVGNode.h"
16
16
  #include "modules/svg/include/SkSVGTransformableNode.h"
17
17
  #include "modules/svg/include/SkSVGTypes.h"
@@ -12,7 +12,7 @@
12
12
  #include "include/core/SkMatrix.h"
13
13
  #include "include/core/SkPath.h"
14
14
  #include "include/core/SkTypes.h"
15
- #include "include/private/base/SkNoncopyable.h"
15
+ #include "include/private/SkNoncopyable.h"
16
16
  #include "modules/svg/include/SkSVGTypes.h"
17
17
 
18
18
  class SK_API SkSVGValue : public SkNoncopyable {
@@ -8,11 +8,11 @@
8
8
  #ifndef SkArenaAlloc_DEFINED
9
9
  #define SkArenaAlloc_DEFINED
10
10
 
11
- #include "include/private/base/SkASAN.h"
12
- #include "include/private/base/SkAssert.h"
13
- #include "include/private/base/SkSpan_impl.h"
14
- #include "include/private/base/SkTFitsIn.h"
15
- #include "include/private/base/SkTo.h"
11
+ #include "include/core/SkSpan.h"
12
+ #include "include/private/SkASAN.h"
13
+ #include "include/private/SkAssert.h"
14
+ #include "include/private/SkTFitsIn.h"
15
+ #include "include/private/SkTo.h"
16
16
 
17
17
  #include <algorithm>
18
18
  #include <array>
@@ -8,7 +8,7 @@
8
8
  #ifndef SkAutoLocaleSetter_DEFINED
9
9
  #define SkAutoLocaleSetter_DEFINED
10
10
 
11
- #include "include/private/base/SkNoncopyable.h"
11
+ #include "include/private/SkNoncopyable.h"
12
12
 
13
13
  #if defined(SK_BUILD_FOR_WIN)
14
14
  #include <optional>
@@ -9,7 +9,7 @@
9
9
  #define SkChecksum_DEFINED
10
10
 
11
11
  #include "include/core/SkString.h"
12
- #include "include/private/base/SkAPI.h"
12
+ #include "include/private/SkAPI.h"
13
13
 
14
14
  #include <cstddef>
15
15
  #include <cstdint>
@@ -8,9 +8,9 @@
8
8
  #ifndef SkLRUCache_DEFINED
9
9
  #define SkLRUCache_DEFINED
10
10
 
11
- #include "src/base/SkTInternalLList.h"
12
11
  #include "src/core/SkChecksum.h"
13
12
  #include "src/core/SkTHash.h"
13
+ #include "src/core/SkTInternalLList.h"
14
14
 
15
15
  struct SkNoOpPurge {
16
16
  template <typename K, typename V>
@@ -8,9 +8,9 @@
8
8
  #ifndef SkMathPriv_DEFINED
9
9
  #define SkMathPriv_DEFINED
10
10
 
11
- #include "include/private/base/SkAssert.h"
12
- #include "include/private/base/SkCPUTypes.h"
13
- #include "include/private/base/SkTemplates.h"
11
+ #include "include/private/SkAssert.h"
12
+ #include "include/private/SkCPUTypes.h"
13
+ #include "include/private/SkTemplates.h"
14
14
 
15
15
  #include <bit>
16
16
  #include <cstddef>
@@ -9,8 +9,8 @@
9
9
  #define SkTHash_DEFINED
10
10
 
11
11
  #include "include/core/SkTypes.h"
12
- #include "src/base/SkMathPriv.h"
13
12
  #include "src/core/SkChecksum.h"
13
+ #include "src/core/SkMathPriv.h"
14
14
 
15
15
  #include <initializer_list>
16
16
  #include <memory>
@@ -8,9 +8,9 @@
8
8
  #ifndef SkTInternalLList_DEFINED
9
9
  #define SkTInternalLList_DEFINED
10
10
 
11
- #include "include/private/base/SkAssert.h"
12
- #include "include/private/base/SkDebug.h"
13
- #include "include/private/base/SkTo.h"
11
+ #include "include/private/SkAssert.h"
12
+ #include "include/private/SkDebug.h"
13
+ #include "include/private/SkTo.h"
14
14
 
15
15
  /**
16
16
  * This macro creates the member variables required by the SkTInternalLList class. It should be
@@ -8,7 +8,7 @@
8
8
  #ifndef SkTLazy_DEFINED
9
9
  #define SkTLazy_DEFINED
10
10
 
11
- #include "include/private/base/SkAssert.h"
11
+ #include "include/private/SkAssert.h"
12
12
 
13
13
  #include <optional>
14
14
  #include <utility>
@@ -3,7 +3,7 @@
3
3
  #ifndef SkUTF_DEFINED
4
4
  #define SkUTF_DEFINED
5
5
 
6
- #include "include/private/base/SkAPI.h"
6
+ #include "include/private/SkAPI.h"
7
7
 
8
8
  #include <cstddef>
9
9
  #include <cstdint>
@@ -1,6 +1,32 @@
1
+ import type { SharedValue } from "react-native-reanimated";
2
+ /**
3
+ * Binds a prop to a single key of a "grouped" shared value: one shared value
4
+ * whose `.value` is an object can drive many props (one key each) instead of
5
+ * requiring a separate shared value per prop.
6
+ *
7
+ * Created via {@link select}. `T` is the type of the selected value; `__type`
8
+ * is a phantom marker carrying that type and is never present at runtime.
9
+ */
10
+ export type SharedValueSelector<T> = {
11
+ __sv: {
12
+ value: Record<string, unknown>;
13
+ };
14
+ __key: string;
15
+ readonly __type?: T;
16
+ };
1
17
  export type AnimatedProp<T> = T | {
2
18
  value: T;
3
- };
19
+ } | SharedValueSelector<T>;
20
+ /**
21
+ * Selects a single key of a shared value so it can drive an animated prop.
22
+ * This lets one shared value (whose value is an object) drive multiple props
23
+ * — one per key — instead of using a separate shared value for each.
24
+ *
25
+ * @example
26
+ * const data = useSharedValue({ x: 0, y: 0, r: 10 });
27
+ * <Circle cx={select(data, "x")} cy={select(data, "y")} r={select(data, "r")} />
28
+ */
29
+ export declare const select: <T extends object, K extends keyof T & string>(value: SharedValue<T>, key: K) => SharedValueSelector<T[K]>;
4
30
  export type AnimatedProps<T, O extends keyof T | never = never> = {
5
31
  [K in keyof T]: K extends "children" ? T[K] : K extends O ? T[K] : AnimatedProp<T[K]>;
6
32
  };
@@ -1,2 +1,30 @@
1
1
  "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.select = void 0;
7
+ /**
8
+ * Binds a prop to a single key of a "grouped" shared value: one shared value
9
+ * whose `.value` is an object can drive many props (one key each) instead of
10
+ * requiring a separate shared value per prop.
11
+ *
12
+ * Created via {@link select}. `T` is the type of the selected value; `__type`
13
+ * is a phantom marker carrying that type and is never present at runtime.
14
+ */
15
+
16
+ /**
17
+ * Selects a single key of a shared value so it can drive an animated prop.
18
+ * This lets one shared value (whose value is an object) drive multiple props
19
+ * — one per key — instead of using a separate shared value for each.
20
+ *
21
+ * @example
22
+ * const data = useSharedValue({ x: 0, y: 0, r: 10 });
23
+ * <Circle cx={select(data, "x")} cy={select(data, "y")} r={select(data, "r")} />
24
+ */
25
+ const select = (value, key) => ({
26
+ __sv: value,
27
+ __key: key
28
+ });
29
+ exports.select = select;
2
30
  //# sourceMappingURL=Animations.js.map
@@ -1 +1 @@
1
- {"version":3,"names":[],"sources":["Animations.ts"],"sourcesContent":["export type AnimatedProp<T> = T | { value: T };\n\nexport type AnimatedProps<T, O extends keyof T | never = never> = {\n [K in keyof T]: K extends \"children\"\n ? T[K]\n : K extends O\n ? T[K]\n : AnimatedProp<T[K]>;\n};\n\nexport type SkiaProps<\n P = object,\n O extends keyof P | never = never,\n> = AnimatedProps<P, O>;\n\ntype WithOptional<T extends object, N extends keyof T> = Omit<T, N> & {\n [K in N]?: T[K];\n};\n\nexport type SkiaDefaultProps<\n T extends object,\n N extends keyof T,\n> = WithOptional<SkiaProps<T>, N>;\n"],"mappings":"","ignoreList":[]}
1
+ {"version":3,"names":["select","value","key","__sv","__key","exports"],"sources":["Animations.ts"],"sourcesContent":["import type { SharedValue } from \"react-native-reanimated\";\n\n/**\n * Binds a prop to a single key of a \"grouped\" shared value: one shared value\n * whose `.value` is an object can drive many props (one key each) instead of\n * requiring a separate shared value per prop.\n *\n * Created via {@link select}. `T` is the type of the selected value; `__type`\n * is a phantom marker carrying that type and is never present at runtime.\n */\nexport type SharedValueSelector<T> = {\n __sv: { value: Record<string, unknown> };\n __key: string;\n readonly __type?: T;\n};\n\nexport type AnimatedProp<T> = T | { value: T } | SharedValueSelector<T>;\n\n/**\n * Selects a single key of a shared value so it can drive an animated prop.\n * This lets one shared value (whose value is an object) drive multiple props\n * — one per key — instead of using a separate shared value for each.\n *\n * @example\n * const data = useSharedValue({ x: 0, y: 0, r: 10 });\n * <Circle cx={select(data, \"x\")} cy={select(data, \"y\")} r={select(data, \"r\")} />\n */\nexport const select = <T extends object, K extends keyof T & string>(\n value: SharedValue<T>,\n key: K\n): SharedValueSelector<T[K]> => ({\n __sv: value as unknown as { value: Record<string, unknown> },\n __key: key,\n});\n\nexport type AnimatedProps<T, O extends keyof T | never = never> = {\n [K in keyof T]: K extends \"children\"\n ? T[K]\n : K extends O\n ? T[K]\n : AnimatedProp<T[K]>;\n};\n\nexport type SkiaProps<\n P = object,\n O extends keyof P | never = never,\n> = AnimatedProps<P, O>;\n\ntype WithOptional<T extends object, N extends keyof T> = Omit<T, N> & {\n [K in N]?: T[K];\n};\n\nexport type SkiaDefaultProps<\n T extends object,\n N extends keyof T,\n> = WithOptional<SkiaProps<T>, N>;\n"],"mappings":";;;;;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AASA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACO,MAAMA,MAAM,GAAGA,CACpBC,KAAqB,EACrBC,GAAM,MACyB;EAC/BC,IAAI,EAAEF,KAAsD;EAC5DG,KAAK,EAAEF;AACT,CAAC,CAAC;AAACG,OAAA,CAAAL,MAAA,GAAAA,MAAA","ignoreList":[]}
@@ -4,6 +4,7 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.materializeCommand = exports.isGroup = exports.isDrawCommand = exports.isCommand = exports.CommandType = void 0;
7
+ var _utils = require("../utils");
7
8
  let CommandType = exports.CommandType = /*#__PURE__*/function (CommandType) {
8
9
  // Context
9
10
  CommandType[CommandType["Group"] = 0] = "Group";
@@ -57,7 +58,13 @@ const materializeCommand = command => {
57
58
  };
58
59
  if (command.animatedProps) {
59
60
  for (const key in command.animatedProps) {
60
- newProps[key] = command.animatedProps[key].value;
61
+ const entry = command.animatedProps[key];
62
+ if ((0, _utils.isSharedValueSelector)(entry)) {
63
+ const group = entry.__sv.value;
64
+ newProps[key] = group && typeof group === "object" ? group[entry.__key] : undefined;
65
+ } else {
66
+ newProps[key] = entry.value;
67
+ }
61
68
  }
62
69
  }
63
70
  return {
@@ -1 +1 @@
1
- {"version":3,"names":["CommandType","exports","materializeCommand","command","newProps","props","animatedProps","key","value","isCommand","type","isGroup","Group","isDrawCommand"],"sources":["Core.ts"],"sourcesContent":["import type {\n BlurMaskFilterProps,\n CircleProps,\n CTMProps,\n ImageProps,\n PointsProps,\n PathProps,\n RectProps,\n RoundedRectProps,\n OvalProps,\n LineProps,\n PatchProps,\n VerticesProps,\n DiffRectProps,\n TextProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n PictureProps,\n ImageSVGProps,\n ParagraphProps,\n AtlasProps,\n DrawingNodeProps,\n SkottieProps,\n} from \"../../dom/types\";\n\nexport enum CommandType {\n // Context\n Group,\n SavePaint,\n RestorePaint,\n SaveCTM,\n RestoreCTM,\n PushColorFilter,\n PushBlurMaskFilter,\n PushImageFilter,\n PushPathEffect,\n PushShader,\n ComposeColorFilter,\n ComposeImageFilter,\n ComposePathEffect,\n MaterializePaint,\n SaveBackdropFilter,\n SaveLayer,\n RestorePaintDeclaration,\n // Drawing\n DrawBox,\n DrawImage,\n DrawCircle,\n DrawPaint,\n DrawPoints,\n DrawPath,\n DrawRect,\n DrawRRect,\n DrawOval,\n DrawLine,\n DrawPatch,\n DrawVertices,\n DrawDiffRect,\n DrawText,\n DrawTextPath,\n DrawTextBlob,\n DrawGlyphs,\n DrawPicture,\n DrawImageSVG,\n DrawParagraph,\n DrawAtlas,\n DrawSkottie,\n}\n\nexport type Command<T extends CommandType = CommandType> = {\n type: T;\n [key: string]: unknown;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport const materializeCommand = (command: any) => {\n \"worklet\";\n const newProps = { ...command.props };\n if (command.animatedProps) {\n for (const key in command.animatedProps) {\n newProps[key] = command.animatedProps[key].value;\n }\n }\n return { ...command, props: newProps };\n};\n\nexport const isCommand = <T extends CommandType>(\n command: Command,\n type: T\n): command is Command<T> => {\n \"worklet\";\n return command.type === type;\n};\n\nexport interface GroupCommand extends Command<CommandType.Group> {\n props?: Pick<DrawingNodeProps, \"zIndex\">;\n children: Command[];\n}\n\nexport const isGroup = (command: Command): command is GroupCommand => {\n \"worklet\";\n return command.type === CommandType.Group;\n};\n\ninterface Props {\n [CommandType.DrawImage]: ImageProps;\n [CommandType.DrawCircle]: CircleProps;\n [CommandType.SaveCTM]: CTMProps;\n [CommandType.SavePaint]: DrawingNodeProps;\n [CommandType.PushBlurMaskFilter]: BlurMaskFilterProps;\n [CommandType.DrawPoints]: PointsProps;\n [CommandType.DrawPath]: PathProps;\n [CommandType.DrawRect]: RectProps;\n [CommandType.DrawRRect]: RoundedRectProps;\n [CommandType.DrawOval]: OvalProps;\n [CommandType.DrawLine]: LineProps;\n [CommandType.DrawPatch]: PatchProps;\n [CommandType.DrawVertices]: VerticesProps;\n [CommandType.DrawDiffRect]: DiffRectProps;\n [CommandType.DrawText]: TextProps;\n [CommandType.DrawTextPath]: TextPathProps;\n [CommandType.DrawTextBlob]: TextBlobProps;\n [CommandType.DrawGlyphs]: GlyphsProps;\n [CommandType.DrawPicture]: PictureProps;\n [CommandType.DrawImageSVG]: ImageSVGProps;\n [CommandType.DrawParagraph]: ParagraphProps;\n [CommandType.DrawAtlas]: AtlasProps;\n [CommandType.DrawSkottie]: SkottieProps;\n}\n\ninterface DrawCommand<T extends CommandType> extends Command<T> {\n props: T extends keyof Props ? Props[T] : never;\n}\n\nexport const isDrawCommand = <T extends keyof Props>(\n command: Command,\n type: T\n): command is DrawCommand<T> => {\n \"worklet\";\n return command.type === type;\n};\n"],"mappings":";;;;;;IA0BYA,WAAW,GAAAC,OAAA,CAAAD,WAAA,0BAAXA,WAAW;EACrB;EADUA,WAAW,CAAXA,WAAW;EA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OAAO,CAACG,aAAa,EAAE;MACvCF,QAAQ,CAACG,GAAG,CAAC,GAAGJ,OAAO,CAACG,aAAa,CAACC,GAAG,CAAC,CAACC,KAAK;IAClD;EACF;EACA,OAAO;IAAE,GAAGL,OAAO;IAAEE,KAAK,EAAED;EAAS,CAAC;AACxC,CAAC;AAACH,OAAA,CAAAC,kBAAA,GAAAA,kBAAA;AAEK,MAAMO,SAAS,GAAGA,CACvBN,OAAgB,EAChBO,IAAO,KACmB;EAC1B,SAAS;;EACT,OAAOP,OAAO,CAACO,IAAI,KAAKA,IAAI;AAC9B,CAAC;AAACT,OAAA,CAAAQ,SAAA,GAAAA,SAAA;AAOK,MAAME,OAAO,GAAIR,OAAgB,IAA8B;EACpE,SAAS;;EACT,OAAOA,OAAO,CAACO,IAAI,KAAKV,WAAW,CAACY,KAAK;AAC3C,CAAC;AAACX,OAAA,CAAAU,OAAA,GAAAA,OAAA;AAgCK,MAAME,aAAa,GAAGA,CAC3BV,OAAgB,EAChBO,IAAO,KACuB;EAC9B,SAAS;;EACT,OAAOP,OAAO,CAACO,IAAI,KAAKA,IAAI;AAC9B,CAAC;AAACT,OAAA,CAAAY,aAAA,GAAAA,aAAA","ignoreList":[]}
1
+ {"version":3,"names":["_utils","require","CommandType","exports","materializeCommand","command","newProps","props","animatedProps","key","entry","isSharedValueSelector","group","__sv","value","__key","undefined","isCommand","type","isGroup","Group","isDrawCommand"],"sources":["Core.ts"],"sourcesContent":["import type {\n BlurMaskFilterProps,\n CircleProps,\n CTMProps,\n ImageProps,\n PointsProps,\n PathProps,\n RectProps,\n RoundedRectProps,\n OvalProps,\n LineProps,\n PatchProps,\n VerticesProps,\n DiffRectProps,\n TextProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n PictureProps,\n ImageSVGProps,\n ParagraphProps,\n AtlasProps,\n DrawingNodeProps,\n SkottieProps,\n} from \"../../dom/types\";\nimport { isSharedValueSelector } from \"../utils\";\n\nexport enum CommandType {\n // Context\n Group,\n SavePaint,\n RestorePaint,\n SaveCTM,\n RestoreCTM,\n PushColorFilter,\n PushBlurMaskFilter,\n PushImageFilter,\n PushPathEffect,\n PushShader,\n ComposeColorFilter,\n ComposeImageFilter,\n ComposePathEffect,\n MaterializePaint,\n SaveBackdropFilter,\n SaveLayer,\n RestorePaintDeclaration,\n // Drawing\n DrawBox,\n DrawImage,\n DrawCircle,\n DrawPaint,\n DrawPoints,\n DrawPath,\n DrawRect,\n DrawRRect,\n DrawOval,\n DrawLine,\n DrawPatch,\n DrawVertices,\n DrawDiffRect,\n DrawText,\n DrawTextPath,\n DrawTextBlob,\n DrawGlyphs,\n DrawPicture,\n DrawImageSVG,\n DrawParagraph,\n DrawAtlas,\n DrawSkottie,\n}\n\nexport type Command<T extends CommandType = CommandType> = {\n type: T;\n [key: string]: unknown;\n};\n\n// eslint-disable-next-line @typescript-eslint/no-explicit-any\nexport const materializeCommand = (command: any) => {\n \"worklet\";\n const newProps = { ...command.props };\n if (command.animatedProps) {\n for (const key in command.animatedProps) {\n const entry = command.animatedProps[key];\n if (isSharedValueSelector(entry)) {\n const group = entry.__sv.value;\n newProps[key] =\n group && typeof group === \"object\"\n ? (group as Record<string, unknown>)[entry.__key]\n : undefined;\n } else {\n newProps[key] = entry.value;\n }\n }\n }\n return { ...command, props: newProps };\n};\n\nexport const isCommand = <T extends CommandType>(\n command: Command,\n type: T\n): command is Command<T> => {\n \"worklet\";\n return command.type === type;\n};\n\nexport interface GroupCommand extends Command<CommandType.Group> {\n props?: Pick<DrawingNodeProps, \"zIndex\">;\n children: Command[];\n}\n\nexport const isGroup = (command: Command): command is GroupCommand => {\n \"worklet\";\n return command.type === CommandType.Group;\n};\n\ninterface Props {\n [CommandType.DrawImage]: ImageProps;\n [CommandType.DrawCircle]: CircleProps;\n [CommandType.SaveCTM]: CTMProps;\n [CommandType.SavePaint]: DrawingNodeProps;\n [CommandType.PushBlurMaskFilter]: BlurMaskFilterProps;\n [CommandType.DrawPoints]: PointsProps;\n [CommandType.DrawPath]: PathProps;\n [CommandType.DrawRect]: RectProps;\n [CommandType.DrawRRect]: RoundedRectProps;\n [CommandType.DrawOval]: OvalProps;\n [CommandType.DrawLine]: LineProps;\n [CommandType.DrawPatch]: PatchProps;\n [CommandType.DrawVertices]: VerticesProps;\n [CommandType.DrawDiffRect]: DiffRectProps;\n [CommandType.DrawText]: TextProps;\n [CommandType.DrawTextPath]: TextPathProps;\n [CommandType.DrawTextBlob]: TextBlobProps;\n [CommandType.DrawGlyphs]: GlyphsProps;\n [CommandType.DrawPicture]: PictureProps;\n [CommandType.DrawImageSVG]: ImageSVGProps;\n [CommandType.DrawParagraph]: ParagraphProps;\n [CommandType.DrawAtlas]: AtlasProps;\n [CommandType.DrawSkottie]: SkottieProps;\n}\n\ninterface DrawCommand<T extends CommandType> extends Command<T> {\n props: T extends keyof Props ? Props[T] : never;\n}\n\nexport const isDrawCommand = <T extends keyof Props>(\n command: Command,\n type: T\n): command is DrawCommand<T> => {\n \"worklet\";\n return command.type === type;\n};\n"],"mappings":";;;;;;AAyBA,IAAAA,MAAA,GAAAC,OAAA;AAAiD,IAErCC,WAAW,GAAAC,OAAA,CAAAD,WAAA,0BAAXA,WAAW;EACrB;EADUA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAAXA,WAAW,CAAXA,WAAW;EAmBrB;EAnBUA,WAAW,CAAXA,WAAW;EAA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KAAK,EAAED;EAAS,CAAC;AACxC,CAAC;AAACH,OAAA,CAAAC,kBAAA,GAAAA,kBAAA;AAEK,MAAMa,SAAS,GAAGA,CACvBZ,OAAgB,EAChBa,IAAO,KACmB;EAC1B,SAAS;;EACT,OAAOb,OAAO,CAACa,IAAI,KAAKA,IAAI;AAC9B,CAAC;AAACf,OAAA,CAAAc,SAAA,GAAAA,SAAA;AAOK,MAAME,OAAO,GAAId,OAAgB,IAA8B;EACpE,SAAS;;EACT,OAAOA,OAAO,CAACa,IAAI,KAAKhB,WAAW,CAACkB,KAAK;AAC3C,CAAC;AAACjB,OAAA,CAAAgB,OAAA,GAAAA,OAAA;AAgCK,MAAME,aAAa,GAAGA,CAC3BhB,OAAgB,EAChBa,IAAO,KACuB;EAC9B,SAAS;;EACT,OAAOb,OAAO,CAACa,IAAI,KAAKA,IAAI;AAC9B,CAAC;AAACf,OAAA,CAAAkB,aAAA,GAAAA,aAAA","ignoreList":[]}
@@ -27,6 +27,14 @@ class ReanimatedRecorder {
27
27
  return;
28
28
  }
29
29
  Object.values(props).forEach(value => {
30
+ if ((0, _utils.isSharedValueSelector)(value) && !this.values.has(value.__sv)) {
31
+ const sv = value.__sv;
32
+ // eslint-disable-next-line @typescript-eslint/ban-ts-comment
33
+ // @ts-expect-error
34
+ sv.name = `variable${this.values.size}`;
35
+ this.values.add(sv);
36
+ return;
37
+ }
30
38
  if ((0, _utils.isSharedValue)(value) && !this.values.has(value)) {
31
39
  // eslint-disable-next-line @typescript-eslint/ban-ts-comment
32
40
  // @ts-expect-error
@@ -1 +1 @@
1
- {"version":3,"names":["_utils","require","_defineProperty","e","r","t","_toPropertyKey","Object","defineProperty","value","enumerable","configurable","writable","i","_toPrimitive","Symbol","toPrimitive","call","TypeError","String","Number","ReanimatedRecorder","constructor","Skia","Set","recorder","Recorder","reset","values","clear","processAnimationValues","props","forEach","isSharedValue","has","name","size","add","getRecorder","getSharedValues","Array","from","saveGroup","restoreGroup","savePaint","standalone","restorePaint","restorePaintDeclaration","materializePaint","pushPathEffect","pathEffectType","pushImageFilter","imageFilterType","pushColorFilter","colorFilterType","pushShader","shaderType","children","pushBlurMaskFilter","composePathEffect","composeColorFilter","composeImageFilter","saveCTM","restoreCTM","drawPaint","saveLayer","saveBackdropFilter","drawBox","boxProps","shadows","shadow","map","s","drawImage","drawCircle","drawPoints","drawPath","drawRect","drawRRect","drawOval","drawLine","drawPatch","drawVertices","drawDiffRect","drawText","drawTextPath","drawTextBlob","drawGlyphs","drawPicture","drawImageSVG","drawParagraph","drawAtlas","drawSkottie","exports"],"sources":["ReanimatedRecorder.ts"],"sourcesContent":["import type { SharedValue } from \"react-native-reanimated\";\n\nimport type { BaseRecorder, JsiRecorder, Skia } from \"../../skia/types\";\nimport type {\n PaintProps,\n NodeType,\n BlurMaskFilterProps,\n CTMProps,\n BoxProps,\n BoxShadowProps,\n ImageProps,\n CircleProps,\n PointsProps,\n PathProps,\n RectProps,\n RoundedRectProps,\n OvalProps,\n LineProps,\n PatchProps,\n VerticesProps,\n DiffRectProps,\n TextProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n PictureProps,\n ImageSVGProps,\n ParagraphProps,\n AtlasProps,\n SkottieProps,\n DrawingNodeProps,\n} from \"../../dom/types\";\nimport type { AnimatedProps } from \"../../renderer\";\nimport { isSharedValue } from \"../utils\";\n\n/**\n * Currently the recorder only work if the GPU resources (e.g Images) are owned by the main thread.\n * It will crash otherwise on Ganesh (iOS/Android).\n */\nexport class ReanimatedRecorder implements BaseRecorder {\n private values = new Set<SharedValue<unknown>>();\n private recorder: JsiRecorder;\n\n constructor(Skia: Skia) {\n this.recorder = Skia.Recorder();\n }\n\n reset() {\n this.values.clear();\n this.recorder.reset();\n }\n\n private processAnimationValues(props?: Record<string, unknown>) {\n if (!props) {\n return;\n }\n Object.values(props).forEach((value) => {\n if (isSharedValue(value) && !this.values.has(value)) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-expect-error\n value.name = `variable${this.values.size}`;\n this.values.add(value as SharedValue<unknown>);\n }\n });\n }\n\n getRecorder() {\n return this.recorder;\n }\n\n getSharedValues() {\n return Array.from(this.values);\n }\n\n saveGroup(props?: AnimatedProps<Pick<DrawingNodeProps, \"zIndex\">>): void {\n if (props) {\n this.processAnimationValues(props);\n this.recorder.saveGroup(props);\n } else {\n this.recorder.saveGroup();\n }\n }\n\n restoreGroup(): void {\n this.recorder.restoreGroup();\n }\n\n savePaint(props: AnimatedProps<PaintProps>, standalone: boolean): void {\n this.processAnimationValues(props);\n this.recorder.savePaint(props, standalone);\n }\n\n restorePaint(): void {\n this.recorder.restorePaint();\n }\n\n restorePaintDeclaration(): void {\n this.recorder.restorePaintDeclaration();\n }\n\n materializePaint(): void {\n this.recorder.materializePaint();\n }\n\n pushPathEffect(\n pathEffectType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushPathEffect(pathEffectType, props);\n }\n\n pushImageFilter(\n imageFilterType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushImageFilter(imageFilterType, props);\n }\n\n pushColorFilter(\n colorFilterType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushColorFilter(colorFilterType, props);\n }\n\n pushShader(\n shaderType: NodeType,\n props: AnimatedProps<unknown>,\n children: number\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushShader(shaderType, props, children);\n }\n\n pushBlurMaskFilter(props: AnimatedProps<BlurMaskFilterProps>): void {\n this.processAnimationValues(props);\n this.recorder.pushBlurMaskFilter(props);\n }\n\n composePathEffect(): void {\n this.recorder.composePathEffect();\n }\n\n composeColorFilter(): void {\n this.recorder.composeColorFilter();\n }\n\n composeImageFilter(): void {\n this.recorder.composeImageFilter();\n }\n\n saveCTM(props: AnimatedProps<CTMProps>): void {\n this.processAnimationValues(props);\n this.recorder.saveCTM(props);\n }\n\n restoreCTM(): void {\n this.recorder.restoreCTM();\n }\n\n drawPaint(): void {\n this.recorder.drawPaint();\n }\n\n saveLayer(): void {\n this.recorder.saveLayer();\n }\n\n saveBackdropFilter(): void {\n this.recorder.saveBackdropFilter();\n }\n\n drawBox(\n boxProps: AnimatedProps<BoxProps>,\n shadows: {\n props: BoxShadowProps;\n }[]\n ): void {\n this.processAnimationValues(boxProps);\n shadows.forEach((shadow) => {\n this.processAnimationValues(\n shadow.props as AnimatedProps<BoxShadowProps>\n );\n });\n this.recorder.drawBox(\n boxProps,\n // TODO: Fix this type BaseRecorder.drawBox()\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-expect-error\n shadows.map((s) => s.props)\n );\n }\n\n drawImage(props: AnimatedProps<ImageProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawImage(props);\n }\n\n drawCircle(props: AnimatedProps<CircleProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawCircle(props);\n }\n\n drawPoints(props: AnimatedProps<PointsProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPoints(props);\n }\n\n drawPath(props: AnimatedProps<PathProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPath(props);\n }\n\n drawRect(props: AnimatedProps<RectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawRect(props);\n }\n\n drawRRect(props: AnimatedProps<RoundedRectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawRRect(props);\n }\n\n drawOval(props: AnimatedProps<OvalProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawOval(props);\n }\n\n drawLine(props: AnimatedProps<LineProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawLine(props);\n }\n\n drawPatch(props: AnimatedProps<PatchProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPatch(props);\n }\n\n drawVertices(props: AnimatedProps<VerticesProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawVertices(props);\n }\n\n drawDiffRect(props: AnimatedProps<DiffRectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawDiffRect(props);\n }\n\n drawText(props: AnimatedProps<TextProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawText(props);\n }\n\n drawTextPath(props: AnimatedProps<TextPathProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawTextPath(props);\n }\n\n drawTextBlob(props: AnimatedProps<TextBlobProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawTextBlob(props);\n }\n\n drawGlyphs(props: AnimatedProps<GlyphsProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawGlyphs(props);\n }\n\n drawPicture(props: AnimatedProps<PictureProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPicture(props);\n }\n\n drawImageSVG(props: AnimatedProps<ImageSVGProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawImageSVG(props);\n }\n\n drawParagraph(props: AnimatedProps<ParagraphProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawParagraph(props);\n }\n\n drawAtlas(props: AnimatedProps<AtlasProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawAtlas(props);\n }\n\n drawSkottie(props: AnimatedProps<SkottieProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawSkottie(props);\n }\n}\n"],"mappings":";;;;;;AAiCA,IAAAA,MAAA,GAAAC,OAAA;AAAyC,SAAAC,gBAAAC,CAAA,EAAAC,CAAA,EAAAC,CAAA,YAAAD,CAAA,GAAAE,cAAA,CAAAF,CAAA,MAAAD,CAAA,GAAAI,MAAA,CAAAC,cAAA,CAAAL,CAAA,EAAAC,CAAA,IAAAK,KAAA,EAAAJ,CAAA,EAAAK,UAAA,MAAAC,YAAA,MAAAC,QAAA,UAAAT,CAAA,CAAAC,CAAA,IAAAC,CAAA,EAAAF,CAAA;AAAA,SAAAG,eAAAD,CAAA,QAAAQ,CAAA,GAAAC,YAAA,CAAAT,CAAA,uCAAAQ,CAAA,GAAAA,CAAA,GAAAA,CAAA;AAAA,SAAAC,aAAAT,CAAA,EAAAD,CAAA,2BAAAC,CAAA,KAAAA,CAAA,SAAAA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C;EAEAyD,WAAWA,CAACzD,KAAkC,EAAQ;IACpD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAAC+D,WAAW,CAACzD,KAAK,CAAC;EAClC;EAEA0D,YAAYA,CAAC1D,KAAmC,EAAQ;IACtD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACgE,YAAY,CAAC1D,KAAK,CAAC;EACnC;EAEA2D,aAAaA,CAAC3D,KAAoC,EAAQ;IACxD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACiE,aAAa,CAAC3D,KAAK,CAAC;EACpC;EAEA4D,SAASA,CAAC5D,KAAgC,EAAQ;IAChD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACkE,SAAS,CAAC5D,KAAK,CAAC;EAChC;EAEA6D,WAAWA,CAAC7D,KAAkC,EAAQ;IACpD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACmE,WAAW,CAAC7D,KAAK,CAAC;EAClC;AACF;AAAC8D,OAAA,CAAAxE,kBAAA,GAAAA,kBAAA","ignoreList":[]}
1
+ {"version":3,"names":["_utils","require","_defineProperty","e","r","t","_toPropertyKey","Object","defineProperty","value","enumerable","configurable","writable","i","_toPrimitive","Symbol","toPrimitive","call","TypeError","String","Number","ReanimatedRecorder","constructor","Skia","Set","recorder","Recorder","reset","values","clear","processAnimationValues","props","forEach","isSharedValueSelector","has","__sv","sv","name","size","add","isSharedValue","getRecorder","getSharedValues","Array","from","saveGroup","restoreGroup","savePaint","standalone","restorePaint","restorePaintDeclaration","materializePaint","pushPathEffect","pathEffectType","pushImageFilter","imageFilterType","pushColorFilter","colorFilterType","pushShader","shaderType","children","pushBlurMaskFilter","composePathEffect","composeColorFilter","composeImageFilter","saveCTM","restoreCTM","drawPaint","saveLayer","saveBackdropFilter","drawBox","boxProps","shadows","shadow","map","s","drawImage","drawCircle","drawPoints","drawPath","drawRect","drawRRect","drawOval","drawLine","drawPatch","drawVertices","drawDiffRect","drawText","drawTextPath","drawTextBlob","drawGlyphs","drawPicture","drawImageSVG","drawParagraph","drawAtlas","drawSkottie","exports"],"sources":["ReanimatedRecorder.ts"],"sourcesContent":["import type { SharedValue } from \"react-native-reanimated\";\n\nimport type { BaseRecorder, JsiRecorder, Skia } from \"../../skia/types\";\nimport type {\n PaintProps,\n NodeType,\n BlurMaskFilterProps,\n CTMProps,\n BoxProps,\n BoxShadowProps,\n ImageProps,\n CircleProps,\n PointsProps,\n PathProps,\n RectProps,\n RoundedRectProps,\n OvalProps,\n LineProps,\n PatchProps,\n VerticesProps,\n DiffRectProps,\n TextProps,\n TextPathProps,\n TextBlobProps,\n GlyphsProps,\n PictureProps,\n ImageSVGProps,\n ParagraphProps,\n AtlasProps,\n SkottieProps,\n DrawingNodeProps,\n} from \"../../dom/types\";\nimport type { AnimatedProps } from \"../../renderer\";\nimport { isSharedValue, isSharedValueSelector } from \"../utils\";\n\n/**\n * Currently the recorder only work if the GPU resources (e.g Images) are owned by the main thread.\n * It will crash otherwise on Ganesh (iOS/Android).\n */\nexport class ReanimatedRecorder implements BaseRecorder {\n private values = new Set<SharedValue<unknown>>();\n private recorder: JsiRecorder;\n\n constructor(Skia: Skia) {\n this.recorder = Skia.Recorder();\n }\n\n reset() {\n this.values.clear();\n this.recorder.reset();\n }\n\n private processAnimationValues(props?: Record<string, unknown>) {\n if (!props) {\n return;\n }\n Object.values(props).forEach((value) => {\n if (isSharedValueSelector(value) && !this.values.has(value.__sv)) {\n const sv = value.__sv;\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-expect-error\n sv.name = `variable${this.values.size}`;\n this.values.add(sv as SharedValue<unknown>);\n return;\n }\n\n if (isSharedValue(value) && !this.values.has(value)) {\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-expect-error\n value.name = `variable${this.values.size}`;\n this.values.add(value as SharedValue<unknown>);\n }\n });\n }\n\n getRecorder() {\n return this.recorder;\n }\n\n getSharedValues() {\n return Array.from(this.values);\n }\n\n saveGroup(props?: AnimatedProps<Pick<DrawingNodeProps, \"zIndex\">>): void {\n if (props) {\n this.processAnimationValues(props);\n this.recorder.saveGroup(props);\n } else {\n this.recorder.saveGroup();\n }\n }\n\n restoreGroup(): void {\n this.recorder.restoreGroup();\n }\n\n savePaint(props: AnimatedProps<PaintProps>, standalone: boolean): void {\n this.processAnimationValues(props);\n this.recorder.savePaint(props, standalone);\n }\n\n restorePaint(): void {\n this.recorder.restorePaint();\n }\n\n restorePaintDeclaration(): void {\n this.recorder.restorePaintDeclaration();\n }\n\n materializePaint(): void {\n this.recorder.materializePaint();\n }\n\n pushPathEffect(\n pathEffectType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushPathEffect(pathEffectType, props);\n }\n\n pushImageFilter(\n imageFilterType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushImageFilter(imageFilterType, props);\n }\n\n pushColorFilter(\n colorFilterType: NodeType,\n props: AnimatedProps<unknown>\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushColorFilter(colorFilterType, props);\n }\n\n pushShader(\n shaderType: NodeType,\n props: AnimatedProps<unknown>,\n children: number\n ): void {\n this.processAnimationValues(props);\n this.recorder.pushShader(shaderType, props, children);\n }\n\n pushBlurMaskFilter(props: AnimatedProps<BlurMaskFilterProps>): void {\n this.processAnimationValues(props);\n this.recorder.pushBlurMaskFilter(props);\n }\n\n composePathEffect(): void {\n this.recorder.composePathEffect();\n }\n\n composeColorFilter(): void {\n this.recorder.composeColorFilter();\n }\n\n composeImageFilter(): void {\n this.recorder.composeImageFilter();\n }\n\n saveCTM(props: AnimatedProps<CTMProps>): void {\n this.processAnimationValues(props);\n this.recorder.saveCTM(props);\n }\n\n restoreCTM(): void {\n this.recorder.restoreCTM();\n }\n\n drawPaint(): void {\n this.recorder.drawPaint();\n }\n\n saveLayer(): void {\n this.recorder.saveLayer();\n }\n\n saveBackdropFilter(): void {\n this.recorder.saveBackdropFilter();\n }\n\n drawBox(\n boxProps: AnimatedProps<BoxProps>,\n shadows: {\n props: BoxShadowProps;\n }[]\n ): void {\n this.processAnimationValues(boxProps);\n shadows.forEach((shadow) => {\n this.processAnimationValues(\n shadow.props as AnimatedProps<BoxShadowProps>\n );\n });\n this.recorder.drawBox(\n boxProps,\n // TODO: Fix this type BaseRecorder.drawBox()\n // eslint-disable-next-line @typescript-eslint/ban-ts-comment\n // @ts-expect-error\n shadows.map((s) => s.props)\n );\n }\n\n drawImage(props: AnimatedProps<ImageProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawImage(props);\n }\n\n drawCircle(props: AnimatedProps<CircleProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawCircle(props);\n }\n\n drawPoints(props: AnimatedProps<PointsProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPoints(props);\n }\n\n drawPath(props: AnimatedProps<PathProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPath(props);\n }\n\n drawRect(props: AnimatedProps<RectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawRect(props);\n }\n\n drawRRect(props: AnimatedProps<RoundedRectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawRRect(props);\n }\n\n drawOval(props: AnimatedProps<OvalProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawOval(props);\n }\n\n drawLine(props: AnimatedProps<LineProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawLine(props);\n }\n\n drawPatch(props: AnimatedProps<PatchProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPatch(props);\n }\n\n drawVertices(props: AnimatedProps<VerticesProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawVertices(props);\n }\n\n drawDiffRect(props: AnimatedProps<DiffRectProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawDiffRect(props);\n }\n\n drawText(props: AnimatedProps<TextProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawText(props);\n }\n\n drawTextPath(props: AnimatedProps<TextPathProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawTextPath(props);\n }\n\n drawTextBlob(props: AnimatedProps<TextBlobProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawTextBlob(props);\n }\n\n drawGlyphs(props: AnimatedProps<GlyphsProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawGlyphs(props);\n }\n\n drawPicture(props: AnimatedProps<PictureProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawPicture(props);\n }\n\n drawImageSVG(props: AnimatedProps<ImageSVGProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawImageSVG(props);\n }\n\n drawParagraph(props: AnimatedProps<ParagraphProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawParagraph(props);\n }\n\n drawAtlas(props: AnimatedProps<AtlasProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawAtlas(props);\n }\n\n drawSkottie(props: AnimatedProps<SkottieProps>): void {\n this.processAnimationValues(props);\n this.recorder.drawSkottie(props);\n }\n}\n"],"mappings":";;;;;;AAiCA,IAAAA,MAAA,GAAAC,OAAA;AAAgE,SAAAC,gBAAAC,CAAA,EAAAC,CAAA,EAAAC,CAAA,YAAAD,CAAA,GAAAE,cAAA,CAAAF,CAAA,MAAAD,CAAA,GAAAI,MAAA,CAAAC,cAAA,CAAAL,CAAA,EAAAC,CAAA,IAAAK,KAAA,EAAAJ,CAAA,EAAAK,UAAA,MAAAC,YAAA,MAAAC,QAAA,UAAAT,CAAA,CAAAC,CAAA,IAAAC,CAAA,EAAAF,CAAA;AAAA,SAAAG,eAAAD,CAAA,QAAAQ,CAAA,GAAAC,YAAA,CAAAT,CAAA,uCAAAQ,CAAA,GAAAA,CAAA,GAAAA,CAAA;AAAA,SAAAC,aAAAT,CAAA,EAAAD,CAAA,2BAAAC,CAAA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KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAAC+D,YAAY,CAACzD,KAAK,CAAC;EACnC;EAEA0D,YAAYA,CAAC1D,KAAmC,EAAQ;IACtD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACgE,YAAY,CAAC1D,KAAK,CAAC;EACnC;EAEA2D,UAAUA,CAAC3D,KAAiC,EAAQ;IAClD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACiE,UAAU,CAAC3D,KAAK,CAAC;EACjC;EAEA4D,WAAWA,CAAC5D,KAAkC,EAAQ;IACpD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACkE,WAAW,CAAC5D,KAAK,CAAC;EAClC;EAEA6D,YAAYA,CAAC7D,KAAmC,EAAQ;IACtD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACmE,YAAY,CAAC7D,KAAK,CAAC;EACnC;EAEA8D,aAAaA,CAAC9D,KAAoC,EAAQ;IACxD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACoE,aAAa,CAAC9D,KAAK,CAAC;EACpC;EAEA+D,SAASA,CAAC/D,KAAgC,EAAQ;IAChD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACqE,SAAS,CAAC/D,KAAK,CAAC;EAChC;EAEAgE,WAAWA,CAAChE,KAAkC,EAAQ;IACpD,IAAI,CAACD,sBAAsB,CAACC,KAAK,CAAC;IAClC,IAAI,CAACN,QAAQ,CAACsE,WAAW,CAAChE,KAAK,CAAC;EAClC;AACF;AAACiE,OAAA,CAAA3E,kBAAA,GAAAA,kBAAA","ignoreList":[]}
@@ -42,7 +42,7 @@ export declare class Recorder implements BaseRecorder {
42
42
  saveBackdropFilter(): void;
43
43
  drawBox(boxProps: AnimatedProps<BoxProps>, shadows: {
44
44
  props: BoxShadowProps;
45
- animatedProps?: Record<string, SharedValue<unknown>>;
45
+ animatedProps?: Record<string, unknown>;
46
46
  }[]): void;
47
47
  drawImage(props: AnimatedProps<ImageProps>): void;
48
48
  drawCircle(props: AnimatedProps<CircleProps>): void;
@@ -45,6 +45,10 @@ class Recorder {
45
45
  this.animationValues.add(prop);
46
46
  animatedProps[key] = prop;
47
47
  hasAnimatedProps = true;
48
+ } else if ((0, _utils.isSharedValueSelector)(prop)) {
49
+ this.animationValues.add(prop.__sv);
50
+ animatedProps[key] = prop;
51
+ hasAnimatedProps = true;
48
52
  }
49
53
  }
50
54
  return {