[fpc-pascal] FreeGLUT on Windows
Ryan Joseph
ryan at thealchemistguild.com
Thu Dec 24 12:02:17 CET 2015
> On Dec 24, 2015, at 12:28 PM, leledumbo <leledumbo_cool at yahoo.co.id> wrote:
>
> FreeGLUT is a drop-in replacement for GLUT (well, minus some behavior
> difference which is documented in their website), so any GLUT program should
> work on FreeGLUT. The Pascal wrapper, however, is not the same glut32 unit
> because it links to different dll and FreeGLUT has its own extension so it
> deserves its own unit, which has been in FPC since 2.4.4:
> http://svn.freepascal.org/svn/fpc/tags/release_2_4_4/packages/opengl/src/freeglut.pp
If it's a drop in replacement why do I get compiler errors that functions like glutInitWindowPosition are not declared?
There’s the units from the example program I started from:
{$mode objfpc}{$H+}
program firstprogram;
uses
gl, glu, freeglut, sysutils, dynlibs;
And then I’m trying to load the .dll like this:
LoadFreeGlut(LoadLibrary('/freeglut/bin/freeglut.dll'));
Did I miss something?
Thanks.
Regards,
Ryan Joseph
More information about the fpc-pascal
mailing list