I want to add a new Chrome DevTools Protocol (CDP) command to the Emulation domain for mocking speech synthesis voices on my own chromium fork.
That command would be called Emulation.setSpeechSynthesisVoiceOverride() and it would take an array of voices, which are objects with the same shape as the
SpeechSynthesisVoice interface of the Web Speech API.
I read the chromium docs about
CDP dev and I think the right domain handler to patch is at
content/browser/devtools/protocol/emulation_handler.cc, is that right? Where I should incude the C++ function which implements setSpeechSynthesisVoiceOverride() and how I should declare the array of voices parameter?