@@ -94,6 +94,51 @@ <h2>纹理结合操作</h2>
9494 [page:Constant MixOperation] 使用反射率来混和两种颜色。uses reflectivity to blend between the two colors.< br />
9595 [page:Constant AddOperation] 用于对两种颜色进行相加。</ p >
9696
97+ < h2 > Stencil Functions</ h2 >
98+ < code >
99+ THREE.NeverStencilFunc
100+ THREE.LessStencilFunc
101+ THREE.EqualStencilFunc
102+ THREE.LessEqualStencilFunc
103+ THREE.GreaterStencilFunc
104+ THREE.NotEqualStencilFunc
105+ THREE.GreaterEqualStencilFunc
106+ THREE.AlwaysStencilFunc
107+ </ code >
108+ < p >
109+ Which stencil function the material uses to determine whether or not to perform a stencil operation.< br />
110+ [page:Materials NeverStencilFunc] will never return true.< br />
111+ [page:Materials LessStencilFunc] will return true if the stencil reference value is less than the current stencil value.< br />
112+ [page:Materials EqualStencilFunc] will return true if the stencil reference value is equal to the current stencil value.< br />
113+ [page:Materials LessEqualStencilFunc] will return true if the stencil reference value is less than or equal to the current stencil value.< br />
114+ [page:Materials GreaterStencilFunc] will return true if the stencil reference value is greater than the current stencil value.< br />
115+ [page:Materials NotEqualStencilFunc] will return true if the stencil reference value is not equal to the current stencil value.< br />
116+ [page:Materials GreaterEqualStencilFunc] will return true if the stencil reference value is greater than or equal to the current stencil value.< br />
117+ [page:Materials AlwaysStencilFunc] will always return true.< br />
118+ </ p >
119+
120+ < h2 > Stencil Operations</ h2 >
121+ < code >
122+ THREE.ZeroStencilOp
123+ THREE.KeepStencilOp
124+ THREE.ReplaceStencilOp
125+ THREE.IncrementStencilOp
126+ THREE.DecrementStencilOp
127+ THREE.IncrementWrapStencilOp
128+ THREE.DecrementWrapStencilOp
129+ THREE.InvertStencilOp
130+ </ code >
131+ < p >
132+ Which stencil operation the material will perform on the stencil buffer pixel if the provided stencil function passes.< br />
133+ [page:Materials ZeroStencilOp] will set the stencil value to 0.< br />
134+ [page:Materials KeepStencilOp] will not change the current stencil value.< br />
135+ [page:Materials ReplaceStencilOp] will replace the stencil value with the specified stencil reference value.< br />
136+ [page:Materials IncrementStencilOp] will increment the current stencil value by 1.< br />
137+ [page:Materials DecrementStencilOp] will decrement the current stencil value by 1.< br />
138+ [page:Materials IncrementWrapStencilOp] will increment the current stencil value by 1. If the value increments past 255 it will be set to 0.< br />
139+ [page:Materials DecrementWrapStencilOp] will increment the current stencil value by 1. If the value decrements below 0 it will be set to 255.< br />
140+ [page:Materials InvertStencilOp] will perform a bitwise iversion of the current stencil value.< br />
141+ </ p >
97142
98143 < h2 > 源代码</ h2 >
99144
0 commit comments