directx

How do I draw transparent DirectX content in a transparent window?

风流意气都作罢 提交于 2019-12-18 01:15:19
问题 I want to draw DirectX content so that it appears to be floating over top of the desktop and any other applications that are running. I also need to be able to make the directx content semi-transparent, so other things show through. Is there a way of doing this? I am using Managed DX with C#. 回答1: I found a solution which works on Vista, starting from the link provided by OregonGhost. This is the basic process, in C# syntax. This code is in a class inheriting from Form. It doesn't seem to

WPF and DirectX - Game Overlay

给你一囗甜甜゛ 提交于 2019-12-18 01:13:29
问题 Greetings I've read WPF utilizes DirectX so I'm wondering if it is possible to create a Game Overlay with WPF. I have tried with Winforms or WPF by itself and the transparent forms or windows always cause problems for streaming software thus I'm wondering is it possible to do the following: Create a WPF application which shows a Window on the desktop with all the options needed for the overlay. Once all the options is filled in you can press Update and the Overlay is created in the game with

DirectX SDK (June 2010) Installation Problems: Error Code S1023

≯℡__Kan透↙ 提交于 2019-12-17 22:59:58
问题 I seem to be having some problems installing the DirectX SDK. Everything seems to be going well during the install, but at the end I get the message: Setup failed. Errors were encountered during installation of redistributable packages. Please close all open programs and try running setup again. If problems persist, contact DirectX Developer Support. Error Code: S1023 Well, I have tried closing all open programs and installing again but I get the same error. What is error code S1023 ? I tried

Why can't DirectX/DirectWrite/Direct2D text rendering be as sharp as GDI?

随声附和 提交于 2019-12-17 22:43:02
问题 I already know that sub-pixel positioning causes DirectWrite text rendering to be blurry compared to GDI. However, my question is a bit more fundamental: Why can't DirectWrite (and related methods) be made to render text as sharply as GDI? In other words: What prevents DirectWrite from being able to snap text to the nearest pixel, the way GDI can? Is it, for example, a hardware issue? A driver architecture issue? Is it simply not implemented? Or something else? Smaller sample: Larger samples:

OpenGL/DirectX Hook - Similar to FRAPS

依然范特西╮ 提交于 2019-12-17 22:39:27
问题 Is it possible to detect what applications are using OpenGL or DirectX similar to what FRAPS does? (Possibly using some form of hook)? I probably won't need to actually draw to the window, I just need to know what processes are doing some form of 3D rendering for the time being. (Edit:) In case you are not familiar with it, FRAPS is a program that can be used to draw a "Frame-per-second" counter on a 3D application. FRAPS finds all running 3D applications by itself without needing you to

3D Screenspace Raycasting/Picking DirectX9

醉酒当歌 提交于 2019-12-17 21:35:31
问题 I need to convert a 2D mouse coordinate to a 3D world coordinate based on a specific depth (it's for raycasting). I'm not directly using DirectX in C++, I'm using a proprietary language, but if you give me an answer in C++ or pseudocode (C++ preferred) I can convert it. I have access to the world matrix, view matrix and projection matrix and a variety of matrix manipulation functions. If it's necessary to multiply a vector4 by a matrix4, the only function I have available that takes both a

Intel graphics hardware H264 MFT ProcessInput call fails after feeding few input samples, the same works fine with Nvidia hardware MFT

为君一笑 提交于 2019-12-17 19:23:19
问题 I'm capturing the desktop using DesktopDuplication API and converting the samples from RGBA to NV12 in GPU and feeding the same to MediaFoundation hardware H264 MFT. This works fine with Nvidia graphics, and also with software encoders but fails when only intel graphics hardware MFT is available. The code works fine on the same intel graphics machine if I fallback to Software MFT. I also have ensured that the encoding is actually done in hardware on Nvidia graphics machines. On Intel graphics

Getting green screen in ffplay: Streaming desktop (DirectX surface) as H264 video over RTP stream using Live555

青春壹個敷衍的年華 提交于 2019-12-17 18:56:20
问题 I'm trying to stream the desktop(DirectX surface in NV12 format) as H264 video over RTP stream using Live555 & Windows media foundation's hardware encoder on Windows10, and expecting it to be rendered by ffplay (ffmpeg 4.2). But only getting a green screen like below, I referred MFWebCamToRTP mediafoundation-sample & Encoding DirectX surface using hardware MFT for implementing live555's FramedSource and changing the input source to DirectX surface instead of webCam. Here is an excerpt of my

Should I use DirectInput or Windows message loop?

大城市里の小女人 提交于 2019-12-17 18:33:09
问题 I'm working on a C++ DirectX 2D game and I need keyboard and mouse input. Wikipedia says: Microsoft recommends that new applications make use of the Windows message loop for keyboard and mouse input instead of DirectInput So how should I use it? I have a GameScreen class whice take care of the drawing and the updating(game logic), I call the Draw and the Update methods inside a windows message loop. Thanks 回答1: Since you pretty much have to run a message pump in order to have a window, you

DirectX 11 framebuffer capture (C++, no Win32 or D3DX)

我的未来我决定 提交于 2019-12-17 17:58:18
问题 I would like to capture the contents of my front or back buffer using DirectX 11 into an array of bytes which I can then use as a texture or as a source for creating a file. I have a swap chain setup, lots of rendering happening and the following code so far - which I make sure to call after the call to Present. ID3D11Texture2D* pSurface; HRESULT hr = m_swapChain->GetBuffer( 0, __uuidof( ID3D11Texture2D ), reinterpret_cast< void** >( &pSurface ) ); if( pSurface ) { const int width = static