From 35665fe271cdbb2c641ef64eb36a02aacf98bb3d Mon Sep 17 00:00:00 2001 From: Egor Date: Sat, 17 Feb 2018 22:25:41 -0800 Subject: Few minor updates to lua test scripts --- Tests/TestApp/assets/BlendStateTest.lua | 8 ++++---- Tests/TestApp/assets/DepthStencilStateTest.lua | 8 ++++---- Tests/TestApp/assets/RasterizerStateTest.lua | 8 ++++---- .../assets/Shaders/RTTest/RenderToTexturesPS_DX.hlsl | 4 ++-- Tests/TestApp/src/MTResourceCreationTest.cpp | 18 +++++++++--------- Tests/TestApp/src/TestPipelineStateBase.cpp | 20 ++++++++++---------- 6 files changed, 33 insertions(+), 33 deletions(-) (limited to 'Tests/TestApp') diff --git a/Tests/TestApp/assets/BlendStateTest.lua b/Tests/TestApp/assets/BlendStateTest.lua index 45c305c..4504ff9 100644 --- a/Tests/TestApp/assets/BlendStateTest.lua +++ b/Tests/TestApp/assets/BlendStateTest.lua @@ -69,13 +69,13 @@ TrivialVS = Shader.Create{ Source = [[void VSMain(out float4 pos : SV_Position) { - pos = float4(0,0,0,0); + pos = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "VSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_VERTEX", - Name = "TrivialVS" + Name = "TrivialVS (BlendStateTest.lua)" } } @@ -83,13 +83,13 @@ TrivialPS = Shader.Create{ Source = [[void PSMain(out float4 col : SV_TARGET) { - col = float4(0,0,0,0); + col = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "PSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_PIXEL", - Name = "TrivialPS" + Name = "TrivialPS (BlendStateTest.lua)" } } diff --git a/Tests/TestApp/assets/DepthStencilStateTest.lua b/Tests/TestApp/assets/DepthStencilStateTest.lua index 8c143ae..c0697ba 100644 --- a/Tests/TestApp/assets/DepthStencilStateTest.lua +++ b/Tests/TestApp/assets/DepthStencilStateTest.lua @@ -35,13 +35,13 @@ TrivialVS = Shader.Create{ Source = [[void VSMain(out float4 pos : SV_Position) { - pos = float4(0,0,0,0); + pos = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "VSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_VERTEX", - Name = "TrivialVS" + Name = "TrivialVS (DepthStencilStateTest.lua)" } } @@ -49,13 +49,13 @@ TrivialPS = Shader.Create{ Source = [[void PSMain(out float4 col : SV_TARGET) { - col = float4(0,0,0,0); + col = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "PSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_PIXEL", - Name = "TrivialPS" + Name = "TrivialPS (DepthStencilStateTest.lua)" } } diff --git a/Tests/TestApp/assets/RasterizerStateTest.lua b/Tests/TestApp/assets/RasterizerStateTest.lua index 52a78b0..9701bcb 100644 --- a/Tests/TestApp/assets/RasterizerStateTest.lua +++ b/Tests/TestApp/assets/RasterizerStateTest.lua @@ -32,13 +32,13 @@ TrivialVS = Shader.Create{ Source = [[void VSMain(out float4 pos : SV_Position) { - pos = float4(0,0,0,0); + pos = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "VSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_VERTEX", - Name = "TrivialVS" + Name = "TrivialVS (RasterizerStateTest.lua)" } } @@ -46,13 +46,13 @@ TrivialPS = Shader.Create{ Source = [[void PSMain(out float4 col : SV_TARGET) { - col = float4(0,0,0,0); + col = float4(0.0, 0.0, 0.0, 0.0); }]], EntryPoint = "PSMain", SourceLanguage = "SHADER_SOURCE_LANGUAGE_HLSL", Desc = { ShaderType = "SHADER_TYPE_PIXEL", - Name = "TrivialPS" + Name = "TrivialPS (RasterizerStateTest.lua)" } } diff --git a/Tests/TestApp/assets/Shaders/RTTest/RenderToTexturesPS_DX.hlsl b/Tests/TestApp/assets/Shaders/RTTest/RenderToTexturesPS_DX.hlsl index 03f35aa..c3e08bc 100644 --- a/Tests/TestApp/assets/Shaders/RTTest/RenderToTexturesPS_DX.hlsl +++ b/Tests/TestApp/assets/Shaders/RTTest/RenderToTexturesPS_DX.hlsl @@ -8,6 +8,6 @@ void main(VSOut In, out float4 Col0 : SV_Target0, out float4 Col1 : SV_Target1) { - Col0 = float4( 0.5+0.5*cos(In.f2UV.x*3.1415*6), 0, 0, 0 ); - Col1 = float4( 0, 0.5+0.5*cos(In.f2UV.y*3.1415*8), 0, 0 ); + Col0 = float4( 0.5+0.5*cos(In.f2UV.x*3.1415*6.0), 0.0, 0.0, 0.0 ); + Col1 = float4( 0.0, 0.5+0.5*cos(In.f2UV.y*3.1415*8.0), 0.0, 0.0 ); } diff --git a/Tests/TestApp/src/MTResourceCreationTest.cpp b/Tests/TestApp/src/MTResourceCreationTest.cpp index 22813cb..d1160b5 100644 --- a/Tests/TestApp/src/MTResourceCreationTest.cpp +++ b/Tests/TestApp/src/MTResourceCreationTest.cpp @@ -32,14 +32,14 @@ using namespace Diligent; static const char g_ShaderSource[] = "void VSMain(out float4 pos : SV_POSITION) \n" -"{ \n" -" pos = float4(0,0,0,0); \n" -"} \n" -" \n" +"{ \n" +" pos = float4(0.0, 0.0, 0.0, 0.0); \n" +"} \n" +" \n" "void PSMain(out float4 col : SV_TARGET)\n" -"{ \n" -" col = float4(0,0,0,0); \n" -"} \n" +"{ \n" +" col = float4(0.0, 0.0, 0.0, 0.0); \n" +"} \n" ; MTResourceCreationTest::MTResourceCreationTest(IRenderDevice *pDevice, IDeviceContext *pContext, Uint32 NumThreads) : @@ -189,13 +189,13 @@ void MTResourceCreationTest::ThreadWorkerFunc(bool bIsMasterThread) Attrs.Source = g_ShaderSource; Attrs.EntryPoint = "VSMain"; Attrs.Desc.ShaderType = SHADER_TYPE_VERTEX; - Attrs.Desc.Name = "TrivialVS"; + Attrs.Desc.Name = "TrivialVS (MTResourceCreationTest)"; Attrs.SourceLanguage = SHADER_SOURCE_LANGUAGE_HLSL; m_pDevice->CreateShader(Attrs, &pTrivialVS); Attrs.EntryPoint = "PSMain"; Attrs.Desc.ShaderType = SHADER_TYPE_PIXEL; - Attrs.Desc.Name = "TrivialPS"; + Attrs.Desc.Name = "TrivialPS (MTResourceCreationTest)"; m_pDevice->CreateShader(Attrs, &pTrivialPS); PipelineStateDesc PSODesc; diff --git a/Tests/TestApp/src/TestPipelineStateBase.cpp b/Tests/TestApp/src/TestPipelineStateBase.cpp index f5479eb..b4c5041 100644 --- a/Tests/TestApp/src/TestPipelineStateBase.cpp +++ b/Tests/TestApp/src/TestPipelineStateBase.cpp @@ -30,14 +30,14 @@ using namespace Diligent; static const char g_ShaderSource[] = "void VSMain(out float4 pos : SV_POSITION) \n" -"{ \n" -" pos = float4(0,0,0,0); \n" -"} \n" -" \n" -"void PSMain(out float4 col : SV_TARGET)\n" -"{ \n" -" col = float4(0,0,0,0); \n" -"} \n" +"{ \n" +" pos = float4(0.0, 0.0, 0.0, 0.0); \n" +"} \n" +" \n" +"void PSMain(out float4 col : SV_TARGET) \n" +"{ \n" +" col = float4(0.0, 0.0, 0.0, 0.0); \n" +"} \n" ; TestPipelineStateBase::TestPipelineStateBase(Diligent::IRenderDevice *pDevice, const char *Name) : @@ -48,13 +48,13 @@ TestPipelineStateBase::TestPipelineStateBase(Diligent::IRenderDevice *pDevice, c Attrs.Source = g_ShaderSource; Attrs.EntryPoint = "VSMain"; Attrs.Desc.ShaderType = SHADER_TYPE_VERTEX; - Attrs.Desc.Name = "TrivialVS"; + Attrs.Desc.Name = "TrivialVS (TestPipelineStateBase)"; Attrs.SourceLanguage = SHADER_SOURCE_LANGUAGE_HLSL; m_pDevice->CreateShader(Attrs, &m_pTrivialVS); Attrs.EntryPoint = "PSMain"; Attrs.Desc.ShaderType = SHADER_TYPE_PIXEL; - Attrs.Desc.Name = "TrivialPS"; + Attrs.Desc.Name = "TrivialPS (TestPipelineStateBase)"; m_pDevice->CreateShader(Attrs, &m_pTrivialPS); m_PSODesc.GraphicsPipeline.pVS = m_pTrivialVS; -- cgit v1.2.3