Skip to content

Commit ea73a8e

Browse files
author
Floyd Huizinga
committed
change ShaderCollection::Set to ShaderCollection::ApplyToContext for clarity, remove Models-Refactored
1 parent f2a3e38 commit ea73a8e

File tree

5 files changed

+5
-15
lines changed

5 files changed

+5
-15
lines changed

src/Cpp/1-getting-started/1-3-3-SettingUp3DRendering/ShaderCollection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ bool ShaderCollection::CompileShader(const std::wstring& filePath, const std::st
182182
}
183183

184184

185-
void ShaderCollection::Set(ID3D11DeviceContext* context)
185+
void ShaderCollection::ApplyToContext(ID3D11DeviceContext* context)
186186
{
187187
context->IASetInputLayout(_inputLayout.Get());
188188
context->VSSetShader(_vertexShader.Get(), nullptr, 0);

src/Cpp/1-getting-started/1-3-3-SettingUp3DRendering/ShaderCollection.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ class ShaderCollection
2323

2424
static size_t GetLayoutByteSize(VertexType vertexType);
2525

26-
void Set(ID3D11DeviceContext* context);
26+
void ApplyToContext(ID3D11DeviceContext* context);
2727
void Destroy();
2828

2929
private:
@@ -52,7 +52,7 @@ class ShaderCollection
5252
WRL::ComPtr<ID3D11VertexShader> _vertexShader = nullptr;
5353
WRL::ComPtr<ID3D11PixelShader> _pixelShader = nullptr;
5454
WRL::ComPtr<ID3D11InputLayout> _inputLayout = nullptr;
55-
D3D11_PRIMITIVE_TOPOLOGY _primitiveTopology = {};
55+
D3D11_PRIMITIVE_TOPOLOGY _primitiveTopology = {};*
5656
uint32_t _vertexSize = 0;
5757
static std::unordered_map<VertexType, std::vector<D3D11_INPUT_ELEMENT_DESC>> _layoutMap;
5858
};

src/Cpp/1-getting-started/1-3-4-3DRendering/ShaderCollection.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -182,7 +182,7 @@ bool ShaderCollection::CompileShader(const std::wstring& filePath, const std::st
182182
}
183183

184184

185-
void ShaderCollection::Set(ID3D11DeviceContext* context)
185+
void ShaderCollection::ApplyToContext(ID3D11DeviceContext* context)
186186
{
187187
context->IASetInputLayout(_inputLayout.Get());
188188
context->VSSetShader(_vertexShader.Get(), nullptr, 0);

src/Cpp/1-getting-started/1-3-4-3DRendering/ShaderCollection.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class ShaderCollection
2222
const ShaderCollectionDescriptor& settings, ID3D11Device* device);
2323
static size_t GetLayoutByteSize(VertexType vertexType);
2424

25-
void Set(ID3D11DeviceContext* context);
25+
void ApplyToContext(ID3D11DeviceContext* context);
2626
void Destroy();
2727

2828
private:

src/LearnD3D11.sln

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -66,11 +66,6 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "1-1-3-HelloTriangle-Refacto
6666
{A3B1AE74-436A-44B7-AD17-A0D19168773C} = {A3B1AE74-436A-44B7-AD17-A0D19168773C}
6767
EndProjectSection
6868
EndProject
69-
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "1-3-5-Models-Refactored", "Cpp\1-getting-started\1-3-5-Models-Refactored\1-3-5-Models-Refactored.vcxproj", "{1B3547F4-344F-41FC-8AB0-312AF6E01A96}"
70-
ProjectSection(ProjectDependencies) = postProject
71-
{A3B1AE74-436A-44B7-AD17-A0D19168773C} = {A3B1AE74-436A-44B7-AD17-A0D19168773C}
72-
EndProjectSection
73-
EndProject
7469
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "1-3-7-DearImGui", "Cpp\1-getting-started\1-3-7-DearImGui\1-3-7-DearImGui.vcxproj", "{0989B526-EC66-4C1C-8121-4B9AC53E2C83}"
7570
ProjectSection(ProjectDependencies) = postProject
7671
{A3B1AE74-436A-44B7-AD17-A0D19168773C} = {A3B1AE74-436A-44B7-AD17-A0D19168773C}
@@ -141,10 +136,6 @@ Global
141136
{A1F990E5-58A1-4345-AF2B-599F785519A7}.Debug|x64.Build.0 = Debug|x64
142137
{A1F990E5-58A1-4345-AF2B-599F785519A7}.Release|x64.ActiveCfg = Release|x64
143138
{A1F990E5-58A1-4345-AF2B-599F785519A7}.Release|x64.Build.0 = Release|x64
144-
{1B3547F4-344F-41FC-8AB0-312AF6E01A96}.Debug|x64.ActiveCfg = Debug|x64
145-
{1B3547F4-344F-41FC-8AB0-312AF6E01A96}.Debug|x64.Build.0 = Debug|x64
146-
{1B3547F4-344F-41FC-8AB0-312AF6E01A96}.Release|x64.ActiveCfg = Release|x64
147-
{1B3547F4-344F-41FC-8AB0-312AF6E01A96}.Release|x64.Build.0 = Release|x64
148139
{0989B526-EC66-4C1C-8121-4B9AC53E2C83}.Debug|x64.ActiveCfg = Debug|x64
149140
{0989B526-EC66-4C1C-8121-4B9AC53E2C83}.Debug|x64.Build.0 = Debug|x64
150141
{0989B526-EC66-4C1C-8121-4B9AC53E2C83}.Release|x64.ActiveCfg = Release|x64
@@ -188,7 +179,6 @@ Global
188179
{FAFF4FF7-7CB0-475D-AC8E-59156B3BC8B4} = {125F76A8-AE74-44AE-B471-BE7C09EB5EB4}
189180
{C1C659F7-25F7-463E-BC25-83DCD748044E} = {125F76A8-AE74-44AE-B471-BE7C09EB5EB4}
190181
{A1F990E5-58A1-4345-AF2B-599F785519A7} = {69E36221-7B54-4891-AB39-B9F2C5025815}
191-
{1B3547F4-344F-41FC-8AB0-312AF6E01A96} = {125F76A8-AE74-44AE-B471-BE7C09EB5EB4}
192182
{0989B526-EC66-4C1C-8121-4B9AC53E2C83} = {125F76A8-AE74-44AE-B471-BE7C09EB5EB4}
193183
{1B35D552-7FE9-43AD-B0BC-7375D96034A5} = {125F76A8-AE74-44AE-B471-BE7C09EB5EB4}
194184
{B88367A4-CB5C-4FB1-9FF9-ADDA3D9D0AB2} = {69E36221-7B54-4891-AB39-B9F2C5025815}

0 commit comments

Comments
 (0)