Example #1
0
 protected void EnsureDevice()
 {
     if (this.Device == null)
     {
         this.Device = CompositionHelper.CreateDevice(this.DxgiContainer.DxgiDevice, this.DeviceVariant);
     }
 }
        private void CreateSurface()
        {
            var size = this.Options.Size;

            this.Surface = CompositionHelper.CreateSurface(this.Device, this.DeviceVariant, size.Width, size.Height,
                                                           this.Options.PixelFormat, this.Options.AlphaMode);
            this.SetContent(this.Surface);
        }
Example #3
0
 protected CompositorCore(int variant)
 {
     if (variant == -1)
     {
         variant = CompositionHelper.GetVariantForPlatform();
     }
     this.DeviceVariant             = variant;
     this.m_onDxgiDestroyedAction   = () => this.DestroyInternal(true);
     this.m_onDxgiInitializedAction = () => this.InitializeInternal(true);
 }
Example #4
0
 public void Commit()
 {
     CompositionHelper.Commit(this.Device, this.DeviceVariant);
 }