public override void Apply(RenderTargetI renderTarget) { #if SILVERLIGHT try { #endif var viewPort = new Microsoft.Xna.Framework.Graphics.Viewport() { X = Position.X, Y = renderTarget.Size.Height - Size.Height - Position.Y, Width = Size.Width, Height = Size.Height, MinDepth = 0, MaxDepth = 1 }; video.Device.Viewport = viewPort; #if SILVERLIGHT } catch {} #endif }
public override void Apply(RenderTargetI renderTarget) { video.context.SetViewport(Location.X, Location.Y, Size.Width, Size.Height); }