Coder Social home page Coder Social logo

alien-opengl's People

Watchers

 avatar  avatar

alien-opengl's Issues

API for dynamically loading GL extensions

Since OpenGL supports loading function pointers on demand, and this varies per platform, it seems reasonable to abstract this behavior in the Alien:: module. There is an entire separate project "GLEW" to deal with this problem, which we might or might not want to include. The main theme of GLEW is just to declare a lot of global pointer-to-function, and then lazy-load them on demand. I came up with a (greatly) simplified version of their loader for my OpenGL::Sandbox project, dealing with only the functions I needed, and named it "glducktape". I think the giant table of function pointers might be too much for the alien module (maybe best saved for a OpenGL::GLEW module), but wrapping the C loader function with a platform-neutral API would be small-ish and quite useful for the perl ecosystem.

The loader I wrote (linked above) is

void* glducktape_initProcAddress(const char *name, void **fnptr);

and implemented for Linux, Mac, and Win32. It is just a wrapper around dlsym, GetProcAddress, or glXGetProcAccress.

Support for ExtUtils::Depends

It would be nice if Alien::OpenGL included support for ExtUtils::Depends, providing a quick and easy way for people to get the C linker flags and header path for the host's OpenGL, and also to conveniently set things up for quick Inline code.

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.