How to Speed Up Performance of ISpVoice?2019 Community Moderator ElectionHow do you set, clear, and toggle a single bit?How do I iterate over the words of a string?How can I profile C++ code running on Linux?Hang problem in webControl and SAPI in C#C++11 introduced a standardized memory model. What does it mean? And how is it going to affect C++ programming?Why does changing 0.1f to 0 slow down performance by 10x?SendInput sends “num8” when I want to send “vk_up” ? How come?Replacing a 32-bit loop counter with 64-bit introduces crazy performance deviationsHow do I stop a delay-loaded DLL from throwing a “missing from your computer” system error?Does the C++ standard allow for an uninitialized bool to crash a program?

How do you justify more code being written by following clean code practices?

DisplayForm problem with pi in FractionBox

Justification failure in beamer enumerate list

CLI: Get information Ubuntu releases

Unfrosted light bulb

Nested Dynamic SOQL Query

Homology of the fiber

Have the tides ever turned twice on any open problem?

PTIJ: Which Dr. Seuss books should one obtain?

Do people actually use the word "kaputt" in conversation?

Do I need an EFI partition for each 18.04 ubuntu I have on my HD?

If I cast the Enlarge/Reduce spell on an arrow, what weapon could it count as?

PTIJ: At the Passover Seder, is one allowed to speak more than once during Maggid?

Determine voltage drop over 10G resistors with cheap multimeter

When should a starting writer get his own webpage?

How are passwords stolen from companies if they only store hashes?

Why is participating in the European Parliamentary elections used as a threat?

Fair way to split coins

Why didn’t Eve recognize the little cockroach as a living organism?

Isn't the word "experience" wrongly used in this context?

Weird lines in Microsoft Word

Print a physical multiplication table

What kind of footwear is suitable for walking in micro gravity environment?

Norwegian Refugee travel document



How to Speed Up Performance of ISpVoice?



2019 Community Moderator ElectionHow do you set, clear, and toggle a single bit?How do I iterate over the words of a string?How can I profile C++ code running on Linux?Hang problem in webControl and SAPI in C#C++11 introduced a standardized memory model. What does it mean? And how is it going to affect C++ programming?Why does changing 0.1f to 0 slow down performance by 10x?SendInput sends “num8” when I want to send “vk_up” ? How come?Replacing a 32-bit loop counter with 64-bit introduces crazy performance deviationsHow do I stop a delay-loaded DLL from throwing a “missing from your computer” system error?Does the C++ standard allow for an uninitialized bool to crash a program?










0















I am trying to build a game menu that reads the highlighted text using ISpVoice and keyboard.



My problem is that there is a delay whenever I change the highlighted text using the keyboard. This only happens when I use ISpVoice.



tts->Speak(myWstring.c_str(), SPF_PURGEBEFORESPEAK | SPF_ASYNC, 0);


I tried the above code but still there is a lag.



tts->Speak(myWstring.c_str(), SPF_ASYNC, 0);


the above code works but I want it to immediate stop whenever I want to change the highlighted text.










share|improve this question






















  • Have you tried calling ISpVoice::Pause() before speaking new text?

    – Remy Lebeau
    Mar 7 at 1:29












  • I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

    – Alzer Casiño
    Mar 7 at 3:08











  • So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

    – Remy Lebeau
    Mar 7 at 3:14











  • I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

    – Alzer Casiño
    Mar 7 at 3:22











  • I think it lags when the thread finishes.

    – Alzer Casiño
    Mar 7 at 3:28















0















I am trying to build a game menu that reads the highlighted text using ISpVoice and keyboard.



My problem is that there is a delay whenever I change the highlighted text using the keyboard. This only happens when I use ISpVoice.



tts->Speak(myWstring.c_str(), SPF_PURGEBEFORESPEAK | SPF_ASYNC, 0);


I tried the above code but still there is a lag.



tts->Speak(myWstring.c_str(), SPF_ASYNC, 0);


the above code works but I want it to immediate stop whenever I want to change the highlighted text.










share|improve this question






















  • Have you tried calling ISpVoice::Pause() before speaking new text?

    – Remy Lebeau
    Mar 7 at 1:29












  • I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

    – Alzer Casiño
    Mar 7 at 3:08











  • So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

    – Remy Lebeau
    Mar 7 at 3:14











  • I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

    – Alzer Casiño
    Mar 7 at 3:22











  • I think it lags when the thread finishes.

    – Alzer Casiño
    Mar 7 at 3:28













