Esempio n. 1
0
        protected override void OnEnable()
        {
            base.OnEnable();
            switch (motionVectorState)
            {
            case MotionVectorState.Static:
                drawFunction = () => PipelineFunction.DrawNoMotionVectors(ref buffers, proceduralMat);
                break;

            case MotionVectorState.DynamicWithMotionVector:
                drawFunction = () =>
                {
                    PipelineFunction.SetLastFrameMatrix(ref buffers, ref lastVPMatrix);
                    //Add Movement Operations here
                    PipelineFunction.Draw(ref buffers, proceduralMat);
                };
                break;

            case MotionVectorState.DynamicWithoutMotionVector:
                //Add Movement Operations here
                drawFunction = () => PipelineFunction.DrawNoMotionVectors(ref buffers, proceduralMat);
                break;
            }
        }
Esempio n. 2
0
 public override void OnPreRenderEvent()
 {
     PipelineFunction.SetCullingBuffer(ref buffers);
     PipelineFunction.RunCulling(ref viewMatrix, ref projMatrix, ref rtProjMatrix, ref buffers);
     drawFunction();
 }
Esempio n. 3
0
 private void OnDestroy()
 {
     PipelineFunction.Dispose(ref buffers);
 }
Esempio n. 4
0
 private void Awake()
 {
     PipelineFunction.InitBuffers(ref buffers, allExtents, localToWorldMatrices, mesh);
 }