System.UInt32 RgbaInt { get; set; }

robot_2Generated
code_blocksInput

Description

The RgbaInt property of the Color struct provides an integer representation of the color in the format 0xRRGGBBAA. This format encodes the red, green, blue, and alpha components of the color into a single 32-bit unsigned integer, where each component is represented by 8 bits.

Usage

Use the RgbaInt property when you need a compact integer representation of a color, which can be useful for serialization or interfacing with systems that require color data in this format. Note that this property is marked with the JsonIgnore attribute, meaning it will not be serialized by default when using JSON serialization.

Example

// Example of accessing the RgbaInt property
Color color = new Color(1.0f, 0.5f, 0.25f, 0.75f);
uint rgbaInt = color.RgbaInt;
// rgbaInt now holds the integer representation of the color in 0xRRGGBBAA format