0












0








0








I am trying to build a game menu that reads the highlighted text using ISpVoice and keyboard.



My problem is that there is a delay whenever I change the highlighted text using the keyboard. This only happens when I use ISpVoice.



tts->Speak(myWstring.c_str(), SPF_PURGEBEFORESPEAK | SPF_ASYNC, 0);


I tried the above code but still there is a lag.



tts->Speak(myWstring.c_str(), SPF_ASYNC, 0);


the above code works but I want it to immediate stop whenever I want to change the highlighted text.










share|improve this question














I am trying to build a game menu that reads the highlighted text using ISpVoice and keyboard.



My problem is that there is a delay whenever I change the highlighted text using the keyboard. This only happens when I use ISpVoice.



tts->Speak(myWstring.c_str(), SPF_PURGEBEFORESPEAK | SPF_ASYNC, 0);


I tried the above code but still there is a lag.



tts->Speak(myWstring.c_str(), SPF_ASYNC, 0);


the above code works but I want it to immediate stop whenever I want to change the highlighted text.







c++ winapi sapi






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked Mar 6 at 23:08









Alzer CasiñoAlzer Casiño

13




13












  • Have you tried calling ISpVoice::Pause() before speaking new text?

    – Remy Lebeau
    Mar 7 at 1:29












  • I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

    – Alzer Casiño
    Mar 7 at 3:08











  • So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

    – Remy Lebeau
    Mar 7 at 3:14











  • I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

    – Alzer Casiño
    Mar 7 at 3:22











  • I think it lags when the thread finishes.

    – Alzer Casiño
    Mar 7 at 3:28

















  • Have you tried calling ISpVoice::Pause() before speaking new text?

    – Remy Lebeau
    Mar 7 at 1:29












  • I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

    – Alzer Casiño
    Mar 7 at 3:08











  • So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

    – Remy Lebeau
    Mar 7 at 3:14











  • I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

    – Alzer Casiño
    Mar 7 at 3:22











  • I think it lags when the thread finishes.

    – Alzer Casiño
    Mar 7 at 3:28
















Have you tried calling ISpVoice::Pause() before speaking new text?

– Remy Lebeau
Mar 7 at 1:29






Have you tried calling ISpVoice::Pause() before speaking new text?

– Remy Lebeau
Mar 7 at 1:29














I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

– Alzer Casiño
Mar 7 at 3:08





I tried calling the functions but it resumes only when ISpVoice::Resume() is called. It goes silent if ISpVoice::Pause() is only called.

– Alzer Casiño
Mar 7 at 3:08













So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

– Remy Lebeau
Mar 7 at 3:14





So, Pause()'ing the current voice, Speak()'ing the new text with purge, and then Resume()'ing doesn't work?

– Remy Lebeau
Mar 7 at 3:14













I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

– Alzer Casiño
Mar 7 at 3:22





I tried it. Performance is better but it still lags when the tts almost finishes the sentence.

– Alzer Casiño
Mar 7 at 3:22













I think it lags when the thread finishes.

– Alzer Casiño
Mar 7 at 3:28





I think it lags when the thread finishes.

– Alzer Casiño
Mar 7 at 3:28












0






active

oldest

votes











Your Answer






StackExchange.ifUsing("editor", function ()
StackExchange.using("externalEditor", function ()
StackExchange.using("snippets", function ()
StackExchange.snippets.init();
);
);
, "code-snippets");

StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "1"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: true,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: 10,
bindNavPrevention: true,
postfix: "",
imageUploader:
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
,
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













draft saved

draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55033630%2fhow-to-speed-up-performance-of-ispvoice%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes















draft saved

draft discarded
















































Thanks for contributing an answer to Stack Overflow!


  • Please be sure to answer the question. Provide details and share your research!

But avoid


  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.

To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fstackoverflow.com%2fquestions%2f55033630%2fhow-to-speed-up-performance-of-ispvoice%23new-answer', 'question_page');

);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

1928 у кіно

Захаров Федір Захарович

Ель Греко