fix stencil API
							parent
							
								
									00adec189c
								
							
						
					
					
						commit
						019afa91f5
					
				| 
						 | 
				
			
			@ -1 +1 @@
 | 
			
		|||
Subproject commit 4268db46161ec5ff924c8006a66aa59635d3ca50
 | 
			
		||||
Subproject commit 86cc5fa1422c8b79c436c4e4fc345114e9615dbb
 | 
			
		||||
| 
						 | 
				
			
			@ -154,11 +154,7 @@ namespace MoonWorks.Graphics
 | 
			
		|||
		public StencilOp PassOp;
 | 
			
		||||
		public StencilOp DepthFailOp;
 | 
			
		||||
		public CompareOp CompareOp;
 | 
			
		||||
		public uint CompareMask;
 | 
			
		||||
		public uint WriteMask;
 | 
			
		||||
		public uint Reference;
 | 
			
		||||
 | 
			
		||||
		// FIXME: can we do an explicit cast here?
 | 
			
		||||
		public Refresh.StencilOpState ToRefresh()
 | 
			
		||||
		{
 | 
			
		||||
			return new Refresh.StencilOpState
 | 
			
		||||
| 
						 | 
				
			
			@ -166,10 +162,7 @@ namespace MoonWorks.Graphics
 | 
			
		|||
				failOp = (Refresh.StencilOp) FailOp,
 | 
			
		||||
				passOp = (Refresh.StencilOp) PassOp,
 | 
			
		||||
				depthFailOp = (Refresh.StencilOp) DepthFailOp,
 | 
			
		||||
				compareOp = (Refresh.CompareOp) CompareOp,
 | 
			
		||||
				compareMask = CompareMask,
 | 
			
		||||
				writeMask = WriteMask,
 | 
			
		||||
				reference = Reference
 | 
			
		||||
				compareOp = (Refresh.CompareOp) CompareOp
 | 
			
		||||
			};
 | 
			
		||||
		}
 | 
			
		||||
	}
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -61,7 +61,11 @@ namespace MoonWorks.Graphics
 | 
			
		|||
			refreshGraphicsPipelineCreateInfo.blendConstants[2] = blendConstants.B;
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.blendConstants[3] = blendConstants.A;
 | 
			
		||||
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.stencilState = depthStencilState.StencilState.ToRefresh();
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.backStencilState = depthStencilState.BackStencilState.ToRefresh();
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.frontStencilState = depthStencilState.FrontStencilState.ToRefresh();
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.compareMask = depthStencilState.CompareMask;
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.writeMask = depthStencilState.WriteMask;
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.reference = depthStencilState.Reference;
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.compareOp = (Refresh.CompareOp) depthStencilState.CompareOp;
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.depthBoundsTestEnable = Conversions.BoolToByte(depthStencilState.DepthBoundsTestEnable);
 | 
			
		||||
			refreshGraphicsPipelineCreateInfo.depthStencilState.depthTestEnable = Conversions.BoolToByte(depthStencilState.DepthTestEnable);
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -11,9 +11,29 @@
 | 
			
		|||
		public bool DepthTestEnable;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// Describes the stencil operation.
 | 
			
		||||
		/// Describes the back-face stencil operation.
 | 
			
		||||
		/// </summary>
 | 
			
		||||
		public StencilOpState StencilState;
 | 
			
		||||
		public StencilOpState BackStencilState;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// Describes the front-face stencil operation.
 | 
			
		||||
		/// </summary>
 | 
			
		||||
		public StencilOpState FrontStencilState;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// The compare mask for stencil ops.
 | 
			
		||||
		/// </summary>
 | 
			
		||||
		public uint CompareMask;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// The write mask for stencil ops.
 | 
			
		||||
		/// </summary>
 | 
			
		||||
		public uint WriteMask;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// The stencil reference value.
 | 
			
		||||
		/// </summary>
 | 
			
		||||
		public uint Reference;
 | 
			
		||||
 | 
			
		||||
		/// <summary>
 | 
			
		||||
		/// The comparison operator used in the depth test.
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue