Giter Site home page Giter Site logo

Smoothing bug about cava HOT 7 CLOSED

karlstav avatar karlstav commented on July 17, 2024
Smoothing bug

from cava.

Comments (7)

livibetter avatar livibetter commented on July 17, 2024

Off-topic: I swear I didn't laugh out loud when I clicked on the GIF #cavatwitcheffect

from cava.

karlstav avatar karlstav commented on July 17, 2024

no laughing matter, or is it...

I was able to reproduce the problem. It seems that when you pause MPD it stops sending data to the fifo. So instead of getting all zeroes as one would get from alsa, it just waits on 'fread' and whatever was in the shared buffer when paused remains there. I'm trying to write m way around it by using a non-blocking file descriptor, but it's a mess. I think using select() and a timeout is the solution. I'll have to look more into it later.

from cava.

karlstav avatar karlstav commented on July 17, 2024

I was able to fix it by using a non-blocking read(), turns out it wasn't a mess at all. Closing issue.

from cava.

anko avatar anko commented on July 17, 2024

@karlstav Friendly tip: You can also close issues through a commit message, which creates a link to the related commit for future reference.

from cava.

karlstav avatar karlstav commented on July 17, 2024

@anko cool, I'm still learning

from cava.

livibetter avatar livibetter commented on July 17, 2024

Were 99cb8f4 and f0b9d40 having some hiccups? Or result of some changes in astyle configuration?

Either way, this would make harder to spot what exactly changed for this issue.

If I git diff 4f08afd f0b9d40 that looks more normal. When this kind of things happen and you can try to use git commit --amend if you haven't pushed, even you do, I would say it's still save to do a --force push if you correct in a few minutes.

Frankly, if that's really the configuration, I would suggest to ditch astyle, I really don't believe using that would help for languages like C, our eyes, hands, and brain are the best tool.

git diff and check every line before commit.

from cava.

karlstav avatar karlstav commented on July 17, 2024

Ok so here is what happened:

After fixing the issue i decided to style it again with astyle. Then I realized my horrible mistake, I had styled it according to an older setting (with whitespaces as indent). So i restyled it and committed again :/ .

So thanks to @livibetter I have no learned three thing:

  1. --amend lets you "regret" mistakes you made
  2. ALWAYS run git diff before you commit
  3. astyle is a "lazy man's tool" and it's much better to have control of your code "by hand".

from cava.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.