adrianlyjak / obsidian-aloud-tts

MIT License
26 stars 1 forks source link

[FR] - The ability to be able to permanently mark a piece of text (by wrapping in a callout or similar) #27

Open spiritualgeek opened 7 months ago

spiritualgeek commented 7 months ago

Hi,

I am uncertain if this is an unusual request. However, I would greatly appreciate the functionality to permanently mark a portion of text, which would subsequently generate a small audio icon alongside it, enabling playback.

Whether this could be done in a callout or as part of an embedded code snippet would be up to you (There may be better ways apart from what I illustrate below)

e.g.

> [!tts|1.2 voice]
> Text to play back

or

```tts
playbackspeed: 1.2
voice: xxx

Text to play back


Thanks
adrianlyjak commented 7 months ago

@spiritualgeek , I like the concept! I've seen other plugins use the code fences with the plugin identifier to good effect, toggling between some-sort of widget mode when not directly editing the section.

It's certainly a bigger undertaking, but it seems like it would fit well into the existing architecture.

Another thought might be to just read from a "context" while playing the audio. I could see that being useful for marking up dialog, and pressing play on that and having the player automatically switch voices.

```tts
voice: A
---
Hello! I am Alice
voice: B
---
Hi Alice, I'm Bob!


Unfortunately it gets a bit verbose in the dialog case with the code block
spiritualgeek commented 7 months ago

Precisly this. I'm waiting with bated breath 😄

adrianlyjak commented 1 month ago

@spiritualgeek I still like your ideas here, and am thinking about how to implement elegantly. I did release a different feature today where you can now easily create text to speech audio files and embed them in your document. You would need to update voices in settings, and then export each, (and then click each file separately to play the separate voice). Just letting you know in case it helps your use case

spiritualgeek commented 1 month ago

I appreciate the feedback. Thanks :)