------------------------------------------------------------------------------
| 1058 | |
| 1059 | //------------------------------------------------------------------------------ |
| 1060 | void vtkTransformConcatenationStack::Push(vtkTransformConcatenation** concat) |
| 1061 | { |
| 1062 | // check stack size and grow if necessary |
| 1063 | if ((this->Stack - this->StackBottom) == this->StackSize) |
| 1064 | { |
| 1065 | int newStackSize = this->StackSize + 10; |
| 1066 | vtkTransformConcatenation** newStackBottom = new vtkTransformConcatenation*[newStackSize]; |
| 1067 | for (int i = 0; i < this->StackSize; i++) |
| 1068 | { |
| 1069 | newStackBottom[i] = this->StackBottom[i]; |
| 1070 | } |
| 1071 | delete[] this->StackBottom; |
| 1072 | this->StackBottom = newStackBottom; |
| 1073 | this->Stack = this->StackBottom + this->StackSize; |
| 1074 | this->StackSize = newStackSize; |
| 1075 | } |
| 1076 | |
| 1077 | // add item to the stack |
| 1078 | *this->Stack++ = *concat; |
| 1079 | |
| 1080 | // make a copy of that item the current item |
| 1081 | *concat = vtkTransformConcatenation::New(); |
| 1082 | (*concat)->DeepCopy(*(this->Stack - 1)); |
| 1083 | } |
| 1084 | |
| 1085 | //------------------------------------------------------------------------------ |
| 1086 | void vtkTransformConcatenationStack::DeepCopy(vtkTransformConcatenationStack* stack) |