Difference between revisions of "ColorComponent Script"

235 bytes removed ,  07:26, 2 February 2014
m
]] where it shouldn't be
imported>CraftySentinel
m (changed param format.)
imported>CraftySentinel
m (]] where it shouldn't be)
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
__NOTOC__ __NOEDITSECTION__
__NOTOC__ __NOEDITSECTION__
'''Source:''' [[:Category:SKSE|SKSE]] 1.06.00
'''Extends:''' None
'''Extends:''' None


'''Flags:''' [[Flag Reference|Hidden]]
Script for the manipulation of Color Codes.


Script for the manipulation of Color Codes.


== Definition ==
== Definition ==
Line 15: Line 11:
== Global SKSE Member Functions==
== Global SKSE Member Functions==


{|class="wikitable" width =100%
:'''Int [[GetAlpha - ColorComponent|GetAlpha]](Int ''argb'')'''
!style="text-align:left;" width=25%|Function
:*Gets the Alpha component Value from the specified Alpha-Red-Green-Blue(ARGB) code.
!style="text-align:left;"|Description
|-
|[[GetAlpha - ColorComponent|Int '''GetAlpha'''(Int ''argb'')]]
||Gets the Alpha component Value from the specified Alpha-Red-Green-Blue(ARGB) code.
|-


|[[GetRed - ColorComponent|Int '''GetRed'''(Int ''argb'')]]
:'''Int [[GetRed - ColorComponent|GetRed]](Int ''argb'')'''
|Gets the Red component value from the specified ARGB color code.
:*Gets the Red component value from the specified ARGB color code.
|-


|[[GetGreen - ColorComponent|Int '''GetGreen'''(Int ''argb'')]]
:'''Int [[GetGreen - ColorComponent|GetGreen]](Int ''argb'')'''
|Gets the Green component value of the specified ARGB color code.
:*Gets the Green component value of the specified ARGB color code.
|-


|[[GetBlue - ColorComponent|Int '''GetBlue'''(Int ''argb'')]]
:'''Int [[GetBlue - ColorComponent|GetBlue]](Int ''argb'')'''
|Gets the Blue component value of the specified ARGB color code.
:*Gets the Blue component value of the specified ARGB color code.
|-


|[[GetHue - ColorComponent|Float '''GetHue'''(Int ''argb'')]]
:'''Float [[GetHue - ColorComponent|GetHue]](Int ''argb'')'''
||Gets the Hue value of the specified ARGB, ranging from 0.0 to 360.0.
:*Gets the Hue value of the specified ARGB, ranging from 0.0 to 360.0.
|-


|[[GetSaturation - ColorComponent|Float '''GetSaturation'''(Int ''argb'')]]
:'''Float [[GetSaturation - ColorComponent|GetSaturation]](Int ''argb'')'''
|Gets the Saturation value of the specified ARGB color code.
:*Gets the Saturation value of the specified ARGB color code.
|-


|[[GetValue - ColorComponent|Float '''GetValue'''(Int ''argb'')]]
:'''Float [[GetValue - ColorComponent|GetValue]](Int ''argb'')'''
|Gets the Value of the specified ARGB color code, Value is also known as Brightness or Luminosity.
:*Gets the Value of the specified ARGB color code, Value is also known as Brightness or Luminosity.
|-


|[[SetAlpha - ColorComponent|Int '''SetAlpha'''(Int ''argb'', Int ''a'')]]
:'''Int [[SetAlpha - ColorComponent|SetAlpha]](Int ''argb'', Int ''a'')'''
|Sets the Alpha component value of the specified ARGB color code to the specified amount.
:*Sets the Alpha component value of the specified ARGB color code to the specified amount.
|-


|[[SetRed - ColorComponent|Int '''SetRed'''(Int ''argb'', Int ''r'')]]
:'''Int [[SetRed - ColorComponent|SetRed]](Int ''argb'', Int ''r'')'''
|Sets the Red component value of the specified ARGB color code to the specified amount.
:*Sets the Red component value of the specified ARGB color code to the specified amount.
|-


|[[SetGreen - ColorComponent|Int '''SetGreen'''(Int ''argb'', Int ''g'')]]
:'''Int [[SetGreen - ColorComponent|SetGreen]](Int ''argb'', Int ''g'')'''
|Sets the Green component value of the specified ARGB color code to the specified amount.
:*Sets the Green component value of the specified ARGB color code to the specified amount.
|-


|[[SetBlue - ColorComponent|Int '''SetBlue'''(Int ''argb'', Int ''b'')]]
:'''Int [[SetBlue - ColorComponent|SetBlue]](Int ''argb'', Int ''b'')'''
|Sets the Blue component value of the specified ARGB color code to the specified amount.
:*Sets the Blue component value of the specified ARGB color code to the specified amount.
|-


|[[SetHue - ColorComponent|Int '''SetHue'''(Int ''argb'', Float ''h'')]]
:'''Int [[SetHue - ColorComponent|SetHue]](Int ''argb'', Float ''h'')'''
|Sets the Hue value of the specified ARGB color code to the specified value.
:*Sets the Hue value of the specified ARGB color code to the specified value.
|-


|[[SetSaturation - ColorComponent|Int '''SetSaturation'''(Int ''argb'', Float ''s'')]]
:'''Int [[SetSaturation - ColorComponent|SetSaturation]](Int ''argb'', Float ''s'')'''
|Sets the Saturation value of the specified ARGB color code to the specified value.
:*Sets the Saturation value of the specified ARGB color code to the specified value.
|-


|[[SetValue - ColorComponent|Int '''SetValue'''(Int ''argb'', Float ''v'')]]
:'''Int [[SetValue - ColorComponent|SetValue]](Int ''argb'', Float ''v'')'''
|Sets the Value (Brightness) of the specified ARGB color code to the specified value.
:*Sets the Value (Brightness) of the specified ARGB color code to the specified value.


|}


== Notes ==
== Notes ==
Line 82: Line 60:
*The get functions (Excluding '''GetAlpha''' since ColorForms do not contain a alpha channel) within this script are used by functions of the same name contained within [[ColorForm Script]], to access the individual color components of a [[ColorForm]]'s ARGB.
*The get functions (Excluding '''GetAlpha''' since ColorForms do not contain a alpha channel) within this script are used by functions of the same name contained within [[ColorForm Script]], to access the individual color components of a [[ColorForm]]'s ARGB.


*All ARGB color codes are Decimal conversions of Hex color codes. For example, a color code of 167777215 in Decimal is equivalent to #00FFFFFF in Hex (0 ,255, 255, 255 in ARGB values).
*All ARGB color codes are Decimal conversions of Hex color codes. For example, a color code of 16777215 in Decimal is equivalent to #00FFFFFF in Hex (0 ,255, 255, 255 in ARGB values).
 


==See Also ==
==See Also ==