Esempio n. 1
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0.0 - 360.0)</param>
 /// <param name="S">Saturation (0.0 - 1.0)</param>
 public ColorHSx(RGBSpaceName Space, double H, double S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp         = this.Space.ReferenceWhite;
     this.H     = H;
     this.S     = S;
 }
Esempio n. 2
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0 - 255)</param>
 /// <param name="S">Saturation (0 - 255)</param>
 public BColorHSx(RGBSpaceName Space, byte H, byte S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp         = this.Space.ReferenceWhite.Name;
     this.H     = H;
     this.S     = S;
 }
Esempio n. 3
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0.0 - 360.0)</param>
 /// <param name="S">Saturation (0 - 65535)</param>
 public UColorHSx(RGBSpaceName Space, ushort H, ushort S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp         = this.Space.ReferenceWhite.Name;
     this.H     = H;
     this.S     = S;
 }
Esempio n. 4
0
 /// <summary>
 /// Creates a new instance of a YCbCr Color
 /// </summary>
 /// <param name="Y">Luma-value (0 to 255)</param>
 /// <param name="Cb">Blue-Yellow Chrominance-value (0 to 255)</param>
 /// <param name="Cr">Red-Green Chrominance-value (0 to 255)</param>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="BaseSpace">The colorspace this color is based on</param>
 public BColorYCbCr(YCbCrSpaceName Space, RGBSpaceName BaseSpace, byte Y, byte Cb, byte Cr)
     : base()
 {
     this.Y         = Y;
     this.Cb        = Cb;
     this.Cr        = Cr;
     this.Space     = YCbCrColorspace.GetColorspace(Space);
     this.BaseSpace = RGBColorspace.GetColorspace(BaseSpace);
     wp             = this.Space.ReferenceWhite.Name;
 }
Esempio n. 5
0
 /// <summary>
 /// Creates a new instance of a RGB Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="R">The red value (0 - 255)</param>
 /// <param name="G">The green value (0 - 255)</param>
 /// <param name="B">The blue value (0 - 255)</param>
 /// <param name="IsLinear">States if the given values are linear or not</param>
 public BColorRGB(RGBSpaceName Space, byte R, byte G, byte B, bool IsLinear)
     : base()
 {
     this.Space    = RGBColorspace.GetColorspace(Space);
     wp            = this.Space.ReferenceWhite.Name;
     this.R        = R;
     this.G        = G;
     this.B        = B;
     this.IsLinear = IsLinear;
 }
Esempio n. 6
0
 /// <summary>
 /// Creates a new instance of a RGB Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="R">The red value (0 - 65535)</param>
 /// <param name="G">The green value (0 - 65535)</param>
 /// <param name="B">The blue value (0 - 65535)</param>
 /// <param name="IsLinear">States if the given values are linear or not</param>
 public UColorRGB(RGBSpaceName Space, ushort R, ushort G, ushort B, bool IsLinear)
     : base()
 {
     this.Space    = RGBColorspace.GetColorspace(Space);
     wp            = this.Space.ReferenceWhite.Name;
     this.R        = R;
     this.G        = G;
     this.B        = B;
     this.IsLinear = IsLinear;
 }
Esempio n. 7
0
 private void ColorspaceToDroDo_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (IsInit)
     {
         if (ColorspaceToDroDo.SelectedIndex == (int)RGBSpaceName.ICC)
         {
             if ((ColorModel)ColorToDroDo.SelectedIndex == ColorModel.YCbCr)
             {
                 ColorspaceToDroDo.SelectedIndex = PrevToSpace;
             }
             else
             {
                 LoadICC(false, true);
             }
         }
         else
         {
             RefWhiteToDroDo.SelectedIndex = (int)RGBColorspace.GetColorspace((RGBSpaceName)ColorspaceToDroDo.SelectedIndex).ReferenceWhite.Name;
         }
         PrevToSpace = ColorspaceToDroDo.SelectedIndex;
     }
 }
