Results 1 to 6 of 6

Thread: Lazarus port of Tom Nuydens "Mr. Potato Head" GLSL demo using modern GL functionality

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Honestly my original point was kind of an oversimplification. I basically meant "why isn't QueryPerformanceCounter implemented as an alias for a specific use of GetTimeOfDay that returns identical output to the Windows QueryPerformanceCounter on non-windows FPC platforms?" Also there's more to it than that, I suppose... a larger problem is that there's not really any easy way that I'm aware of to load specific sets of OpenGL extensions for non-windows platforms. (As in, everything up to and including OpenGL 3.3.) Obviously dglOpenGL will load EVERYTHING when you call InitOpenGL and ReadExtensions (on Windows), but for Linux it seems to be tied to the ancient GLX API, and for OSX I'm not sure it has support for modern functionality at all. So I just stuck to FPCs GL and GLEXT units. Again though, without trying to sound like an asshole, it's not my problem that Linux and OSX have significantly less user-friendly/robust OpenGL initialization APIs. Missing functionality is missing functionality. ​It's not something to be catered to.

  2. #2
    Thanks for the sample! One small nitpick: calls to LoadOpenGL('opengl32.dll'); Load_GL_version_1_2; ... Load_GL_version_3_2; - are not needed, at least not if you use units distributed with FPC. LoadOpenGL runs in GL unit initialization and the version loading functions cascade to lower versions.

  3. #3
    Quote Originally Posted by imcold View Post
    Thanks for the sample! One small nitpick: calls to LoadOpenGL('opengl32.dll'); Load_GL_version_1_2; ... Load_GL_version_3_2; - are not needed, at least not if you use units distributed with FPC. LoadOpenGL runs in GL unit initialization and the version loading functions cascade to lower versions.
    Yeah, I actually remembered that a few days after I originally posted this.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •