[vtkusers] X-Y Plots problem
Saira Saleem Pathan
sarakhan_engr at hotmail.com
Mon Apr 30 07:21:19 EDT 2007
hi
Apply Casting Function :)
Read from Documentation ,how to convert one data type to another, if solve
then let me know otherwise i will send u code :)
<DIV>
<P><STRONG><FONT color=#0000ff>Saira Saleem Pathan</FONT></STRONG><IMG
height=2 src="http://graphics.hotmail.com/greypixel.gif" width="100%"
vspace=9></P>
<P> Ph.D. Student</P>
<P>Univerity of Leeds </P>
United Kingdom.
>From: "Lledo Museros Cabedo" <lledo.museros at itc.uji.es>
>To: <vtkusers at vtk.org>
>Subject: [vtkusers] X-Y Plots problem
>Date: Mon, 30 Apr 2007 12:51:45 +0200
>
>Hello,
>
>I am new using VTK, therefore I am reading the VTK books and trying to
>do examples. I have written the example xyPlot.tcl (which is in
>VTK/Examples/Annotation/TCl/) in C++, and now I have a compiler error
>which I do not know how to solve. The error says that
>'vtkProbeFilter::SetSource' : cannot translate the parameter from
>'vtkStructuredGrid *' to 'vtkDataObject *'. I have read the doxygen
>manuals and in fact SetSource needs as parameter a vtkDataObject but
>GetOutput from a vtkPLOT3DReader returns a vtkStructuredGrid.
>
>I send the part of the code pointing out where the error is:
>
>//
>// Create a PLOT3D reader and load the data.
>//
>
>vtkPLOT3DReader *pl3d=vtkPLOT3DReader::New();
>pl3d->SetXYZFileName("C:/VTKData/Data/combxyz.bin");
>pl3d->SetQFileName("C:/VTKData/Data/combq.bin");
>pl3d->SetScalarFunctionNumber(100);
>pl3d->SetVectorFunctionNumber(202);
>pl3d->Update();
>
>// Create three the line source to use for the probe lines.
>vtkLineSource *line=vtkLineSource::New();
>line->SetResolution(30);
>
>// Move the line into place and create the probe filter. For
>vtkProbeFilter, // the probe line is the input, and the underlying data
>set is the source.
>
>vtkTransform *transL1=vtkTransform::New();
>transL1->Translate(3.7, 0.0, 28.37);
>transL1->Scale(5,5,5);
>transL1->RotateY(90);
>vtkTransformPolyDataFilter *tf=vtkTransformPolyDataFilter::New();
>tf->SetInputConnection(line->GetOutputPort());
>tf->SetTransform(transL1);
>vtkProbeFilter *probe=vtkProbeFilter::New();
>probe->SetInputConnection(tf->GetOutputPort());
>probe->SetSource(pl3d->GetOutput()); ----> In this line is the ERROR.
>
>Can anyone help me?
>
>Thank you in advance.
>
>Best regards,
>LLEDO
>
>
>
>
>_______________________________________________
>This is the private VTK discussion list.
>Please keep messages on-topic. Check the FAQ at:
>http://www.vtk.org/Wiki/VTK_FAQ
>Follow this link to subscribe/unsubscribe:
>http://www.vtk.org/mailman/listinfo/vtkusers
_________________________________________________________________
Express yourself instantly with MSN Messenger! Download today it's FREE!
http://messenger.msn.click-url.com/go/onm00200471ave/direct/01/
More information about the vtkusers
mailing list