Tuesday, February 16, 2016

Digital Clock Redesign: (2) Getting Back Into Inkscape





Progress is underway in turning my pencil-and-paper sketches into vector files I can use with Processing. Currently, these are the three vectors I have completed. They are not locked into being the colors they are now; I chose the colors randomly for demonstration purposes only.

The current goal is to have all ten vector files prepped and ready for Thursday's class. My next update will showcase all ten completed files.

Paige Ruka

3 comments:

  1. This is looking GREAT! I am so excited about your cat clock.

    A question: What is your plan for parsing out the individual digits for hours and minutes? (i.e. 11:30 --> 1-1:3-0) This will be important, unless you plan on making 12 different images for hours and 60 for minutes...

    ReplyDelete
    Replies
    1. Great question! Yeah, having 60 different images for minutes might be a *little* bit crazy. Luckily, I've got a solution in mind! For the second minute digit (i.e. the "5" in 25) I plan to use a for-loop to subtract 10 from the number of minutes until it's a digit between 0 and 9. The code would look a little something like this:

      int minDigit = 0;
      for (int i=minute(); i>=0; i-=10){
      minDigit = i;
      }
      println(minDigit);

      Then I could use some sort of switch-statement to translate that into whatever cat corresponds with the leftover digit. I haven't worked out all the details, but the way I see it, there shouldn't be any problems!

      As for the first minute digit (i.e. the "2" in 25), I could use a series of if-statements; if minute() equals a number between 00 and 09, set the first digit to 0, if minute() equals a number between 10 and 19, set the first digit to 1, etc. Any issues I have with the hours would be worked out the same way I plan to work out the minutes.

      Glad you're excited to see the completed project! I'm excited to create it!

      Paige Ruka

      Delete
  2. This sounds like an excellent plan. Can't wait to see it!

    ReplyDelete