heronarts / LX

Core library for 3D LED lighting engines
https://chromatik.co/
Other
41 stars 25 forks source link

Refactoring performed on the code #59

Closed janvipatel1412 closed 2 years ago

janvipatel1412 commented 2 years ago

I went over the project and refactored a few items to make the code more readable. The changes to the code are:

  1. Rename Variable: In the class StrobeEffect.java, I refactored a variable that was declared as amt to amount to make it more meaningful.

  2. Extract Method: In the class FourierTransform.java, I refactored a method named computing. I extracted a block of code from the method as it was feasible to put a logic that was different from another method.

  3. Move Variable: In the class SparkleEffect.java, a variable amount was more used in SparklePattern.java rather than the SparkleEffect.java class. So, it was moved to another class.

  4. Pull up variable: A variable was not declared in the class LXAudioComponent.java, but its two subclasses LXAudioInput.java and LXAudioOuput.java had it declared. So, I removed the variables from both the subclasses and pulled them up to the superclass.

  5. Extract Class: In the class LXCommand.java, there were other subclasses that performed different operations. So, I moved them to another class which I made.

CLAassistant commented 2 years ago

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


jnp seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.
You have signed the CLA already but the status is still pending? Let us recheck it.