Tuesday, December 13, 2011

Progress Report (12/7 - 12/13)

First off I apologize for not really posting at all on my blog in the past few weeks. Moving on.

This week: I have attempted to work with Java2D to make the arcs rather than through the use of multiple calls to moveby3d and changing the heading during the loop. After much thought of how to get the arcs drawn by Java2D to work how they are intended to work and a few tries, I have decided that it would be best to not use Java2D's arcs. This is because of two properties of Java2D arcs: 1. The way I would be using them would not be the way they were designed, This would mean hacking their properties to get them to work the way I want them to; 2. The ability to change the width along the way of the arc would not be possible by merely redrawing the arcs based off the way they are drawn. To explain further, an arc constructor takes 6 floats and an int for type. These floats are 4 for the box, an X and Y for one corner and a width and height of the box, as well as starting angle and angle extent. For 1, the way the Java2D arcs are designed the arguments define a box that is the space that contains the arc. The arc is contained within this space and is drawn around the center of the box, this is not what we are looking for since we have is a starting point; with the starting point not every being able to be entirely within the box, we have to move the box. This would seem hackish but theoretically not that difficult. For 2, the ability to change the width of the arc seems to me much more hard and hacked than reason 1, this is because I see no way to change the width of the arcs as they are draw other than to repeatably use them and that would be a complete waste because the whole reason was to use Java2D arcs instead of repeatably using dots/lines of move by. Unless I am informed otherwise I believe that Java2D's arcs would not be the best form to use this. In that respect I updated the code on my computer to use more calls of move by to be sharper. Sadly this is not a form of anti-aliasing that Professor Eglash asked for, it merely looks better than the previous form.

The first form, which while it looks good, some of the lines are choppy on the smaller arcs of the letters.


The second form does indeed look better. I personally didn't realize it at first because I was mainly
focusing on the larger red arcs.


The last thing I did was to update the heading to be counter clockwise and not clockwise. This change was made to work with standard of counter-clockwise angles in mathematics.

Next: I plan to discuss what the other think of the arcs, I feel silly taking so long to make progress on this, but I have been busy with other class work and I was quite honestly a bit stubborn on the idea that I should make this work. After finally clearing my mind of other classes for a bit I realized the difficulty of getting Java2D arcs to work as we want them to work in this program