Results 1 to 4 of 4
  1. #1
    dunnkers is offline Member
    Join Date
    Feb 2011
    Posts
    2
    Rep Power
    0

    Cool Need help with fillArc()

    I want to create some sort of progress circle like this:
    (I made these in paint, not in java)

    25%


    75%


    How would i do this with fillArc()?


    What i already have:
    I draw the background:
    Java Code:
    		g.drawOval(0, 0, 100, 100);
    I can fill half the oval:
    Java Code:
    		g.fillArc(0, 0, 100, 100, 0, -180);

    How fillArc works:
    fillArc(x, y, width, height, startAngle, angle);
    - 3 o'clock is 0
    - positive values go clockwise, negative values go counter clockwise


    Thanks, Dunnkers.

  2. #2
    KevinWorkman's Avatar
    KevinWorkman is offline Crazy Cat Lady
    Join Date
    Oct 2010
    Location
    Washington, DC
    Posts
    3,963
    Rep Power
    8

    Default

    How to Ask Questions the Smart Way
    Static Void Games - Play indie games, learn from game tutorials and source code, upload your own games!

  3. #3
    dunnkers is offline Member
    Join Date
    Feb 2011
    Posts
    2
    Rep Power
    0

    Default

    As stated above, i crossposted this thread.
    I refer you to: Need help with fillArc() - Java Programming Forums

    Sorry for the crosspost.

  4. #4
    Fubarable's Avatar
    Fubarable is offline Moderator
    Join Date
    Jun 2008
    Posts
    19,316
    Blog Entries
    1
    Rep Power
    26

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •