Skip to content

Commit

Permalink
Remove playback functionality entrypoint
Browse files Browse the repository at this point in the history
  • Loading branch information
ozaner committed Oct 19, 2024
1 parent 68dfccf commit 1e7e303
Showing 1 changed file with 0 additions and 23 deletions.
23 changes: 0 additions & 23 deletions src/index.es6
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
import {PlayBuffer, RenderBuffer} from './util/player.es6'
import {TextToPhonemes} from './reciter/reciter.es6';
import {TextToPhonemesCMU} from './reciter/cmu-reciter.es6';
import {SamProcess, SamBuffer} from './sam/sam.es6';
Expand Down Expand Up @@ -70,28 +69,6 @@ function SamJs (options) {
*/
this.buf32 = (text, phonetic) => buf32(ensurePhonetic(text, phonetic), opts);

/**
* Render the passed text as wave buffer and play it over the speakers.
*
* @param {string} text The text to render or phoneme string.
* @param {boolean} [phonetic] Flag if the input text is already phonetic data.
*
* @return {Promise}
*/
this.speak = (text, phonetic) => PlayBuffer(this.buf32(text, phonetic));

/**
* Render the passed text as wave buffer and download it via URL API.
*
* @param {string} text The text to render or phoneme string.
* @param {boolean} [phonetic] Flag if the input text is already phonetic data.
*
* @return void
*/
this.download = (text, phonetic) => {
RenderBuffer(this.buf8(text, phonetic));
}

/**
* Render the passed text as wave buffer array.
*
Expand Down

0 comments on commit 1e7e303

Please sign in to comment.