Example #1
0
 public SRGBColour(ColourVector v, ByteColourComponent a)
 {
     _r = v.X;
     _g = v.Y;
     _b = v.Z;
     _a = a;
 }
Example #2
0
 public SRGBColour(ByteColourComponent r, ByteColourComponent g, ByteColourComponent b)
 {
     _r = r;
     _g = g;
     _b = b;
     _a = 255;
 }
Example #3
0
 public SRGBColour(ByteColourComponent r, ByteColourComponent g, ByteColourComponent b, ByteColourComponent a)
 {
     _r = r;
     _g = g;
     _b = b;
     _a = a;
 }
 public static UnitColourComponent ToUnitColour(this ByteColourComponent colourComp) => new UnitColourComponent((ColourPrimitive)colourComp.Value / (ColourPrimitive)ByteColourComponent.MaxValue);