Skip to content

Sapi4: Only send prosody commands when there is prosody in the sequence#15583

Merged
seanbudd merged 1 commit into
nvaccess:masterfrom
LeonarddeR:sapi4Fix
Oct 5, 2023
Merged

Sapi4: Only send prosody commands when there is prosody in the sequence#15583
seanbudd merged 1 commit into
nvaccess:masterfrom
LeonarddeR:sapi4Fix

Conversation

@LeonarddeR

Copy link
Copy Markdown
Collaborator

Link to issue number:

Fixes #15580
Follow up of #15502

Summary of the issue:

In #15502, I fixed some regressions regarding capital pitch changes introduced in #15271. This meant that we'd add prosody commands to every speech sequence to support a specific version of IBM TTS that seemed to need that. However, it introduced a regression in that it was no longer possible to change speech parameters using the gui.

Description of user facing changes

It is again possible to change SAPI4 parameters using the GUI.

Description of development approach

Only add blank prosody commands when there is any prosody in the sequence. IF not, don't do anything.

Additional context

A prosody command in SAPI4 (like pitch) behaves as the pitch would really be changed with PitchSet. In other words, when you'd fetch the pitch from the synth driver during a long sequence that contains a PitchCommand, the driver would return the Pitch as reflected by the PitchCommand. This meant that, when we'd set the pitch using the GUI, the pitch would also be affected by the PitchCommand added to the speech sequence. This caused conflicts. Thus, we should only add prosody commands when necessary.

Testing strategy:

Tested str from #15580 and #15500

Known issues with pull request:

None nkown

Code Review Checklist:

  • Documentation:
    • Change log entry
    • User Documentation
    • Developer / Technical Documentation
    • Context sensitive help for GUI changes
  • Testing:
    • Unit tests
    • System (end to end) tests
    • Manual testing
  • UX of all users considered:
    • Speech
    • Braille
    • Low Vision
    • Different web browsers
    • Localization in other languages / culture than English
  • API is compatible with existing add-ons.
  • Security precautions taken.

@LeonarddeR LeonarddeR requested a review from a team as a code owner October 4, 2023 19:08
@LeonarddeR LeonarddeR requested a review from seanbudd October 4, 2023 19:08

@seanbudd seanbudd left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @LeonarddeR

@seanbudd seanbudd merged commit 37e5eb8 into nvaccess:master Oct 5, 2023
@nvaccessAuto nvaccessAuto added this to the 2024.1 milestone Oct 5, 2023
@LeonarddeR LeonarddeR deleted the sapi4Fix branch August 23, 2025 06:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

SAPI 4: impossible to adjust any speech parameters

3 participants