[comp.sys.amiga] A 3D Graphics shared lib ...

bmacintyre@watcgl.waterloo.edu (Blair MacIntyre) (05/10/89)

Ok, heres a question of style ...

I'm almost finished my 3d graphics library.  I'm in the process of
making it into a load library.  

I had been using doubles for the Coordinates throughout ( it's a 
typedef, no big deal to change it ) because I wanted to compile
it using the 881 inline code and double precision, or the IEEE
double precision lib.  BUT, now I'm looking at the library interface
(having to use 2 regs per coordinate) and it got me thinking.

Right now, I'm using FFP, so I really only need to use floats, thus
single regs for the parms.  If I wanted to recompile the lib using
inline floating point calls, it could just use single precision on
the 881 ... would that be enough precission?  I don't think so.  Right
now I end up being off by a bit here and there on the screen!

So, the big question is:  Should I leave it at double and use FFP
or IEEE? IEEE software emulation is slower than the FFP, but it
allows for the transparant use of the 881, which appeals to me.

If you were going to use the lib to do 3d stuff, which would you want?

( Note: right now the library provides lines, points and filled/unfilled
  polygons ... no shading because that would defeat the Ami's hardware
  filling ... no surface stuff because I haven't gotten around to it
  yet.  
  The routine names are modeled after the IRIS library calls ... because
  that's what I was using when I wrote it! )

Anyway, gotta run.  Any comments would be most helpful.  I've still
got to write a half decent non-hacked demo for it, so it'll be weeks
yet before it gets to Bob Page ...

Blair
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-///-=
= Blair MacIntyre, bmacintyre@watcgl.{waterloo.edu, UWaterloo.ca}     \\\///  =
=   now appearing at the Computer Graphics Lab, U of Waterloo!         \XX/   =
= "Don't be mean ... remember, no matter where you go, there you are." BBanzai=

bmacintyre@watcgl.waterloo.edu (Blair MacIntyre) (05/11/89)

(hows this for a good way to start a discussion ... talk to yourself on
 the net!! )

In article <9630@watcgl.waterloo.edu> I wrote:
> [ discussion of which kind of floating point to use ]

Based on some mail I got, I'm considering this as the solution:

Three versions of the interface and lib:

-(1 and 2) uses doubles and is compiled either for the IEEE lib or for inline
 floating point.  The two versions are compatible, and could be substitued
 for each other, depending on the machine.

-(3) uses floats and FFP

How does this sound?
-- 
=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-///-=
= Blair MacIntyre, bmacintyre@watcgl.{waterloo.edu, UWaterloo.ca}     \\\///  =
=   now appearing at the Computer Graphics Lab, U of Waterloo!         \XX/   =
= "Don't be mean ... remember, no matter where you go, there you are." BBanzai=

kevin@uts.amdahl.com (Kevin Clague) (05/11/89)

In article <9641@watcgl.waterloo.edu> bmacintyre@watcgl.waterloo.edu (Blair MacIntyre) writes:
>(hows this for a good way to start a discussion ... talk to yourself on
> the net!! )
>
>In article <9630@watcgl.waterloo.edu> I wrote:
>> [ discussion of which kind of floating point to use ]
>
>Based on some mail I got, I'm considering this as the solution:
>
>Three versions of the interface and lib:
>
>-(1 and 2) uses doubles and is compiled either for the IEEE lib or for inline
> floating point.  The two versions are compatible, and could be substitued
> for each other, depending on the machine.
>
>-(3) uses floats and FFP
>
>How does this sound?

It sounds like a great solution.  Everyone gets what they want.

>-- 
>=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-///-=
>= Blair MacIntyre, bmacintyre@watcgl.{waterloo.edu, UWaterloo.ca}     \\\///  =
>=   now appearing at the Computer Graphics Lab, U of Waterloo!         \XX/   =
>= "Don't be mean ... remember, no matter where you go, there you are." BBanzai=


-- 
UUCP:  kevin@uts.amdahl.com
  or:  {sun,decwrl,hplabs,pyramid,seismo,oliveb}!amdahl!kevin
DDD:   408-737-5481
USPS:  Amdahl Corp.  M/S 249,  1250 E. Arques Av,  Sunnyvale, CA 94086

[  Any thoughts or opinions which may or may not have been expressed  ]
[  herein are my own.  They are not necessarily those of my employer. ]