<html><head></head><body><div style="font-family: Verdana;font-size: 12.0px;"><div>Hello all,</div>
<div> </div>
<div>I want to add specific color to part of the surface of a volume data. For that I first use vtkExtractVOI to get the part I want, then get the surface by calling vtkMarchingCubes. Now, if I try then to addScalars to its Output I can't.</div>
<div> </div>
<div>Here is the code:</div>
<div> </div>
<div>Instantiate(colors,vtkUnsignedCharArray); ...</div>
<div>Instantiate(colorLookupTable, vtkLookupTable); ...</div>
<div> </div>
<div>
<div> Instantiate(brainsection, vtkExtractVOI);<br/>
brainsection->SetInput(imageData);<br/>
brainsection->SetVOI(minIJK[0],maxIJK[0],minIJK[1],maxIJK[1], minIJK[2],maxIJK[2]);<br/>
brainsection->Update();</div>
<div> </div>
<div> Instantiate( brainsectionMC, vtkMarchingCubes );<br/>
brainsectionMC->SetValue(0,1);<br/>
brainsectionMC->SetInput( brainsection->GetOutput() );<br/>
brainsectionMC->Update();</div>
<div><br/>
Instantiate(brainsectionLocator, vtkPointLocator);<br/>
brainsectionLocator->SetDataSet(brainsectionMC->GetOutput());<br/>
brainsectionLocator->BuildLocator();</div>
<div> brainsectionMC->GetOutput()->GetPointData(); // And here I would like to call ->SetScalars(colors); but I get the error:<br/>
"error C2027: use of undefined type 'vtkPointData'". But even I copy this pointData to some new Instance of vtkPointData I get the same error.</div>
<div> </div>
<div>Does anyone know why or how I should do this?</div>
<div>Thanks,</div>
<div>Susi</div>
<div> </div>
</div>
<div> </div></div></body></html>