FreeType

Recommended Posts

Has anyone here had any experiance with FreeType 2? I keep recieving "[Linker Error] Unresolved external '_FT_Init_FreeType' referenced from E:\MYDOCS\CHRIS\PROGRAMING\DIRECTX\MERC ENGINE\UNIT1.OBJ" everytime I attempt to use FT_Init_FreeType(). I've checked the doccumentation, but it appears I'm doing everything right... I've included the Include dir, and added the right #includes... Any help would be great! Cheers Sigma

Share on other sites
You need to link with the library as well.

It is usually located in the FreeType source tree under builds/Win32/visualc

I did...

Share on other sites
Any thing else I could try?

CHeers

Sigma

Share on other sites
There are lots of different versions of the library for debug/release, multithreaded/single threaded, linking dll/static libraries etc. Make sure you have the right one.

Share on other sites
OK, well I definatly DID have the wrong version, and my current version seems right. But I can't find the .lib files. So I can't include them..Does anyone know wehre I can find these?

Cheers

Sigma

Share on other sites
for me they are in

\freetype2\objs

you can find them by doing a search:

Window-Key and F
freetype*.lib

Share on other sites
OK, I tried a different version, the one with the exe setup. I now have the libs as well as the BCB lib(I'm using BCB6)

But I still have the issue.
I've included
//FreeType stuff#include <ft2build.h>#include FT_FREETYPE_H

FreeType/lib/libfreetype-bcc.lib to my project

FreeType/include to my include directories

Tried adding FreeType/lib to my lib directories, but that didn't have any effect

What am I missing?

Cheers

Sigma

[Edited by - _Sigma on November 14, 2004 2:30:31 PM]

Share on other sites
Common! Must I beg? ;)

I tried adding other headers, but that didn't work. I also tried a full rebuild, but alas, that wasn't the cause...

Share on other sites
This is clearly a linker issue, not so much a freetype one. Perhaps you should change the subject?

btw, BCB? Borland somethingorother?

Share on other sites
Did you build freetype from source? Do that if you haven't.

Share on other sites
No idea how i would do that.

@C-Junkie: Borland C++ Builder ;)

anyone?

Share on other sites
It's been so long and apparently I did not keep notes, but I think I used either mingw32-make.exe or jam(or I bruteforced it-added files manually).
Either way I managed to compile Freetype 2.1.9 into a .lib for my Borland compiler, would you like me to send it to you?
Also, is the inclusion of the Freetype headers within an 'extern "C" {...}' block, cause mine is.

Share on other sites
>Either way I managed to compile Freetype 2.1.9 into a .lib for my >Borland compiler, would you like me to send it to you?

>Also, is the inclusion of the Freetype headers within an 'extern >"C" {...}' block, cause mine is.

How do I do that again?
extern "C"{//FreeType stuff#include <ft2build.h>#include FT_FREETYPE_H}

Like so?

Cheers

Sigma

Share on other sites
Quote:
 Original post by _SigmaNo idea how i would do that.@C-Junkie: Borland C++ Builder ;)

Freetype is quite easy to build actually.

There are instructions in the Freetype folder, but simply, you just need to pretty much include all of the c files and compile!

There are some toggles you can play with as well, but Free type will compile out of the box.

Another thing, did you try to run the the coff2omf.exe (borland command utility) to transform the .lib file in a format that Borland understand?

Or was it cofftoomf?

Share on other sites
me thinks it was already done, but I'll check

Share on other sites
Ya, it can included with a libfreetype-bcc.lib file, which BCB doesn't reject, so I assume its all good.

Share on other sites
Ok, how do I build this damn thing? :D I can't figure it out for the life of me!

CHeers

Sigma

Share on other sites
I got a failure on the e-mail so here's a link.

As far as compiling it yourself, the jam and make files have all the instructions, you just have to learn how to read them.

The extern "C" example you've shown is correct.

Share on other sites
Cheers

I'll look into that stuff. What do thos libs do?

Share on other sites
/bow

Problem sloved. Cheers!

Share on other sites
Now download FTGL and see if you can get it working. It's a nice piece of code and I've never had trouble with it as it's well made.

Share on other sites
Well..firstly its Mac! And secondly is OpenGl! :) I know neither!

@RolandofGilead: Have any sample code I could have?

Share on other sites
Quote:
 Original post by _SigmaWell..firstly its Mac!

It is cross platform.

Quote:
 And secondly is OpenGl! :) I know neither!

You don't need to know.

It'll show you how to use Freetype nicely.

Create an account

Register a new account

• Forum Statistics

• Total Topics
627757
• Total Posts
2978950

• 11
• 10
• 10
• 23
• 14