[HOpenGL] New programmer => some comments/suggestions

L Corbijn aspergesoepje at gmail.com
Sat Apr 30 21:50:39 CEST 2011


Hi everyone,

I was wondering if anyone is working on improving the OpenGL package. As the
git repository [1] on github looks rather quiet, beside my (Laar, not my
real name) casual editing. In that process of adding extra functions to
improve the library to some higher version of OpenGL I ran into some
structural inconveniences. But as I'm not that experienced with Haskell nor
with collaborating in open source projects.

The major problem in my opinion is the boat load of deprecated functions and
objects that make finding and having an overview of the code rather
difficult. This is not helped by the fact that there are a lot of files that
could be marked as deprecated. Therefore I think that something more serious
should be done than only adding deprecated pragma's as Jason Dagit suggests
in [2]. I think it should improve the overview of the code if all deprecated
functions/code/etc. are move to a different namespace, say
...OpenGL.GL.Deprecated. This would help a lot as with coding new stuff the
files would be quite a bit smaller as you wouldn't  see the deprecated
stuff. Though this will probably be quite a hard break with older code.
Though quite a lot of code to refactor I think it would lead to a better
structured project that is easier to maintain.

Furthermore in it's current state importing ...OpenGL.GL does import
everything, whether it's deprecated, usefull or even only usable for higher
versions of OpenGL-contexts than you use. Although the exported
functions/Types wouldn't lead to clashes it would be nice to have modules
that only export the stuff that is usable for a certain OpenGL-context (e.g.
importing ...Core31 or ...Core31Compatibility). This would lead to a compile
error when using unsupported functions, which is a lot more pleasant than
having to debug why code doesn't work (talking from experience). And if the
future brings better auto-complete for Haskell it might lead to better
suggestions (all the unused stuff out).

Greetings,

L Corbijn

[1] https://github.com/dagit/OpenGL/network
[2] http://www.haskell.org/pipermail/hopengl/2011-April/001002.html
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.haskell.org/pipermail/hopengl/attachments/20110430/0278794a/attachment.htm>


More information about the HOpenGL mailing list