<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Verdana
}
</style>
</head>
<body class='hmmessage'>There is probably something I did not understand in the management of vtkCellArray, despite I looked at the examples.<br>My code is below:<br><br> printf("Before:\n");<br> int npts, *sp;<br> for (int st=0 ; st<this->outputLines->GetNumberOfCells() ; st++) {<br> this->outputLines->GetCell(st, npts, sp);<br> printf("st=%d npts=%d\n", st, npts);<br> }<br> this->outputLines->InsertNextCell(3);<br> this->outputLines->InsertCellPoint(4);<br> this->outputLines->InsertCellPoint(5);<br> this->outputLines->InsertCellPoint(7);<br> printf("After:\n");<br> for (int st=0 ; st<this->outputLines->GetNumberOfCells() ; st++) {<br> this->outputLines->GetCell(st, npts, sp);<br> printf("st=%d npts=%d\n", st, npts);<br> }<br><br>And the output here:<br><br>Before:<br>st=0 npts=98<br>After:<br>st=0 npts=98<br>st=1 npts=0<br><br>which means that my insertion has failed.<br>So where do I make a mistake?<br><br /><hr />Un avatar à votre image ? <a href='http://www.ilovemessenger.fr/minimize-me' target='_new'>Créez votre mini-moi !</a></body>
</html>