<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40"><head><meta http-equiv=Content-Type content="text/html; charset=us-ascii"><meta name=Generator content="Microsoft Word 12 (filtered medium)"><style><!--
/* Font Definitions */
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:SimSun;
        panose-1:2 1 6 0 3 1 1 1 1 1;}
@font-face
        {font-family:NSimSun;
        panose-1:2 1 6 9 3 1 1 1 1 1;}
@font-face
        {font-family:NSimSun;
        panose-1:2 1 6 9 3 1 1 1 1 1;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle18
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.25in 1.0in 1.25in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]--></head><body lang=EN-US link=blue vlink=purple><div class=WordSection1><p class=MsoNormal><span style='color:#1F497D'>Below is the original email I posted for help on the vtkGraphAlgorithm. I did some more investigation on this issue and found the following problem. I hope someone can help me to solve this problem. <o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Here is the test. I copied the class vtkVertexDegree in VTK to my testing class vtkVertexDegreeTest. I compiled the vtkVertexDegreeTest class as a static lib and dynamic lib (.dll) respectively and called this class in my test code. Now you will see the issue. If I compiled the class as a static lib, everything was fine. However, if I compiled the class as a dynamic lib, the previously described error happened. I attached my testing code for your examination. In cmake configuration, there is a switch to compile the library as a static (unchecked) or dynamic (checked) lib. &nbsp;Again, my VTK version is 5.4.2.<o:p></o:p></span></p><p class=MsoNormal><span style='color:#1F497D'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal><span style='color:#1F497D'>Thank you very much for your help!<o:p></o:p></span></p><div><p class=MsoNormal><span style='color:#1F497D'>-Jinzhong<o:p></o:p></span></p></div><p class=MsoNormal><span style='color:#1F497D'><o:p>&nbsp;</o:p></span></p><div><div style='border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0in 0in 0in'><p class=MsoNormal><b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>From:</span></b><span style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> Yang, Jinzhong [mailto:jinzhong76@gmail.com] <br><b>Sent:</b> Tuesday, October 18, 2011 10:30 AM<br><b>To:</b> vtkusers@vtk.org<br><b>Subject:</b> Derive from vtkGraphAlgorithm<o:p></o:p></span></p></div></div><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Hi All,<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>I was trying to implement a class deriving from vtkGraphAlgorithm. I used the vtkBoostbreadthFirstSearch as the template for my implementation; however, I did not implement the FillInputPortInformaiton and FillOutputPortInformation. However, when I tested my code, I got the following error message:<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>ERROR: In ..\..\source\Filtering\vtkExecutive.cxx, line 757<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>vtkStreamingDemandDrivenPipeline (01965648): Algorithm vtkUndirectedGraphCPP(01963930) returned failure for request: vtkInformation (01965E08)<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; Debug: Off<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; Modified Time: 23<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; Reference Count: 1<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; Registered Events: (none)<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; Request: REQUEST_DATA_OBJECT<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; ALGORITHM_AFTER_FORWARD: 1<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'>&nbsp; FORWARD_DIRECTION: 0<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:NSimSun'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal>The following is the testing code to call my implemented class vtkUndirectedGraphCPP:<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:"Courier New"'>&nbsp; vtkUndirectedGraphCPP * cpp = vtkUndirectedGraphCPP::New();<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:"Courier New"'>&nbsp; cpp-&gt;SetInput(g);<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:"Courier New"'>&nbsp; cpp-&gt;SetOriginVertex(<span style='color:#FF8000'>0</span>);<o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span style='font-size:9.0pt;font-family:"Courier New"'>&nbsp; cpp-&gt;SetEdgeCostArrayName(<span style='color:#A31515'>&quot;weights&quot;</span>);<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:9.0pt;font-family:"Courier New"'>&nbsp; cpp-&gt;Update();<o:p></o:p></span></p><p class=MsoNormal><span style='font-size:9.0pt;font-family:"Courier New"'><o:p>&nbsp;</o:p></span></p><p class=MsoNormal>Here g is a vtkMutableUndirectedGraph. I did a little bit search and found that I should overwrite RequestDataObject instead of RequestData. This would be quite different from other implementations in vtk. Could anybody help to solve this problem? My VTK version is &nbsp;5.4.2.<o:p></o:p></p><p class=MsoNormal><o:p>&nbsp;</o:p></p><p class=MsoNormal>Thanks,<o:p></o:p></p><p class=MsoNormal>Jinzhong<o:p></o:p></p></div></body></html>