示例#1
0
 public bool SetHWRender(ref retro_hw_render_callback hwRenderCallback)
 {
     if (_hwRenderer != null)
     {
         _hwRenderer.Destroy();
     }
     _glRenderContext = new DxTextureRenderContext(_device);
     _hwRenderer      = new GLHardwareRenderer(new DefaultRenderStrategy(), _glRenderContext);
     if (!_maxSize.IsEmpty)
     {
         _hwRenderer.SetDimensions(_maxSize.Width, _maxSize.Height);
     }
     return(_hwRenderer.SetHWRender(ref hwRenderCallback));
 }
示例#2
0
 public void Destroy()
 {
     _hwRenderer?.Destroy();
 }