diff --git a/apps/docs/content/docs/integrations/react-native-skia.mdx b/apps/docs/content/docs/integrations/react-native-skia.mdx index 98bcfa110..6dbe5ba2f 100644 --- a/apps/docs/content/docs/integrations/react-native-skia.mdx +++ b/apps/docs/content/docs/integrations/react-native-skia.mdx @@ -18,7 +18,8 @@ Because the two packages share Dawn, react-native-skia v3 and react-native-webgp | react-native-webgpu | react-native-skia | | --- | --- | -| 0.13.1 and later | 3.4.0 and later, or 3.0.8 | +| 0.17.0 and later | 3.7.0 and later | +| 0.13.1 to 0.16.1 | 3.4.0 to 3.6.3, or 3.0.8 | | 0.13.0 | 3.1.0 to 3.3.0, or 3.0.8 | | 0.12.1 | 3.0.6 to 3.0.8, or 3.1.0 and later | | 0.10.0 to 0.11.2 | 3.0.0 to 3.0.5 | diff --git a/apps/example/package.json b/apps/example/package.json index ef04e0027..fa635a8f0 100644 --- a/apps/example/package.json +++ b/apps/example/package.json @@ -37,7 +37,7 @@ "react-native-nitro-modules": "0.35.7", "react-native-reanimated": "4.6.0", "react-native-safe-area-context": "^5.4.0", - "react-native-skia": "3.0.8", + "react-native-skia": "3.7.0", "react-native-vision-camera": "5.0.10", "react-native-vision-camera-worklets": "5.0.10", "react-native-web": "^0.21.2", diff --git a/packages/webgpu/cpp/rnwgpu/api/GPUFeatures.h b/packages/webgpu/cpp/rnwgpu/api/GPUFeatures.h index 5a8975040..d16808e4a 100644 --- a/packages/webgpu/cpp/rnwgpu/api/GPUFeatures.h +++ b/packages/webgpu/cpp/rnwgpu/api/GPUFeatures.h @@ -104,6 +104,7 @@ namespace rnwgpu { V(AdapterPropertiesWGPU, "adapter-properties-wgpu") \ V(SharedBufferMemoryFromWindowsHandle, \ "shared-buffer-memory-from-windows-handle") \ + V(SharedBufferMemoryHostPointer, "shared-buffer-memory-host-pointer") \ V(SharedTextureMemoryD3D12Resource, "shared-texture-memory-d3d12-resource") \ V(ChromiumExperimentalSamplingResourceTable, \ "chromium-experimental-sampling-resource-table") \ diff --git a/packages/webgpu/package.json b/packages/webgpu/package.json index bb856e47e..9d0e47cd3 100644 --- a/packages/webgpu/package.json +++ b/packages/webgpu/package.json @@ -24,7 +24,7 @@ "app.plugin.js", "plugin/build/**" ], - "dawn": "chrome-m154a", + "dawn": "chrome-m157", "androidMinSdkVersion": 26, "scripts": { "test": "NODE_OPTIONS='--experimental-require-module' jest -i", @@ -111,7 +111,7 @@ "yargs": "^17.7.2" }, "dependencies": { - "react-native-webgpu-dawn": "154.3.0" + "react-native-webgpu-dawn": "157.0.0" }, "peerDependencies": { "react": "*", diff --git a/packages/webgpu/scripts/check-dawn.ts b/packages/webgpu/scripts/check-dawn.ts index a8f35392e..f9b3c6f4f 100644 --- a/packages/webgpu/scripts/check-dawn.ts +++ b/packages/webgpu/scripts/check-dawn.ts @@ -28,7 +28,7 @@ if (!installedCommit) { const dawnWorkarounds = [ { marker: "DAWN_WORKAROUND_DEVICE_DESTROY_BEFORE_SURFACE_RELEASE", - commit: "3d786993a7ded64c4ebb4884b9b079db9ad0e580", + commit: "ada567700e13aecf7989d78b21f7d330b522ea80", files: ["cpp/rnwgpu/SurfaceRegistry.h", "cpp/rnwgpu/api/GPUDevice.cpp"], // Android: device.destroy() before the native view is dropped crashed in // SwapChain::DetachFromSurfaceImpl (Vulkan FencedDeleter of the dead @@ -41,7 +41,7 @@ const dawnWorkarounds = [ // The functions it declares are exported by the Dawn binaries; the header // has to match the Dawn the binaries were built from. marker: "DAWN_VENDORED_EXTERNAL_TEXTURE_PARAMS", - commit: "3d786993a7ded64c4ebb4884b9b079db9ad0e580", + commit: "ada567700e13aecf7989d78b21f7d330b522ea80", files: ["cpp/dawn/common/ExternalTextureParams.h"], upstream: "diff the copy against src/dawn/common/ExternalTextureParams.h at the new commit and re-sync it", diff --git a/yarn.lock b/yarn.lock index b5dcc136b..a793acae0 100644 --- a/yarn.lock +++ b/yarn.lock @@ -7926,7 +7926,7 @@ __metadata: react-native-nitro-modules: 0.35.7 react-native-reanimated: 4.6.0 react-native-safe-area-context: ^5.4.0 - react-native-skia: 3.0.8 + react-native-skia: 3.7.0 react-native-test-app: 5.4.13 react-native-vision-camera: 5.0.10 react-native-vision-camera-worklets: 5.0.10 @@ -9194,6 +9194,15 @@ __metadata: languageName: node linkType: hard +"canvaskit-wasm@npm:0.41.1": + version: 0.41.1 + resolution: "canvaskit-wasm@npm:0.41.1" + dependencies: + "@webgpu/types": 0.1.21 + checksum: d8d673497e41f07b843766234dd89d73d95d5da3bbc2befa1e67d399c4a54ff2196126391f110b985ac2cadce6928a0a2880b00843c06d61ba747a1b5b8b3b90 + languageName: node + linkType: hard + "ccount@npm:^2.0.0": version: 2.0.1 resolution: "ccount@npm:2.0.1" @@ -20750,6 +20759,13 @@ __metadata: languageName: node linkType: hard +"react-native-skia-graphite-android@npm:157.0.0": + version: 157.0.0 + resolution: "react-native-skia-graphite-android@npm:157.0.0" + checksum: 3c776d672fa4868344f03e2e4a9ae5099e68780ea2dc0cdf8bd1f000848df2609589efb95e681bd89d27d458020317fcb94c7a166b6fd2395d007f12243f8975 + languageName: node + linkType: hard + "react-native-skia-graphite-apple-ios@npm:154.1.0": version: 154.1.0 resolution: "react-native-skia-graphite-apple-ios@npm:154.1.0" @@ -20757,6 +20773,13 @@ __metadata: languageName: node linkType: hard +"react-native-skia-graphite-apple-ios@npm:157.0.0": + version: 157.0.0 + resolution: "react-native-skia-graphite-apple-ios@npm:157.0.0" + checksum: b80f2c85b6aedd49bbf77c87681806f17448b308bb61d11d76201ed5c69cb5ced0a1efd0d88034d06639aae17409a47870ce8270c08e1243df4f3a148a277524 + languageName: node + linkType: hard + "react-native-skia-graphite-apple-macos@npm:154.1.0": version: 154.1.0 resolution: "react-native-skia-graphite-apple-macos@npm:154.1.0" @@ -20764,6 +20787,20 @@ __metadata: languageName: node linkType: hard +"react-native-skia-graphite-apple-macos@npm:157.0.0": + version: 157.0.0 + resolution: "react-native-skia-graphite-apple-macos@npm:157.0.0" + checksum: 4604dad35c8fe33e729f7740a9494895d905847ca8db5d6d49fee7b366002626a1a2d6fb9885fd600f19db91d76b479a8a71ecc1b7f12968c7f03a3b06397746 + languageName: node + linkType: hard + +"react-native-skia-graphite-apple-tvos@npm:157.0.0": + version: 157.0.0 + resolution: "react-native-skia-graphite-apple-tvos@npm:157.0.0" + checksum: 2c98013f843d6c969039a176f5ab83067ba5cce1a3dd9a0207465fdae6626a0b4b868250e1dd8bdf20a6623018b03a3240453fac4794407d6b6165b91b59b9a6 + languageName: node + linkType: hard + "react-native-skia@npm:3.0.8": version: 3.0.8 resolution: "react-native-skia@npm:3.0.8" @@ -20791,6 +20828,35 @@ __metadata: languageName: node linkType: hard +"react-native-skia@npm:3.7.0": + version: 3.7.0 + resolution: "react-native-skia@npm:3.7.0" + dependencies: + canvaskit-wasm: 0.41.1 + react-native-skia-graphite-android: 157.0.0 + react-native-skia-graphite-apple-ios: 157.0.0 + react-native-skia-graphite-apple-macos: 157.0.0 + react-native-skia-graphite-apple-tvos: 157.0.0 + react-native-webgpu-dawn: 157.0.0 + react-reconciler: 0.31.0 + peerDependencies: + react: ">=19.0" + react-native: ">=0.79" + react-native-reanimated: ">=4.0.0" + react-native-worklets: ">=0.7.0" + peerDependenciesMeta: + react-native: + optional: true + react-native-reanimated: + optional: true + react-native-worklets: + optional: true + bin: + setup-skia-web: scripts/setup-canvaskit.js + checksum: b8743a0c8074a494c8f7e14fd236b1088da6798c0ea565d8910b2a10dcba91fa3bb9aa4aa6affad939f82d98f393cf40d510076400f004a0409000c221ceacbb + languageName: node + linkType: hard + "react-native-test-app@npm:5.4.13": version: 5.4.13 resolution: "react-native-test-app@npm:5.4.13" @@ -20871,10 +20937,10 @@ __metadata: languageName: node linkType: hard -"react-native-webgpu-dawn@npm:154.3.0": - version: 154.3.0 - resolution: "react-native-webgpu-dawn@npm:154.3.0" - checksum: 29a03a1c88e046413395e1cca965dbcce10146387e24540c59b00e25d069402667ecbf8bf971a66bc69e8d1ae369ca3c63fa0d0af903ff01ee1b16f2aa0dfb65 +"react-native-webgpu-dawn@npm:157.0.0": + version: 157.0.0 + resolution: "react-native-webgpu-dawn@npm:157.0.0" + checksum: 2fbebac05e083a4d0ecd258e459ddb6a41c1755f1720b9361a43af31c37d8e67aac60904f2731535b52e9fb19dfb0ced05d3011861635786a449e8a3835cbb20 languageName: node linkType: hard @@ -20939,7 +21005,7 @@ __metadata: react-native-builder-bob: ^0.23.2 react-native-reanimated: 4.6.0 react-native-web: ^0.21.2 - react-native-webgpu-dawn: 154.3.0 + react-native-webgpu-dawn: 157.0.0 react-native-worklets: 0.12.2 rimraf: ^5.0.7 seedrandom: ^3.0.5