Subversion Repositories eduke32

Compare Revisions

Ignore whitespace Rev 7792 → Rev 7793

/.gitignore
54,5 → 54,3
 
.DS_Store
._*
 
/source/build/src/generated/
/GNUmakefile
1012,12 → 1012,12
$$(COMPILE_STATUS)
$$(RECIPE_IF) $$(COMPILER_C) $$($1_cflags) -c $$< -o $$@ $$(RECIPE_RESULT_COMPILE)
 
$$($1_obj)/%.$$o: $$($1_src)/%.glsl | $$($1_obj) $$($1_src)/generated
@echo Creating $$(<D)/generated/$$(<F).h from $$<
@$$(call RAW_ECHO,char const *$$(basename $$(<F)) = R"shader$$(paren_open)) > $$(<D)/generated/$$(<F).h
@$$(call CAT,$$<) >> $$(<D)/generated/$$(<F).h
@$$(call RAW_ECHO,$$(paren_close)shader";) >> $$(<D)/generated/$$(<F).h
@$$(COMPILER_CXX) $$($1_cflags) -x c++ -c $$($1_src)/empty.cpp -o $$@
$$($1_obj)/%.$$o: $$($1_src)/%.glsl | $$($1_obj)
@echo Creating $$($1_obj)/$$(<F).cpp from $$<
@$$(call RAW_ECHO,char const *$$(basename $$(<F)) = R"shader$$(paren_open)) > $$($1_obj)/$$(<F).cpp
@$$(call CAT,$$<) >> $$($1_obj)/$$(<F).cpp
@$$(call RAW_ECHO,$$(paren_close)shader";) >> $$($1_obj)/$$(<F).cpp
@$$(RECIPE_IF) $$(COMPILER_CXX) $$($1_cflags) -c $$($1_obj)/$$(<F).cpp -o $$@ $$(RECIPE_RESULT_COMPILE)
 
## Cosmetic stuff
 
1052,7 → 1052,7
 
### Directories
 
$(foreach i,$(components),$($i_obj)) $(foreach i,$(components),$($i_src)/generated):
$(foreach i,$(components),$($i_obj)):
-$(call MKDIR,$@)
 
### Phonies
/platform/Windows/build.vcxproj
385,21 → 385,57
<ItemGroup>
<CustomBuild Include="..\..\source\build\src\polymost1Frag.glsl">
<FileType>Document</FileType>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">mkdir %(RelativeDir)generated
echo char const *%(Filename) = R^"shader( &gt; %(RelativeDir)generated\%(Filename)%(Extension).h
type %(Identity) &gt;&gt; %(RelativeDir)generated\%(Filename)%(Extension).h
echo )shader^"; &gt;&gt; %(RelativeDir)generated\%(Filename)%(Extension).h</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Creating header from %(Identity)</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%(RelativeDir)\generated\%(Filename)%(Extension).h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS /GL /analyze- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Gm- /O2 /Fd"Win32\Build\build\Release\build.pdb" /Zc:inline /fp:precise /D "NDEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /errorReport:prompt /WX- /Zc:forScope /arch:SSE2 /Gd /Oy /Oi /MD /Fa"Win32\Build\build\Release\\" /EHs /nologo /Fo"Win32\Build\build\Release\\" /Ot /Fp"Win32\Build\build\Release\build.pch" "$(IntermediateOutputPath)%(Filename)%(Extension).cpp"</Command>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS- /analyze- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Zi /Gm /Od /Fd"Win32\Build\build\Debug\build.pdb" /Zc:inline /fp:precise /D "_DEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /errorReport:prompt /WX- /Zc:forScope /RTC1 /arch:SSE2 /Gd /Oy- /MDd /Fa"Win32\Build\build\Debug\\" /EHs /nologo /Fo"Win32\Build\build\Debug\\" /Fp"Win32\Build\build\Debug\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Compiling shader to %(Identity).obj</Message>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compiling shader to %(Identity).obj</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS /GL /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Gm- /O2 /Fd"x64\Build\build\Release\build.pdb" /Zc:inline /fp:precise /D "NDEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /D "NOASM=1" /errorReport:prompt /WX- /Zc:forScope /Gd /Oy /Oi /MD /Fa"x64\Build\build\Release\\" /EHs /nologo /Fo"x64\Build\build\Release\\" /Ot /Fp"x64\Build\build\Release\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Zi /Gm /Od /Fd"x64\Build\build\Debug\build.pdb" /Zc:inline /fp:precise /D "_DEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /D "NOASM=1" /errorReport:prompt /WX- /Zc:forScope /RTC1 /Gd /Oy- /MDd /Fa"x64\Build\build\Debug\\" /EHs /nologo /Fo"x64\Build\build\Debug\\" /Fp"x64\Build\build\Debug\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Compiling shader to %(Identity).obj</Message>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Compiling shader to %(Identity).obj</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
</CustomBuild>
<CustomBuild Include="..\..\source\build\src\polymost1Vert.glsl">
<FileType>Document</FileType>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">mkdir %(RelativeDir)generated
echo char const *%(Filename) = R^"shader( &gt; %(RelativeDir)generated\%(Filename)%(Extension).h
type %(Identity) &gt;&gt; %(RelativeDir)generated\%(Filename)%(Extension).h
echo )shader^"; &gt;&gt; %(RelativeDir)generated\%(Filename)%(Extension).h</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Creating header from %(Identity)</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">%(RelativeDir)\generated\%(Filename)%(Extension).h</Outputs>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS /GL /analyze- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Gm- /O2 /Fd"Win32\Build\build\Release\build.pdb" /Zc:inline /fp:precise /D "NDEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /errorReport:prompt /WX- /Zc:forScope /arch:SSE2 /Gd /Oy /Oi /MD /Fa"Win32\Build\build\Release\\" /EHs /nologo /Fo"Win32\Build\build\Release\\" /Ot /Fp"Win32\Build\build\Release\build.pch" "$(IntermediateOutputPath)%(Filename)%(Extension).cpp"</Command>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS- /analyze- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Zi /Gm /Od /Fd"Win32\Build\build\Debug\build.pdb" /Zc:inline /fp:precise /D "_DEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /errorReport:prompt /WX- /Zc:forScope /RTC1 /arch:SSE2 /Gd /Oy- /MDd /Fa"Win32\Build\build\Debug\\" /EHs /nologo /Fo"Win32\Build\build\Debug\\" /Fp"Win32\Build\build\Debug\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Compiling shader to %(Identity).obj</Message>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Compiling shader to %(Identity).obj</Message>
<Command Condition="'$(Configuration)|$(Platform)'=='Release|x64'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS /GL /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Gm- /O2 /Fd"x64\Build\build\Release\build.pdb" /Zc:inline /fp:precise /D "NDEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /D "NOASM=1" /errorReport:prompt /WX- /Zc:forScope /Gd /Oy /Oi /MD /Fa"x64\Build\build\Release\\" /EHs /nologo /Fo"x64\Build\build\Release\\" /Ot /Fp"x64\Build\build\Release\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Command Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">echo char const *%(Filename) = R^"shader( &gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
type %(Identity) &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
echo )shader^"; &gt;&gt; $(IntermediateOutputPath)%(Filename)%(Extension).cpp
cl /c /MP /GS- /W3 /wd"4996" /wd"4244" /wd"4018" /wd"4267" /Gy /Zc:wchar_t /I"./include" /I"./include/vpx/" /I"./include/sdl2/" /I"../../source/build/include" /I"../../source/mact/include" /I"../../source/audiolib/include" /I"../../source/enet/include" /I"../../source/glad/include" /I"../../source/libxmp-lite/include" /I"../../source/libxmp-lite/include/libxmp-lite" /Zi /Gm /Od /Fd"x64\Build\build\Debug\build.pdb" /Zc:inline /fp:precise /D "_DEBUG" /D "_LIB" /D "_CRT_SECURE_NO_WARNINGS" /D "WIN32" /D "RENDERTYPESDL=1" /D "MIXERTYPEWIN=1" /D "SDL_USEFOLDER" /D "SDL_TARGET=2" /D "USE_OPENGL=1" /D "POLYMER=1" /D "STARTUP_WINDOW" /D "USE_LIBVPX" /D "HAVE_VORBIS" /D "HAVE_XMP" /D "NOASM=1" /errorReport:prompt /WX- /Zc:forScope /RTC1 /Gd /Oy- /MDd /Fa"x64\Build\build\Debug\\" /EHs /nologo /Fo"x64\Build\build\Debug\\" /Fp"x64\Build\build\Debug\build.pch" $(IntermediateOutputPath)%(Filename)%(Extension).cpp</Command>
<Message Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">Compiling shader to %(Identity).obj</Message>
<Message Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Compiling shader to %(Identity).obj</Message>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
<Outputs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(IntermediateOutputPath)%(Filename)%(Extension).obj;$(IntermediateOutputPath)%(Filename)%(Extension).cpp</Outputs>
</CustomBuild>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
/source/build/src/polymost.cpp
165,6 → 165,8
static int32_t lastbasepal = -1;
static GLuint paletteTextureIDs[MAXBASEPALS];
static GLuint palswapTextureID = 0;
extern char const *polymost1Frag;
extern char const *polymost1Vert;
static GLuint polymost1CurrentShaderProgramID = 0;
static GLuint polymost1BasicShaderProgramID = 0;
static GLuint polymost1ExtendedShaderProgramID = 0;
1121,9 → 1123,6
fogRangeLoc = glGetUniformLocation(polymost2BasicShaderProgramID, "u_fogRange");
fogColorLoc = glGetUniformLocation(polymost2BasicShaderProgramID, "u_fogColor");
 
#include "generated/polymost1Vert.glsl.h"
#include "generated/polymost1Frag.glsl.h"
 
polymost1ExtendedShaderProgramID = glCreateProgram();
GLuint polymost1BasicVertexShaderID = polymost2_compileShader(GL_VERTEX_SHADER, polymost1Vert);
GLuint polymost1ExtendedFragmentShaderID = polymost2_compileShader(GL_FRAGMENT_SHADER, polymost1Frag);