4 ms·
> I could have built this 25 years ago with a single GIF with about 6 frames, that was a couple of kilobytes and would be performant on the (relative) potato co
by deathanatos 1y ago
> I could have built this 25 years ago with a single GIF with about 6 frames, that was a couple of kilobytes and would be performant on the (relative) potato computers we had then. […] But modern "web designers" feel the need to spend how long carefully crafting that CSS animation which adds dozens of lines of code to the codebase and burns a ton of CPU...why? Just because you can, I assume?
The animation (which is not suppose to be constant/static) conveys whether audio is being picked up by the application. I.e., it's VU meter.
- efilife 1y agoHey, grammar police here. The animation is supposeD, like in "watcheD" not "watche". Its meter, not "it's". Its means possession, it's is a contraction that means "it is"
- xp84 1y agoI can't use the app in question, but I haven't seen any proof it doesn't just "dance when receiving audio". If it tracks amplitude and pitch, I'd still say it's overengineered, since in practice no one can discern anything useful except 2 or maybe 3 states (silent, quiet, not quiet).
- deathanatos 1y agoTrue, the article didn't say that it for sure isn't being used as a glorified GIF, but … why not just give the benefit of the doubt that it UI element is doing the thing the UI element ought to do? Then, "Here's how that turned into a performance problem" followed by the rest of the article. > I'd still say it's overengineered, since in practice no one can discern anything useful except 2 or maybe 3 states (silent, quiet, not quiet). For most use cases … that's all that's necessary? It helps confirm that the audio equipment and various software layers are working. … like I use these UI elements all the time, because Bluetooth has decided that "nah, I'm not going to connect, even though every device reports as connected".
- xp84 1y agoWe agree that 2-3 states is all we need to discern -- I was just saying that if it's actually wasting even more CPU by truly analysing both the amplitude and frequencies in the audio, I'd chastise whoever decided to do that for wasting time when "sound" "quiet sound" and "loud sound" serves 100% of the use cases for this widget. And the above is a separate question unrelated to implementation. A true VU meter in CSS animation is the most overengineered, a glorified GIF built as a CSS animation is somewhat overengineered, and a couple of simple GIFs is the simplest.