Giter Site home page Giter Site logo

Comments (13)

ptitSeb avatar ptitSeb commented on July 30, 2024

You are trying to link something that need OpenGL 2.0 functions. glshim only support OpenGL up to 1.5 for now.

What are you trying to compile?

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

I looked it up and the functions seem to be part of glesv2.

I'm porting a small game to Android.

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

Yes, there are part of GLESv2, but the glesv2 backend of glshim is not working. I plan to work on that, but much later. The GLESv2 part should not be activated.
The link error is during link of glshim or link of your game?

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

the link error is during linking of the game!

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

This game is probably not compatible with glshim for now, it need GL 2+ functions that are not available.

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

Isn't all the glshim needs to do to forward those calls to openglesv2?

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

Yes and no.
If the game use a GLES2 compatible context, then yes (but in that case, you probably don't need glshim and can just link with libGLESv2.so).
GLSL langage between full GL and GLESv2 are different (not much, but still GLSL 1.0 from ES is a subsample of GL v1.20). Plus all fixed pipeline function should be emulated with GLES2 functions.
So, for most game, no, it's not that simple.

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

I can't just link with libGLESv2.so, because then I get many many more undefined references when linking.
Linking with with glshim eliminates almost all of these link errors except for these 3 functions above. I think the game is overwhelmingly opengl1.x and very little opengl2.0.

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

Here's a little information about those functions and what they are used for:

http://www.gamedev.net/topic/655785-is-glenablevertexattribarray-redundant/

Quote:
"Much of this is legacy from the old fixed pipeline (glEnable/DisableVertexAttribArray were modelled on glEnable/DisableClientState and first appeared in GL_ARB_vertex_program roundabout OpenGL 1.5: the older calls go back to 1.1) and dates to a time when you might be mixing vertex array drawing with immediate mode drawing. So you'd use vertex arrays for your complex meshes and maybe glBegin/glEnd for your 2D GUI."

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

If there is little to no GL 2.0, you can do the other way then.
Create some dumys function yourself for those 3 function with;

void glEnableVertexAttribArray(GLuint index) { }
void glDisableVertexAttribArray(GLuint index); { }
void glVertexAttribPointer(GLuint index, GLint size, GLenum type, GLboolean normalized, GLsizei stride, const GLvoid * pointer) { }

Put that in some C sources of your game (better not put it in glshim itself).
and it should link. Chance are it will not behave correctly if those functions are really used.

from gl4es.

tobimensch avatar tobimensch commented on July 30, 2024

Unfortunately they are really used. :-(

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

Is your game opensource (if yes, which one is it)? I can try to hack some kind of support for that, but I'm not sure I undestood how it really works / what is the expected behavour of thoses functions.

from gl4es.

ptitSeb avatar ptitSeb commented on July 30, 2024

It doesn't make much sense to have this function in fixed pipeline mode. I will probably close that ticket for now.

from gl4es.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.