Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

build problems with libgles2 #292

Open
chrysn opened this Issue · 7 comments

3 participants

@chrysn

ubuntu has recently added support for the armhf platform, where they use gles2 instead of regular opengl[1]. on that platform, openscad 2013.01 fails to compile; the build log of the failed build resides at [2], you can compare it to a working one at 3.

if opengl es2 is not yet supported in openscad, please take this as a "gles2 support missing" ticket (potentially including hints on what went wrong in the build log), otherwise ... something else is broken.

[1] honestly, i don't even understand how the different kinds of using an opengl library at run time vs linking against it vs just having them installed interact. i'm only describing what i see in the build logs -- armhf installs libgles2-mesa-dev, which amd64 doesn't.
[2] https://launchpadlibrarian.net/132800202/buildlog_ubuntu-raring-armhf.openscad_2013.01%2Bdfsg-2_FAILEDTOBUILD.txt.gz
[3] https://launchpadlibrarian.net/132801895/buildlog_ubuntu-raring-amd64.openscad_2013.01%2Bdfsg-2_UPLOADING.txt.gz

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@kintel
Owner

OpenGL ES2 is not supported - we still use old style, immediate-mode OpenGL.

I would prefer to rewrite the entire GL rendering code to use a scene-graph-like library. Don also did some good work recently to clean up rendering (e.g. introducing a camera class).

@donbright
Collaborator

surely we are not the only package to 'break' on this? what are other packages doing to solve ?

@chrysn

i don't know how other packages handle that; i'm not really familiar with the ubuntu workflows behind it. i've investigated further, and it seems to be the decision of the ubuntu qt4-x11 maintainers to use libgles2-mesa instead of libgl1-mesa iff it gets built on arm. (that decision is documented in debian too[1], but the current packages all use libgl1[2]).

i'm adding a build conflict against libgles2-mesa-dev -- that won't solve the problem, but at least it's easier spotted. that's what others did too before they became gles compatible (eg [3]).

that won't solve the practical problem of openscad not being available on arm ubuntu, of course, and i don't know if (and if: how) that can be done without going all the way of becoming gles2 compatible.

[1] http://packages.debian.org/changelogs/pool/main/q/qt4-x11/qt4-x11_4.8.2+dfsg-11/changelog#version4:4.7.3-2
[2] http://packages.debian.org/source/sid/qt4-x11
[3] http://bugs.debian.org/688801

@donbright
Collaborator

Marius do you have any scene graph libraries you have been thinking about?

Chrysn: do you know if OpenCSG's example builds on ubuntu or debian arm? I am wondering if OpenCSG even works with GLES2.0

@chrysn

opencsg's example doesn't use qt-x11. plain libgl is available, so opencsg built against it; just qt-x11 pulls in libgles and the things go bad. if you can manage to make openscad ignore the gles stuff and use libgl even though qt-x11 uses libgles, things might work without an port.

@donbright
Collaborator

note to future self :

google for "conflicting declaration 'typedef khronos_intptr_t GLintptr'"

and it will turn up huge discussions of similar problems. for example, Stellarium on the Raspebrry Pi.


more notes to self:

http://www.flashbang.se/archives/133

http://www.jwz.org/blog/2012/06/i-have-ported-xscreensaver-to-the-iphone/

@kintel
Owner

I was thinking about something pretty lightweight, like http://www.visualizationlibrary.org or http://sourceforge.net/projects/glvu.
I'd try to stay away from the larger ones (Ogre, Open Scenegraph, Coin3D/Open Inventor) as that feels like overkill (and drags in complex build systems).

I haven't followed developments on Free Software graphics libraries in a while, so this requires some research. It would be a nice and relatively self-contained project to do this though so it would be an excellent task for a new developer with 3D experience (it's allowed to dream ;)).

@kintel kintel added the Rendering label
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.