From: Shawn Hargreaves Newsgroups: comp.os.msdos.djgpp Subject: Re: The Allegro get_camera_matrix_f 'aspect' variable Date: Sun, 15 Jun 1997 17:37:43 +0100 Organization: None Distribution: world Message-ID: <5kBN9DAXpBpzEwJR@talula.demon.co.uk> References: <33a192dd DOT 3930277 AT news DOT btinternet DOT com> NNTP-Posting-Host: talula.demon.co.uk MIME-Version: 1.0 Lines: 16 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk Thomas Harte writes: > Basically, I guess my question is - am I supposed to presume square >pixels, or 4:3 ratio pixels when I calculate this value? Or can someone just >give me a simple formula which does what I want? I tried one in 320x200 mode, >and this definitely wasn't right, but then it doesn't appear correct within the >ex25 demo when it is set to 1 with the 4:3 ratio window (ie 320x240). I Allegro adjusts for the 4:3 proportions of a standard monitor display, so given a square pixel mode like 320x240, 640x480, 600x600, etc, you can just pass an aspect of 1. For other modes, assuming you are drawing onto the entire area of the screen, use (SCREEN_W*3)/(SCREEN_H*4). -- Shawn Hargreaves - shawn AT talula DOT demon DOT co DOT uk - http://www.talula.demon.co.uk/ Beauty is a French phonetic corruption of a short cloth neck ornament.