Esempio n. 8
0
 /// <summary>
 /// Creates a new instance of a YCbCr Color
 /// </summary>
 /// <param name="Y">Luma-value (0.0 - 1.0)</param>
 /// <param name="Cb">Blue-Yellow Chrominance-value (0.0 - 1.0)</param>
 /// <param name="Cr">Red-Green Chrominance-value (0.0 - 1.0)</param>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="BaseSpace">The colorspace this color is based on</param>
 public ColorYCbCr(YCbCrSpaceName Space, RGBSpaceName BaseSpace, double Y, double Cb, double Cr)
     : base()
 {
     this.Y = Y;
     this.Cb = Cb;
     this.Cr = Cr;
     this.Space = YCbCrColorspace.GetColorspace(Space);
     this.BaseSpace = RGBColorspace.GetColorspace(BaseSpace);
     wp = this.Space.ReferenceWhite;
 }
Esempio n. 9
0
 /// <summary>
 /// Creates a new instance of a RGB Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="R">The red value (0.0 - 1.0)</param>
 /// <param name="G">The green value (0.0 - 1.0)</param>
 /// <param name="B">The blue value (0.0 - 1.0)</param>
 /// <param name="IsLinear">States if the given values are linear or not</param>
 public ColorRGB(RGBSpaceName Space, double R, double G, double B, bool IsLinear)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp = this.Space.ReferenceWhite;
     this.R = R;
     this.G = G;
     this.B = B;
     this.IsLinear = IsLinear;
 }
Esempio n. 10
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0.0 - 360.0)</param>
 /// <param name="S">Saturation (0.0 - 1.0)</param>
 public ColorHSx(RGBSpaceName Space, double H, double S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp = this.Space.ReferenceWhite;
     this.H = H;
     this.S = S;
 }
Esempio n. 11
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0 - 255)</param>
 /// <param name="S">Saturation (0 - 255)</param>
 public BColorHSx(RGBSpaceName Space, byte H, byte S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp = this.Space.ReferenceWhite.Name;
     this.H = H;
     this.S = S;
 }
Esempio n. 12
0
 /// <summary>
 /// Creates a new instance of a YCbCr Color
 /// </summary>
 /// <param name="Y">Luma-value (0 - 65535)</param>
 /// <param name="Cb">Blue-Yellow Chrominance-value (0 - 65535)</param>
 /// <param name="Cr">Red-Green Chrominance-value (0 - 65535)</param>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="BaseSpace">The colorspace this color is based on</param>
 public UColorYCbCr(YCbCrSpaceName Space, RGBSpaceName BaseSpace, ushort Y, ushort Cb, ushort Cr)
     : base()
 {
     this.Y = Y;
     this.Cb = Cb;
     this.Cr = Cr;
     this.Space = YCbCrColorspace.GetColorspace(Space);
     this.BaseSpace = RGBColorspace.GetColorspace(BaseSpace);
     wp = this.Space.ReferenceWhite.Name;
 }
Esempio n. 13
0
 /// <summary>
 /// Creates a new instance of a RGB Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="R">The red value (0 - 65535)</param>
 /// <param name="G">The green value (0 - 65535)</param>
 /// <param name="B">The blue value (0 - 65535)</param>
 /// <param name="IsLinear">States if the given values are linear or not</param>
 public UColorRGB(RGBSpaceName Space, ushort R, ushort G, ushort B, bool IsLinear)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp = this.Space.ReferenceWhite.Name;
     this.R = R;
     this.G = G;
     this.B = B;
     this.IsLinear = IsLinear;
 }
Esempio n. 14
0
 /// <summary>
 /// Creates a new instance of a HSx Color
 /// </summary>
 /// <param name="Space">The colorspace this color is in</param>
 /// <param name="H">Hue (0.0 - 360.0)</param>
 /// <param name="S">Saturation (0 - 65535)</param>
 public UColorHSx(RGBSpaceName Space, ushort H, ushort S)
     : base()
 {
     this.Space = RGBColorspace.GetColorspace(Space);
     wp = this.Space.ReferenceWhite.Name;
     this.H = H;
     this.S = S;
 }