directx

DirectX full screen window to windowed by window handle with use Windows API functions

南笙酒味 提交于 2019-12-13 02:38:56
问题 Short story A game is started fullscreen but is a fullscreen directX window. The game supports windowed but I have to do it manually. I made a program in Delphi that stretch/resize any window to fit the screen (with use of a system-wide hotkey) without border and caption so it looks like a fullscreen but doesn't trigger direct hardware access. This is important because I'm using a DisplayLink adapter that doesn't support the tricks used by direct hardware access but want to play it full

Interpretation of raw mouse input

穿精又带淫゛_ 提交于 2019-12-13 02:23:43
问题 I have recently started reading Beginning DirectX 11 Programming(Allen Sherrod, Wendy Jones) and have stumbled upon a problem concerning input. The book only teaches me how to use Win32, DirectInput and XInput for input-handling. After a bit of research, however, I have realized that I should be using RawInput for input handling. This is where the problem arises. I have managed to enable my application to receive raw mouse input. My question to you guys is: how do I interpret the raw mouse

Can I develop a Windows Universal Application using DirectX and C#

雨燕双飞 提交于 2019-12-13 02:16:10
问题 I've seen that there is a template to do so in Visual C++, but not in C#. Have I to stick to C++ to develop a Direct X (Universal) application ?? Can I use C#? If so, how? 回答1: Have I to stick to C++ to develop a Direct X (Universal) application? Technically, you can use the DirectX in .NET platform by using the interop technology. SharpDX has done such kind of things for you and you can easily use the DX in you .NET project including the Window 8.1 and Windows Phone 8.1 app project. However,

Changing image format of a Directx acquired surface in opencl

感情迁移 提交于 2019-12-13 02:15:00
问题 I am working in opencl gets a Media surface from Directx /* Working on NV12 surfaces, associate the shared buffer with the kernel object*/ p->memobj[0] = clCreateFromDX9MediaSurfaceINTEL(p->context, CL_MEM_READ_ONLY, input_D3D_surf, input_D3D_surf_hdl, 0, &error); p->memobj[1] = clCreateFromDX9MediaSurfaceINTEL(p->context, CL_MEM_READ_ONLY, input_D3D_surf, input_D3D_surf_hdl, 1, &error); p->memobj[2] = clCreateFromDX9MediaSurfaceINTEL(p->context, CL_MEM_READ_ONLY, input_D3D_surf, input_D3D

iPhone / DirectX : 3D models question

寵の児 提交于 2019-12-13 01:41:56
问题 Sorry for the random question Years ago I built a 3D world in directX. If I remember the models were in .x and I even had characters that were animated. Last night it hit me that it would be fun to put this in to iOS as I been playing with openGL quite a bit So Question! Can you convert animated .x files so they can be used in iOS 来源: https://stackoverflow.com/questions/6660949/iphone-directx-3d-models-question

XNA: How to get the BackBuffer RenderTarget

半城伤御伤魂 提交于 2019-12-13 01:40:05
问题 in XNA, I need to get a reference to the RenderTarget (2D) of the BackBuffer in order to draw it to a texture or change its Usage to Usage.PreserveContents , is there any method which allows me to do that? 回答1: Check out this blog post about what happened to ResolveBackBuffer in XNA 4.0. Basically, you should just use render targets. If you really need the back-buffer, you can use GetBackBufferData . But it only works on the HiDef profile. If you need to change the RenderTargetUsage of the

DIDEVICEINSTANCE guidInstance and guidProduct change on same device

走远了吗. 提交于 2019-12-12 18:09:40
问题 I am using DirectInput8 in a project at work that monitors various components of the pc. To monitor joysticks we use DirectInput8. The data is retrieved by enumerating all joysticks with DI8DEVCLASS_GAMECTRL as the type and DIEDFL_ATTACHEDONLY as a flag. Recently it was brought to my attention that we were having multiple joysticks showing up. First I looked at the xml file we store the components in between reboots. There were two entries for the joysticks, Logitech Extreme 3d pro, and each

DirectCompute CreateBuffer fails with error 0x80070057 (E_INVALIDARG)

本小妞迷上赌 提交于 2019-12-12 17:21:37
问题 I'm trying to create a buffer in GPU memory to upload data from CPU. GPU access will be readonly. Data will be used as an input buffer for a compute shader. CreateBuffer() fails with error 0x80070057 (E_INVALIDARG). I read the docs and read it again without discovering which argument cause the failure. Here is an extract from my code where I marked the failure: HRESULT hr = S_OK; RECT rc; GetClientRect( g_hWnd, &rc ); UINT width = rc.right - rc.left; UINT height = rc.bottom - rc.top; UINT

Where can I get Microsoft.DirectX.dll?

二次信任 提交于 2019-12-12 16:02:18
问题 I have no idea where to get it. Is it just the Microsoft SDK? And if yes, how can I add it to my project(Visual Studios 2010 C#)? 回答1: The managed DirectX wrappers are obsolete and no longer included with the DirectX SDK. The last version that had it was the February 2010 release. You can still download it. Replacement is XNA. 回答2: It's part of the Microsoft DirectX SDK. This Code Project tutorial goes over getting yourself up-and-running in Visual Studio. 回答3: You can get it at DirectX

DirectX D3D11CreateDeviceAndSwapChain returning E_INVALIDARG

纵然是瞬间 提交于 2019-12-12 14:26:58
问题 I have the following call, and no matter what I try, hresult is always E_INVALIDARG: LogMessage(L"Creating swap chain. Emulation: " + std::to_wstring(useSoftwareEmulation) + L", Debugging: " + std::to_wstring(enableRenderDebugging)); HRESULT hresult = D3D11CreateDeviceAndSwapChain( (useSoftwareEmulation ? NULL : currentAdapter), (useSoftwareEmulation ? D3D_DRIVER_TYPE_WARP : D3D_DRIVER_TYPE_UNKNOWN), NULL, (enableRenderDebugging ? D3D11_CREATE_DEVICE_DEBUG | D3D11_CREATE_DEVICE_DEBUGGABLE : 0