Comments (14)
Do you have a minimal version of the code that reproduces this error? Otherwise, please collect a process dump and we can take a look.
from windows.ui.composition-win32-samples.
How to collect process dump with visual studio 2019?
from windows.ui.composition-win32-samples.
Once you see the unhandled exception message from your screenshot, go to Debug->Save Dump As. Please make sure you select "Minidump with Heap" when saving.
from windows.ui.composition-win32-samples.
OK, I will do it when it will happen again and upload here the dump.
Thanks
from windows.ui.composition-win32-samples.
It's been a few months since any activity, so I'm going to close this issue. Please reopen it with the crash dump if you see it again.
from windows.ui.composition-win32-samples.
I'm having the same problem. The dmp file is too big so I put it on google drive. Hope this will help.
from windows.ui.composition-win32-samples.
Hey @yjlintw, do you have the same symptoms as the above? Looking at the dump, this won't be a failfast and should throw an exception that you should be able to catch. Are you able to do so?
For some reason I'm not able to recognize the error code that triggers the exception, not sure if there's an issue with the dump or there's some other issue going on. Are you able to reliably reproduce this error? Can you share more about the scenario? Is it always with a certain window? All windows? Does it ever succeed?
We may need to get this reproducing locally to make progress.
from windows.ui.composition-win32-samples.
I don't have the try/catch statement initially. After adding that, I'm able to catch it.
It happens when I stop the capture and then start the capture again. It could happen to all windows, but it does not always happens. It happens every now and then.
My originally implementation was resizing the captured window -> stop capture -> start capture. I now resize the texture instead, which I think is a better implementation anyway, and it helps me get around this error.
from windows.ui.composition-win32-samples.
I'm sorry to revive this kinda old thread, but I see similar fatal exceptions when I try to capture child windows or dialogs. I haven't read anything in the offical reference about whether the API supports top-level windows only so I wonder if this is even possible.
@robmikh, could you please confirm/deny my assumption?
from windows.ui.composition-win32-samples.
That is to be expected. Thanks for a calling that out as far as the documentation goes, we should update it. We only support the capture of top level windows.
from windows.ui.composition-win32-samples.
Just an FYI - I was encountering this issue when trying to capture a window using DirectX 12, in the application settings - after changing to DirectX 11 (Legacy) I was able to capture the window without issue.
from windows.ui.composition-win32-samples.
Correct, the Direct3D11CaptureFramePool
does not support 11-on-12. We need to do some work to support Direct3D 12.
from windows.ui.composition-win32-samples.
interop_factory->CreateForWindow() always crash while begin to capture window zoom->settings, is there something wrong?
from windows.ui.composition-win32-samples.
I'm guessing it's because the window is a tool window. The general rule of thumb is that if it's in alt+tab, you should be able to capture it.
from windows.ui.composition-win32-samples.
Related Issues (20)
- Some samples use `WindowsRuntimeMarshal` class, that is no longer available in .NET 5+ HOT 4
- Cannot use IGraphicsCaptureItemInterop::CreateForWindow with electron apps HOT 6
- This repo is missing important files HOT 4
- How to capture Windows10/11 Virtual Desktop via Windows.Graphics.Capture ? HOT 2
- Accessing screen capture image bytes with MapFlags.DoNotWait for better CPU usage HOT 3
- Can I do successive captures on two different windows HOT 8
- ScreenCapture Sample - write capture stream to disk mp4? HOT 5
- Capture area of a monitor HOT 4
- Memory Leak? HOT 5
- BSODs on 4 separate Hard Drives HOT 3
- Multiple screen captures in a loop cause explorer.exe and native Windows app to lag? HOT 11
- Capture OnFrame Callback very slow on Win11 23H2 HOT 7
- access_denied in CreateForMonitor in some cases HOT 5
- Cannot catch errors in CreateCaptureItemForWindow HOT 3
- WGC CaptureFrame returns wrong SystemRelativeTime in window capture mode HOT 2
- Cursor may become invisible when recording some fullscreen games using WGC HOT 6
- Frame has issue after change window state (maximize from normal/ normal from maximize/ ...) HOT 1
- ScreenCaptureforHWND sample leaks handles leading to "Out of memory" crash HOT 1
- ScreenCaptureforHWND sample main thread hang HOT 2
- ScreenCaptureforHWND: How to get the byte data of the captured frame? HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from windows.ui.composition-win32-samples.