Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: pmndrs/drei
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: v9.88.2
Choose a base ref
...
head repository: pmndrs/drei
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: v9.88.3
Choose a head ref
  • 2 commits
  • 4 files changed
  • 1 contributor

Commits on Oct 17, 2023

  1. 1
    Copy the full SHA
    e409c18 View commit details
  2. 1

    Verified

    This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
    Copy the full SHA
    de048b7 View commit details
Showing with 10 additions and 10 deletions.
  1. +1 −1 package.json
  2. +1 −1 src/core/FaceControls.tsx
  3. +4 −4 src/core/FaceLandmarker.tsx
  4. +4 −4 yarn.lock
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -74,7 +74,7 @@
"stats.js": "^0.17.0",
"suspend-react": "^0.1.3",
"three-mesh-bvh": "^0.6.7",
"three-stdlib": "^2.27.2",
"three-stdlib": "^2.27.3",
"troika-three-text": "^0.47.2",
"utility-types": "^3.10.0",
"uuid": "^9.0.1",
2 changes: 1 addition & 1 deletion src/core/FaceControls.tsx
Original file line number Diff line number Diff line change
@@ -15,7 +15,7 @@ import {
useContext,
} from 'react'
import { useFrame, useThree } from '@react-three/fiber'
import { FaceLandmarkerResult } from '@mediapipe/tasks-vision'
import type { FaceLandmarkerResult } from '@mediapipe/tasks-vision'
import { easing } from 'maath'
import { suspend, clear } from 'suspend-react'

8 changes: 4 additions & 4 deletions src/core/FaceLandmarker.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* eslint react-hooks/exhaustive-deps: 1 */
import * as React from 'react'
import { createContext, ReactNode, useContext, useEffect } from 'react'
import { FilesetResolver, FaceLandmarker as FaceLandmarkerImpl, FaceLandmarkerOptions } from '@mediapipe/tasks-vision'
import type { FaceLandmarker as FaceLandmarkerImpl, FaceLandmarkerOptions } from '@mediapipe/tasks-vision'
import { clear, suspend } from 'suspend-react'

const FaceLandmarkerContext = /* @__PURE__ */ createContext({} as FaceLandmarkerImpl | undefined)
@@ -34,9 +34,9 @@ export function FaceLandmarker({
const opts = JSON.stringify(options)

const faceLandmarker = suspend(async () => {
return await FilesetResolver.forVisionTasks(basePath).then((vision) =>
FaceLandmarkerImpl.createFromOptions(vision, options)
)
const { FilesetResolver, FaceLandmarker } = await import('@mediapipe/tasks-vision')
const vision = await FilesetResolver.forVisionTasks(basePath)
return FaceLandmarker.createFromOptions(vision, options)
}, [basePath, opts])

useEffect(() => {
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
@@ -13042,10 +13042,10 @@ three-mesh-bvh@^0.6.7:
resolved "https://registry.yarnpkg.com/three-mesh-bvh/-/three-mesh-bvh-0.6.7.tgz#6491876f5bf0c0d67be81a4402f2abdbb2266d76"
integrity sha512-RYdjMsH+vZvjLwA+ehI4+ZqTaTehAz4iho2yfL5PdGsIHyxpB78g0iy4Emj8079m/9KBX02TzddkvPSKSruQjg==

three-stdlib@^2.27.2:
version "2.27.2"
resolved "https://registry.yarnpkg.com/three-stdlib/-/three-stdlib-2.27.2.tgz#d9fb6e8341ad93aa12b71bec2b3480528d6e42bf"
integrity sha512-yjHaY4QHRqMi1yGIt5RzWtRFbcCj2YHoCaAY4pldphI5CMf9PoCc9N2UFuVbHqgITQRKnVoCo+OCMU2rIZTXjg==
three-stdlib@^2.27.3:
version "2.27.3"
resolved "https://registry.yarnpkg.com/three-stdlib/-/three-stdlib-2.27.3.tgz#28964e121ecf50d4fcd19203d090f79c8afa9001"
integrity sha512-HA3LDEGnrbahOMGMk4HTfCClr/oKQnwvnvNR2gOMytvHg7nk8SIiABl/qgol2xDVp/Lf7MEbeq5ZjzjajuZxpw==
dependencies:
"@types/draco3d" "^1.4.0"
"@types/offscreencanvas" "^2019.6.4"