Coder Social home page Coder Social logo

Comments (7)

sw5813 avatar sw5813 commented on May 29, 2024

Check out the Microsoft docs for instructions: https://docs.microsoft.com/en-us/windows/mixed-reality/develop/unreal/unreal-voice-input

from microsoft-openxr-unreal.

Pecka95 avatar Pecka95 commented on May 29, 2024

Check out the Microsoft docs for instructions: https://docs.microsoft.com/en-us/windows/mixed-reality/develop/unreal/unreal-voice-input

Yeah, I saw this docs and it's not what i'm asking for. I want to get a recognized phrase from plugin not by speech mapping. I'm trying to send phrase in string form

from microsoft-openxr-unreal.

sw5813 avatar sw5813 commented on May 29, 2024

Gotcha! While dictation isn't supported by the Microsoft OpenXR plugin out of the box, dictation is supported via the SpeechRecognizer WinRT API. We use the same WinRT API to get keywords in the Microsoft OpenXR plugin, so one option would be for you to copy/paste our code and make some small changes to use dictation instead of keywords, then surface that dictated text to your game.

Here is the Microsoft OpenXR plugin code that calls the WinRT speech recognizer with a Keywords constraint in order to recognize keywords: https://github.com/microsoft/Microsoft-OpenXR-Unreal/blob/main/MsftOpenXRGame/Plugins/MicrosoftOpenXR/Source/MicrosoftOpenXR/Private/SpeechPlugin.cpp#L203

The ResultGenerated just has the keyword: https://github.com/microsoft/Microsoft-OpenXR-Unreal/blob/main/MsftOpenXRGame/Plugins/MicrosoftOpenXR/Source/MicrosoftOpenXR/Private/SpeechPlugin.cpp#L248

Here is an example of code that uses that same SpeechRecognizer with a dictation constraint:
https://github.com/microsoft/Windows-universal-samples/blob/master/Samples/SpeechRecognitionAndSynthesis/cpp/Scenario_ContinuousDictation.xaml.cpp#L101

Then the ResultGenerated callback will have the dictated text instead of the keyword: https://github.com/microsoft/Windows-universal-samples/blob/master/Samples/SpeechRecognitionAndSynthesis/cpp/Scenario_ContinuousDictation.xaml.cpp#L353

from microsoft-openxr-unreal.

Pecka95 avatar Pecka95 commented on May 29, 2024

Thank you!! It looks like exactly what i'm looking for! I'll try this. And thank you for a such detailed guide!

from microsoft-openxr-unreal.

sw5813 avatar sw5813 commented on May 29, 2024

You're welcome, glad to be able to help!

from microsoft-openxr-unreal.

FabianEP11 avatar FabianEP11 commented on May 29, 2024

Hi, I am trying to do the same as @Pecka95 described: I need a functionality as the dictation mode (not speech mapping), but I'm not sure how to include it on my app.
I was following the files you provided and I was able to test the speechRecognitionAndSyntesis app on the Hololens device and it is exactly what I need; however, I'm having hard time figuring out how to include it on an app created directly on Unreal.
Could you please guide me with this? or does it work just for UWP apps?

from microsoft-openxr-unreal.

frank-Regal avatar frank-Regal commented on May 29, 2024

@Pecka95, have you been able to successful implement the above approach? We are looking for a similar implementation

from microsoft-openxr-unreal.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.