[vtkusers] Re: Help: Problem compiling example code
marisa aurelio
asiram00 at hotmail.com
Mon Jul 7 06:32:53 EDT 2003
Hi Lina,
1st and 2nd Error:
When you have an error like:
G:\wolken\vtk\Quadric\Quadric.cpp(26) : error C2664: 'SetInput' : cannot
convert parameter 1 from 'class vtkImageData *' to 'class vtkDataSet *'.
Types pointed to are unrelated; conversion requires reinterpret_cast,
C-style cast or function-style cast
It is because you are doing ..something.. -> SetInput(X). This X variable
must be a vtkDataSet and not a vtkImageData like you are doing.
3th and 4th Error:
When you have an error like this:
D:\opengl\visualization\sphere\sp.cpp(26) : error C2027: use of undefined
type 'vtkProperty'
It is because you didn't put an #include.
In this case add to your file -->> #include"vtkProperty.h"
Marisa
>From: vtkusers-request at vtk.org
>Reply-To: vtkusers at vtk.org
>To: vtkusers at vtk.org
>Subject: vtkusers digest, Vol 1 #1935 - 1 msg
>Date: Sun, 06 Jul 2003 07:52:38 -0400
>
>Send vtkusers mailing list submissions to
> vtkusers at vtk.org
>
>To subscribe or unsubscribe via the World Wide Web, visit
> http://www.vtk.org/mailman/listinfo/vtkusers
>or, via email, send a message with subject or body 'help' to
> vtkusers-request at vtk.org
>
>You can reach the person managing the list at
> vtkusers-admin at vtk.org
>
>When replying, please edit your Subject line so it is more specific
>than "Re: Contents of vtkusers digest..."
>
>
>Today's Topics:
>
> 1. Help: Problem compiling example code (Lina)
>
>--__--__--
>
>Message: 1
>Date: Sat, 5 Jul 2003 08:29:52 -0700 (PDT)
>From: Lina <fazeleap at yahoo.com>
>To: vtkusers at vtk.org
>Subject: [vtkusers] Help: Problem compiling example code
>
>--0-1202778316-1057418992=:34334
>Content-Type: text/plain; charset=us-ascii
>
>Hi all,
>I'm a newbie at this. When compiling the example code available on the vtk
>website for visualizing a quadric function, I get the following errors.
>Compiling...
>Quadric.cpp
>G:\wolken\vtk\Quadric\Quadric.cpp(26) : error C2664: 'SetInput' : cannot
>convert parameter 1 from 'class vtkImageData *' to 'class vtkDataSet *'
> Types pointed to are unrelated; conversion requires
>reinterpret_cast, C-style cast or function-style cast
>G:\wolken\vtk\Quadric\Quadric.cpp(42) : error C2664: 'SetInput' : cannot
>convert parameter 1 from 'class vtkImageData *' to 'class vtkDataSet *'
> Types pointed to are unrelated; conversion requires
>reinterpret_cast, C-style cast or function-style cast
>G:\wolken\vtk\Quadric\Quadric.cpp(51) : error C2027: use of undefined type
>'vtkProperty'
> g:\program files\vtk42\include\vtk\vtkactor.h(42) : see
>declaration of 'vtkProperty'
>G:\wolken\vtk\Quadric\Quadric.cpp(51) : error C2227: left of '->SetColor'
>must point to class/struct/union
>
>Could somebody please help me with this?
>Thanks!
>
>
>---------------------------------
>Do you Yahoo!?
>SBC Yahoo! DSL - Now only $29.95 per month!
>--0-1202778316-1057418992=:34334
>Content-Type: text/html; charset=us-ascii
>
><DIV>Hi all,</DIV>
><DIV>I'm a newbie at this. When compiling the example code available on the
>vtk website for visualizing a quadric function, I get the following errors.
></DIV>
><DIV>Compiling...<BR>Quadric.cpp<BR>G:\wolken\vtk\Quadric\Quadric.cpp(26) :
>error C2664: 'SetInput' : cannot convert parameter 1 from 'class
>vtkImageData *' to 'class vtkDataSet
>*'<BR> Types pointed to are
>unrelated; conversion requires reinterpret_cast, C-style cast or
>function-style cast<BR>G:\wolken\vtk\Quadric\Quadric.cpp(42) : error C2664:
>'SetInput' : cannot convert parameter 1 from 'class vtkImageData *' to
>'class vtkDataSet *'<BR> Types
>pointed to are unrelated; conversion requires reinterpret_cast, C-style
>cast or function-style cast<BR>G:\wolken\vtk\Quadric\Quadric.cpp(51) :
>error C2027: use of undefined type
>'vtkProperty'<BR> g:\program
>files\vtk42\include\vtk\vtkactor.h(42) : see declaration of
>'vtkProperty'<BR>G:\wolken\vtk\Quadric\Quadric.cpp(51) : error C2227: left
>of '->SetColor' must point to class/struct/union</DIV>
><DIV> </DIV>
><DIV>Could somebody please help me with this?</DIV>
><DIV>Thanks!</DIV><p><hr SIZE=1>
>Do you Yahoo!?<br>
><a
>href="http://pa.yahoo.com/*http://rd.yahoo.com/evt=1207/*http://promo.yahoo.com/sbc/">SBC
>Yahoo! DSL</a> - Now only $29.95 per month!
>--0-1202778316-1057418992=:34334--
>
>
>--__--__--
>
>_______________________________________________
>vtkusers mailing list
>vtkusers at vtk.org
>http://www.vtk.org/mailman/listinfo/vtkusers
>
>
>End of vtkusers Digest
_________________________________________________________________
Tired of spam? Get advanced junk mail protection with MSN 8.
http://join.msn.com/?page=features/junkmail
More information about the vtkusers
mailing list