Fixed a bug where the DirectX capturer was incorrectly sending frames when there was no screen update.

This commit is contained in:
Jared Goodwin 2019-05-24 20:33:57 -07:00
parent aedce5c63b
commit cd17565e6a
2 changed files with 5 additions and 4 deletions

View File

@ -49,6 +49,8 @@ namespace Remotely_ScreenCast.Win.Capture
NeedsInit = false;
}
PreviousFrame = (Bitmap)CurrentFrame.Clone();
SharpDX.DXGI.Resource screenResource;
OutputDuplicateFrameInformation duplicateFrameInformation;
@ -91,11 +93,10 @@ namespace Remotely_ScreenCast.Win.Capture
bitmap.UnlockBits(mapDest);
device.ImmediateContext.UnmapSubresource(screenTexture, 0);
PreviousFrame = (Bitmap)CurrentFrame.Clone();
CurrentFrame = (Bitmap)bitmap.Clone();
screenResource.Dispose();
duplicatedOutput.ReleaseFrame();
CurrentFrame = (Bitmap)bitmap.Clone();
}
}
catch (SharpDXException e)

View File

@ -1 +1 @@
2019.05.22.0654
2019.05.24.2024