diff options
| author | Jason Maskell <[email protected]> | 2016-05-19 11:56:51 +0200 |
|---|---|---|
| committer | Jason Maskell <[email protected]> | 2016-05-19 11:56:51 +0200 |
| commit | 67e62061658d90b9491c55544bb419f91a0c5c08 (patch) | |
| tree | 8769085a7916ae6e8b4fa6cb61a7d56018704396 /test | |
| parent | Added the ability to specify the "media" directory for the test project. (diff) | |
| download | waveworks_archive-67e62061658d90b9491c55544bb419f91a0c5c08.tar.xz waveworks_archive-67e62061658d90b9491c55544bb419f91a0c5c08.zip | |
D3D11 test is compiling and running with a rendering error (ocean is grey and not dark blue).
D3D11 sample added but still has lots of compile errors, needs to be fully converted to use new DXUT11, etc.
Diffstat (limited to 'test')
| -rw-r--r-- | test/d3d11/ocean_cufft_app.cpp | 21 | ||||
| -rw-r--r-- | test/d3d11/ocean_surface.cpp | 2 | ||||
| -rw-r--r-- | test/media/UI/Font.dds | bin | 0 -> 76128 bytes | |||
| -rw-r--r-- | test/media/ocean_surface_d3d11.fxo | bin | 33379 -> 50313 bytes | |||
| -rw-r--r-- | test/media/sample_d3d11.fxo | bin | 0 -> 82321 bytes |
5 files changed, 12 insertions, 11 deletions
diff --git a/test/d3d11/ocean_cufft_app.cpp b/test/d3d11/ocean_cufft_app.cpp index bee9978..29ca4be 100644 --- a/test/d3d11/ocean_cufft_app.cpp +++ b/test/d3d11/ocean_cufft_app.cpp @@ -95,7 +95,7 @@ GFSDK_WaveWorks_Simulation_Stats g_ocean_stats_simulation; GFSDK_WaveWorks_Simulation_Stats g_ocean_stats_simulation_filtered; int g_max_detail_level; -bool g_RenderWireframe = true; +bool g_RenderWireframe = false; bool g_RenderWater = true; bool g_SimulateWater = true; bool g_ForceKick = false; @@ -256,6 +256,7 @@ INT WINAPI WinMain( HINSTANCE, HINSTANCE, LPSTR cmdline, int ) #endif g_pTestParams = new TestParams(cmdline); + g_pTestParams->MediaDirectory = "D:\\Projects\\WaveworksGit\\WWLibrary\\test\\media"; std::wstring_convert<std::codecvt_utf8_utf16<wchar_t>> converter; @@ -341,7 +342,7 @@ void InitApp() g_ocean_simulation_param.foam_generation_threshold = 0.37f; g_ocean_simulation_settings.fft_period = 1000.0f; - g_ocean_simulation_settings.detail_level = GFSDK_WaveWorks_Simulation_DetailLevel_Normal; + g_ocean_simulation_settings.detail_level = GFSDK_WaveWorks_Simulation_DetailLevel_High; g_ocean_simulation_settings.readback_displacements = false; g_ocean_simulation_settings.num_readback_FIFO_entries = ReadbackArchiveSize; g_ocean_simulation_settings.aniso_level = 4; @@ -558,10 +559,10 @@ HRESULT CALLBACK OnD3D11CreateDevice( ID3D11Device* pd3dDevice, const DXGI_SURFA GFSDK_WaveWorks_InitD3D11(pd3dDevice,&malloHooks,GFSDK_WAVEWORKS_API_GUID); // Do an unnecessary release-init cycle, to test that specific use-case - GFSDK_WaveWorks_InitD3D11(pd3dDevice,&malloHooks,GFSDK_WAVEWORKS_API_GUID); - GFSDK_WaveWorks_ReleaseD3D11(pd3dDevice); - GFSDK_WaveWorks_ReleaseD3D11(pd3dDevice); - GFSDK_WaveWorks_InitD3D11(pd3dDevice,&malloHooks,GFSDK_WAVEWORKS_API_GUID); +// GFSDK_WaveWorks_InitD3D11(pd3dDevice,&malloHooks,GFSDK_WAVEWORKS_API_GUID); +// GFSDK_WaveWorks_ReleaseD3D11(pd3dDevice); +// GFSDK_WaveWorks_ReleaseD3D11(pd3dDevice); +// GFSDK_WaveWorks_InitD3D11(pd3dDevice,&malloHooks,GFSDK_WAVEWORKS_API_GUID); // Ocean sim GFSDK_WaveWorks_Simulation_CreateD3D11(g_ocean_simulation_settings, g_ocean_simulation_param, pd3dDevice, &g_hOceanSimulation); @@ -582,7 +583,7 @@ HRESULT CALLBACK OnD3D11CreateDevice( ID3D11Device* pd3dDevice, const DXGI_SURFA // Skybox { TCHAR path[MAX_PATH]; - V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("..\\Media\\skybox_d3d11.fxo"))); + V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("skybox_d3d11.fxo"))); ID3DBlob* pEffectBuffer = NULL; V_RETURN(LoadFile(path, &pEffectBuffer)); V_RETURN(D3DX11CreateEffectFromMemory(pEffectBuffer->GetBufferPointer(), pEffectBuffer->GetBufferSize(), 0, pd3dDevice, &g_pSkyboxFX)); @@ -608,13 +609,13 @@ HRESULT CALLBACK OnD3D11CreateDevice( ID3D11Device* pd3dDevice, const DXGI_SURFA )); TCHAR path[MAX_PATH]; - V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("..\\Media\\sky_cube.dds"))); + V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("sky_cube.dds"))); ID3D11Resource* pD3D11Resource = NULL; V_RETURN(DirectX::CreateDDSTextureFromFile(pd3dDevice, static_cast<const wchar_t *>(path), &pD3D11Resource, &g_pSkyCubeMap)); // V_RETURN(pd3dDevice->CreateShaderResourceView(pD3D11Resource, NULL, &g_pSkyCubeMap)); SAFE_RELEASE(pD3D11Resource); - V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("..\\Media\\nvidia_logo.dds"))); + V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("nvidia_logo.dds"))); V_RETURN(DirectX::CreateDDSTextureFromFile(pd3dDevice, static_cast<const wchar_t *>(path), &pD3D11Resource, &g_pLogoTex)); // V_RETURN(pd3dDevice->CreateShaderResourceView(pD3D11Resource, NULL, &g_pLogoTex)); SAFE_RELEASE(pD3D11Resource); @@ -632,7 +633,7 @@ HRESULT CALLBACK OnD3D11CreateDevice( ID3D11Device* pd3dDevice, const DXGI_SURFA // Readback marker { TCHAR path[MAX_PATH]; - V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("..\\Media\\ocean_marker_d3d11.fxo"))) + V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("ocean_marker_d3d11.fxo"))) ID3DBlob* pEffectBuffer = NULL; V_RETURN(LoadFile(path, &pEffectBuffer)); V_RETURN(D3DX11CreateEffectFromMemory(pEffectBuffer->GetBufferPointer(), pEffectBuffer->GetBufferSize(), 0, pd3dDevice, &g_pMarkerFX)); diff --git a/test/d3d11/ocean_surface.cpp b/test/d3d11/ocean_surface.cpp index 8c86025..2495886 100644 --- a/test/d3d11/ocean_surface.cpp +++ b/test/d3d11/ocean_surface.cpp @@ -174,7 +174,7 @@ HRESULT OceanSurface::init(const OceanSurfaceParameters& params) if(NULL == m_pOceanFX) { TCHAR path[MAX_PATH]; - V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("..\\Media\\ocean_surface_d3d11.fxo"))); + V_RETURN(DXUTFindDXSDKMediaFileCch(path, MAX_PATH, TEXT("ocean_surface_d3d11.fxo"))); ID3DBlob* pEffectBuffer = NULL; V_RETURN(LoadFile(path, &pEffectBuffer)); V_RETURN(D3DX11CreateEffectFromMemory(pEffectBuffer->GetBufferPointer(), pEffectBuffer->GetBufferSize(), 0, m_pd3dDevice, &m_pOceanFX)); diff --git a/test/media/UI/Font.dds b/test/media/UI/Font.dds Binary files differnew file mode 100644 index 0000000..37514f5 --- /dev/null +++ b/test/media/UI/Font.dds diff --git a/test/media/ocean_surface_d3d11.fxo b/test/media/ocean_surface_d3d11.fxo Binary files differindex 2e18509..d35f8db 100644 --- a/test/media/ocean_surface_d3d11.fxo +++ b/test/media/ocean_surface_d3d11.fxo diff --git a/test/media/sample_d3d11.fxo b/test/media/sample_d3d11.fxo Binary files differnew file mode 100644 index 0000000..9040c57 --- /dev/null +++ b/test/media/sample_d3d11.fxo |