Пример #1
0
        internal sealed override void Begin()
        {
            RC.BeginProfilingBlock("gbuffer pass");

            base.Begin();

            RC.BindGBufferForWrite(GBuffer);

            RC.SetDS(MyDepthStencilState.DepthTestWrite);
        }
        internal static void Draw()
        {
            RC.BindGBufferForWrite(MyGBuffer.Main, DepthStencilAccess.ReadWrite);
            RC.SetupScreenViewport();
            RC.DeviceContext.InputAssembler.PrimitiveTopology = PrimitiveTopology.TriangleList;
            RC.SetVB(0, m_VB.Buffer, m_VB.Stride);
            RC.SetIL(m_il);

            RC.SetRS(MyRender11.m_nocullRasterizerState);
            RC.SetDS(MyDepthStencilState.StereoStereoStencilMask, MyDepthStencilState.GetStereoMask());

            RC.SetVS(m_vs);
            RC.SetPS(m_ps);

            RC.DeviceContext.Draw(m_VBdata.Length, 0);
        }
Пример #3
0
        internal sealed override void Begin()
        {
            RC.BeginProfilingBlock("GBuffer pass");

            base.Begin();

            RC.BindGBufferForWrite(GBuffer);

            if ((!MyStereoRender.Enable) && (!MyStereoRender.EnableUsingStencilMask))
            {
                RC.SetDS(MyDepthStencilState.DepthTestWrite);
            }
            else
            {
                RC.SetDS(MyDepthStencilState.StereoDepthTestWrite);
            }
        }
Пример #4
0
        internal sealed override void Begin()
        {
            base.Begin();

            Context.InputAssembler.PrimitiveTopology = PrimitiveTopology.PointList;
            Context.InputAssembler.InputLayout       = m_inputLayout;

            RC.SetCB(MyCommon.FOLIAGE_SLOT, MyCommon.MaterialFoliageTableConstants);

            RC.SetRS(MyRender11.m_nocullRasterizerState);

            RC.SetVS(m_VS);
            RC.SetIL(m_inputLayout);

            RC.BindGBufferForWrite(MyGBuffer.Main);

            RC.SetDS(MyDepthStencilState.DepthTestWrite);
        }
        internal override void Begin()
        {
            base.Begin();

            RC.BeginProfilingBlock("Foliage pass");

            Context.InputAssembler.PrimitiveTopology = PrimitiveTopology.PointList;
            Context.InputAssembler.InputLayout       = m_inputLayout;

            RC.SetCB(MyCommon.FOLIAGE_SLOT, MyCommon.MaterialFoliageTableConstants);

            RC.SetRS(MyRender11.m_nocullRasterizerState);

            RC.SetVS(m_VS);
            RC.SetIL(m_inputLayout);

            RC.BindGBufferForWrite(MyGBuffer.Main);

            RC.SetDS(MyDepthStencilState.WriteDepthAndStencil, GrassStencilMask);
        }