compilation error : reinterpret_cast ( under linux x86_64 )

You discovered a bug in the engine, and you are sure that it is not a problem of your code? Just post it in here. Please read the bug posting guidelines first.
Post Reply
Ovan
Posts: 70
Joined: Thu Dec 18, 2008 12:41 am
Contact:

compilation error : reinterpret_cast ( under linux x86_64 )

Post by Ovan »

Hello all ;)

Uhm ... I know to start the first topic :roll:
so i start ... 8)

i have to get three error when compiling the svn source code since last month
the three line is 1278, 1305, 1317 under COpenglDriver.cpp
reinterpreter_cast<GLuint> return "error: cast from 'void*' to 'GLuint' loses precision"

but is causing by void* is 32 or 64 bits (defined by os ?)
and GLuint is 32bits so convert 64bits to 32bits integer

how to fixe ? i search in google but i know result to fixe this
BlindSide
Admin
Posts: 2821
Joined: Thu Dec 08, 2005 9:09 am
Location: NZ!

Post by BlindSide »

This is related to the recently added Occlusion query feature. As a temporary measure you could comment all that stuff out if you don't plan to use Occlusion queries.

Cheers
ShadowMapping for Irrlicht!: Get it here
Need help? Come on the IRC!: #irrlicht on irc://irc.freenode.net
Ovan
Posts: 70
Joined: Thu Dec 18, 2008 12:41 am
Contact:

Post by Ovan »

ok thanks BlindSide (fast reply :o) :wink:
else it's possible to change gl headler typedef GLuint -> unsigned long long but not good ...
Nox
Posts: 304
Joined: Wed Jan 14, 2009 6:23 pm

Post by Nox »

Well you can "blind" the gcc as well. Just cast in a long and then in GLuint afaik. But this only hacks the error away and does not handle the loose of precision.
Post Reply