Friday, October 27, 2017

Decision Time!

We're about halfway through the semester, so it's time to decide whether to keep going on the current project or start a new one. Since I got over the main hump, I think I will continue with this project. The main hump being the circle algorithm. Now, I can make the spinning animation and the text display and enter numbers. Also, I think even though this project is mainly meant to be done at school I will work on it at home.

Github commit a26a580.

Thursday, October 12, 2017

Updated circle algorithm, as well as fixing an error

I found an issue: the equation I had for a circle was already using a center, but I was regardless pushing all points down and to the right.
Also, I put the algorithm part into a scope so the dirty-feeling letter variables were destructed to prevent further issues. Also, I added comments in case anybody decides they'd like to contribute. I also started work on interpolating points that aren't integers. That means that when the points are (pi, pi) I can't graph them. However, there's a method that I'm looking into. I may also be able to use a floating point, or have the number be within 5% or so.


Commit bc734d7 on github

Monday, October 2, 2017

Starting circle drawing

As it turns out, drawing a circle with SDL2 in C++ is harder than you'd think. Unless you'd done it before, but hey, I haven't. I'm looking into something called the Midpoint Circle Algorithm, but at the moment the code only blits integer x and y values. I also temporarily got confused and included <cmath>, but then realised I didn't need it. (cmath is a C++ wrapped C library for math-y functions like log, ln, square rooting, etc.)

I also had some issues where I didn't clear the texture after I made it, and there were some really weird undefined things showing up in the background.

Git commit: 5dca5f