-
Notifications
You must be signed in to change notification settings - Fork 13
/
GamutCompress.xml
86 lines (81 loc) · 4.57 KB
/
GamutCompress.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
<ShaderNodePreset
SupportsAdaptiveDegradation="False"
SupportsAction="True"
SupportsTransition="False"
SupportsTimeline="True"
TimelineUseBack="False"
MatteProvider="False"
CommercialUsePermitted="True"
ShaderType="Matchbox"
SoftwareVersion="2017.0.0"
LimitInputsToTexture="True"
Version="0.5"
Description="GamutCompress
maps out of gamut colors back into gamut.
Threshold
Percentage of the gamut to affect. If threshold is 0.2,
the inner 80% of the gamut will be unaffected and
out of gamut values will be compressed into
the outer 20% of the gamut's color volume.
Max Distance
Per color component control to specify what distance will be
compressed to the gamut boundary. For example,
a value of cyan=0.2 will map colors with a distance of red=1.2 from
the achromatic axis to red=1.0, which is the gamut boundary.
Direction
Specifies whether to apply or inverse the gamut compression operation.
About
Written by Jed Smith with lots of help from the ACES Gamut Mapping Virtual Working Group.
https://github.com/jedypod
https://community.acescentral.com/t/rgb-saturation-gamut-mapping-approach-and-a-comp-vfx-perspective
https://community.acescentral.com/c/aces-development-acesnext/vwg-aces-gamut-mapping-working-group
"
Name="Gamut Compress">
<Shader Clear="0" GridSubdivision="1" OutputBitDepth="Output" Index="1">
<Uniform Index="0" NoInput="Error" Tooltip="" DisplayName="Front" Mipmaps="False" GL_TEXTURE_WRAP_T="GL_REPEAT" GL_TEXTURE_WRAP_S="GL_REPEAT" GL_TEXTURE_MAG_FILTER="GL_LINEAR" GL_TEXTURE_MIN_FILTER="GL_LINEAR" Type="sampler2D" Name="frontTex" InputType="Front">
</Uniform>
<Uniform Index="1" NoInput="White" Tooltip="" DisplayName="Selective" Mipmaps="False" GL_TEXTURE_WRAP_T="GL_REPEAT" GL_TEXTURE_WRAP_S="GL_REPEAT" GL_TEXTURE_MAG_FILTER="GL_LINEAR" GL_TEXTURE_MIN_FILTER="GL_LINEAR" Type="sampler2D" Name="selectiveTex" InputType="Selective">
</Uniform>
<Uniform Index="2" NoInput="White" Tooltip="" DisplayName="Matte" Mipmaps="False" GL_TEXTURE_WRAP_T="GL_REPEAT" GL_TEXTURE_WRAP_S="GL_REPEAT" GL_TEXTURE_MAG_FILTER="GL_LINEAR" GL_TEXTURE_MIN_FILTER="GL_LINEAR" Type="sampler2D" Name="matteTex" InputType="Matte">
</Uniform>
<Uniform Inc="0.01" Tooltip="Percentage of the outer gamut boundary to affect. A value of 0.2 means 20% of the outer gamut will be utilized for gamut compression."
Row="0" Col="0" Page="0" IconType="None" ValueType="Position" Type="vec3" ChannelName="threshold" DisplayName="threshold" Name="threshold">
<SubUniform ResDependent="None" Max="0.3" Min="0.0" Default="0.15">
</SubUniform>
<SubUniform ResDependent="None" Max="0.3" Min="0.0" Default="0.15">
</SubUniform>
<SubUniform ResDependent="None" Max="0.3" Min="0.0" Default="0.15">
</SubUniform>
</Uniform>
<Uniform ResDependent="None" Max="1.0" Min="0.0" Default="0.1" Inc="0.01"
Tooltip="Maximum distance beyond the green-blue gamut boundary to compress to the gamut boundary."
Row="0" Col="1" Page="0" Type="float" ChannelName="cyan" DisplayName="cyan" Name="cyan">
</Uniform>
<Uniform ResDependent="None" Max="1.0" Min="0.0" Default="0.2" Inc="0.01"
Tooltip="Maximum distance beyond the blue-red gamut boundary to compress to the gamut boundary."
Row="1" Col="1" Page="0" Type="float" ChannelName="magenta" DisplayName="magenta" Name="magenta">
</Uniform>
<Uniform ResDependent="None" Max="1.0" Min="0.0" Default="0.1" Inc="0.01"
Tooltip="Maximum distance beyond the red-green gamut boundary to compress to the gamut boundary."
Row="2" Col="1" Page="0" Type="float" ChannelName="yellow" DisplayName="yellow" Name="yellow">
</Uniform>
<Uniform Row="0" Col="2" Page="0" Default="0" Inc="1" Tooltip="" Type="int" ChannelName="working_colorspace" DisplayName="working space" Name="working_colorspace" ValueType="Popup">
<PopupEntry Title="ACEScg" Value="0">
</PopupEntry>
<PopupEntry Title="ACEScct" Value="1">
</PopupEntry>
<PopupEntry Title="ACEScc" Value="2">
</PopupEntry>
</Uniform>
<Uniform Row="1" Col="2" Page="0" Default="False" Tooltip="Reverse the direction of the operation from gamut compression to gamut expansion." Type="bool" ChannelName="invert" DisplayName="invert" Name="invert">
</Uniform>
</Shader>
<Page Name="Gamut Compress" Page="0">
<Col Name="Controls" Col="0" Page="0">
</Col>
<Col Name="Max Distance" Col="1" Page="0">
</Col>
<Col Name="Settings" Col="2" Page="0">
</Col>
</Page>
</ShaderNodePreset>