Questions tagged [directx-11]

DirectX 11 is the 11th version of Microsoft's DirectX API, which is used to develop and handle tasks related to Multimedia, such as game programming, 3d visualizations and video on Microsoft platforms. DirectX 11 runs on Windows Vista, Windows 7, Windows 8, Windows 10, and Xbox One.

DirectX 11 is the 11th version of Microsoft's DirectX API (), which is used to develop and handle tasks related to Multimedia, such as game programming, 3d visualizations and video on Microsoft platforms. DirectX 11 runs on Windows Vista (), Windows 7 (), Windows 8 (), Windows 10 (), and Xbox One ().

1933 questions
8
votes
0 answers

Desktop duplication screen capturing - DuplicateOutput returns E_ACCESSDENIED error

I'm capturing the screens using desktop duplication APIs (DirectX11). The DuplicateOutput API returns the access denied error and that too happens very rare(may be 10% of the time) on a windows 8.1 machine on logon screen though my application is…
8
votes
1 answer

DirectX 11 - Compute shader: Writing to an output resource

I've just started using the Compute shader stage in DirectX 11 and encountered some unwanted behaviour when writing to an output resource in the Compute shader. I seem to get only zeroes as output which, to my understanding, means that out-of-bound…
SvinSimpe
  • 850
  • 1
  • 12
  • 28
8
votes
3 answers

Resizing a DXGI Resource or Texture2D in SharpDX

I want to resize a screen captured using the Desktop Duplication API in SharpDX. I am using the Screen Capture sample code from the SharpDX Samples repository, relevant portion follows:. SharpDX.DXGI.Resource…
Jon Galloway
  • 52,327
  • 25
  • 125
  • 193
8
votes
1 answer

DirectX11 2 window rendering

How can I render my objects with DirectX into 2 separated windows?
Quest
  • 2,764
  • 1
  • 22
  • 44
8
votes
2 answers

Missing some colors from PNG texture in DirectX during loading and saving?

I use standard DirectX functions (like CreateTexture2D, D3DX11SaveTextureToFile and D3DX11CreateShaderResourceViewFromFile) to load the PNG image, render it on new created texture and than save to file. All the textures are the power of two sizes.…
PolGraphic
  • 3,233
  • 11
  • 51
  • 108
8
votes
3 answers

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

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…
jheriko
  • 3,043
  • 1
  • 21
  • 28
7
votes
1 answer

DirectX11 with a multiple video adapter (GPU) PC

Usually the DirectX11 initialization starts from creating a DirectX11 device: D3D_DRIVER_TYPE driverTypes[] = { D3D_DRIVER_TYPE_HARDWARE, D3D_DRIVER_TYPE_WARP, D3D_DRIVER_TYPE_REFERENCE, }; UINT nNumDriverTypes =…
Foxy
  • 73
  • 4
7
votes
3 answers

D3D11: How to draw a simple pixel aligned line?

I tried to draw a line between two vertices with D3D11. I have some experiences in D3D9 and D3D11, but it seems to be a problem in D3D11 to draw a line, which starts in one given pixel and ends in an other. What I did: I added 0.5f to the pixel…
sandicz
  • 326
  • 3
  • 9
7
votes
2 answers

Greenish image with BGRA to YUV444 conversion using DirectX11 pixel shader

  I'm new to HLSL. I am trying to convert color space of an image captured using DXGI Desktop Duplication API from BGRA to YUV444 using texture as render target.   I have set my pixel shader to perform the required transformation. And taking the…
7
votes
1 answer

Rendering to a full 3D Render Target in one pass

Using DirectX 11, I created a 3D volume texture that can be bound as a render target: D3D11_TEXTURE3D_DESC texDesc3d; // ... texDesc3d.Usage = D3D11_USAGE_DEFAULT; texDesc3d.BindFlags = D3D11_BIND_RENDER_TARGET; // Create volume texture and…
Daerst
  • 954
  • 7
  • 24
7
votes
1 answer

C# Quickest Way to Get Average Colors of Screen

I'm currently working on creating an Ambilight for my computer monitor with C#, an arduino, and an Ikea Dioder. Currently the hardware portion runs flawlessly; however, I'm having a problem with detecting the average color of a section of screen. I…
GrantByrne
  • 849
  • 10
  • 21
7
votes
1 answer

HLSL buffer stride and threading - what is happening here?

I'm really new to DirectCompute technologies, and have been attempting to learn from the documentation on the msdn website, which is.. dense, to say the least. I'd like to make a basic hlsl file that takes in a 4x4 matrix and a 4xN matrix and…
Zach H
  • 469
  • 5
  • 18
6
votes
2 answers

Is there any performance difference between Buffer, StructuredBuffer and ByteAddressBuffer (also their RW variants)?

I tried looking this up on various websites, including MS Docs on DirectX 11 Compute Shader types; but I haven't found anything mentioning performance differences of these buffer types. Are they exactly the same performance-wise ? If no, what is the…
6
votes
1 answer

Why "Warning X4000: use of potentially uninitialized variable" shows for more than one usage of common method?

I have a common method in hlsli /// RendererShaderTypes.hlsli /// static inline float4 OverlayColor(float2 texOverlay, float4 videoColor) { float4 texColor = float4(imageMixTexture[4].Sample(imageMixSampler[4], texOverlay)); if…
6
votes
3 answers

How do you use CheckMultisampleQualityLevels and enable multisampling

I'm learning directx 11 and trying to set up multisampling. For some reason every tutorial on the internet disables multisampling and never goes over how to enable it. First: I've searched around and can't find any examples of how to use…
Telanor
  • 4,419
  • 6
  • 29
  • 36