Skip to content
This repository was archived by the owner on Jul 22, 2024. It is now read-only.

Commit 165db2b

Browse files
committed
basicly add game_shader_generic_deferred
1 parent 6caa629 commit 165db2b

File tree

6 files changed

+115
-14
lines changed

6 files changed

+115
-14
lines changed

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,3 +13,5 @@ materialsystem/shaderlib/Release/
1313
/build
1414
/materialsystem/shaderlib/.vs
1515
*.user
16+
/materialsystem/swarmshaders/.vs
17+
*.filters

CMakeLists.txt

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,10 @@
11
cmake_minimum_required(VERSION 3.10)
22

3-
# Project Name and Version (Optional)
4-
project(MyGameProject VERSION 1.0.0)
5-
6-
# Find dependencies (if any)
7-
# For example: find_package(OpenGL REQUIRED)
3+
# Project Name and Version
4+
project(SourceDEFUN VERSION 1.0.0)
85

96
# Add subdirectories as projects
107
#add_subdirectory(client)
118
#add_subdirectory(server)
12-
#add_subdirectory(game_shader_generic_deferred)
13-
add_subdirectory(materialsystem/shaderlib) # Assuming shaderlib is located here
14-
15-
# Optional: Add targets to build all subdirectories at once
16-
# This is just an example, you might need to adjust it based on your project structure
17-
#add_custom_target(build_all ALL COMMAND make VERBOSE_MAKEFILE=1)
9+
add_subdirectory(materialsystem/swarmshaders)
10+
add_subdirectory(materialsystem/shaderlib)

create_solution.cmd

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
11
cmake -B build -A Win32
2+
pause
Lines changed: 105 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,105 @@
1+
project(game_shader_generic_deferred)
2+
3+
# source files
4+
set(SOURCE_FILES
5+
BaseVSShader.cpp
6+
blur.cpp
7+
debug_lightingctrl.cpp
8+
debug_radiosity_grid.cpp
9+
debug_shadow.cpp
10+
deferred_brush.cpp
11+
deferred_decalModulate.cpp
12+
deferred_model.cpp
13+
deferred_utility.cpp
14+
defpass_composite.cpp
15+
defpass_gbuffer.cpp
16+
defpass_shadow.cpp
17+
IDeferredExt.cpp
18+
lighting_global.cpp
19+
lighting_pass_basic.cpp
20+
lighting_pass_volum.cpp
21+
lighting_world.cpp
22+
lighting_volume.cpp
23+
pbr_dx9.cpp
24+
radiosity_blend.cpp
25+
radiosity_global.cpp
26+
radiosity_propagate.cpp
27+
screenspace_combine.cpp
28+
screenspace_shading.cpp
29+
volume_blend.cpp
30+
volume_prepass.cpp
31+
)
32+
33+
# header files
34+
set(HEADER_FILES
35+
BaseVSShader.h
36+
commandbuilder.h
37+
common_deferred_fxc.h
38+
common_fxc.h
39+
common_hlsl_cpp_consts.h
40+
common_lighting_fxc.h
41+
common_pragmas.h
42+
common_ps_fxc.h
43+
common_shadowmapping_fxc.h
44+
common_vertexlitgeneric_dx9.h
45+
common_vs_fxc.h
46+
cpp_shader_constant_register_map.h
47+
deferred_context.h
48+
deferred_global_common.h
49+
deferred_includes.h
50+
deferred_utility.h
51+
defpass_composite.h
52+
defpass_gbuffer.h
53+
defpass_shadow.h
54+
IDeferredExt.h
55+
lighting_helper.h
56+
lighting_pass_basic.h
57+
lighting_pass_volum.h
58+
pbr_common_ps2_3_x.h
59+
)
60+
61+
# header directories
62+
include_directories(
63+
../../common
64+
../../public
65+
../../public/tier0
66+
../../public/tier1
67+
../../dx9sdk/include
68+
fxctmp9
69+
include
70+
vshtmp9
71+
)
72+
73+
# link directories
74+
link_directories(
75+
../../lib/common
76+
../../lib/public
77+
)
78+
79+
# link libraries
80+
link_libraries(
81+
version.lib
82+
winmm.lib
83+
../../dx9sdk/lib/d3dx9
84+
../../public/interfaces
85+
../../public/mathlib
86+
../../public/matsys_controls
87+
../../public/shaderlib
88+
../../public/tier0
89+
../../public/tier1
90+
../../public/tier2
91+
../../public/tier3
92+
../../public/vstdlib
93+
)
94+
95+
add_library(game_shader_generic_deferred SHARED ${SOURCE_FILES} ${HEADER_FILES})
96+
97+
# Target compiler and platform (assuming Visual Studio)
98+
target_compile_features(game_shader_generic_deferred PRIVATE)
99+
100+
# Add preprocessor definitions
101+
set(PREPROCESSOR_DEFINITIONS WIN32;_WIN32;_DEBUG;DEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;STDSHADER_DX9_DLL_EXPORT;FAST_MATERIALVAR_ACCESS;COMPILER_MSVC;COMPILER_MSVC32)
102+
add_compile_definitions(${PREPROCESSOR_DEFINITIONS})
103+
104+
# Optional: Set output directory for the library
105+
set_target_properties(game_shader_generic_deferred PROPERTIES OUTPUT_DIRECTORY Release_dx9/game_shader_generic_deferred.dll)

materialsystem/swarmshaders/commandbuilder.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@ template<int N> class CFixedCommandStorageBuffer
4242

4343
FORCEINLINE void EnsureCapacity( size_t sz )
4444
{
45-
Assert( m_nNumBytesRemaining >= sz );
45+
//Assert( m_nNumBytesRemaining >= sz );
4646
}
4747

4848
template<class T> FORCEINLINE void Put( T const &nValue )

materialsystem/swarmshaders/game_shader_generic_swarm.sln

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11

2-
Microsoft Visual Studio Solution File, Format Version 11.00
3-
# Visual Studio 2010
2+
Microsoft Visual Studio Solution File, Format Version 14.00
3+
# Visual Studio 2022
44
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "game_shader_generic_swarm", "game_shader_generic_swarm.vcxproj", "{C8D2DC83-E117-7576-7B43-10C844264C51}"
55
EndProject
66
Global

0 commit comments

Comments
 (0)