Really pissed by OGL..

Started by
7 comments, last by V-man 13 years, 6 months ago
I just wonder why ogl doesn't provide any utility functions such as Math, texture loading, model loading and user interface.

To write my own is just too big a project..
Hope it can improve in the next version..
Advertisement
Quote:Original post by shiqiu1105
I just wonder why ogl doesn't provide any utility functions such as Math, texture loading, model loading and user interface.
Because it's a graphics library.

Quote:Original post by shiqiu1105
To write my own is just too big a project..
Hope it can improve in the next version..
Not going to happen I'm afraid. However, there's various libraries available to do the job for you.
Because OpenGL is a graphics API meant to be an interface to the graphics hardware. Things like math, texture loading, and model loading are outside of the problem space that OpenGL exists to solve. What you want is a game engine, and there are plenty out there.
I do see his point though at least for the math.

if GLSL provides programmers with built in functionality for matrices and such, and ogl 2.1 had the matrix stack, it seems that they downgraded their robustness a bit.

To counter my own statement though, a simple google search for OpenGL Math Library gives you some nice results/solutions.

------------------------------

redwoodpixel.com

Quote:Original post by shiqiu1105
I just wonder why ogl doesn't provide any utility functions such as Math, texture loading, model loading and user interface.
Regarding the math library aspect at least, you got some good suggestions in your other thread (see in particular my link to a list of free math libraries).

Was the feedback you got there not helpful? Or did none of the libraries in question seem suitable?
come on this guy is obviously trolling
No I'm not "trolling"!!

I guess I'm just a little bit uncomfortable using a lot of external library...
It makes my project code like a hodgepodge...

I'm starting to write my own...

Including math, camera, texture and model loading..
how is it going to be better if you create your own library instead of using someone else's which has been in development for years ?
If you actually are experienced enough to write these libraries on your own, why not try improving an existing library, adding the stuff you need ?

I can see that using lots of libraries from different developers would make things messy with conversions and stuff.
If that is your only complaint about it, give my game libraries a try: Click Me
They have all what you are looking for (well some of them not finished yet, but meh help me out if you're desperate enough to write your own).
They are still separate libraries, but they fit together seamlessly and I even have a GUI library in the works:



Quote:Original post by AverageJoeSSU
I do see his point though at least for the math.

if GLSL provides programmers with built in functionality for matrices and such, and ogl 2.1 had the matrix stack, it seems that they downgraded their robustness a bit.

To counter my own statement though, a simple google search for OpenGL Math Library gives you some nice results/solutions.


I had written my own matrix code and was already avoiding the GL matrix stack even before GL 3.0 came out.

I can understand that someone who is new to the scene gets confused and uncomfortable but eventually, they will understand that OpenGL should be just a thin layer for using your GPU.
If you need a one stop solution, then you need a high level library like Ogre (supports GL, D3D and physics and loading images and a bunch of other stuff).
Sig: http://glhlib.sourceforge.net
an open source GLU replacement library. Much more modern than GLU.
float matrix[16], inverse_matrix[16];
glhLoadIdentityf2(matrix);
glhTranslatef2(matrix, 0.0, 0.0, 5.0);
glhRotateAboutXf2(matrix, angleInRadians);
glhScalef2(matrix, 1.0, 1.0, -1.0);
glhQuickInvertMatrixf2(matrix, inverse_matrix);
glUniformMatrix4fv(uniformLocation1, 1, FALSE, matrix);
glUniformMatrix4fv(uniformLocation2, 1, FALSE, inverse_matrix);

This topic is closed to new replies.

Advertisement