public override void RenderAllStrokes(RenderingContext context, IEnumerable <Identifier> excluded, Rect?clipRect)
        {
            lock (mDryStrokeLock)
            {
                foreach (var stroke in mDryStrokes)
                {
                    if (excluded == null || !excluded.Contains(stroke.Id))
                    {
                        // Draw current stroke
                        context.SetTarget(mRenderer.CurrentStrokeLayer);
                        context.ClearColor(Colors.Transparent);

                        DoRenderStroke(context, stroke, mRenderer.TranslationLayerPainted);

                        // Blend stroke to Scene Layer
                        context.SetTarget(mRenderer.SceneLayer);
                        context.DrawLayer(mRenderer.CurrentStrokeLayer, null, Ink.Rendering.BlendMode.SourceOver);

                        // Blend Current Stroke to All Strokes Layer
                        context.SetTarget(mRenderer.AllStrokesLayer);
                        context.DrawLayer(mRenderer.CurrentStrokeLayer, null, Ink.Rendering.BlendMode.SourceOver);
                    }
                }
            }
        }
Exemplo n.º 2
0
        private void BlendCurrentStrokesLayerToAllStrokesLayer()
        {
            RenderingContext.SetTarget(AllStrokesLayer);
            RenderingContext.DrawLayer(CurrentStrokeLayer, null, Ink.Rendering.BlendMode.SourceOver);

            RenderingContext.SetTarget(CurrentStrokeLayer);
            RenderingContext.ClearColor(Colors.Transparent);

            DirtyRectManager.Reset();
        }
Exemplo n.º 3
0
        public void RenderBackbuffer()
        {
            // Copy the scene to the backbuffer
            RenderingContext.SetTarget(BackBufferLayer);

            RenderingContext.DrawLayer(SceneLayer, null, Wacom.Ink.Rendering.BlendMode.Copy);

            if (StrokeHandler.IsSelecting && TranslationLayerPainted)
            {
                StrokeHandler.DrawTranslation(RenderingContext, TranslationLayer);
            }
        }
        public override void DrawTranslation(RenderingContext renderingContext, Layer translationLayer)
        {
            var manipulationTool = mSelectTool as VectorManipulationTool;

            renderingContext.DrawLayer(translationLayer, manipulationTool.SourceRect, manipulationTool.DestRect, Wacom.Ink.Rendering.BlendMode.SourceOver);
        }