Exemplo n.º 1
0
        protected override void DrawCore(RenderDrawContext context)
        {
            // Make sure we keep our uniform weights in synchronization with the number of taps
            if (tapWeights == null || tapWeights.Length != tapCount)
            {
                tapWeights = DoFUtil.GetUniformWeightBlurArray(tapCount);
            }

            if (!useOptimizedPath)
            {
                DrawCoreNaive(context);
            }
            else
            {
                DrawCoreOptimized(context);
            }
        }
Exemplo n.º 2
0
        protected override void DrawCore(RenderDrawContext context)
        {
            // Make sure we keep our uniform weights in synchronization with the number of taps
            if (tapWeights == null || tapWeights.Length != tapCount)
            {
                tapWeights = DoFUtil.GetUniformWeightBlurArray(tapCount);
                CalculateRhombiOffsets();
            }

            if (!useOptimizedPath)
            {
                DrawCoreNaive(context);
            }
            else
            {
                //TODO use MRT to speed-up the process
            }
        }