Re: [Plib-users] compiling plib on irix 6.2
Brought to you by:
sjbaker
From: Ian v. d. N. <ian...@pr...> - 2000-10-27 09:26:53
|
Steve Baker wrote: > > Ian van der Neut wrote: > > > Wanting to write a game for my kids, I wanted to try out plib, however > > I'm running into problems compiling both plib 1.2.0 and 1.3.1 on my SGI > > Indy running IRIX 6.2 and gcc/g++ (Yeah, I know it's old, and the game > > won't really run on it, but I like developping on these boxes :). > > Well - you won't get much speed out of it with textured polygons - but > if you stick with plain or colour blended polygons, it should run passably > well. I know, the end result of the game will not run on the Indy, but on a modern PC with a riva tnt2. > > Er - GL_VERSION *always* has the value 0x1F02 in all versions of OpenGL > because it's just a token that you pass to glGetString(GL_VERSION) > when you are querying the version number at runtime. > > However, you obviously have OpenGL 1.0 because version 1.1 and 1.2 > define tokens like GL_VERSION_1_1 and GL_VERSION_1_2. There is no > GL_VERSION_1_0. Anyway, this is an Indy and I know SGI didn't ever > release an OpenGL 1.1 for machines that old. :-) I see. > OK - we have been bad boys and wrote PLIB 1.2.0 to *require* OpenGL 1.1 or later. > > There are some possible work-arounds: > > * We should probably put conditional compilation around the entire ssgVtxArray > class definition that make it be just an ssgVtxTable. Vertex arrays didn't > exist in OpenGL 1.0. However, since you may well be the last person on > the planet to still be running v1.0, my enthusiasm for a fix is minimal. Don't bother, I'll just login to my gf's 600 MHz PIII Linux box with all shiny hardware acceleration and software :) > * You could go back to PLIB 1.1.xx - it should compile just fine on your > Indy since it didn't support Vertex Arrays. You'll find all the old > versions on the PLIB web site. That's an option I guess depending on the amount of features I'd lose, but I don't know plib well enough yet to know. > * You *might* get lucky and find that your machine had vertex arrays > implemented as OpenGL extensions. Look for the missing functions > and tokens in /usr/include/GL/gl.h - they may be there with an 'EXT' > or 'SGI' tacked on the end...personally, I doubt you'll be that lucky, > but it's worth checking. hmmm... I might be lucky, there's a whole bunch of those in gl.h #define GL_VERTEX_ARRAY_EXT 0x8074 #define GL_NORMAL_ARRAY_EXT 0x8075 #define GL_COLOR_ARRAY_EXT 0x8076 #define GL_TEXTURE_COORD_ARRAY_EXT 0x8078 hmm... maybe not so lucky :/ 122(ian:)% grep glEnableClientState * gls.h:#define GLS_OP_glEnableClientState 286 122(ian:)% grep glVertexPointer * gl.h:extern void glVertexPointerEXT (GLint size, GLenum type, GLsizei stride, GLsizei count, const GLvoid *pointer); gls.h:#define GLS_OP_glVertexPointer 292 gls.h:#define GLS_OP_glVertexPointerEXT 65501 The other ones it's failing on, are there too, with the GLS_OP prefix, but no function prototype :( > > ssgVtxArray.cxx:77: `GL_COLOR_ARRAY' undeclared (first use this > > ssgVtxArray.cxx:78: `GL_NORMAL_ARRAY' undeclared (first use this > > ssgVtxArray.cxx:79: `GL_TEXTURE_COORD_ARRAY' undeclared (first use this > > ssgVtxArray.cxx:80: `GL_VERTEX_ARRAY' undeclared (first use this > > ssgVtxArray.cxx:80: warning: implicit declaration of function `int glEnableClientState(...)' > > ssgVtxArray.cxx:82: warning: implicit declaration of function `int glVertexPointer(...)' > > ssgVtxArray.cxx:89: warning: implicit declaration of function `int glDrawElements(...)' > > ssgVtxArray.cxx:91: warning: implicit declaration of function `int glPopClientAttrib(...)' > > All of these are the same thing basically. OpenGL 1.0 doesn't implement > vertex arrays and we need them. OK, I'll just use the Linux box then. > The software detected that you have an SGI machine - and tried to use the > *NEW* IRIX sound library from IRIX 6.5 (or so). Support for the new audio > library is relatively new to PLIB - which is why you didn't see a problem > with PLIB 1.2.0. > > IRIX 6.2 used the old sound library - which is what we had in PLIB 1.2.0 I've been thinking about upgrading to 6.5, guess I will sometime in the not too distant future. Anyway, doesn't matter if I'll just compile on the Linux peecee. > ...more of the same I'm afraid...these are all 'al' (Audio Library) functions. > > I guess you are stuck with either dumping the PLIB sound code altogether - or > sticking with the 'SL' from version 1.2.0 - which was the last version to support > the old IRIX sound library. > > > I have installed the latest libraries (CD image) that can be downloaded > > from the SGI site. From swmgr, I can see that all GL development files > > have been installed. > > Yep. That machine of yours is definitely showing it's age. SGI don't > actively support machines that old anymore - so you aren't going to find > stuff like OpenGL 1.1/1.2 and the new sound library being ported to it. > > Go get a *cheap* PC and install Linux. Linux is *so* close to IRIX, you'll > hardly notice the difference. I routinely switch between our big ONYX 2 > machines at work and various Linux boxes - and while I'm working I *frequently* > forget which machine I'm logged into - they are *that* similar. But they're a boring shade of grey, the Indy looks a lot sexier ;) I know Linux very well, I've three Linux boxes here. Most of them are as old as the Indy though :) I'm not very fond of PC's, and yes, I'm very well aware that they are faster, but I just love the SGI, and I can't afford an Octane :/ > Bear in mind that a $128 GeForce-2 card in a $600 700MHz PC is considerably > faster than a third of a million dollars worth of ONYX-2 Infinite Reality. > Heck even a 266MHz PC with a Voodoo-1 card would wipe the floor with that > Indy on both performance and image quality. Sad, but true > You'll probably also appreciate the way you can pick up 20Gb disk drives > for $90 too - those old 1Gb Indy drives were pretty restrictive. I've a 1 GB and a 3.2 GB in this baby, and one of the Linux boxes hosts my home dir through NFS, so I have no lack of diskspace. > I think it's time to wave goodbye to your old Indy buddy <sniff>. NEVER! :) > ...or pick up PLIB 1.1.xx if you *absolutely* must. > ...or hack together a hybrid PLIB if you *really* have a lot of > time on your hands! heh, with two kids running around? I don't think so :) > *OR* (radical thought here) install Mesa on your Indy. It'll run > in software-only, so it'll be *REALLY* slow - but it will run PLIB 1.2.0 > and give you OpenGL 1.2. nah, like I said, I'll just steal some CPU cycles and texture memory from the gf's machine, she'll let me if I'm nice to her :) Thanks for your help Steve, would appreciate it if you could tell me what those defines are in gl.h and gls.h that I pasted, although I'm afraid it's not going to make that much of a difference. Can't hurt to know what they are. Ian. -- There's never enough time | To know is to know that to do all the nothing you | you know nothing. That is want. | the meaning of true knowledge. -- Calvin | -- Confucius |