Include hell
by Neil Marshall · in Torque Game Engine · 04/25/2006 (7:31 am) · 3 replies
I've got a compiler problem with the TGE Browser plugin and I'm wondering if someone can help me out with it. The code thats currently on TDN is pretty much where I'm stuck right now.
tdn.garagegames.com/wiki/TGE/Code/How_to_make_torque_a_plugin
April 21st version
When you compile you need to comment out the ATL includes in plugin.cpp, get an error, uncomment the ATL lines, and then recompile for it to work. I'm trying to get rid of this hackery as it's most likely the cause of problems I'm having later on. Can someone who knows their compiler errors help me out with it? I keep running into problems with functions which should be linked to in windows.h.
I'm at a loss as to what to try to fix the problem. windows.h includes fine in ax3DPlugin.h but not in the netscape plugin related files. Does anyone know how to get around this?
tdn.garagegames.com/wiki/TGE/Code/How_to_make_torque_a_plugin
April 21st version
When you compile you need to comment out the ATL includes in plugin.cpp, get an error, uncomment the ATL lines, and then recompile for it to work. I'm trying to get rid of this hackery as it's most likely the cause of problems I'm having later on. Can someone who knows their compiler errors help me out with it? I keep running into problems with functions which should be linked to in windows.h.
C:\Projects\tge14\TGE14Plugin\engine\np3DPlugin\plugin.cpp(526): error C2065: 'WM_MOUSEWHEEL' : undeclared identifier C:\Projects\tge14\TGE14Plugin\engine\np3DPlugin\plugin.cpp(485): error C3861: 'TrackMouseEvent': identifier not found, even with argument-dependent lookup
I'm at a loss as to what to try to fix the problem. windows.h includes fine in ax3DPlugin.h but not in the netscape plugin related files. Does anyone know how to get around this?
Torque Owner Badguy
find that in winuser.h
note that neither of those preprocessor directives are declared by default.
#if(_WIN32_WINNT >= 0x0400) #ifndef NOTRACKMOUSEEVENT .... *snipped* WINUSERAPI BOOL WINAPI TrackMouseEvent( LPTRACKMOUSEEVENT lpEventTrack); ...suffers from the same problem.
probably as simple as defining _WIN32_WINNT to pass those qualifiers.
I'm not 100% sure of the cleanest way to do this if it is done with a different header.
you can just declare that directive and try that.
or continue the research.