function ColorGeometryInstanceAttribute(red, green, blue, alpha) {
  red = red ?? 1.0;
  green = green ?? 1.0;
  blue = blue ?? 1.0;
  alpha = alpha ?? 1.0;

  /**
   * The values for the attributes stored in a typed array.
   *
   * @type Uint8Array
   *
   * @default [255, 255, 255, 255]
   */
  this.value = new Uint8Array([
    Color.floatToByte(red),
    Color.floatToByte(green),
    Color.floatToByte(blue),
    Color.floatToByte(alpha),
  ]);
}
Value and type information for per-instance geometry color.

@alias ColorGeometryInstanceAttribute
@constructor

@param {number} [red=1.0] The red component.
@param {number} [green=1.0] The green component.
@param {number} [blue=1.0] The blue component.
@param {number} [alpha=1.0] The alpha component.


@example
const instance = new Cesium.GeometryInstance({
  geometry : Cesium.BoxGeometry.fromDimensions({
    dimensions : new Cesium.Cartesian3(1000000.0, 1000000.0, 500000.0)
  }),
  modelMatrix : Cesium.Matrix4.multiplyByTranslation(Cesium.Transforms.eastNorthUpToFixedFrame(
    Cesium.Cartesian3.fromDegrees(0.0, 0.0)), new Cesium.Cartesian3(0.0, 0.0, 1000000.0), new Cesium.Matrix4()),
  id : 'box',
  attributes : {
    color : new Cesium.ColorGeometryInstanceAttribute(red, green, blue, alpha)
  }
});

@see GeometryInstance
@see GeometryInstanceAttribute