コード例 #1
0
        protected override Task When()
        {
            _request = new AWSSpeechRequest
            {
                OutputFormat = OutputFormat.Mp3,
                Content      = new string[] { _fiveHundredCharacters },
                VoiceId      = VoiceId.Aditi
            };

            return(Task.CompletedTask);
        }
コード例 #2
0
        protected override Task When()
        {
            var sb = new StringBuilder();

            for (int i = 0; i < 350; i++)
            {
                sb.Append(_fiveHundredCharacters);
            }

            var textChunks = sb.ToString().ChunkWithDelimeters(100000, '.', '!', '?', ')', '"', '}', ']');

            _request = new AWSSpeechRequest
            {
                OutputFormat = OutputFormat.Mp3,
                Content      = textChunks,
                VoiceId      = VoiceId.Aditi
            };

            return(Task.CompletedTask);
        }