OpenGL Problem

Advanced game related topics
Diger
New User
New User
Posts: 2
Joined: Sun Jun 01, 2003 5:40 am

OpenGL Problem

Post by Diger »

I been working with OpenGL but when i call glClearDepth_(1.0).
I get glClearDepth() : Incorrect number of parameters anyone else get this or know a fix :?:
dmoc
Enthusiast
Enthusiast
Posts: 739
Joined: Sat Apr 26, 2003 12:40 am

Post by dmoc »

void glClearDepth(GLclampd depth)

The "d" at the end of "GLclampd" indicates a double, which PB does not support so you have to find a work around.
Diger
New User
New User
Posts: 2
Joined: Sun Jun 01, 2003 5:40 am

Post by Diger »

Thx ill see what i can do.
If you build it thay will come.
Kale
PureBasic Expert
PureBasic Expert
Posts: 3000
Joined: Fri Apr 25, 2003 6:03 pm
Location: Lincoln, UK
Contact:

Post by Kale »

Is this of any use?:

http://www.reelmediaproductions.com/pb/ ... GLU32F.zip

Its a user library for calling procedures args to use floats instead of doubles.

p.s. Link might not work if your not logged in, go here to login:

http://www.reelmediaproductions.com/pb
--Kale

Image
DarkDragon
Addict
Addict
Posts: 2348
Joined: Mon Jun 02, 2003 9:16 am
Location: Germany
Contact:

Post by DarkDragon »

Is this of any use?
No, because the GLU32FLibrary can't call gl functions, but glu functions.
dmoc
Enthusiast
Enthusiast
Posts: 739
Joined: Sat Apr 26, 2003 12:40 am

Post by dmoc »

Search the forums (or look in the code archive) for single to double conversions.
benny
Enthusiast
Enthusiast
Posts: 465
Joined: Fri Apr 25, 2003 7:44 pm
Location: end of www
Contact:

Post by benny »

Maybe I am wrong ... but could the F64-Lib be of any use for you ?
In the description it says:
Allows the using of Double floats (64 Bit) in PureBasic, for using with function calls (e.g. DLL's) as well (with the help of the many included commands) converting between different data types and calculating mathematical, logical and trigonometrical functions.
You find it on PureArea.net http://www.purearea.net in the Userlibs-Section ?!
regards,
benny!
-
pe0ple ar3 str4nge!!!
User avatar
J. Baker
Addict
Addict
Posts: 2196
Joined: Sun Apr 27, 2003 8:12 am
Location: USA
Contact:

Post by J. Baker »

I thought one of the UserLibs supports doubles.

MakeFloatDouble
viewtopic.php?t=8038
traumatic
PureBasic Expert
PureBasic Expert
Posts: 1661
Joined: Sun Apr 27, 2003 4:41 pm
Location: Germany
Contact:

Re: OpenGL Problem

Post by traumatic »

This will work for glClearDepth(): viewtopic.php?p=44532
Good programmers don't comment their code. It was hard to write, should be hard to read.
Post Reply