I was experimenting with desktopduplication api sample code and it was mentioned here that
even full screen DirectX applications can be duplicated.
Also here it is mentioned that
The following components of the operating system can generate the desktop image:
The DWM by composing the desktop image
A full-screen DirectX or OpenGL application
An application by switching to a separate desktop, for example, the secure desktop that is used to display the login screen
However when I tested the sample code with multiple monitors provided here, it worked fine for other applications running on desktop but when I started a fullscreen directx application, the running applications in the background are pushed onto the secondary monitor and only the secondary monitor is captured in the duplicated window.
What might be the reason for this? I ran the exact sample code provided by MSDN. Is there something more I need to do in order to capture DirectX fullscreen games using DesktopDuplication API
Related
So I am trying to figure out how get a video feed (or screenshot feed if I must) of the Desktop using OpenGL in Windows and display that in a 3D environment. I plan to integrate this with ARToolkit to make essentially a virtual screen. The only issue is that I have tried manually getting the pixels in OpenGl, but I have been unable to properly display them in a 3D environment?
I apologize in advance that I do not have minimum runnable code, but due to all the dependencies and whatnot trying to get an ARToolkit code running would be far from minimal. How would I capture the desktop on Windows and display it in ARToolkit?
BONUS: If you can grab each desktop from the 'virtual' desktops in Windows 10, that would be an excellent bonus!
Alternative: If you know another AR library that renders differently, or allows me to achieve the same effect, I would be grateful.
There are 2 different problems here:
a) Make an augmentation that plays video
b) Stream the desktop to somewhere else
For playing video on an augmentation you basically need to have a texture that gets updated on each frame. I recall that ARToolkit for Unity has an example that plays video.However.
Streaming the desktop to the other device is a problem of its own. There are tools that do screen recording, but you probably don't want that.
It sounds to me that what you want to do it to make a VLC viewer and put that into an augmentation. If I am correct, I suggest you to start by looking at existing open source VLC viewers.
I wish to take screenshots of fullscreen applications in a c++ program (i.e games like call of duty). I have tried using GDI and directx both can get screenshots of the desktop. However they just return black images when running fullscreen applications. Has anybody else manage to solve this problem and if so how?
I only need a display for DXGI output, and don't want it to be a part of desktop at all. I really don't want the fullscreened display to exit fullscreen mode just because someone has accidentally moved some window out of the main desktop or so.
Is there a way to enable a display without making it a part of desktop?
"Note Using other monitors as independent displays isn't supported on drivers that are implemented to the Windows Display Driver Model (WDDM)."
Guess I have no luck.
I'm sure this is on the web somewhere, but I'm having trouble with the search terms (getting lots of non-relevant stuff.) Anyway, I've got a Direct3D9 application. When it runs in full screen, on Vista and Windows 7, and you hit Alt-Tab or Win-Tab, my application just shows up blank in the thumbnail/preview/live view (not sure of the correct term.) Is there an API or notification I can respond to where I can draw my backbuffer to the thumbnail?
When running a full-screen Direct3D application window compositing (of which the thumbnails are a part) is disabled. This is typically a good thing, since it can increase performance of the full-screen app. As a default this behavior is reasonable since most full-screen apps (especially those developed against XP or earlier) expect to be the sole focus of the user while the app is running. You can manually instantiate and update your thumbnail in this case if you wish, but alt-tabbing away from a full-screen app is usually and edge case.
For more information about compositing in general, including overviews of the thumbnail APIs, check out this MSDN article
I have a C++ application that uses the Win32 API for Windows, and I'm having a problem with GDI+ dithering, when I don't know why it should be.
I have a custom control (custom window). When I receive the WM_PAINT message, I draw some Polygons using FillPolygon on a Graphics device. This Graphics device was created using the HDC from BeginPaint.
When the polygons appear on the screen, though, they are dithered instead of transparent, and only seem to show few colors (maybe 256?) When I do the same thing in C# using the .NET interface into GDI+, it works fine, which is leaving me wondering what's going on.
I'm not doing anything special, this is a simple example that should work fine, as far as I know. Am I doing something wrong?
Edit: Nevermind. It only happens over Remote Desktop, even though the C# example doesnt Dither over remote desktop. Remote Desktop is set at 32-bit color, so I don't know what's up with that.
Hmm... The filling capabilities are determined by the target device. When working over remote desktop, AFAIK Windows substitutes the display driver, so that can change the supported features of the display.
when drawing on wm_paint, you actually draw directly on the screen surface, while .net usually uses double buffering (draws to in memory bitmap and then blits the entire bitmap)
there are some settings in gdi+ that affect the drawing quality. maybe there are different defaults for on-screen, off-screen and remote painting?
It only happens over Remote Desktop
Many remoting applications will reduce colour depth in order to reduce bandwidth requirements. While I haven't used Remote Desktop, the same happens on certain VNC connections. I'd check your RD server and client settings.