This topic contains step-by-step instructions on how to create and set up a project in Microsoft® Visual Studio® 2017. Note that <KERNEL_DIR> is the directory where you unpacked the Kernel archive.
Start Visual Studio and open the <KERNEL_DIR>\Platforms\vc15dll\Kernel_vc15dll_ex.sln
solution file.
Add a new Win32 Console Application to the solution. Set FirstApp as the project name and <KERNEL_DIR>\Platforms\vc15dll\FacetModeler\examples\ as the location.
Optionally, set FirstApp as a startup project if you want to have it active when the solution opens.
Add a source file to the project, name it FirstApp.cpp and place it in the <KERNEL_DIR>\FacetModeler\examples\FirstApp\ folder.
Set the project properties:
Configuration properties —> General —> Output Directory: <KERNEL_DIR>\exe\vc15dll\
Configuration properties —> C/C++ —> General —> Additional Include Directories:
<KERNEL_DIR>\Kernel\Extensions\ExServices\
<KERNEL_DIR>\Kernel\Include\
<KERNEL_DIR>\ThirdParty\
<KERNEL_DIR>\ThirdParty\activation\
<KERNEL_DIR>\FacetModeler\include\
These options are required so that the Visual C++ compiler can find ODA Software header files.
If pch.cpp and pch.h are automatically generated in your project, remove these files from the project: Configuration properties —> C/C++ -> Precompiled Headers -> Not using precompiled headers
Add the following values to Configuration properties —> C/C++ —> Preprocessor —> Preprocessor definition:
UNICODE
_UNICODE
_CRT_SECURE_NO_DEPRECATE
WIN32
_WIN32
_WINDOWS
_CRT_NOFORCE_MANIFEST
_STL_NOFORCE_MANIFEST
NDEBUG
ODA_LICENSING_ENABLED
_CRTDBG_MAP_ALLOC
ADT_DYNAMIC_BUILD
_TOOLKIT_IN_DLL_
CMAKE_INTDIR="Release"
Configuration properties —> Linker —> General —> Additional Library Directories:
<KERNEL_DIR>\exe\vc15dll\
<KERNEL_DIR>\lib\vc15dll\
The paths are required by the linker to find the necessary ODA Software dynamic and static libraries.