public void DownSample4(RenderTarget2D dst, RenderTarget2D src) { SetDefaultRenderStates(); using (new PixEvent("DownSample4")) { dst.SetViewport(); device.SetTargets(null, dst); device.PipelineState = factory[(int)ShaderFlags.DOWNSAMPLE_4]; device.VertexShaderResources[0] = src; device.PixelShaderResources[0] = src; device.PixelShaderSamplers[0] = SamplerState.LinearPointClamp; device.Draw(3, 0); } device.ResetStates(); }
public void DownSample4( RenderTarget2D dst, RenderTarget2D src ) { SetDefaultRenderStates(); using( new PixEvent("DownSample4") ) { dst.SetViewport(); rs.SetTargets( null, dst ); rs.PipelineState = factory[ (int)ShaderFlags.DOWNSAMPLE_4 ]; rs.VertexShaderResources[0] = src; rs.PixelShaderResources[0] = src; rs.PixelShaderSamplers[0] = SamplerState.LinearPointClamp; rs.Draw( 3, 0 ); } rs.ResetStates(); }