Medical Imaging Interaction Toolkit  2026.06.00
Medical Imaging Interaction Toolkit
mitkColorSequenceCycleH.h
Go to the documentation of this file.
1 /*============================================================================
2 
3 The Medical Imaging Interaction Toolkit (MITK)
4 
5 Copyright (c) German Cancer Research Center (DKFZ)
6 All rights reserved.
7 
8 Use of this source code is governed by a 3-clause BSD license that can be
9 found in the LICENSE file.
10 
11 ============================================================================*/
12 #ifndef mitkColorSequenceCycleH_h
13 #define mitkColorSequenceCycleH_h
14 
16 #include <mitkColorSequence.h>
17 
18 namespace mitk
19 {
33  {
34  public:
37 
40 
46  Color GetNextColor() override;
47 
51  void GoToBegin() override;
52 
64  virtual void ChangeHueValueByCycleSteps(int steps);
65 
73  virtual void ChangeHueValueByAbsoluteNumber(float number);
74 
83  virtual void SetColorCycle(unsigned short cycle);
84 
85  protected:
86  float color_h; // current hue (0 .. 360)
87  float color_s; // current saturation (0 .. 1)
88  float color_v; // current value (0 .. 1)
89 
90  unsigned short color_cycle;
91  };
92 }
93 
94 #endif
#define MITKDATATYPESEXT_EXPORT
Generates ~36 distinguishable colors by cycling through HSV space.
virtual void ChangeHueValueByCycleSteps(int steps)
Advance the hue by a given number of cycle steps.
Color GetNextColor() override
Return the next color in the HSV cycle.
ColorSequenceCycleH()
Construct and initialize to the first color (red, H=0).
virtual void ChangeHueValueByAbsoluteNumber(float number)
Set the hue to an absolute value.
virtual void SetColorCycle(unsigned short cycle)
Set the color cycle index (0–5).
void GoToBegin() override
Rewind to the first color in the sequence.
~ColorSequenceCycleH() override
Destructor.
Abstract interface for generating a sequence of distinguishable colors.
Find image slices visible on a given plane.
itk::RGBPixel< float > Color
Standard RGB color typedef using float components.