Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Windows SDK sample doesn't work under Parallels 13.3.2 (on Mac) #19

Closed
kjk opened this issue Aug 13, 2018 · 2 comments
Closed

Windows SDK sample doesn't work under Parallels 13.3.2 (on Mac) #19

kjk opened this issue Aug 13, 2018 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@kjk
Copy link

kjk commented Aug 13, 2018

This is from SDK 0.9 I tried to run Browser sample on win10 under parallels.

It complains about not being able to create a texture and then crashes.

void GPUDriverD3D11::CreateTexture(uint32_t texture_id,
  Ref<Bitmap> bitmap) {

...

 if (FAILED(hr)) {
    MessageBox(nullptr,
      L"GPUDriverD3D11::CreateTexture, unable to create texture.", L"Error", MB_OK);
  }
  Name Value Type
  hr E_INVALIDARG One or more arguments are invalid. HRESULT
texture_entry (0x0000000000000000 , 0x0000000000000000 ) std::pair<Microsoft::WRL::ComPtr,Microsoft::WRL::ComPtr > &
  texture_id 1 unsigned int

Here's the debug output:

D3D11 ERROR: ID3D11Device::CreateTexture2D: CheckFeatureSupport() API with D3D11_FEATURE_D3D11_OPTIONS2 must report support for MapOnDefaultTextures for a D3D11_USAGE_DEFAULT Texture Resource to have CPUAccessFlags set. CPUAccessFlags are currently set to: D3D11_CPU_ACCESS_READ (0), D3D11_CPU_ACCESS_WRITE (1). MapOnDefaultBuffers is (false). [ STATE_CREATION ERROR #98: CREATETEXTURE2D_INVALIDCPUACCESSFLAGS]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEBE8.
D3D11 ERROR: ID3D11Device::CreateTexture2D: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #104: CREATETEXTURE2D_INVALIDARG_RETURN]
The thread 0x254c has exited with code 0 (0x0).
The thread 0x20d0 has exited with code 0 (0x0).
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: A ShaderResourceView cannot be created from a NULL Resource. [ STATE_CREATION ERROR #129: CREATESHADERRESOURCEVIEW_INVALIDRESOURCE]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEE98.
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #131: CREATESHADERRESOURCEVIEW_INVALIDARG_RETURN]
D3D11 ERROR: ID3D11Device::CreateTexture2D: CheckFeatureSupport() API with D3D11_FEATURE_D3D11_OPTIONS2 must report support for MapOnDefaultTextures for a D3D11_USAGE_DEFAULT Texture Resource to have CPUAccessFlags set. CPUAccessFlags are currently set to: D3D11_CPU_ACCESS_READ (0), D3D11_CPU_ACCESS_WRITE (1). MapOnDefaultBuffers is (false). [ STATE_CREATION ERROR #98: CREATETEXTURE2D_INVALIDCPUACCESSFLAGS]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEBE8.
D3D11 ERROR: ID3D11Device::CreateTexture2D: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #104: CREATETEXTURE2D_INVALIDARG_RETURN]
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: A ShaderResourceView cannot be created from a NULL Resource. [ STATE_CREATION ERROR #129: CREATESHADERRESOURCEVIEW_INVALIDRESOURCE]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEE98.
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #131: CREATESHADERRESOURCEVIEW_INVALIDARG_RETURN]
D3D11 ERROR: ID3D11Device::CreateTexture2D: CheckFeatureSupport() API with D3D11_FEATURE_D3D11_OPTIONS2 must report support for MapOnDefaultTextures for a D3D11_USAGE_DEFAULT Texture Resource to have CPUAccessFlags set. CPUAccessFlags are currently set to: D3D11_CPU_ACCESS_READ (0), D3D11_CPU_ACCESS_WRITE (1). MapOnDefaultBuffers is (false). [ STATE_CREATION ERROR #98: CREATETEXTURE2D_INVALIDCPUACCESSFLAGS]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEBE8.
D3D11 ERROR: ID3D11Device::CreateTexture2D: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #104: CREATETEXTURE2D_INVALIDARG_RETURN]
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: A ShaderResourceView cannot be created from a NULL Resource. [ STATE_CREATION ERROR #129: CREATESHADERRESOURCEVIEW_INVALIDRESOURCE]
Exception thrown at 0x00007FFBD4B5A388 in Browser.exe: Microsoft C++ exception: _com_error at memory location 0x000000C7285FEE98.
D3D11 ERROR: ID3D11Device::CreateShaderResourceView: Returning E_INVALIDARG, meaning invalid parameters were passed. [ STATE_CREATION ERROR #131: CREATESHADERRESOURCEVIEW_INVALIDARG_RETURN]
Exception thrown at 0x00007FFBB03D4979 (d3d11_3SDKLayers.dll) in Browser.exe: 0xC0000005: Access violation reading location 0x0000000000000000.
@adamjs
Copy link
Member

adamjs commented Aug 13, 2018

A quick glance at this Parallels KB article (updated last year so might be out of date) states that Parallels on macOS only supports DirectX 10.1 at this time.

The app framework code on Windows currently uses DirectX 11.1-- I haven't yet ported to other DirectX versions but I've created a new issue (see #20) to add DX10 support.

@adamjs adamjs self-assigned this Aug 13, 2018
@adamjs adamjs added the bug Something isn't working label Aug 13, 2018
@adamjs
Copy link
Member

adamjs commented Jul 4, 2020

The library now supports pure-CPU rendering for environments with limited/no GPU, (see Config::use_gpu_renderer and the new Surface API in trunk).

@adamjs adamjs closed this as completed Jul 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants