------------------------------------------------------------------------------
| 461 | |
| 462 | //------------------------------------------------------------------------------ |
| 463 | void vtkResliceImageViewer::SetColorWindow(double w) |
| 464 | { |
| 465 | double rmin = this->GetColorLevel() - 0.5 * fabs(w); |
| 466 | double rmax = rmin + fabs(w); |
| 467 | this->GetLookupTable()->SetRange(rmin, rmax); |
| 468 | |
| 469 | this->WindowLevel->SetWindow(w); |
| 470 | if (vtkResliceCursorRepresentation* rep = vtkResliceCursorRepresentation::SafeDownCast( |
| 471 | this->ResliceCursorWidget->GetRepresentation())) |
| 472 | { |
| 473 | rep->SetWindowLevel(w, rep->GetLevel(), 1); |
| 474 | } |
| 475 | } |
| 476 | |
| 477 | //------------------------------------------------------------------------------ |
| 478 | void vtkResliceImageViewer::SetColorLevel(double w) |
no test coverage detected