Thread: [Plib-users] Using only PUI without GLUT
Brought to you by:
sjbaker
|
From: Andrew S. <x_b...@ho...> - 2002-04-24 12:37:28
|
hi all, i've been trawling the net now for sometime looking for a gui toolkit = which solely uses opengl calls to draw itself. I need to incorporate = this gui with OpenGL Performer on linux. PUI seems perfect for that. = So now i find out its part of Plib and thats fine but can i compile just = the PUI lib by itself without the other bits and piecs of Plib ? i see = that it depends on ul.h and fnt.h but if i remove those function calls = from all PUI source then it will work yes ? I really want to find a = copy of PUI before it was incorporated into Plib so all i have to do is = remove those glut calls. Am i allowed to modify the source of PUI like = that or is that illegal ? also, i see that the makefile compiles it into a .lib - can i just = include all the PUI files directly into my program source and compile it = like that or does that just defeat the purpose ? :) Thanks for your time in answering, Andrew |
|
From: Sebastian U. <ud...@ha...> - 2002-04-24 13:27:09
|
On Wed, 24 Apr 2002, x_b...@ho... (Andrew Stewart) wrote: > Date: Wed, 24 Apr 2002 22:42:15 +1000 > To: <pli...@li...> > From: x_b...@ho... (Andrew Stewart) > Subject: [Plib-users] Using only PUI without GLUT > > hi all, > > i've been trawling the net now for sometime looking for a gui toolkit > which solely uses opengl calls to draw itself. I need to incorporate > this gui with OpenGL Performer on linux. PUI seems perfect for that. So > now i find out its part of Plib and thats fine but can i compile just the > PUI lib by itself without the other bits and piecs of Plib ? No - you will at least need FNT, SG and UL in addition to PUI. > i see that it depends on ul.h and fnt.h but if i remove those function calls from > all PUI source then it will work yes ? It won't. PUI relies on FNT for rendering of text and on UL for directory handling (file selector widget). > I really want to find a copy of PUI before it was incorporated into Plib > so all i have to do is remove those glut calls. What have PUI's inter-PLIB dependancies to do with GLUT ? What's the problem with them anyway ? Nevertheless, you *can* tell PUI not to depend on GLUT at compile time if you can live with some limitations. If compiled without GLUT, you will have to feed PUI with window dimensions and font textures for now; additionally, PUI currently won't allow you to spread user interface widgets across different windows of your application. For details, please see the PUI documentation (scroll down to the bottom of the document): http://plib.sourceforge.net/pui/ > Am i allowed to modify the source of PUI like that or is that illegal ? Surely you are allowed to do so (as long as you do not remove the copyright headers). Welcome in the world of the (L)GPL license ! > also, i see that the makefile compiles it into a .lib - can i just > include all the PUI files directly into my program source and compile it > like that or does that just defeat the purpose ? :) I don't see any reason why you would want to do so. Besides the fact that simply including all the C++ source files of PUI won't work, the latter consits of about 9500 lines of code - including that much text from each of your source files would slow down compilation of your application in a serious extent. And finally, what is wrong with the lib file ? If the PLIB libraries are statically linked into your application binary, it won't depend on the library files at runtime. - Sebastian |
|
From: Steve B. <sjb...@ai...> - 2002-04-24 15:01:53
|
> Andrew Stewart wrote:
> i've been trawling the net now for sometime looking for a gui toolkit
> which solely uses opengl calls to draw itself. I need to incorporate
> this gui with OpenGL Performer on linux.
(You might want to consider replacing Performer with SSG! I originally
wrote SSG as a Performer replacement - so unless you are heavily dependent
on Performer's multithreading - you might consider dumping it for an
OpenSource alternative).
If you are just looking for an OpenGL-rendered GUI, you could also take
a look at a package called 'GLUI' - I havn't seen many people use it - but
it's the nearest competitor to PUI that I know of.
> PUI seems perfect for that.
It is indeed - I only suggest you look at GLUI because I don't know the
details of your application and it's possible that GLUI might be a better
fit than PUI...it's hard to know.
> So now i find out its part of Plib
> and thats fine but can i compile just the PUI lib by itself without
> the other bits and piecs of Plib ? i see that it depends on ul.h and fnt.h
Yes - but there is no real reason not to link with those too. UL is just a set
of simple utility functions that are shared across all of PLIB - and FNT does the
work of rendering fonts - which you'll certainly need if you are doing without GLUT.
> but if i remove those function calls from all PUI source then it will work yes ?
No.
> I really want to find a copy of PUI before it was incorporated into Plib so all
> i have to do is remove those glut calls.
I *strongly* recommend that you stick with the current revision and link to libplibul.a
and libplibfnt.a (I think you also need libplibsg.a too).
> Am i allowed to modify the source of PUI like that or is that illegal ?
Sure - it's legal - but note that if you give the modified program to anyone else
you have to give them the source code under the LGPL license and abide by the
terms of the LGPL yourself. Those same terms apply to the unmodified PLIB of course.
> also, i see that the makefile compiles it into a .lib...
Actually, a ".a" for Linux...but yes.
> - can i just include all
> the PUI files directly into my program source and compile it like
> that or does that just defeat the purpose ? :)
You *can* do that too - but:
1) Now your ENTIRE PROGRAM falls under the LGPL license...if you give a
copy to anyone else, you have to give them ALL of the source code.
2) You'll find it much harder to take advantage of upgrades and bug fixes.
3) It's somewhat contrary to the *spirit* of free software in that we
would be unable to take advantage of any bug fixes or enhancements
you might happen to make.
I *STRONGLY* advise you to simply compile and install PLIB in it's entirety
(several people here can tell you what to do to get rid of the GLUT dependancy)
and simply link to libplibpui.a, libplibul.a, libplibfnt.a and libplibsg.a
...that should work just fine and it minimises the grief level for all concerned.
> Thanks for your time in answering,
My pleasure.
----------------------------- Steve Baker -------------------------------
Mail : <sjb...@ai...> WorkMail: <sj...@li...>
URLs : http://www.sjbaker.org
http://plib.sf.net http://tuxaqfh.sf.net http://tuxkart.sf.net
http://prettypoly.sf.net http://freeglut.sf.net
http://toobular.sf.net http://lodestone.sf.net
|