<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style id="owaParaStyle" type="text/css">P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">My suggestions, Dejan:<br>
1) Don't put your own code in the VTK install tree.<br>
2) Build your own applications with cmake.  This will take care of all the include files and libraries.  I suggest you start by finding one of the many online examples, which come complete with a CMakeLists.txt.  Then build your program using this example as
 a guide.  Cmake makes life very easy.<br>
<br>
Gib<br>
<div style="font-family: Times New Roman; color: #000000; font-size: 16px">
<hr tabindex="-1">
<div style="direction: ltr;" id="divRpF362015"><font face="Tahoma" color="#000000" size="2"><b>From:</b> vtkusers [vtkusers-bounces@vtk.org] on behalf of Dejan Zivkovic [dejan.zivkovic90@gmail.com]<br>
<b>Sent:</b> Sunday, 6 September 2015 8:29 a.m.<br>
<b>To:</b> vtkusers@vtk.org<br>
<b>Subject:</b> [FORGED] [vtkusers] Unresolved externals when trying to compile my VTK sample project<br>
</font><br>
</div>
<div></div>
<div>
<div dir="ltr">
<div><span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">I got some unresolved externals when trying to compile my VTK sample project in Visual Studio 2010</span></div>
<div><span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px"><br>
</span></div>
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">I did the following steps: </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">1) Downloaded VTK 6.3 from GIT </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">2) Configured it with cmake for VisualStudio 2010 x64 </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">3) Generated a VTK solution, and made an INSTALL release build </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">The result was the folder VTK in C:\ProgramFiles which has </span><b style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">include</b><span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px"> and </span><b style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">libs</b><span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px"> folders </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">that I intended to use for my solution. </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">Finally, I </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">- made an empty VS C++ project </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">- made a cpp files with copied sample code </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">- added include directories from C:\ProgramFiles\VTK\include </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">- set additional lib dir to C:\ProgramFiles\VTK\libs </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">- added all libs in the folder above to the linker input </span><br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<br style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">And I get 15 </span><span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px"> unresolved externals:</span>
<div><br>
</div>
<div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkRenderWindowInteractor::SetRenderWindow(class
 vtkRenderWindow *)" (__imp_?SetRenderWindow@vtkRenderWindowInteractor@@QAEXPAVvtkRenderWindow@@@Z)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkRenderWindowInteractor * __cdecl vtkRenderWindowInteractor::New(void)"
 (__imp_?New@vtkRenderWindowInteractor@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkProp3D::RotateY(double)" (__imp_?RotateY@vtkProp3D@@QAEXN@Z)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkProp3D::RotateX(double)" (__imp_?RotateX@vtkProp3D@@QAEXN@Z)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkCamera::Zoom(double)" (__imp_?Zoom@vtkCamera@@QAEXN@Z)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkCylinderSource * __cdecl vtkCylinderSource::New(void)"
 (__imp_?New@vtkCylinderSource@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkRenderWindow * __cdecl vtkRenderWindow::New(void)"
 (__imp_?New@vtkRenderWindow@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: class vtkProperty * __thiscall vtkActor::GetProperty(void)"
 (__imp_?GetProperty@vtkActor@@QAEPAVvtkProperty@@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkActor * __cdecl vtkActor::New(void)" (__imp_?New@vtkActor@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkPolyDataMapper * __cdecl vtkPolyDataMapper::New(void)"
 (__imp_?New@vtkPolyDataMapper@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkRenderer::ResetCamera(void)" (__imp_?ResetCamera@vtkRenderer@@QAEXXZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: class vtkCamera * __thiscall vtkRenderer::GetActiveCamera(void)"
 (__imp_?GetActiveCamera@vtkRenderer@@QAEPAVvtkCamera@@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: void __thiscall vtkRenderer::AddActor(class vtkProp *)" (__imp_?AddActor@vtkRenderer@@QAEXPAVvtkProp@@@Z)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: static class vtkRenderer * __cdecl vtkRenderer::New(void)"
 (__imp_?New@vtkRenderer@@SAPAV1@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>main.obj : error LNK2001: unresolved external symbol "__declspec(dllimport) public: class vtkAlgorithmOutput * __thiscall vtkAlgorithm::GetOutputPort(void)"
 (__imp_?GetOutputPort@vtkAlgorithm@@QAEPAVvtkAlgorithmOutput@@XZ)</span></font></div>
<div><font face="Verdana, Geneva, Helvetica, Arial, sans-serif" color="#000000"><span style="font-size:13.44px">1>C:\Users\Dejan\documents\visual studio 2010\Projects\VTKTest\Release\VTKTest.exe : fatal error LNK1120: 15 unresolved externals</span></font></div>
<div><br>
</div>
<span style="color:rgb(0,0,0); font-family:Verdana,Geneva,Helvetica,Arial,sans-serif; font-size:13.44px">Can someone help? This has been bugging me for more than a day.</span><br>
</div>
</div>
</div>
</div>
</div>
</body>
</html>