Skip to content

OneCore Voices: Support faster speech rates, greater pitch range, etc. #7498

@jcsteh

Description

@jcsteh

Compared with NVDA, Narrator is able to speak at faster rates with the OneCore Voices. It can also access a much wider pitch range. In addition, the rate set in Narrator is not affected by the rate set in Windows Settings, whereas NVDA is affected by this. This is because Narrator used an API which was previously private. That API has now been made public, so NVDA will be able to use it.

See the Options property on the SpeechSynthesizer class and the SpeechSynthesizerOptions class. Note that AudioPitch, AudioVolume and SpeakingRate (the properties we want) were only introduced in Windows 10 Insider 10.0.16257.0.

Unfortunately, we can't use these just yet for a few reasons:

  1. We need a newer version of the Windows 10 SDK, but versions after 10.0.15063 only work with Visual Studio 2017. We can't yet build with Visual Studio 2017. So, this is blocked by our move to VS 2017, which is in turn blocked by support in SCons.
  2. This is still a preview version of the SDK. Even once it's out of preview, it might be a while before it gets installed on AppVeyor.

Implementation notes:

  1. Because this will only be available in later builds of Windows 10, we'll need to test for support of this new API at runtime. I know UWP provides a way to do this, but I've never done it myself.
  2. Aside from testing for the API, we'll probably still need to keep the code around which adjusts rate, etc. with SSML to work with earlier Windows 10 builds. We might just be able to pass the default rate, volume, etc. to _OcSsmlConverter if the new API is supported instead of passing the cached user settings, but I'm not certain. Either way, this part of the code is going to get a bit ugly because we have to support these two cases.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions