Outdated Documentation & Deprecated API - Face Expressions
I'm going through the documentation and this page about Face Expressions shows some code lines that give "deprecated API" warnings in Lens Studio. There's also one dead link "RenderMeshVisual"
https://developers.snap.com/lens-studio/features/ar-tracking/face/face-expressions
This API page indeed says that "getExpressionWeightByName" is deprecated, but it doesn't say what we should use instead.
https://developers.snap.com/lens-studio/api/lens-scripting/classes/Built-In.FaceRenderObjectProvider.html
However this one says nothing about it being deprecated:
https://developers.snap.com/lens-studio/api/lens-scripting/classes/Built-In.Expressions.html
It's a bit hard to know what to use.
We have fixed these issues that you are citing! Thanks so much for the feedback!
-
Caio Alves
commented
Hey guys,
I came back to this and noticed that the guide is still referencing the deprecated API getExpressionWeightByName('MouthClose')
This page also mentions the deprecated API
https://developers.snap.com/lens-studio/api/lens-scripting/classes/Built-In.Expressions.htmlIt turns out the Face Expressions Template available in the asset library is also using deprecated APIs.
I get the following messages:
[onUpdate@Face Expressions.lspkg/Scripts/ExpressionsController.js:479] Warning on 'getExpressionNames': This API is deprecated. Deprecated APIs will stop functioning in an upcoming Lens Studio version.[onUpdate@Face Expressions.lspkg/Scripts/ExpressionsController.js:480] Warning on 'getExpressionWeights': This API is deprecated. Deprecated APIs will stop functioning in an upcoming Lens Studio version.
This API page is displaying the correct info now!
https://developers.snap.com/lens-studio/api/lens-scripting/classes/Built-In.FaceRenderObjectProvider.html -
Hello Caio, thank you for your feedback. We are certainly looking into it and report back as soon as we can. We appreciate you using this channel to give us this critical feedback.