|
|
@ -60,9 +60,9 @@ class TTSEngine:
|
|
|
|
self.call_tts("title", process_text(self.reddit_object["thread_title"]))
|
|
|
|
self.call_tts("title", process_text(self.reddit_object["thread_title"]))
|
|
|
|
processed_text = process_text(self.reddit_object["thread_post"])
|
|
|
|
processed_text = process_text(self.reddit_object["thread_post"])
|
|
|
|
if (
|
|
|
|
if (
|
|
|
|
processed_text != ""
|
|
|
|
processed_text != ""
|
|
|
|
and settings.config["settings"]["storymode"] == True
|
|
|
|
and settings.config["settings"]["storymode"] == True
|
|
|
|
):
|
|
|
|
):
|
|
|
|
self.call_tts("posttext", processed_text)
|
|
|
|
self.call_tts("posttext", processed_text)
|
|
|
|
|
|
|
|
|
|
|
|
idx = None
|
|
|
|
idx = None
|
|
|
@ -122,7 +122,7 @@ class TTSEngine:
|
|
|
|
def call_tts(self, filename: str, text: str):
|
|
|
|
def call_tts(self, filename: str, text: str):
|
|
|
|
self.tts_module.run(
|
|
|
|
self.tts_module.run(
|
|
|
|
text, filepath=f"{self.path}/{filename}.mp3"
|
|
|
|
text, filepath=f"{self.path}/{filename}.mp3"
|
|
|
|
)
|
|
|
|
)
|
|
|
|
# try:
|
|
|
|
# try:
|
|
|
|
# self.length += MP3(f"{self.path}/{filename}.mp3").info.length
|
|
|
|
# self.length += MP3(f"{self.path}/{filename}.mp3").info.length
|
|
|
|
# except (MutagenError, HeaderNotFoundError):
|
|
|
|
# except (MutagenError, HeaderNotFoundError):
|
|
|
|