Re: coordinate system confusion

New Message Reply Date view Thread view Subject view Author view

Scott McMillan (scott++at++ht.com)
Thu, 10 Apr 1997 13:15:25 -0400 (EDT)


Chris Volpe (volpe++at++ash.crd.ge.com) wrote:
> Hi Performers-
>
> The man page for pfLightSource gives the following piece of sample
> code:
>
> /* Time of day is high noon */
> sun->setPos(0.0f, 1.0f, 0.0f, 0.0f);
>
> Since the up direction is +Z (according to the Programmer's Guide page
> 95), shouldn't this code be as follows:
>
> /* Time of day is high noon */
> sun->setPos(0.0f, 0.0f, 1.0f, 0.0f);
>
> Is this a documentation error or am I misinterpreting something?

If this is NOT a documentation error, I am guessing this is because of
another one of those confusing discrepancies between Performer's and OpenGL's
coordinate systems (Y is up in OpenGL). I have had to struggle with this
before. Here's the line of reasoning....

pfLightSource borrows a lot from pfLight (says so in the man page)
pfLight man pages refer to Iris GL lmdef or OpenGL glLight.
OpenGL uses a Y up coordinate system.

It had me confused for quite a while until a coworker pointed all this out.

Good luck,
scott

-- 
  Scott McMillan  |       HT Medical, Inc.      | Developing virtual environ-
   scott++at++ht.com   |      http://www.ht.com      | ment medical and surgical
 Ph: 301-984-3706 | 6001 Montrose Rd., Ste. 902 | simulations and surgery
Fax: 301-984-2104 |     Rockville, MD 20852     | simulation creation tools.

======================================================================= List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/ Submissions: info-performer++at++sgi.com Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:55:02 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.