Hello all  in mailing list,<br><br>The develop tool of  my application are VC6.0 + vtk5.1. And I'd  appreciate any advice to help me to soleve the problem.<br><br>The state of mine is that when i use MC to reconstruct , and select one single contour value,  the number of image is 200(bmp: 329*354). of coucse , the app is sucessfully executing!<br>
However, i'd like to reconstuct multi-isosurface. In addition, i hope the app can control property of each isosurface(vtkactor*). So I use multi-pipeline to reconstruct,each actor has private pipeline, but the result is error when there are many contour values ,for example the number of contour values is 4 , the main code and relevant information as follows:<br>
<br>// the data set is bmp: 329*354*350<br><br>    std::vector<vtkMarchingCubes*> vskinExtractor;<br>    std::vector<vtkDecimatePro*> vdeci;//<br>    std::vector<vtkSmoothPolyDataFilter*> vsmoother;//<br>
    std::vector<vtkPolyDataNormals*> vskinNormal;//<br>    std::vector<vtkPolyDataMapper*> vskinMapper;//<br>    std::vector<vtkActor*> vskin;<br>    <br>//y is the number of the scalar value, here is 4<br>
    for (size_t numIndex = 0; numIndex < y; numIndex++)<br>    {<br>        vskinExtractor.push_back(vtkMarchingCubes::New());<br>        vskinExtractor[numIndex]->SetInputConnection(m_read->GetOutputPort());<br>
        vskinExtractor[numIndex]->SetValue(numIndex, vYuzhi[numIndex]);<br><br>        vdeci.push_back(vtkDecimatePro::New());<br>        vdeci[numIndex]->SetInputConnection(vskinExtractor[numIndex]->GetOutputPort());//<br>
        vdeci[numIndex]->SetTargetReduction(0.5);//<br>        vdeci[numIndex]->PreserveTopologyOn();//<br><br>        vsmoother.push_back(vtkSmoothPolyDataFilter::New());<br>        vsmoother[numIndex]->SetInputConnection(vdeci[numIndex]->GetOutputPort());//<br>
        vsmoother[numIndex]->SetNumberOfIterations(800);//Specify the number of iterations for Laplacian smoothing<br><br>        vskinNormal.push_back(vtkPolyDataNormals::New());<br>        vskinNormal[numIndex]->SetInputConnection(vsmoother[numIndex]->GetOutputPort());//<br>
        vskinNormal[numIndex]->SetFeatureAngle(60.0);//<br><br>        vskinMapper.push_back(vtkPolyDataMapper::New());<br>        vskinMapper[numIndex]->SetInputConnection(vskinNormal[numIndex]->GetOutputPort());<br>
        vskinMapper[numIndex]->ScalarVisibilityOff();<br>        <br>        vskin.push_back(vtkActor::New());<br>        vskin[numIndex]->SetMapper(vskinMapper[numIndex]);        <br>    }<br><br><br>After the app  executing  dozens of minutes, the vtkOutputWindow output error messages:<br>
Error:in c:\vtk5.0\vtk\common\vtkDataArrayTemplate.cxx line 255<br>vtkIdTypeArray(0x...):unable to allocate 62300005 elements of size 2<br><br>In my opinion,may be the reason  is that  data is too large or there are generating too many meshes while MC   extracting isosurface, but i do not know how to solve it!<br>
I alse lookup information in "VTK FAQ" in KitWare web, and the solution can't fit my problem. Thanks for any help!!<br clear="all"><br>