------------------------------------------------------------------------------
| 437 | |
| 438 | //------------------------------------------------------------------------------ |
| 439 | void vtkPiecewiseFunction::SortAndUpdateRange(bool updateSearchMethod) |
| 440 | { |
| 441 | // Use stable_sort to avoid shuffling of DuplicateScalars |
| 442 | std::stable_sort( |
| 443 | this->Internal->Nodes.begin(), this->Internal->Nodes.end(), this->Internal->CompareNodes); |
| 444 | bool modifiedInvoked = this->UpdateRange(); |
| 445 | // If range is updated, Modified() has been called, don't call it again. |
| 446 | if (!modifiedInvoked) |
| 447 | { |
| 448 | this->Modified(); |
| 449 | } |
| 450 | |
| 451 | if (updateSearchMethod) |
| 452 | { |
| 453 | this->UpdateSearchMethod(); |
| 454 | } |
| 455 | } |
| 456 | |
| 457 | //------------------------------------------------------------------------------ |
| 458 | bool vtkPiecewiseFunction::UpdateRange() |
no test coverage detected