project compile with IrrlichtML problem

If you are a new Irrlicht Engine user, and have a newbie-question, this is the forum for you. You may also post general programming questions here.
Post Reply
lostgdi
Posts: 5
Joined: Wed Jan 05, 2011 12:28 pm

project compile with IrrlichtML problem

Post by lostgdi »

Hi all, since now , I was search the whole bbs topic for solution IrrlichtML-1.7.1-win32Linux problem.this problem was took me 2 day. finaly I was block in compiling, and the compile's message follow:

error LNK2019: "public: static class irr::gui::CGUITTFont * __cdecl irr::gui::CGUITTFont::createTTFont(class irr::gui::IGUIEnvironment *,class irr::core::string<wchar_t,class irr::core::irrAllocator<wchar_t> > const &,unsigned int)" (?createTTFont@CGUITTFont@gui@irr@@SAPAV123@PAVIGUIEnvironment@23@ABV?$string@_WV?$irrAllocator@_W@core@irr@@@core@3@I@Z), test3.obj test3

Note:
1. I has success in compile the freetype-2.4.4;
2. I has success in Re-compile in rrlicht-1.7.1\examples\IMETest sample(binding my new successfull freetype lib),and run fine;
3. My compiler is (VS2008) and environment was configed which rrlicht tutorials are recommand. and I was try and success some tutorials case;
4. Engine is irrlicht-1.7.2.

My test project cpp code follow(very simple):

Code: Select all

#include "stdafx.h"
#include <CGUITTFont.h>
#include <irrlicht.h>
#include "driverChoice.h"


#pragma comment(lib, "freetype244MT_D.lib")
#pragma comment(lib, "Irrlicht.lib")

using namespace irr;
using namespace core;
using namespace scene;
using namespace video;
using namespace io;
using namespace gui;

int _tmain(int argc, _TCHAR* argv[])
{
	video::E_DRIVER_TYPE driverType=driverChoiceConsole();
	if (driverType==video::EDT_COUNT) return 1;

	IrrlichtDevice *Device;
	Device = createDevice(driverType, core::dimension2d<u32>(640, 480));
	if(Device == NULL) return 1;

	IVideoDriver *Driver = Device->getVideoDriver();
	IGUIEnvironment* env = Device->getGUIEnvironment();


	CGUITTFont* tt_font = gui::CGUITTFont::createTTFont(Device->getGUIEnvironment(), "simsun.ttc", 14);

	return 0;
}
thank for you help.
:cry:
lostgdi
Posts: 5
Joined: Wed Jan 05, 2011 12:28 pm

Post by lostgdi »

24 hours passed(including sleeping)

even 1 day pass, but I found my topic was alway no answer. I feel a little bit disapoint.
How ever I solve it myself.

the reason is , I hasn't include the header file and implement file to project which call CGUITTFont.h and CGUITTFont.cpp. although there were in my irrlicht include folder.

thank for attenttion !
hybrid
Admin
Posts: 14143
Joined: Wed Apr 19, 2006 9:20 pm
Location: Oldenburg(Oldb), Germany
Contact:

Post by hybrid »

Well, I guess that a lot of people read your post, and knew the answer immediately. But if you would know your tools just a little, or would have used the search function of the forum, you would have found the answer on your own before they could answer. So you didn't get a response, but finally learned a little more about your IDE. Congrats :!:
Post Reply