[vtkusers] RE: Linking errors
p3rdigao
p3rdigao at netcabo.pt
Wed Sep 15 09:31:15 EDT 2004
First of all i must say...that i have 2 directories of vtk...
1) one is the original extracted from the Zip file...
2) the other is VTKB the bin directorie.....crreated with cmake...
i only include the .h files in vtk dirs in the include files (Tools-> Options ->Project->VC++ Directuries ->Include files)....but i confess is the first time i work on Visual Studio....
so; how do i link against the appropriate libraries?
Did you link against the appropriate VTK libraries (vtkCommon and vtkIO)?
- Amy
At 04:09 PM 9/14/2004, p3rdigao wrote:
>Hello I compile this program...
>
>#include "vtkDataSetReader.h"
>
>#include "vtkDataSetWriter.h"
>
>#include "vtkDataSet.h"
>
>void main(void){
>
> vtkDataSetReader *Reader = vtkDataSetReader::New();
>
> Reader->SetFileName("c:\braquial.vtk");
>
> vtkDataSet *dataSet = (vtkDataSet*)vtkDataSet::New();
>
> dataSet = Reader->GetOutput();
>
>}
>
>but in the end the result are these 4 linkage errors:
>
>1) LNK2001: unresolved external symbol "public: class vtkDataSet *
>__thiscall vtkDataSetReader::GetOutput(void)"
>(?GetOutput at vtkDataSetReader@@$$FQAEPAVvtkDataSet@@XZ)
>
>2) LNK2001: unresolved external symbol "public: static class
>vtkDataObject
>* __cdecl vtkDataObject::New(void)" (?New at vtkDataObject@@$$FSAPAV1 at XZ)
>
>3) LNK2001: unresolved external symbol "public: static class
>vtkDataSetReader * __cdecl vtkDataSetReader::New(void)" (?
><mailto:?New at vtkDataSetReader@@$$FSAPAV1 at XZ <mailto:?New at vtkDataSetReader@@$$FSAPAV1 at XZ> >
>New at vtkDataSetReader@@$$FSAPAV1 at XZ)
>
>
>4) test fatal error LNK1120: 3 unresolved externals
>
>So what is the problem?
>
>thanks
>
>
>
More information about the vtkusers
mailing list