Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: Spectrogram #9

Open
eye-wave opened this issue Jul 8, 2024 · 4 comments
Open

Feature request: Spectrogram #9

eye-wave opened this issue Jul 8, 2024 · 4 comments
Labels
blocked Requires more work on something else first enhancement New feature or request

Comments

@eye-wave
Copy link

eye-wave commented Jul 8, 2024

I don't know what else to say. Spectrogram would be a really cool addition for this app

izotope: understanding spectrograms

@eye-wave
Copy link
Author

eye-wave commented Jul 8, 2024

i already tried making it myself, but afaik ratatui graphs do not allow for solid blocks that would look the best for this usecase.

@joshka
Copy link

joshka commented Jul 23, 2024

It's maybe not quite fully what you're looking for, but I added ChartType::Bar to the Chart widget just recently in ratatui/ratatui#1205. This should be out in Ratatui 0.27.1 (and is likely in an alpha release already).

I don't think it would get close to that image though :D

@alemidev
Copy link
Owner

alemidev commented Aug 2, 2024

hi! sorry for my late replies

Spectrogram would be a really cool addition for this app

it definitely would @eye-wave ! right now i have a spectogram implemented (you can reach it cycling views with TAB), but it is only an instant view: there is no color shading for history. to support such a view i need to first rework a bit how we receive audio data: right now scope-tui completely relies on your audio backend and thus receives only an "instant" of what is being played, keeping instead an internal buffer would allow to display history (and also to have higher refresh rates! by showing "half" of the new "window" and a smoother visualization)

i plan to do this eventually ™️ but it's not a very small change, some work will be required :)

It's maybe not quite fully what you're looking for, but I added ChartType::Bar to the Chart widget just recently in ratatui-org/ratatui#1205

thanks! this looks great and it definitely helps a ton, but to achieve a usable spectrogram with history we probably need to be able to shade bar blocks individually. i think it's possible as both cava and btop do it, i'm not sure if ratatui already supports it from 0.27.1, i may look into adding such feature into ratatui first! once again thanks @joshka for maintaining this awesome library!! c:

@alemidev alemidev added enhancement New feature or request blocked Requires more work on something else first labels Aug 2, 2024
@eye-wave
Copy link
Author

eye-wave commented Aug 2, 2024

oh speaking of usable spectrogram history, that would be also nice for other stuff. for example using smaller buffer with a oscilloscope to achieve the resolution of huge buffers that normally would drop the framerate to 1 or 2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
blocked Requires more work on something else first enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants