←back to thread

225 points attogram | 3 comments | | HN request time: 0.656s | source

A github project to collect a bunch of bash-based screensavers/visualizations.
Show context
throwaway2037 ◴[] No.45733242[source]
How can anyone have a bad day when great projects like this pop up on the front page of HN?

Did you see the library of viz? https://github.com/attogram/bash-screensavers/blob/main/libr...

My favourite API: lov_die_with_honor()

replies(2): >>45739596 #>>45741285 #
1. axiolite ◴[] No.45739596[source]
With "matrix" causing bash to consume 46% of my CPU time, I think I'll pass. I think I can play the actual film in 4K with less CPU time than that.
replies(1): >>45742670 #
2. o11c ◴[] No.45742670[source]
Hm, does caching the result of each unique `tput` fix that?
replies(1): >>45753782 #
3. axiolite ◴[] No.45753782[source]
I don't see any `tput`s inside the Main loop. Only at startup and exit. Comment at the top of my version (HEAD as of yesterday) says:

  # This version is optimized for speed by:
  # 1. Using direct ANSI escape codes instead of forking `tput` for every update.