ly-ms-edge-tts
Advanced tools
Comparing version 1.0.3 to 1.0.4
@@ -28,5 +28,5 @@ /// <reference types="node" /> | ||
private _startTime; | ||
private pitch; | ||
private rate; | ||
private volume; | ||
private _pitch; | ||
private _rate; | ||
private _volume; | ||
private readonly _agent; | ||
@@ -33,0 +33,0 @@ private _log; |
@@ -29,5 +29,5 @@ "use strict"; | ||
this._startTime = 0; | ||
this.pitch = 0; | ||
this.rate = 0; | ||
this.volume = 0; | ||
this._pitch = 0; | ||
this._rate = 0; | ||
this._volume = 0; | ||
this._enableLogger = enableLogger; | ||
@@ -121,3 +121,3 @@ this._agent = agent; | ||
<voice name="${this._voice}"> | ||
<prosody pitch='+${this.pitch}Hz' rate ='+${this.rate}%' volume='+${this.volume}%'> | ||
<prosody pitch='+${this._pitch}Hz' rate ='+${this._rate}%' volume='+${this._volume}%'> | ||
${input} | ||
@@ -156,7 +156,10 @@ </prosody> | ||
const oldOutputFormat = this._outputFormat; | ||
const oldPitch = this._pitch; | ||
const oldRate = this._rate; | ||
const oldVolume = this._volume; | ||
this._voice = voiceName; | ||
this._voiceLocale = voiceLocale; | ||
this.pitch = pitch; | ||
this.rate = rate; | ||
this.volume = volume; | ||
this._pitch = pitch; | ||
this._rate = rate; | ||
this._volume = volume; | ||
if (!this._voiceLocale) { | ||
@@ -171,3 +174,6 @@ const voiceLangMatch = MsEdgeTTS.VOICE_LANG_REGEX.exec(this._voice); | ||
|| oldVoiceLocale !== this._voiceLocale | ||
|| oldOutputFormat !== this._outputFormat; | ||
|| oldOutputFormat !== this._outputFormat | ||
|| oldPitch != pitch | ||
|| oldRate != rate | ||
|| oldVolume != volume; | ||
// create new client | ||
@@ -174,0 +180,0 @@ if (changed || this._ws.readyState !== this._ws.OPEN) { |
{ | ||
"name": "ly-ms-edge-tts", | ||
"version": "1.0.3", | ||
"version": "1.0.4", | ||
"description": "An Azure Speech Service module that uses the Microsoft Edge Read Aloud API.", | ||
@@ -12,3 +12,3 @@ "author": "孤泉冷月 <guquanlengyue@gmail.com>", | ||
"scripts": { | ||
"start": "yarn run build && node src/test/index.js", | ||
"start": "yarn run build && node test/index.js", | ||
"build": "tsc", | ||
@@ -15,0 +15,0 @@ "prepublishOnly": "yarn run build", |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
34828
443