返回 RGB 颜色中红绿蓝(Red,Green,Blue)颜色值的数组.
#Include <Color.au3>
_ColorGetRGB($nColor)
| $nColor | RGB 颜色值(0x00RRGGBB). |
| 成功: | 返回颜色成分范围值(0-255)的数组: |
| [0] 红颜色成分值 | |
| [1] 绿颜色成分值 | |
| [2] 蓝颜色成分值 | |
| 失败: | 设置 @error 为 1 |
#include <Color.au3>
Local $nColor = 0x8090ff
Local $aColor = _ColorGetRGB($nColor)
MsgBox(4096, "AutoIt", "Color=" & Hex($nColor) & @CRLF & " Red=" & Hex($aColor[0], 2) & " Blue=" & Hex($aColor[1], 2) & " Green=" & Hex($aColor[2], 2))