www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/02/04/11:54:35

From: ams94 AT ecs DOT soton DOT ac DOT uk (Adrian Smith)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: ellipses at an angle
Date: 4 Feb 1997 14:53:43 GMT
Organization: Electronics and Computer Science, University of Southampton
Lines: 22
Message-ID: <5d7ihn$e1e@wapping.ecs.soton.ac.uk>
References: <5d098v$b00 AT nr1 DOT ottawa DOT istar DOT net>
NNTP-Posting-Host: servalan.ecs.soton.ac.uk
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

hotpulp AT netidea DOT com writes:

>I was wondering: how would I go about drawing an ellipse that has its
>major and minor axis at an angle? If you're having trouble visuallizing
>that: picture an ellipse leaning against a wall, what algorithm would I
>use to draw that?

>Shawn Betts

Hi, I think if you use Bresenham's algorithm, or the midpoint algorithm (which
are similar), you should be able to do it.  That can certainly draw straight
lines and circles.

Consult a graphics text book (e.g. Computer Graphics, Principles and Practice,
Foley and Van Damm).

Hope this is of some help,

Adrian Smith,
Undergraduate, Southampton University, England
ams94 AT ecs DOT soton DOT ac DOT uk

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019