<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=koi8-r"><meta name=Generator content="Microsoft Word 14 (filtered medium)"><style><!--
/* Font Definitions */
@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;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:11.0pt;
        font-family:"Calibri","sans-serif";
        mso-fareast-language:EN-US;}
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;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle19
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.EmailStyle20
        {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:612.0pt 792.0pt;
        margin:2.0cm 42.5pt 2.0cm 3.0cm;}
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=RU link=blue vlink=purple><div class=WordSection1><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>H</span><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>ello! Please let you help me solve the problem.<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>We needš to combine two or more intersectedš shell surface type objects, implemented as vtkPolyDataAlgorithm objects, in a single bound surface with initial points andš cellsš of given objectsš but inner points (and cells) excluded.<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>To test the possible workaround I have created two sample successorsš ofš vtkSphereSource class [vtkSphereSourceNew ] withš reimplemented RequestData member function. The last generates its own points and cells.<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>These two objects of vtkSphereSourceNewš type are intersected in universe space.<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>I try to use vtkImplicitBoolean function to combine in one united outer surface with inner points and cells excluded.</span><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal style='text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif";mso-fareast-language:RU'>Please inform me whetherš vtkImplicitDataSet class was used properly?<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>The followingš test code will result in exception:</span><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'><o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkSphereSourceNew> sphere1 = vtkSmartPointer<vtkSphereSourceNew>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š sphere1->SetCenter(.9,0,0);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkImplicitDataSet* Imsphere1 = vtkImplicitDataSet::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š Imsphere2->SetDataSet(sphere1->GetOutput());<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkSphereSourceNew> sphere2 =vtkSmartPointer<vtkSphereSourceNew>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š sphere2->SetCenter(-.9,0,0);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkImplicitDataSet* Imsphere2 = vtkImplicitDataSet::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š Imsphere2->SetDataSet(sphere2->GetOutput());<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkImplicitBoolean> implicitBoolean =vtkSmartPointer<vtkImplicitBoolean>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š implicitBoolean->AddFunction(Imsphere1);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š implicitBoolean->AddFunction(Imsphere2);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š implicitBoolean->SetOperationTypeToUnion();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkSampleFunction> sample =ššš vtkSmartPointer<vtkSampleFunction>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š sample->SetSampleDimensions(10,10,10);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š sample->SetImplicitFunction(implicitBoolean);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š double value = 3.0;<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š double xmin = -value, xmax = value,<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>ššš ymin = -value, ymax = value,<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>ššš zmin = -value, zmax = value;<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š sample->SetModelBounds(xmin, xmax, ymin, ymax, zmin, zmax);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkContourFilter> contours =vtkSmartPointer<vtkContourFilter>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š contours->SetInputConnection(sample->GetOutputPort());<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š contours->GenerateValues(1, 1, 1);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkDataSetMapper> mapper = vtkSmartPointer<vtkDataSetMapper>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š mapper->SetInputConnection(contours->GetOutputPort());<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š mapper->Update();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š vtkSmartPointer<vtkActor> actor = vtkSmartPointer<vtkActor>::New();<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='color:#1F497D'>š actor->SetMapper(mapper);<o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif";color:#1F497D'><o:p> </o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=EN-US style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'> </span><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>Thank you for help!</span><span lang=EN-US><o:p></o:p></span></p><p class=MsoNormal style='mso-margin-top-alt:auto;mso-margin-bottom-alt:auto;text-autospace:none'><span lang=X-NONE style='font-size:10.0pt;font-family:"Tahoma","sans-serif"'>Faithfully yours, Andrey.</span><o:p></o:p></p><p class=MsoNormal><o:p> </o:p></p></div></body></html>