Skip to content

Commit

Permalink
add release
Browse files Browse the repository at this point in the history
  • Loading branch information
LanLou123 committed Jul 17, 2021
1 parent 7a8939f commit 1da609e
Show file tree
Hide file tree
Showing 23 changed files with 28 additions and 18 deletions.
4 changes: 2 additions & 2 deletions DXE/App.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -359,10 +359,10 @@ bool App::Initialize() {
mScene = std::make_unique<Scene>(md3dDevice.Get(), mClientWidth, mClientHeight);
mScene->initScene();

float modelScale = 4.5;
float modelScale = 0.1;
float ww2Scale = 10.11;
DirectX::XMStoreFloat4x4(&mScene->getObjectInfos()["ww2.obj"]->World, DirectX::XMMatrixScaling(ww2Scale, ww2Scale, ww2Scale));
//DirectX::XMStoreFloat4x4(&mScene->getObjectInfos()["castle.obj"]->World, DirectX::XMMatrixScaling(modelScale, modelScale, modelScale));
//DirectX::XMStoreFloat4x4(&mScene->getObjectInfos()["sponza.obj"]->World, DirectX::XMMatrixScaling(modelScale, modelScale, modelScale));

//DirectX::XMStoreFloat4x4(&mScene->getObjectInfos()["area"]->World, DirectX::XMMatrixScaling(1,1,1) * DirectX::XMMatrixRotationRollPitchYaw(0, MathUtils::Pi / 2.0,0) * DirectX::XMMatrixTranslation(50, 60, 40) );

Expand Down
2 changes: 1 addition & 1 deletion DXE/App.h
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ class App : public Core {
struct ImguiParameters {
std::vector<float> LightPos;
std::vector<float> l2pos = { 20,10,10 };
std::vector<float> groundpos = { 0,3,0 };
std::vector<float> groundpos = { 0,-100,0 };
}mImguiPara;


Expand Down
8 changes: 4 additions & 4 deletions DXE/Assets/Model.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -146,10 +146,10 @@ void Model::buildGeometryAssimp(){



ThrowIfFailed(D3DCreateBlob(vbByteSize, VertexBufferCPU.GetAddressOf()));
CopyMemory(VertexBufferCPU->GetBufferPointer(), vertices.data(), vbByteSize);
ThrowIfFailed(D3DCreateBlob(ibByteSize, IndexBufferCPU.GetAddressOf()));
CopyMemory(IndexBufferCPU->GetBufferPointer(), indices.data(), ibByteSize);
//ThrowIfFailed(D3DCreateBlob(vbByteSize, VertexBufferCPU.GetAddressOf()));
//CopyMemory(VertexBufferCPU->GetBufferPointer(), vertices.data(), vbByteSize);
//ThrowIfFailed(D3DCreateBlob(ibByteSize, IndexBufferCPU.GetAddressOf()));
//CopyMemory(IndexBufferCPU->GetBufferPointer(), indices.data(), ibByteSize);

VertexBufferByteSize = vbByteSize;
VertexByteStride = sizeof(Vertex);
Expand Down
6 changes: 4 additions & 2 deletions DXE/Shaders/pix.hlsl
Original file line number Diff line number Diff line change
Expand Up @@ -376,10 +376,12 @@ float4 PS(VertexOut pin) : SV_Target
}

//col.xyz = diffuseCol * lit;
diffusOcclusion = 1.0 - diffusOcclusion * 0.26;
diffusOcclusion = 1.0 - diffusOcclusion * 0.32;
//col.xyz *= float3(1.0,0.5,0.1);
float3 skyLight = 1.0 * diffusOcclusion * Alb.rgb;
//col.xyz += skyLight;
//col.xyz *= diffusOcclusion;
//

//col.xyz = float3(diffusOcclusion, diffusOcclusion, diffusOcclusion) * 2.0;

float gamma = 0.9;
Expand Down
3 changes: 2 additions & 1 deletion DXE/Shaders/voxelizer.hlsl
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,8 @@ void PS(PS_INPUT pin)
//imageAtomicRGBA8Avg(gVoxelizerAlbedo, texIndex, diffuseAlbedo);
//diffuseAlbedo = float4(1, 1, 1, 1);
float4 writeCol = diffuseAlbedo.xyzw;
writeCol = (diffuseAlbedo.a == 0) ? float4(0, 0, 0, 0) : float4(diffuseAlbedo.xyz, 1.0);

writeCol = (diffuseAlbedo.a == 0) ? float4(0, 0, 0, 0) : float4(diffuseAlbedo.xyz * gRoughness, 1.0);
float4 writeColEmissive = writeCol;
writeColEmissive.a = 0.0;

Expand Down
4 changes: 2 additions & 2 deletions DXE/imgui.ini
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@ Size=400,400
Collapsed=0

[Window][Hello, world!]
Pos=20,819
Size=619,201
Pos=-11,805
Size=1395,220
Collapsed=0

[Window][Dear ImGui Demo]
Expand Down
Binary file modified DXE/x64/Release/App.obj
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.iobj
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.ipdb
Binary file not shown.
18 changes: 12 additions & 6 deletions DXE/x64/Release/DXE.log
Original file line number Diff line number Diff line change
@@ -1,9 +1,15 @@
 Scene.cpp
E:\DX12\DXE\DXE\DXE\Assets\Scene.cpp(107,27): warning C4305: '=': truncation from 'double' to 'float'
E:\DX12\DXE\DXE\DXE\Assets\Scene.cpp(246,31): warning C4244: '=': conversion from 'INT64' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\Assets\Scene.cpp(256,52): warning C4244: '=': conversion from 'INT64' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\Assets\Scene.cpp(270,31): warning C4244: '=': conversion from 'INT64' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\Assets\Scene.cpp(280,52): warning C4244: '=': conversion from 'INT64' to 'UINT', possible loss of data
 App.cpp
E:\DX12\DXE\DXE\DXE\App.cpp(24,129): warning C4267: '=': conversion from 'size_t' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(36,119): warning C4244: 'argument': conversion from 'INT64' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(314,197): warning C4244: 'argument': conversion from 'double' to 'float', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(314,173): warning C4244: 'argument': conversion from 'double' to 'float', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(362,27): warning C4305: 'initializing': truncation from 'double' to 'float'
E:\DX12\DXE\DXE\DXE\App.cpp(363,27): warning C4305: 'initializing': truncation from 'double' to 'float'
E:\DX12\DXE\DXE\DXE\App.cpp(1135,85): warning C4244: 'argument': conversion from 'double' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(1135,77): warning C4244: 'argument': conversion from 'double' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(1135,48): warning C4244: 'argument': conversion from 'double' to 'UINT', possible loss of data
E:\DX12\DXE\DXE\DXE\App.cpp(1160,23): warning C4018: '<': signed/unsigned mismatch
E:\DX12\DXE\DXE\DXE\App.cpp(1168,29): warning C4018: '>=': signed/unsigned mismatch
Generating code
1 of 4958 functions (<0.1%) were compiled, the rest were copied from previous compilation.
0 functions were new in current compilation
Expand Down
Binary file modified DXE/x64/Release/DXE.tlog/CL.command.1.tlog
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.tlog/CL.read.1.tlog
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.tlog/CL.write.1.tlog
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.tlog/DXE.write.1u.tlog
Binary file not shown.
Binary file modified DXE/x64/Release/DXE.tlog/link.read.1.tlog
Binary file not shown.
Binary file modified DXE/x64/Release/Model.obj
Binary file not shown.
Binary file modified DXE/x64/Release/Scene.obj
Binary file not shown.
Binary file modified DXE/x64/Release/main.obj
Binary file not shown.
Binary file modified DXE/x64/Release/vc142.pdb
Binary file not shown.
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
![](sc/small.PNG)
![](sc/addy1.gif)
![](sc/addy2.gif)
![](sc/reflect.gif)
![](sc/imgg.PNG)
### red diffuse reflection
![](sc/diffreflect.PNG)
Expand Down
Binary file added sc/reflect.gif
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified x64/Release/DXE.exe
Binary file not shown.
Binary file modified x64/Release/DXE.pdb
Binary file not shown.

0 comments on commit 1da609e

Please sign in to comment.