-
Notifications
You must be signed in to change notification settings - Fork 90
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
winrt::windows::Graphics::Capture::GraphicsCaptureSession.Close() hangs on Windows 10 #65
Comments
Unfortunately, it looks like the zip is corrupted. I'm unable to open it. |
Sorry and I will try to rezip and upload it again to the feeback. Thanks. |
@robmikh just attached another zip file to the feefback that is keep-surfacepro-dump-on-capture.zip. Hope that this time the file would be fine. |
@robmikh are you getting a chance to take a look at dump files. If you still face the issue to download my zip file, I can upload it to my google drive, then you can download the zip file from a google link, but I need your email address to give you access. |
Sorry, I took a look at your second zip earlier but I didn't have time to respond. It looks like the app is waiting on the service, but the service dump has nothing interesting in it. I'm guessing it's not the same instance, and the original instance had crashed. I don't have any guidance at the moment, this needs further investigation. With the holidays and a lack of leads it might be awhile before I can come back to this. |
@robmikh My team has a December release, so we need to fix this issue on December release. Could you point to some area, I can modify my application to avoid this kind of hanging? Thanks. |
@robmikh it has been a while. It's so close to my desktop app's Dec release deadline. Could you take a time to respond to my above question. Really appreciate your help to find a solution to avoid this kind of hanging. |
In a loop of capturing all open application windows' images, GraphicsCaptureSession.Close() occasionally hangs. Yesterday I was able to duplicate this issue and collected all dump files.
Below is the code flow:
App.cpp
winrt::GraphicsCaptureItem App::StartCaptureFromWindowHandle(HWND hwnd)
{
auto item = util::CreateCaptureItemForWindow(hwnd);
StartCaptureFromItem(item);
return item;
}
void App::StartCaptureFromItem(winrt::GraphicsCaptureItem item)
{
m_capture = std::make_unique(m_device, item, m_pixelFormat);
}
SimpleCapgture.cpp
void SimpleCapture::Close()
{
auto expected = false;
if (m_closed.compare_exchange_strong(expected, true))
{
m_session.Close(); ---- ***** Issue is here and it's hanging on Close() and never finish this Close() call
m_framePool.Close();
}
I have created this instance on the feeback and it's link is https://aka.ms/AAnlnr9. The attached zip file contains dump files for CaptureService, DWM.exe and my application iClicker Cloud's dmp and pdb files, and stack trace file.
@robmikh what could be a root cause to hanging on m_session.Close()? Please let me know if you need additional info.
The text was updated successfully, but these errors were encountered: