- removed templates.h includes.

This commit is contained in:
Christoph Oelckers 2021-10-30 10:51:03 +02:00
parent b02a6a3ec9
commit 6e0fbb2043
84 changed files with 99 additions and 99 deletions

View file

@ -33,7 +33,7 @@
*/ */
#include <stdarg.h> #include <stdarg.h>
#include "templates.h"
#include "v_2ddrawer.h" #include "v_2ddrawer.h"
#include "vectors.h" #include "vectors.h"
#include "vm.h" #include "vm.h"

View file

@ -36,7 +36,7 @@
#include <stdarg.h> #include <stdarg.h>
#include "v_draw.h" #include "v_draw.h"
#include "vm.h" #include "vm.h"
#include "templates.h"
#include "texturemanager.h" #include "texturemanager.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "c_cvars.h" #include "c_cvars.h"

View file

@ -43,7 +43,7 @@
#include "m_argv.h" #include "m_argv.h"
#include "filesystem.h" #include "filesystem.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "templates.h"
#include "stats.h" #include "stats.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "c_cvars.h" #include "c_cvars.h"

View file

@ -36,7 +36,7 @@
#include <chrono> #include <chrono>
#include "c_cvars.h" #include "c_cvars.h"
#include "templates.h"
#include "oalsound.h" #include "oalsound.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "v_text.h" #include "v_text.h"

View file

@ -34,7 +34,7 @@
#include "s_soundinternal.h" #include "s_soundinternal.h"
#include "sc_man.h" #include "sc_man.h"
#include "templates.h"
#include "cmdlib.h" #include "cmdlib.h"

View file

@ -36,7 +36,7 @@
#include "s_soundinternal.h" #include "s_soundinternal.h"
#include "sc_man.h" #include "sc_man.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"
#include "filesystem.h" #include "filesystem.h"
#include "i_system.h" #include "i_system.h"
#include "printf.h" #include "printf.h"

View file

@ -36,7 +36,7 @@
#include <stdio.h> #include <stdio.h>
#include <stdlib.h> #include <stdlib.h>
#include "templates.h"
#include "s_soundinternal.h" #include "s_soundinternal.h"
#include "m_swap.h" #include "m_swap.h"
#include "superfasthash.h" #include "superfasthash.h"

View file

@ -41,7 +41,7 @@
#include "c_dispatch.h" #include "c_dispatch.h"
#include "configfile.h" #include "configfile.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
#include "i_time.h" #include "i_time.h"
#include "printf.h" #include "printf.h"
#include "sc_man.h" #include "sc_man.h"

View file

@ -34,7 +34,7 @@
*/ */
#include "c_buttons.h" #include "c_buttons.h"
#include "templates.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "printf.h" #include "printf.h"
#include "cmdlib.h" #include "cmdlib.h"

View file

@ -34,7 +34,7 @@
#include <string> #include <string>
#include "templates.h"
#include "version.h" #include "version.h"
#include "c_bind.h" #include "c_bind.h"
#include "c_console.h" #include "c_console.h"

View file

@ -39,7 +39,7 @@
#include <string.h> #include <string.h>
#include <ctype.h> #include <ctype.h>
#include "templates.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "c_console.h" #include "c_console.h"
#include "c_dispatch.h" #include "c_dispatch.h"

View file

@ -49,7 +49,7 @@
#include "v_draw.h" #include "v_draw.h"
#include "s_music.h" #include "s_music.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"

View file

@ -75,7 +75,7 @@
#include "cmdlib.h" #include "cmdlib.h"
#include "printf.h" #include "printf.h"
#include "i_interface.h" #include "i_interface.h"
#include "templates.h"
#include "i_net.h" #include "i_net.h"

View file

@ -37,7 +37,7 @@
#include "m_crc32.h" #include "m_crc32.h"
#include "printf.h" #include "printf.h"
#include "colormatcher.h" #include "colormatcher.h"
#include "templates.h"
#include "palettecontainer.h" #include "palettecontainer.h"
#include "files.h" #include "files.h"

View file

@ -40,11 +40,11 @@
#include "engineerrors.h" #include "engineerrors.h"
#include "sc_man.h" #include "sc_man.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"
#include "printf.h" #include "printf.h"
#include "name.h" #include "name.h"
#include "v_text.h" #include "v_text.h"
#include "templates.h"
#include "zstring.h" #include "zstring.h"
#include "name.h" #include "name.h"
#include <inttypes.h> #include <inttypes.h>

View file

@ -34,7 +34,7 @@
*/ */
#include "resourcefile.h" #include "resourcefile.h"
#include "templates.h"
#include "printf.h" #include "printf.h"
//========================================================================== //==========================================================================

View file

@ -36,7 +36,7 @@
#include <time.h> #include <time.h>
#include "file_zip.h" #include "file_zip.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"
#include "printf.h" #include "printf.h"
#include "w_zip.h" #include "w_zip.h"

View file

@ -40,7 +40,7 @@
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>
#include "templates.h"
#include "m_swap.h" #include "m_swap.h"
#include "v_font.h" #include "v_font.h"
#include "printf.h" #include "printf.h"

View file

@ -39,7 +39,7 @@
#include <string.h> #include <string.h>
#include <math.h> #include <math.h>
#include "templates.h"
#include "m_swap.h" #include "m_swap.h"
#include "v_font.h" #include "v_font.h"
#include "filesystem.h" #include "filesystem.h"

View file

@ -50,7 +50,7 @@
#include "texturemanager.h" #include "texturemanager.h"
#include "printf.h" #include "printf.h"
#include "i_interface.h" #include "i_interface.h"
#include "templates.h"
bool CheckSkipGameOptionBlock(FScanner& sc); bool CheckSkipGameOptionBlock(FScanner& sc);

View file

@ -57,7 +57,7 @@
// HEADER FILES ------------------------------------------------------------ // HEADER FILES ------------------------------------------------------------
#include "dobject.h" #include "dobject.h"
#include "templates.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "menu.h" #include "menu.h"
#include "stats.h" #include "stats.h"

View file

@ -39,7 +39,7 @@
#include "i_system.h" #include "i_system.h"
#include "m_argv.h" #include "m_argv.h"
#include "m_joy.h" #include "m_joy.h"
#include "templates.h"
#include "v_text.h" #include "v_text.h"
#include "printf.h" #include "printf.h"
#include "keydef.h" #include "keydef.h"

View file

@ -34,7 +34,7 @@
#include "basics.h" #include "basics.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"
#include "m_joy.h" #include "m_joy.h"
#include "keydef.h" #include "keydef.h"

View file

@ -39,7 +39,7 @@
#include "gl_sysfb.h" #include "gl_sysfb.h"
#include "hardware.h" #include "hardware.h"
#include "templates.h"
#include "version.h" #include "version.h"
#include "c_console.h" #include "c_console.h"
#include "v_video.h" #include "v_video.h"

View file

@ -39,7 +39,7 @@
#include "gl_sysfb.h" #include "gl_sysfb.h"
#include "hardware.h" #include "hardware.h"
#include "templates.h"
#include "version.h" #include "version.h"
#include "c_console.h" #include "c_console.h"
#include "v_video.h" #include "v_video.h"

View file

@ -45,7 +45,7 @@
#include "i_input.h" #include "i_input.h"
#include "d_eventbase.h" #include "d_eventbase.h"
#include "templates.h"
#include "gameconfigfile.h" #include "gameconfigfile.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "v_text.h" #include "v_text.h"

View file

@ -38,7 +38,7 @@
#include "i_input.h" #include "i_input.h"
#include "d_eventbase.h" #include "d_eventbase.h"
#include "templates.h"
#include "gameconfigfile.h" #include "gameconfigfile.h"
#include "m_argv.h" #include "m_argv.h"
#include "cmdlib.h" #include "cmdlib.h"

View file

@ -73,7 +73,7 @@
#include "i_input.h" #include "i_input.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "templates.h"
#include "gameconfigfile.h" #include "gameconfigfile.h"
#include "v_font.h" #include "v_font.h"
#include "i_system.h" #include "i_system.h"

View file

@ -40,7 +40,7 @@
#include "i_input.h" #include "i_input.h"
#include "d_eventbase.h" #include "d_eventbase.h"
#include "templates.h"
#include "gameconfigfile.h" #include "gameconfigfile.h"
#include "m_argv.h" #include "m_argv.h"
#include "cmdlib.h" #include "cmdlib.h"

View file

@ -41,7 +41,7 @@
#include "st_start.h" #include "st_start.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "templates.h"
#include "i_system.h" #include "i_system.h"
#include "i_input.h" #include "i_input.h"
#include "hardware.h" #include "hardware.h"

View file

@ -35,7 +35,7 @@
#include <windows.h> #include <windows.h>
#include "hardware.h" #include "hardware.h"
#include "templates.h"
#include "version.h" #include "version.h"
#include "c_console.h" #include "c_console.h"
#include "v_video.h" #include "v_video.h"

View file

@ -40,7 +40,7 @@
#include "gl_sysfb.h" #include "gl_sysfb.h"
#include "hardware.h" #include "hardware.h"
#include "templates.h"
#include "version.h" #include "version.h"
#include "c_console.h" #include "c_console.h"
#include "v_video.h" #include "v_video.h"

View file

@ -19,7 +19,7 @@
** 3. This notice may not be removed or altered from any source distribution. ** 3. This notice may not be removed or altered from any source distribution.
*/ */
#include "templates.h"
#include "gl_system.h" #include "gl_system.h"
#include "gl_debug.h" #include "gl_debug.h"
#include "stats.h" #include "stats.h"

View file

@ -36,7 +36,7 @@
#include "gl_system.h" #include "gl_system.h"
#include "v_video.h" #include "v_video.h"
#include "m_png.h" #include "m_png.h"
#include "templates.h"
#include "i_time.h" #include "i_time.h"
#include "gl_interface.h" #include "gl_interface.h"

View file

@ -34,7 +34,7 @@
*/ */
#include "gl_system.h" #include "gl_system.h"
#include "templates.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "hw_material.h" #include "hw_material.h"

View file

@ -33,7 +33,7 @@
#include "flatvertices.h" #include "flatvertices.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "v_video.h" #include "v_video.h"
#include "templates.h"
#include "hw_vrmodes.h" #include "hw_vrmodes.h"
#include "v_draw.h" #include "v_draw.h"

View file

@ -19,7 +19,7 @@
** 3. This notice may not be removed or altered from any source distribution. ** 3. This notice may not be removed or altered from any source distribution.
*/ */
#include "templates.h"
#include "gl_system.h" #include "gl_system.h"
#include "gl_interface.h" #include "gl_interface.h"
#include "gl_postprocessstate.h" #include "gl_postprocessstate.h"

View file

@ -30,7 +30,7 @@
#include "gl_postprocessstate.h" #include "gl_postprocessstate.h"
#include "gl_shaderprogram.h" #include "gl_shaderprogram.h"
#include "gl_buffers.h" #include "gl_buffers.h"
#include "templates.h"
#include <random> #include <random>
EXTERN_CVAR(Int, gl_debug_level) EXTERN_CVAR(Int, gl_debug_level)

View file

@ -25,7 +25,7 @@
** **
*/ */
#include "templates.h"
#include "gl_system.h" #include "gl_system.h"
#include "gl_interface.h" #include "gl_interface.h"
#include "hw_cvars.h" #include "hw_cvars.h"

View file

@ -34,7 +34,7 @@
#include "gl_framebuffer.h" #include "gl_framebuffer.h"
#include "gl_shaderprogram.h" #include "gl_shaderprogram.h"
#include "gl_buffers.h" #include "gl_buffers.h"
#include "templates.h"
EXTERN_CVAR(Int, vr_mode) EXTERN_CVAR(Int, vr_mode)
EXTERN_CVAR(Float, vid_saturation) EXTERN_CVAR(Float, vid_saturation)

View file

@ -36,7 +36,7 @@
#include "gles_system.h" #include "gles_system.h"
#include "v_video.h" #include "v_video.h"
#include "m_png.h" #include "m_png.h"
#include "templates.h"
#include "i_time.h" #include "i_time.h"
#include "gles_framebuffer.h" #include "gles_framebuffer.h"

View file

@ -34,7 +34,7 @@
*/ */
#include "gles_system.h" #include "gles_system.h"
#include "templates.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "hw_material.h" #include "hw_material.h"

View file

@ -32,7 +32,7 @@
#include "flatvertices.h" #include "flatvertices.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "v_video.h" #include "v_video.h"
#include "templates.h"
#include "hw_vrmodes.h" #include "hw_vrmodes.h"
#include "v_draw.h" #include "v_draw.h"

View file

@ -19,7 +19,7 @@
** 3. This notice may not be removed or altered from any source distribution. ** 3. This notice may not be removed or altered from any source distribution.
*/ */
#include "templates.h"
#include "gles_system.h" #include "gles_system.h"
#include "gles_postprocessstate.h" #include "gles_postprocessstate.h"

View file

@ -28,7 +28,7 @@
#include "gles_postprocessstate.h" #include "gles_postprocessstate.h"
#include "gles_shaderprogram.h" #include "gles_shaderprogram.h"
#include "gles_buffers.h" #include "gles_buffers.h"
#include "templates.h"
#include <random> #include <random>
EXTERN_CVAR(Int, gl_debug_level) EXTERN_CVAR(Int, gl_debug_level)

View file

@ -25,7 +25,7 @@
** **
*/ */
#include "templates.h"
#include "gles_system.h" #include "gles_system.h"
#include "hw_cvars.h" #include "hw_cvars.h"
#include "flatvertices.h" #include "flatvertices.h"

View file

@ -26,7 +26,7 @@
#include "hwrenderer/postprocessing/hw_postprocessshader.h" #include "hwrenderer/postprocessing/hw_postprocessshader.h"
#include <random> #include <random>
#include "texturemanager.h" #include "texturemanager.h"
#include "templates.h"
#include "stats.h" #include "stats.h"
Postprocess hw_postprocess; Postprocess hw_postprocess;

View file

@ -1,6 +1,6 @@
#pragma once #pragma once
#include "templates.h"
struct FModelVertex struct FModelVertex
{ {

View file

@ -21,7 +21,7 @@
*/ */
#include <stddef.h> #include <stddef.h>
#include "templates.h"
#include "i_system.h" #include "i_system.h"
#include "filesystem.h" #include "filesystem.h"
#include "v_video.h" #include "v_video.h"

View file

@ -27,7 +27,7 @@
#include <thread> #include <thread>
#include <mutex> #include <mutex>
#include <condition_variable> #include <condition_variable>
#include "templates.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "basics.h" #include "basics.h"

View file

@ -34,7 +34,7 @@
#include "c_dispatch.h" #include "c_dispatch.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "v_video.h" #include "v_video.h"
#include "templates.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "v_draw.h" #include "v_draw.h"

View file

@ -61,7 +61,7 @@
#include "texturemanager.h" #include "texturemanager.h"
#include "i_interface.h" #include "i_interface.h"
#include "v_draw.h" #include "v_draw.h"
#include "templates.h"
EXTERN_CVAR(Int, menu_resolution_custom_width) EXTERN_CVAR(Int, menu_resolution_custom_width)
EXTERN_CVAR(Int, menu_resolution_custom_height) EXTERN_CVAR(Int, menu_resolution_custom_height)

View file

@ -36,7 +36,7 @@
#include "flatvertices.h" #include "flatvertices.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
EXTERN_CVAR(Int, gl_dither_bpc) EXTERN_CVAR(Int, gl_dither_bpc)

View file

@ -27,7 +27,7 @@
#include "vulkan/system/vk_builders.h" #include "vulkan/system/vk_builders.h"
#include "vulkan/system/vk_framebuffer.h" #include "vulkan/system/vk_framebuffer.h"
#include "hw_cvars.h" #include "hw_cvars.h"
#include "templates.h"
VkRenderBuffers::VkRenderBuffers() VkRenderBuffers::VkRenderBuffers()
{ {

View file

@ -26,7 +26,7 @@
#include "vulkan/renderer/vk_renderpass.h" #include "vulkan/renderer/vk_renderpass.h"
#include "vulkan/renderer/vk_renderbuffers.h" #include "vulkan/renderer/vk_renderbuffers.h"
#include "vulkan/textures/vk_hwtexture.h" #include "vulkan/textures/vk_hwtexture.h"
#include "templates.h"
#include "hw_skydome.h" #include "hw_skydome.h"
#include "hw_viewpointuniforms.h" #include "hw_viewpointuniforms.h"
#include "hw_lightbuffer.h" #include "hw_lightbuffer.h"

View file

@ -26,7 +26,7 @@
#include "v_video.h" #include "v_video.h"
#include "m_png.h" #include "m_png.h"
#include "templates.h"
#include "r_videoscale.h" #include "r_videoscale.h"
#include "i_time.h" #include "i_time.h"
#include "v_text.h" #include "v_text.h"

View file

@ -20,7 +20,7 @@
** **
*/ */
#include "templates.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "hw_material.h" #include "hw_material.h"
#include "hw_cvars.h" #include "hw_cvars.h"

View file

@ -18473,8 +18473,8 @@ VkMemoryRequirements img2MemReq;
vkGetImageMemoryRequirements(device, img2, &img2MemReq); vkGetImageMemoryRequirements(device, img2, &img2MemReq);
VkMemoryRequirements finalMemReq = {}; VkMemoryRequirements finalMemReq = {};
finalMemReq.size = max(img1MemReq.size, img2MemReq.size); finalMemReq.size = std::max(img1MemReq.size, img2MemReq.size);
finalMemReq.alignment = max(img1MemReq.alignment, img2MemReq.alignment); finalMemReq.alignment = std::max(img1MemReq.alignment, img2MemReq.alignment);
finalMemReq.memoryTypeBits = img1MemReq.memoryTypeBits & img2MemReq.memoryTypeBits; finalMemReq.memoryTypeBits = img1MemReq.memoryTypeBits & img2MemReq.memoryTypeBits;
// Validate if(finalMemReq.memoryTypeBits != 0) // Validate if(finalMemReq.memoryTypeBits != 0)

View file

@ -43,7 +43,7 @@
#include "texturemanager.h" #include "texturemanager.h"
#include "m_random.h" #include "m_random.h"
#include "v_font.h" #include "v_font.h"
#include "templates.h"
extern FRandom pr_exrandom; extern FRandom pr_exrandom;
FMemArena FxAlloc(65536); FMemArena FxAlloc(65536);

View file

@ -35,7 +35,7 @@
#include <float.h> #include <float.h>
#include "dobject.h" #include "dobject.h"
#include "templates.h"
#include "serializer.h" #include "serializer.h"
#include "types.h" #include "types.h"
#include "vm.h" #include "vm.h"

View file

@ -33,7 +33,7 @@
#include "dobject.h" #include "dobject.h"
#include "c_console.h" #include "c_console.h"
#include "templates.h"
#include "vmintern.h" #include "vmintern.h"
#include "printf.h" #include "printf.h"

View file

@ -40,7 +40,7 @@
#include "version.h" #include "version.h"
#include "zcc_parser.h" #include "zcc_parser.h"
#include "zcc_compile.h" #include "zcc_compile.h"
#include "templates.h"
TArray<FString> Includes; TArray<FString> Includes;
TArray<FScriptPosition> IncludeLocs; TArray<FScriptPosition> IncludeLocs;

View file

@ -41,7 +41,7 @@
#include "c_cvars.h" #include "c_cvars.h"
#include "c_bind.h" #include "c_bind.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "templates.h"
#include "menu.h" #include "menu.h"
#include "vm.h" #include "vm.h"
#include "gstrings.h" #include "gstrings.h"

View file

@ -37,7 +37,7 @@
#include "v_text.h" #include "v_text.h"
#include "stats.h" #include "stats.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "templates.h"
#include "vmintern.h" #include "vmintern.h"
#include "types.h" #include "types.h"
#include "jit.h" #include "jit.h"

View file

@ -35,7 +35,7 @@
#include <assert.h> #include <assert.h>
#include "templates.h"
#include "base_sbar.h" #include "base_sbar.h"
#include "printf.h" #include "printf.h"
#include "v_draw.h" #include "v_draw.h"

View file

@ -34,7 +34,7 @@
#include "animtexture.h" #include "animtexture.h"
#include "bitmap.h" #include "bitmap.h"
#include "texturemanager.h" #include "texturemanager.h"
#include "templates.h"
//========================================================================== //==========================================================================
// //

View file

@ -37,7 +37,7 @@
#define __BITMAP_H__ #define __BITMAP_H__
#include "basics.h" #include "basics.h"
#include "templates.h"
#include "palentry.h" #include "palentry.h"
struct FCopyInfo; struct FCopyInfo;

View file

@ -35,7 +35,7 @@
*/ */
#include "files.h" #include "files.h"
#include "templates.h"
#include "m_png.h" #include "m_png.h"
#include "bitmap.h" #include "bitmap.h"
#include "imagehelpers.h" #include "imagehelpers.h"

View file

@ -35,7 +35,7 @@
#include "files.h" #include "files.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
#include "bitmap.h" #include "bitmap.h"
#include "imagehelpers.h" #include "imagehelpers.h"
#include "image.h" #include "image.h"

View file

@ -37,7 +37,7 @@
#include "printf.h" #include "printf.h"
#include "files.h" #include "files.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
#include "textures.h" #include "textures.h"
#include "bitmap.h" #include "bitmap.h"
#include "colormatcher.h" #include "colormatcher.h"

View file

@ -35,7 +35,7 @@
#include "files.h" #include "files.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
#include "bitmap.h" #include "bitmap.h"
#include "image.h" #include "image.h"
#include "textures.h" #include "textures.h"

View file

@ -37,7 +37,7 @@
#include "printf.h" #include "printf.h"
#include "files.h" #include "files.h"
#include "filesystem.h" #include "filesystem.h"
#include "templates.h"
#include "textures.h" #include "textures.h"
#include "bitmap.h" #include "bitmap.h"
#include "colormatcher.h" #include "colormatcher.h"

View file

@ -37,7 +37,7 @@
#include "filesystem.h" #include "filesystem.h"
#include "printf.h" #include "printf.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "templates.h"
#include "gstrings.h" #include "gstrings.h"
#include "textures.h" #include "textures.h"
#include "texturemanager.h" #include "texturemanager.h"

View file

@ -132,7 +132,7 @@ private:
alloc_traits::deallocate(alloc, allocation, blockSize); alloc_traits::deallocate(alloc, allocation, blockSize);
} }
allocations.clear(); allocations.clear();
blockSize = max<std::size_t>(1, newBlockSize); blockSize = std::max<std::size_t>(1, newBlockSize);
currentBlock = nullptr; currentBlock = nullptr;
currentIndex = blockSize; currentIndex = blockSize;
} }
@ -184,15 +184,15 @@ void Earcut<N>::operator()(const Polygon& points) {
do { do {
x = p->x; x = p->x;
y = p->y; y = p->y;
minX = min<double>(minX, x); minX = std::min<double>(minX, x);
minY = min<double>(minY, y); minY = std::min<double>(minY, y);
maxX = max<double>(maxX, x); maxX = std::max<double>(maxX, x);
maxY = max<double>(maxY, y); maxY = std::max<double>(maxY, y);
p = p->next; p = p->next;
} while (p != outerNode); } while (p != outerNode);
// minX, minY and size are later used to transform coords into integers for z-order calculation // minX, minY and size are later used to transform coords into integers for z-order calculation
inv_size = max<double>(maxX - minX, maxY - minY); inv_size = std::max<double>(maxX - minX, maxY - minY);
inv_size = inv_size != .0 ? (1. / inv_size) : .0; inv_size = inv_size != .0 ? (1. / inv_size) : .0;
} }
@ -350,10 +350,10 @@ bool Earcut<N>::isEarHashed(Node* ear) {
if (area(a, b, c) >= 0) return false; // reflex, can't be an ear if (area(a, b, c) >= 0) return false; // reflex, can't be an ear
// triangle bbox; min & max are calculated like this for speed // triangle bbox; min & max are calculated like this for speed
const double minTX = min<double>(a->x, min<double>(b->x, c->x)); const double minTX = std::min<double>(a->x, std::min<double>(b->x, c->x));
const double minTY = min<double>(a->y, min<double>(b->y, c->y)); const double minTY = std::min<double>(a->y, std::min<double>(b->y, c->y));
const double maxTX = max<double>(a->x, max<double>(b->x, c->x)); const double maxTX = std::max<double>(a->x, std::max<double>(b->x, c->x));
const double maxTY = max<double>(a->y, max<double>(b->y, c->y)); const double maxTY = std::max<double>(a->y, std::max<double>(b->y, c->y));
// z-order range for the current triangle bbox; // z-order range for the current triangle bbox;
const int32_t minZ = zOrder(minTX, minTY); const int32_t minZ = zOrder(minTX, minTY);
@ -717,10 +717,10 @@ bool Earcut<N>::intersects(const Node* p1, const Node* q1, const Node* p2, const
// for collinear points p, q, r, check if point q lies on segment pr // for collinear points p, q, r, check if point q lies on segment pr
template <typename N> template <typename N>
bool Earcut<N>::onSegment(const Node* p, const Node* q, const Node* r) { bool Earcut<N>::onSegment(const Node* p, const Node* q, const Node* r) {
return q->x <= max<double>(p->x, r->x) && return q->x <= std::max<double>(p->x, r->x) &&
q->x >= min<double>(p->x, r->x) && q->x >= std::min<double>(p->x, r->x) &&
q->y <= max<double>(p->y, r->y) && q->y <= std::max<double>(p->y, r->y) &&
q->y >= min<double>(p->y, r->y); q->y >= std::min<double>(p->y, r->y);
} }
template <typename N> template <typename N>

View file

@ -34,7 +34,7 @@
*/ */
#include "files.h" #include "files.h"
#include "templates.h" // just for 'clamp' // just for 'clamp'
#include "zstring.h" #include "zstring.h"

View file

@ -42,7 +42,7 @@
#include <stdexcept> #include <stdexcept>
#include "files.h" #include "files.h"
#include "templates.h"
#include "zstring.h" #include "zstring.h"
#include "cmdlib.h" #include "cmdlib.h"

View file

@ -39,7 +39,7 @@
#include "files.h" #include "files.h"
#include "filesystem.h" #include "filesystem.h"
#include "printf.h" #include "printf.h"
#include "templates.h"
#include "m_png.h" #include "m_png.h"
/****************************/ /****************************/

View file

@ -21,7 +21,7 @@
*/ */
#include <stdlib.h> #include <stdlib.h>
#include "templates.h"
#include "r_memory.h" #include "r_memory.h"
#include <stdlib.h> #include <stdlib.h>

View file

@ -37,7 +37,7 @@
#include "cmdlib.h" #include "cmdlib.h"
#include "s_playlist.h" #include "s_playlist.h"
#include "templates.h"
#include "v_text.h" #include "v_text.h"
#include "files.h" #include "files.h"

View file

@ -36,7 +36,7 @@
#include <assert.h> #include <assert.h>
#include "mapinfo.h" #include "mapinfo.h"
#include "g_mapinfo.h" #include "g_mapinfo.h"
#include "templates.h"
#include "filesystem.h" #include "filesystem.h"
#include "cmdlib.h" #include "cmdlib.h"
#include "v_video.h" #include "v_video.h"

View file

@ -35,7 +35,7 @@
// HEADER FILES ------------------------------------------------------------ // HEADER FILES ------------------------------------------------------------
#include "templates.h"
#include "c_dispatch.h" #include "c_dispatch.h"
#include "filesystem.h" #include "filesystem.h"
#include "v_text.h" #include "v_text.h"

View file

@ -15,7 +15,7 @@
#include "filesystem.h" #include "filesystem.h"
#include "zstring.h" #include "zstring.h"
#include "palentry.h" #include "palentry.h"
#include "templates.h"
enum enum
{ {

View file

@ -36,7 +36,7 @@
#include <assert.h> #include <assert.h>
#include "build.h" #include "build.h"
#include "templates.h"
#include "statusbar.h" #include "statusbar.h"
#include "c_cvars.h" #include "c_cvars.h"
#include "c_dispatch.h" #include "c_dispatch.h"

View file

@ -12,7 +12,7 @@
#include "hw_material.h" #include "hw_material.h"
#include "hw_renderstate.h" #include "hw_renderstate.h"
#include "pm_renderstate.h" #include "pm_renderstate.h"
#include "templates.h"
class FShader; class FShader;
class FGameTexture; class FGameTexture;