Results 1 to 4 of 4

Thread: quick circle plotting help needed ...

  1. #1
    Guest

    quick circle plotting help needed ...

    Hi All,

    I need an openGL routine that plots a circle or circles and later on at different locations using Salford FTN95 fortran compiler. The data available would be x and y coordinates of the centre and the radius. I really would like to see if this would work satisfactorily for me as a first step before I get the books out on openGL and spend ages.

    This may appear completely trivial to some of you but I would appreciate a piece of fortran code that plots these circles in a kind of animated fashion.

    Thanks in advance,

    Ozi

  2. #2
    Senior Member OpenGL Pro
    Join Date
    May 2001
    Location
    Kristianstad,Skåne,Sweden
    Posts
    1,595

    Re: quick circle plotting help needed ...

    If I remember correct (correct me oltherwise).

    xpos = x + radius * cos( angle)
    ypos = y + radius * sin( angle)

    Where angle is in radians, the problem here is to calculate the number of segments to use to get a nice looking circle, not sure if there is a good algorithm for that.

    Mikael


    [This message has been edited by mikael_aronsson (edited 12-24-2002).]

  3. #3
    Member Contributor
    Join Date
    Oct 2002
    Location
    bangalore
    Posts
    56

    Re: quick circle plotting help needed ...

    i hope u've got the hint.
    Mikael is pretty much corret.
    thanks & regards
    Prashant G.P

  4. #4
    Junior Member Newbie
    Join Date
    Dec 2002
    Location
    Greece
    Posts
    9

    Re: quick circle plotting help needed ...

    If u want an accurate circle ,search the WEB for the Bresenham algorithm.

Similar Threads

  1. Replies: 4
    Last Post: 05-31-2016, 05:21 PM
  2. Connect midpoint circle dots for circle outline
    By TalysShade in forum OpenGL: Basic Coding
    Replies: 4
    Last Post: 10-05-2012, 03:42 PM
  3. 3d plotting
    By gezpu in forum OpenGL: General
    Replies: 1
    Last Post: 10-04-2010, 12:05 PM
  4. Circle - Circle Collision
    By johnnyp05 in forum OpenGL: General
    Replies: 2
    Last Post: 08-03-2005, 11:02 AM
  5. Draw Circle, MidPoint Circle Algorithm
    By Trivialnight in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 09-25-2004, 03:14 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean