I’m trying to use the Freetype2 module of openCV to use custom fonts, but I’m failing to make it work.
I have tried using the pre-compiled libraries and building openCV with the git-bash method of OpenCV: Installation in Windows (latest current release, 4.5.2) with no success.
I want to use it in Visual Studio: I have tried adding “PreviousPath\OpenCV_4.5.2\opencv_contrib\modules\freetype\include” to the Additional Include Directories in the project properties; while this makes Visual Studio and Intellisense “accept” freetype.hpp, when I try to build the solution it tells me there are unresolved externals (which obviously means I have failed to properly add the library, but I don’t know where my mistake is).
I’m unsure if I’m not configuring my project correctly or if I’m failing to build the source correctly. I have tried looking at tutorials on how to build OpenCV with Freetype, but the documentation is scarce and I haven’t been able to follow the methods proposed. I have seen mentioned that I need the freetype and hardbuzz libraries, but I don’t know how to add them so that CMake recognises them when building the extra modules of OpenCV.
Has anyone been able to use it and could you please tell me how to do it?