ProtoFlux:ColorX To Hex Code

From Resonite Wiki
Revision as of 22:19, 25 February 2024 by PJB (talk | contribs) (Created page with " {{#Invoke:ProtoFlux|GenerateUI |Name=Color XTo Hex Code |Category=Colors |Inputs= [ {"Name":"Color", "Type":"colorX"}, {"Name":"ShortForm", "Type":"bool"}, {"Name":"IncludeAlpha", "Type":"bool"}, {"Name":"Prefix", "Type":"String"} ] |Outputs= [ {"Name":"*", "Type":"String"} ] |}} Color To Hex Code converts a ColorX to a string [https://en.wikipedia.org/wiki/Web_colors hex color code] such as "#FFAABC". == Inputs == === Color (Color) ===...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Color XTo Hex Code
Color
*
ShortForm
IncludeAlpha
Prefix
Colors

Color To Hex Code converts a ColorX to a string hex color code such as "#FFAABC".

Inputs

Color (Color)

The color to convert. Color components are clamped to the range 0-1.

ShortForm (Bool)

If true, convert to a short form such as "#FAC" instead of "#FFAACC".

This is currently bugged and produces incorrect results.[1]

IncludeAlpha (Bool)

If true, include the alpha channel as the last component.

Prefix (String)

The string to prefix the color code with. Defaults to "#".

Outputs

* (String)

The resulting hex code.

See Also

References