diff --git a/CMakeLists.txt b/CMakeLists.txt index 7434353ad34..e51373b4400 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -777,13 +777,6 @@ mark_as_advanced(WITH_MEM_JEMALLOC) option(WITH_MEM_VALGRIND "Enable extended valgrind support for better reporting" OFF) mark_as_advanced(WITH_MEM_VALGRIND) -# Debug -option(WITH_CXX_GUARDEDALLOC "\ -Enable GuardedAlloc for C++ memory allocation tracking (only enable for development)" - OFF -) -mark_as_advanced(WITH_CXX_GUARDEDALLOC) - option(WITH_ASSERT_ABORT "Call abort() when raising an assertion through BLI_assert()" ON) mark_as_advanced(WITH_ASSERT_ABORT) @@ -2598,12 +2591,6 @@ mark_as_advanced( # ------------------------------------------------------------------------------- # Global Defines -# better not set includes here but this debugging option is off by default. -if(WITH_CXX_GUARDEDALLOC) - include_directories(${CMAKE_SOURCE_DIR}/intern/guardedalloc) - add_definitions(-DWITH_CXX_GUARDEDALLOC) -endif() - if(WITH_ASSERT_ABORT) add_definitions(-DWITH_ASSERT_ABORT) endif() diff --git a/build_files/cmake/config/blender_developer.cmake b/build_files/cmake/config/blender_developer.cmake index ddf729f3131..939a9f12a92 100644 --- a/build_files/cmake/config/blender_developer.cmake +++ b/build_files/cmake/config/blender_developer.cmake @@ -26,7 +26,3 @@ set(WITH_PYTHON_SAFETY ON CACHE BOOL "" FORCE) if(WIN32) set(WITH_WINDOWS_BUNDLE_CRT OFF CACHE BOOL "" FORCE) endif() - -# This may have issues with C++ initialization order, needs to be tested -# on all platforms to be sure this is safe to enable. -# set(WITH_CXX_GUARDEDALLOC ON CACHE BOOL "" FORCE) diff --git a/intern/dualcon/CMakeLists.txt b/intern/dualcon/CMakeLists.txt index 37006136952..68f19fa559c 100644 --- a/intern/dualcon/CMakeLists.txt +++ b/intern/dualcon/CMakeLists.txt @@ -5,6 +5,7 @@ set(INC . intern + ../guardedalloc ) set(INC_SYS diff --git a/intern/dualcon/dualcon.h b/intern/dualcon/dualcon.h index 2a6c6ee85db..f442fc7e647 100644 --- a/intern/dualcon/dualcon.h +++ b/intern/dualcon/dualcon.h @@ -5,9 +5,7 @@ #ifndef __DUALCON_H__ #define __DUALCON_H__ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #ifdef __cplusplus extern "C" { diff --git a/intern/dualcon/intern/MemoryAllocator.h b/intern/dualcon/intern/MemoryAllocator.h index 9203cc5d1fc..903f00e07f6 100644 --- a/intern/dualcon/intern/MemoryAllocator.h +++ b/intern/dualcon/intern/MemoryAllocator.h @@ -33,9 +33,7 @@ class VirtualMemoryAllocator { virtual int getAll() = 0; virtual int getBytes() = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:VirtualMemoryAllocator") -#endif }; /** @@ -194,9 +192,7 @@ template class MemoryAllocator : public VirtualMemoryAllocator { return N; }; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:MemoryAllocator") -#endif }; #endif /* __MEMORYALLOCATOR_H__ */ diff --git a/intern/dualcon/intern/ModelReader.h b/intern/dualcon/intern/ModelReader.h index e55d644b60a..e058da4b7d2 100644 --- a/intern/dualcon/intern/ModelReader.h +++ b/intern/dualcon/intern/ModelReader.h @@ -7,9 +7,7 @@ #include "GeoCommon.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" /* * Virtual class for input file readers @@ -44,9 +42,7 @@ class ModelReader { virtual void printInfo() = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:ModelReader") -#endif }; #endif /* __MODELREADER_H__ */ diff --git a/intern/dualcon/intern/Projections.cpp b/intern/dualcon/intern/Projections.cpp index 31e8b25b5b9..635001a370b 100644 --- a/intern/dualcon/intern/Projections.cpp +++ b/intern/dualcon/intern/Projections.cpp @@ -2,9 +2,7 @@ * * SPDX-License-Identifier: GPL-2.0-or-later */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "Projections.h" #include diff --git a/intern/dualcon/intern/Projections.h b/intern/dualcon/intern/Projections.h index 6011e8d1b04..811dc922849 100644 --- a/intern/dualcon/intern/Projections.h +++ b/intern/dualcon/intern/Projections.h @@ -106,9 +106,7 @@ class CubeTriangleIsect { float getIntersectionPrimary(int edgeInd) const; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:CubeTriangleIsect") -#endif }; #endif /* __PROJECTIONS_H__ */ diff --git a/intern/dualcon/intern/Queue.h b/intern/dualcon/intern/Queue.h index aa2445fc70b..11c229217e8 100644 --- a/intern/dualcon/intern/Queue.h +++ b/intern/dualcon/intern/Queue.h @@ -75,9 +75,7 @@ class GridQueue { return 1; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:GridQueue") -#endif }; #endif /* __QUEUE_H__ */ diff --git a/intern/dualcon/intern/cubes.h b/intern/dualcon/intern/cubes.h index a968465fff7..5920bd194a9 100644 --- a/intern/dualcon/intern/cubes.h +++ b/intern/dualcon/intern/cubes.h @@ -24,9 +24,7 @@ class Cubes { } } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:Cubes") -#endif }; #endif /* __CUBES_H__ */ diff --git a/intern/dualcon/intern/dualcon_c_api.cpp b/intern/dualcon/intern/dualcon_c_api.cpp index 73b582600c4..29c14180980 100644 --- a/intern/dualcon/intern/dualcon_c_api.cpp +++ b/intern/dualcon/intern/dualcon_c_api.cpp @@ -143,9 +143,7 @@ class DualConInputReader : public ModelReader { return sizeof(DualConInputReader); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:DualConInputReader") -#endif }; void *dualcon(const DualConInput *input_mesh, diff --git a/intern/dualcon/intern/octree.cpp b/intern/dualcon/intern/octree.cpp index f1778fd2d43..aa166f7e8bd 100644 --- a/intern/dualcon/intern/octree.cpp +++ b/intern/dualcon/intern/octree.cpp @@ -2,9 +2,7 @@ * * SPDX-License-Identifier: GPL-2.0-or-later */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "octree.h" #include diff --git a/intern/dualcon/intern/octree.h b/intern/dualcon/intern/octree.h index f093e1afc07..c52947f663a 100644 --- a/intern/dualcon/intern/octree.h +++ b/intern/dualcon/intern/octree.h @@ -1390,9 +1390,7 @@ class Octree { return npar; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("DUALCON:Octree") -#endif }; #endif /* __OCTREE_H__ */ diff --git a/intern/ghost/CMakeLists.txt b/intern/ghost/CMakeLists.txt index 15a3e318716..abc5786bc64 100644 --- a/intern/ghost/CMakeLists.txt +++ b/intern/ghost/CMakeLists.txt @@ -5,6 +5,7 @@ set(INC PUBLIC . ../../source/blender/imbuf + ../guardedalloc ) set(INC_SYS diff --git a/intern/ghost/GHOST_IContext.hh b/intern/ghost/GHOST_IContext.hh index 8814a86e3d1..9387a1bb4de 100644 --- a/intern/ghost/GHOST_IContext.hh +++ b/intern/ghost/GHOST_IContext.hh @@ -110,7 +110,5 @@ class GHOST_IContext { std::function swap_buffers_post_callback) = 0; #endif -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_IContext") -#endif }; diff --git a/intern/ghost/GHOST_IEvent.hh b/intern/ghost/GHOST_IEvent.hh index d14f1c0d469..de1c9ad8642 100644 --- a/intern/ghost/GHOST_IEvent.hh +++ b/intern/ghost/GHOST_IEvent.hh @@ -56,7 +56,5 @@ class GHOST_IEvent { */ virtual GHOST_TEventDataPtr getData() const = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_IEvent") -#endif }; diff --git a/intern/ghost/GHOST_IEventConsumer.hh b/intern/ghost/GHOST_IEventConsumer.hh index 546fd592518..eec31e82e5e 100644 --- a/intern/ghost/GHOST_IEventConsumer.hh +++ b/intern/ghost/GHOST_IEventConsumer.hh @@ -34,7 +34,5 @@ class GHOST_IEventConsumer { */ virtual bool processEvent(const GHOST_IEvent *event) = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_IEventConsumer") -#endif }; diff --git a/intern/ghost/GHOST_ISystem.hh b/intern/ghost/GHOST_ISystem.hh index ec80b9ea395..884a08b50a1 100644 --- a/intern/ghost/GHOST_ISystem.hh +++ b/intern/ghost/GHOST_ISystem.hh @@ -560,7 +560,5 @@ class GHOST_ISystem { /** Function to call that sets the back-trace. */ static GHOST_TBacktraceFn m_backtrace_fn; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_ISystem") -#endif }; diff --git a/intern/ghost/GHOST_ISystemPaths.hh b/intern/ghost/GHOST_ISystemPaths.hh index c463a38e64b..d94f47c7d80 100644 --- a/intern/ghost/GHOST_ISystemPaths.hh +++ b/intern/ghost/GHOST_ISystemPaths.hh @@ -79,7 +79,5 @@ class GHOST_ISystemPaths { /** The one and only system paths. */ static GHOST_ISystemPaths *m_systemPaths; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_ISystemPaths") -#endif }; diff --git a/intern/ghost/GHOST_ITimerTask.hh b/intern/ghost/GHOST_ITimerTask.hh index 8b823f0af29..c77106c4fa6 100644 --- a/intern/ghost/GHOST_ITimerTask.hh +++ b/intern/ghost/GHOST_ITimerTask.hh @@ -54,7 +54,5 @@ class GHOST_ITimerTask { */ virtual void setUserData(const GHOST_TUserDataPtr userData) = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_ITimerTask") -#endif }; diff --git a/intern/ghost/GHOST_IWindow.hh b/intern/ghost/GHOST_IWindow.hh index c3124b814e3..ace5c52df27 100644 --- a/intern/ghost/GHOST_IWindow.hh +++ b/intern/ghost/GHOST_IWindow.hh @@ -364,7 +364,5 @@ class GHOST_IWindow { virtual void endIME() = 0; #endif /* WITH_INPUT_IME */ -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_IWindow") -#endif }; diff --git a/intern/ghost/GHOST_Rect.hh b/intern/ghost/GHOST_Rect.hh index d8bab3eaba8..2b85e2c49fe 100644 --- a/intern/ghost/GHOST_Rect.hh +++ b/intern/ghost/GHOST_Rect.hh @@ -159,9 +159,7 @@ class GHOST_Rect { /** Bottom coordinate of the rectangle */ int32_t m_b; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_Rect") -#endif }; inline int32_t GHOST_Rect::getWidth() const diff --git a/intern/ghost/GHOST_Types.h b/intern/ghost/GHOST_Types.h index 4c4e9916587..5883096d10d 100644 --- a/intern/ghost/GHOST_Types.h +++ b/intern/ghost/GHOST_Types.h @@ -21,17 +21,9 @@ /* This is used by `GHOST_C-api.h` too, cannot use C++ conventions. */ // NOLINTBEGIN: modernize-use-using -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#else -/* Convenience unsigned abbreviations (#WITH_CXX_GUARDEDALLOC defines these). */ -typedef unsigned int uint; -typedef unsigned short ushort; -typedef unsigned long ulong; -typedef unsigned char uchar; -#endif +#include "MEM_guardedalloc.h" -#if defined(WITH_CXX_GUARDEDALLOC) && defined(__cplusplus) +#if defined(__cplusplus) # define GHOST_DECLARE_HANDLE(name) \ typedef struct name##__ { \ int unused; \ diff --git a/intern/ghost/intern/GHOST_CallbackEventConsumer.hh b/intern/ghost/intern/GHOST_CallbackEventConsumer.hh index 4966e56e0d5..3bd5dcedfbd 100644 --- a/intern/ghost/intern/GHOST_CallbackEventConsumer.hh +++ b/intern/ghost/intern/GHOST_CallbackEventConsumer.hh @@ -44,7 +44,5 @@ class GHOST_CallbackEventConsumer : public GHOST_IEventConsumer { /** The data passed back through the call-back routine. */ GHOST_TUserDataPtr m_userData; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_CallbackEventConsumer") -#endif }; diff --git a/intern/ghost/intern/GHOST_Context.hh b/intern/ghost/intern/GHOST_Context.hh index 1a46fc14a81..c5b922036a3 100644 --- a/intern/ghost/intern/GHOST_Context.hh +++ b/intern/ghost/intern/GHOST_Context.hh @@ -195,9 +195,7 @@ class GHOST_Context : public GHOST_IContext { static void initClearGL(); #endif -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_Context") -#endif }; #ifdef _WIN32 diff --git a/intern/ghost/intern/GHOST_DisplayManager.hh b/intern/ghost/intern/GHOST_DisplayManager.hh index b14daea7595..e7104aa6ed1 100644 --- a/intern/ghost/intern/GHOST_DisplayManager.hh +++ b/intern/ghost/intern/GHOST_DisplayManager.hh @@ -106,7 +106,5 @@ class GHOST_DisplayManager { /** The list with display settings for the main display. */ std::vector m_settings; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_DisplayManager") -#endif }; diff --git a/intern/ghost/intern/GHOST_DropTargetWin32.hh b/intern/ghost/intern/GHOST_DropTargetWin32.hh index f06fd55efca..f8ec4d8b34e 100644 --- a/intern/ghost/intern/GHOST_DropTargetWin32.hh +++ b/intern/ghost/intern/GHOST_DropTargetWin32.hh @@ -133,7 +133,5 @@ class GHOST_DropTargetWin32 : public IDropTarget { /* Data type of the dragged object */ GHOST_TDragnDropTypes m_draggedObjectType; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_DropTargetWin32") -#endif }; diff --git a/intern/ghost/intern/GHOST_DropTargetX11.hh b/intern/ghost/intern/GHOST_DropTargetX11.hh index d89ba2a7d78..8953f47e3aa 100644 --- a/intern/ghost/intern/GHOST_DropTargetX11.hh +++ b/intern/ghost/intern/GHOST_DropTargetX11.hh @@ -98,7 +98,5 @@ class GHOST_DropTargetX11 { /* Counter of references to global #XDND structures. */ static int m_refCounter; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_DropTargetX11") -#endif }; diff --git a/intern/ghost/intern/GHOST_EventManager.hh b/intern/ghost/intern/GHOST_EventManager.hh index 8f52dca3717..ebe4efd88c4 100644 --- a/intern/ghost/intern/GHOST_EventManager.hh +++ b/intern/ghost/intern/GHOST_EventManager.hh @@ -120,7 +120,5 @@ class GHOST_EventManager { /** The list with event consumers. */ TConsumerVector m_consumers; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_EventManager") -#endif }; diff --git a/intern/ghost/intern/GHOST_TimerManager.hh b/intern/ghost/intern/GHOST_TimerManager.hh index 2597c6aea2b..7248dd16cb1 100644 --- a/intern/ghost/intern/GHOST_TimerManager.hh +++ b/intern/ghost/intern/GHOST_TimerManager.hh @@ -92,7 +92,5 @@ class GHOST_TimerManager { /** The list with event consumers. */ TTimerVector m_timers; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_TimerManager") -#endif }; diff --git a/intern/ghost/intern/GHOST_WindowManager.hh b/intern/ghost/intern/GHOST_WindowManager.hh index b6b1120e31f..08ee22f6869 100644 --- a/intern/ghost/intern/GHOST_WindowManager.hh +++ b/intern/ghost/intern/GHOST_WindowManager.hh @@ -123,7 +123,5 @@ class GHOST_WindowManager { /** Window that was active before entering full-screen state. */ GHOST_IWindow *m_activeWindowBeforeFullScreen; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("GHOST:GHOST_WindowManager") -#endif }; diff --git a/intern/guardedalloc/CMakeLists.txt b/intern/guardedalloc/CMakeLists.txt index a15378c46d7..70af302d721 100644 --- a/intern/guardedalloc/CMakeLists.txt +++ b/intern/guardedalloc/CMakeLists.txt @@ -63,14 +63,6 @@ endif() blender_add_lib(bf_intern_guardedalloc "${SRC}" "${INC}" "${INC_SYS}" "${LIB}") add_library(bf::intern::guardedalloc ALIAS bf_intern_guardedalloc) -# Override C++ allocator, optional. -if(WITH_CXX_GUARDEDALLOC) - set(SRC - cpp/mallocn.cpp - ) - blender_add_lib(bf_intern_guardedalloc_cpp "${SRC}" "${INC}" "${INC_SYS}" "${LIB}") -endif() - if(WITH_GTESTS) set(TEST_SRC tests/guardedalloc_alignment_test.cc diff --git a/intern/guardedalloc/cpp/mallocn.cpp b/intern/guardedalloc/cpp/mallocn.cpp deleted file mode 100644 index 71d1ed9f9f6..00000000000 --- a/intern/guardedalloc/cpp/mallocn.cpp +++ /dev/null @@ -1,51 +0,0 @@ -/* SPDX-FileCopyrightText: 2002-2022 Blender Authors - * - * SPDX-License-Identifier: GPL-2.0-or-later */ - -/** \file - * \ingroup intern_mem - */ - -#include -#include - -#include "../intern/mallocn_intern_function_pointers.hh" - -using namespace mem_guarded::internal; - -void *operator new(size_t size, const char *str); -void *operator new[](size_t size, const char *str); - -/* not default but can be used when needing to set a string */ -void *operator new(size_t size, const char *str) -{ - return mem_mallocN_aligned_ex(size, 1, str, AllocationType::NEW_DELETE); -} -void *operator new[](size_t size, const char *str) -{ - return mem_mallocN_aligned_ex(size, 1, str, AllocationType::NEW_DELETE); -} - -void *operator new(size_t size) -{ - return mem_mallocN_aligned_ex(size, 1, "C++/anonymous", AllocationType::NEW_DELETE); -} -void *operator new[](size_t size) -{ - return mem_mallocN_aligned_ex(size, 1, "C++/anonymous[]", AllocationType::NEW_DELETE); -} - -void operator delete(void *p) throw() -{ - /* `delete nullptr` is valid in c++. */ - if (p) { - mem_freeN_ex(p, AllocationType::NEW_DELETE); - } -} -void operator delete[](void *p) throw() -{ - /* `delete nullptr` is valid in c++. */ - if (p) { - mem_freeN_ex(p, AllocationType::NEW_DELETE); - } -} diff --git a/source/blender/blenkernel/BKE_cryptomatte.hh b/source/blender/blenkernel/BKE_cryptomatte.hh index 66286ac1817..ac1df67a98e 100644 --- a/source/blender/blenkernel/BKE_cryptomatte.hh +++ b/source/blender/blenkernel/BKE_cryptomatte.hh @@ -96,9 +96,7 @@ struct CryptomatteHash { struct CryptomatteLayer { blender::Map hashes; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("cryptomatte:CryptomatteLayer") -#endif static std::unique_ptr read_from_manifest(blender::StringRefNull manifest); uint32_t add_ID(const ID &id); diff --git a/source/blender/blenkernel/intern/cryptomatte.cc b/source/blender/blenkernel/intern/cryptomatte.cc index 38a6e24cb15..461ac3a4297 100644 --- a/source/blender/blenkernel/intern/cryptomatte.cc +++ b/source/blender/blenkernel/intern/cryptomatte.cc @@ -51,9 +51,7 @@ struct CryptomatteSession { blender::bke::cryptomatte::CryptomatteLayer &add_layer(std::string layer_name); std::optional operator[](float encoded_hash) const; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("cryptomatte:CryptomatteSession") -#endif }; CryptomatteSession::CryptomatteSession(const Main *bmain) diff --git a/source/blender/blenlib/BLI_implicit_sharing.hh b/source/blender/blenlib/BLI_implicit_sharing.hh index 79b90f5de2b..b5ffca3b21d 100644 --- a/source/blender/blenlib/BLI_implicit_sharing.hh +++ b/source/blender/blenlib/BLI_implicit_sharing.hh @@ -214,9 +214,7 @@ template class ImplicitSharedValue : public ImplicitSharingInfo { { } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("ImplicitSharedValue"); -#endif private: void delete_self_with_data() override diff --git a/source/blender/blenlib/intern/task_graph.cc b/source/blender/blenlib/intern/task_graph.cc index cd7e09c31c2..f39bf8e8824 100644 --- a/source/blender/blenlib/intern/task_graph.cc +++ b/source/blender/blenlib/intern/task_graph.cc @@ -8,9 +8,7 @@ * Task graph. */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "BLI_task.h" @@ -28,9 +26,7 @@ struct TaskGraph { #endif std::vector> nodes; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("task_graph:TaskGraph") -#endif }; /* TaskNode - a node in the task graph. */ @@ -94,9 +90,7 @@ struct TaskNode { } } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("task_graph:TaskNode") -#endif }; TaskGraph *BLI_task_graph_create() diff --git a/source/blender/compositor/intern/COM_Converter.h b/source/blender/compositor/intern/COM_Converter.h index 7bc66948b81..5e0d6dee871 100644 --- a/source/blender/compositor/intern/COM_Converter.h +++ b/source/blender/compositor/intern/COM_Converter.h @@ -4,9 +4,7 @@ #pragma once -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" struct bNode; diff --git a/source/blender/compositor/intern/COM_Device.h b/source/blender/compositor/intern/COM_Device.h index 8d25cbc8f6c..56670cd998c 100644 --- a/source/blender/compositor/intern/COM_Device.h +++ b/source/blender/compositor/intern/COM_Device.h @@ -4,9 +4,7 @@ #pragma once -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -40,9 +38,7 @@ class Device { */ virtual void execute(struct WorkPackage *work) = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:Device") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_ExecutionModel.h b/source/blender/compositor/intern/COM_ExecutionModel.h index 1b28cf01160..5d1a1586b95 100644 --- a/source/blender/compositor/intern/COM_ExecutionModel.h +++ b/source/blender/compositor/intern/COM_ExecutionModel.h @@ -8,9 +8,7 @@ #include "DNA_vec_types.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -51,9 +49,7 @@ class ExecutionModel { virtual void execute(ExecutionSystem &exec_system) = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:BaseExecutionModel") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_ExecutionSystem.cc b/source/blender/compositor/intern/COM_ExecutionSystem.cc index ffe45b1d3b5..54551f75274 100644 --- a/source/blender/compositor/intern/COM_ExecutionSystem.cc +++ b/source/blender/compositor/intern/COM_ExecutionSystem.cc @@ -13,9 +13,7 @@ #include "COM_profiler.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { diff --git a/source/blender/compositor/intern/COM_ExecutionSystem.h b/source/blender/compositor/intern/COM_ExecutionSystem.h index 9fdfd046825..70d3451dd9e 100644 --- a/source/blender/compositor/intern/COM_ExecutionSystem.h +++ b/source/blender/compositor/intern/COM_ExecutionSystem.h @@ -192,9 +192,7 @@ class ExecutionSystem { /* allow the DebugInfo class to look at internals */ friend class DebugInfo; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:ExecutionSystem") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_FullFrameExecutionModel.cc b/source/blender/compositor/intern/COM_FullFrameExecutionModel.cc index 69c5696166e..8882fe34afd 100644 --- a/source/blender/compositor/intern/COM_FullFrameExecutionModel.cc +++ b/source/blender/compositor/intern/COM_FullFrameExecutionModel.cc @@ -16,9 +16,7 @@ #include "BLI_timeit.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { diff --git a/source/blender/compositor/intern/COM_FullFrameExecutionModel.h b/source/blender/compositor/intern/COM_FullFrameExecutionModel.h index 30f0a2a55bf..66bc28fd013 100644 --- a/source/blender/compositor/intern/COM_FullFrameExecutionModel.h +++ b/source/blender/compositor/intern/COM_FullFrameExecutionModel.h @@ -9,9 +9,7 @@ #include "COM_Enums.h" #include "COM_ExecutionModel.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -84,9 +82,7 @@ class FullFrameExecutionModel : public ExecutionModel { void update_progress_bar(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:FullFrameExecutionModel") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_MemoryBuffer.h b/source/blender/compositor/intern/COM_MemoryBuffer.h index 4f724cf09f8..3039bd73378 100644 --- a/source/blender/compositor/intern/COM_MemoryBuffer.h +++ b/source/blender/compositor/intern/COM_MemoryBuffer.h @@ -679,9 +679,7 @@ class MemoryBuffer { int to_y, int to_channel_offset); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:MemoryBuffer") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_MetaData.h b/source/blender/compositor/intern/COM_MetaData.h index 56b6c142abf..bf7bb062db4 100644 --- a/source/blender/compositor/intern/COM_MetaData.h +++ b/source/blender/compositor/intern/COM_MetaData.h @@ -59,9 +59,7 @@ class MetaData { /* Invokes the given callback on each entry of the meta data. */ void for_each_entry(FunctionRef callback) const; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:MetaData") -#endif }; struct MetaDataExtractCallbackData { diff --git a/source/blender/compositor/intern/COM_NodeConverter.h b/source/blender/compositor/intern/COM_NodeConverter.h index 081a54e2f5e..1f8da29ab61 100644 --- a/source/blender/compositor/intern/COM_NodeConverter.h +++ b/source/blender/compositor/intern/COM_NodeConverter.h @@ -4,9 +4,7 @@ #pragma once -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -104,9 +102,7 @@ class NodeConverter { /** The internal builder for storing the results of the graph construction. */ NodeOperationBuilder *builder_; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeCompiler") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_NodeGraph.h b/source/blender/compositor/intern/COM_NodeGraph.h index b4d9a9a94e8..a374c9ccc92 100644 --- a/source/blender/compositor/intern/COM_NodeGraph.h +++ b/source/blender/compositor/intern/COM_NodeGraph.h @@ -6,9 +6,7 @@ #include "DNA_node_types.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -96,9 +94,7 @@ class NodeGraph { bNodeInstanceKey key, bool is_active_group); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeGraph") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_NodeOperation.h b/source/blender/compositor/intern/COM_NodeOperation.h index 1fabae0deb6..de755866187 100644 --- a/source/blender/compositor/intern/COM_NodeOperation.h +++ b/source/blender/compositor/intern/COM_NodeOperation.h @@ -126,9 +126,7 @@ class NodeOperationInput { */ bool determine_canvas(const rcti &preferred_area, rcti &r_area); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeOperation") -#endif }; class NodeOperationOutput { @@ -155,9 +153,7 @@ class NodeOperationOutput { void determine_canvas(const rcti &preferred_area, rcti &r_area); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeOperation") -#endif }; struct NodeOperationFlags { @@ -565,9 +561,7 @@ class NodeOperation { /* allow the DebugInfo class to look at internals */ friend class DebugInfo; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeOperation") -#endif }; std::ostream &operator<<(std::ostream &os, const NodeOperationFlags &node_operation_flags); diff --git a/source/blender/compositor/intern/COM_NodeOperationBuilder.h b/source/blender/compositor/intern/COM_NodeOperationBuilder.h index 4d2d652ca54..5eb6cf5b754 100644 --- a/source/blender/compositor/intern/COM_NodeOperationBuilder.h +++ b/source/blender/compositor/intern/COM_NodeOperationBuilder.h @@ -144,9 +144,7 @@ class NodeOperationBuilder { void merge_equal_operations(); void merge_equal_operations(NodeOperation *from, NodeOperation *into); void save_graphviz(StringRefNull name = ""); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:NodeCompilerImpl") -#endif }; /** Create a graphviz representation of the NodeOperationBuilder. */ diff --git a/source/blender/compositor/intern/COM_SharedOperationBuffers.h b/source/blender/compositor/intern/COM_SharedOperationBuffers.h index 7e9509efe1b..08dff4db6d4 100644 --- a/source/blender/compositor/intern/COM_SharedOperationBuffers.h +++ b/source/blender/compositor/intern/COM_SharedOperationBuffers.h @@ -9,9 +9,7 @@ #include "DNA_vec_types.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -81,9 +79,7 @@ class SharedOperationBuffers { private: BufferData &get_buffer_data(NodeOperation *op); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:SharedOperationBuffers") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_WorkPackage.h b/source/blender/compositor/intern/COM_WorkPackage.h index 951eb981977..62221dfda21 100644 --- a/source/blender/compositor/intern/COM_WorkPackage.h +++ b/source/blender/compositor/intern/COM_WorkPackage.h @@ -4,9 +4,7 @@ #pragma once -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include @@ -27,9 +25,7 @@ struct WorkPackage { */ std::function executed_fn; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:WorkPackage") -#endif }; } // namespace blender::compositor diff --git a/source/blender/compositor/intern/COM_WorkScheduler.h b/source/blender/compositor/intern/COM_WorkScheduler.h index 4a1ac60a983..78368aef5a7 100644 --- a/source/blender/compositor/intern/COM_WorkScheduler.h +++ b/source/blender/compositor/intern/COM_WorkScheduler.h @@ -4,9 +4,7 @@ #pragma once -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace blender::compositor { @@ -62,9 +60,7 @@ struct WorkScheduler { static int current_thread_id(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("COM:WorkScheduler") -#endif }; } // namespace blender::compositor diff --git a/source/blender/editors/animation/keyframes_keylist.cc b/source/blender/editors/animation/keyframes_keylist.cc index 3fa857c7de9..9b2484f4d7b 100644 --- a/source/blender/editors/animation/keyframes_keylist.cc +++ b/source/blender/editors/animation/keyframes_keylist.cc @@ -101,9 +101,7 @@ struct AnimKeylist { BLI_listbase_clear(&this->runtime.list_wrapper); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("editors:AnimKeylist") -#endif }; AnimKeylist *ED_keylist_create() diff --git a/source/blender/editors/space_view3d/view3d_navigate.cc b/source/blender/editors/space_view3d/view3d_navigate.cc index 8eff8979197..aa0a7662950 100644 --- a/source/blender/editors/space_view3d/view3d_navigate.cc +++ b/source/blender/editors/space_view3d/view3d_navigate.cc @@ -467,9 +467,7 @@ struct ViewOpsData_Utility : ViewOpsData { WM_keyconfig_update_suppress_end(); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("ViewOpsData_Utility") -#endif }; static bool view3d_navigation_poll_impl(bContext *C, const char viewlock) diff --git a/source/blender/editors/space_view3d/view3d_navigate.hh b/source/blender/editors/space_view3d/view3d_navigate.hh index 08c817d2c67..e4016c47e9e 100644 --- a/source/blender/editors/space_view3d/view3d_navigate.hh +++ b/source/blender/editors/space_view3d/view3d_navigate.hh @@ -189,9 +189,7 @@ struct ViewOpsData { const bool use_cursor_init = false); void end_navigation(bContext *C); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("ViewOpsData") -#endif }; /* view3d_navigate.cc */ diff --git a/source/blender/editors/transform/transform_snap_object_editmesh.cc b/source/blender/editors/transform/transform_snap_object_editmesh.cc index 007cbf859fe..8cc1368cebf 100644 --- a/source/blender/editors/transform/transform_snap_object_editmesh.cc +++ b/source/blender/editors/transform/transform_snap_object_editmesh.cc @@ -71,9 +71,7 @@ struct SnapCache_EditMesh : public SnapObjectContext::SnapCache { this->clear(); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("SnapCache_EditMesh") -#endif }; static Mesh *create_mesh(SnapObjectContext *sctx, diff --git a/source/blender/editors/transform/transform_snap_sequencer.cc b/source/blender/editors/transform/transform_snap_sequencer.cc index fa28b1769c6..e41a156a3fa 100644 --- a/source/blender/editors/transform/transform_snap_sequencer.cc +++ b/source/blender/editors/transform/transform_snap_sequencer.cc @@ -40,9 +40,7 @@ struct TransSeqSnapData { blender::Array source_snap_points; blender::Array target_snap_points; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("TransSeqSnapData") -#endif }; /* -------------------------------------------------------------------- */ diff --git a/source/blender/freestyle/intern/application/AppConfig.h b/source/blender/freestyle/intern/application/AppConfig.h index 148abf9e79d..d7059c87d64 100644 --- a/source/blender/freestyle/intern/application/AppConfig.h +++ b/source/blender/freestyle/intern/application/AppConfig.h @@ -14,9 +14,7 @@ #include "../system/Precision.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -74,9 +72,7 @@ class Path { static string getEnvVar(const string &iEnvVarName); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Config:Path") -#endif }; // diff --git a/source/blender/freestyle/intern/application/AppView.h b/source/blender/freestyle/intern/application/AppView.h index 9d623bd5d7b..b29aae0eaba 100644 --- a/source/blender/freestyle/intern/application/AppView.h +++ b/source/blender/freestyle/intern/application/AppView.h @@ -17,9 +17,7 @@ #include "BLI_math_base.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -253,9 +251,7 @@ class AppView { NodeGroup _p2DNode; NodeDrawingStyle *_p2DSelectionNode; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:AppView") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/application/Controller.h b/source/blender/freestyle/intern/application/Controller.h index 86f36996ff1..b549c927644 100644 --- a/source/blender/freestyle/intern/application/Controller.h +++ b/source/blender/freestyle/intern/application/Controller.h @@ -18,9 +18,7 @@ #include "../view_map/FEdgeXDetector.h" #include "../view_map/ViewMapBuilder.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" struct Depsgraph; struct Render; @@ -261,9 +259,7 @@ class Controller { SceneHash sceneHashFunc; real prevSceneHash; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Controller") -#endif }; extern Controller *g_pController; diff --git a/source/blender/freestyle/intern/blender_interface/BlenderFileLoader.h b/source/blender/freestyle/intern/blender_interface/BlenderFileLoader.h index e7f27d3fdc7..08421247262 100644 --- a/source/blender/freestyle/intern/blender_interface/BlenderFileLoader.h +++ b/source/blender/freestyle/intern/blender_interface/BlenderFileLoader.h @@ -42,9 +42,7 @@ #include "DEG_depsgraph_query.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -142,9 +140,7 @@ class BlenderFileLoader { RenderMonitor *_pRenderMonitor; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BlenderFileLoader") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/blender_interface/BlenderStrokeRenderer.h b/source/blender/freestyle/intern/blender_interface/BlenderStrokeRenderer.h index 7998c2a0a14..0fee01aa9d1 100644 --- a/source/blender/freestyle/intern/blender_interface/BlenderStrokeRenderer.h +++ b/source/blender/freestyle/intern/blender_interface/BlenderStrokeRenderer.h @@ -81,9 +81,7 @@ class BlenderStrokeRenderer : public StrokeRenderer { vector _strokeReps; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BlenderStrokeRenderer") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/blender_interface/BlenderStyleModule.h b/source/blender/freestyle/intern/blender_interface/BlenderStyleModule.h index 2418f86b9bd..ef2ef2a02f1 100644 --- a/source/blender/freestyle/intern/blender_interface/BlenderStyleModule.h +++ b/source/blender/freestyle/intern/blender_interface/BlenderStyleModule.h @@ -38,9 +38,7 @@ class BufferedStyleModule : public StyleModule { private: string _buffer; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BufferedStyleModule") -#endif }; class BlenderStyleModule : public StyleModule { @@ -64,9 +62,7 @@ class BlenderStyleModule : public StyleModule { private: struct Text *_text; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BlenderStyleModule") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/BBox.h b/source/blender/freestyle/intern/geometry/BBox.h index 6b3882c71c6..f1a68ee714a 100644 --- a/source/blender/freestyle/intern/geometry/BBox.h +++ b/source/blender/freestyle/intern/geometry/BBox.h @@ -14,9 +14,7 @@ #include "BLI_utildefines.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -124,9 +122,7 @@ template class BBox { Point _max; bool _empty; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BBox") -#endif }; template BBox &operator+(const BBox &b1, const BBox &b2) diff --git a/source/blender/freestyle/intern/geometry/Bezier.h b/source/blender/freestyle/intern/geometry/Bezier.h index aae1c4717f4..9e4875b16af 100644 --- a/source/blender/freestyle/intern/geometry/Bezier.h +++ b/source/blender/freestyle/intern/geometry/Bezier.h @@ -15,9 +15,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -44,9 +42,7 @@ class BezierCurveSegment { return _Vertices; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BezierCurveSegment") -#endif }; class BezierCurve { @@ -72,9 +68,7 @@ class BezierCurve { return _Segments; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BezierCurve") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/FastGrid.h b/source/blender/freestyle/intern/geometry/FastGrid.h index 6a46c1c6768..1a9b0db31d1 100644 --- a/source/blender/freestyle/intern/geometry/FastGrid.h +++ b/source/blender/freestyle/intern/geometry/FastGrid.h @@ -57,9 +57,7 @@ class FastGrid : public Grid { Cell **_cells; uint _cells_size; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FastGrid") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/GeomCleaner.h b/source/blender/freestyle/intern/geometry/GeomCleaner.h index 04f19b7a858..1c2ddf7be24 100644 --- a/source/blender/freestyle/intern/geometry/GeomCleaner.h +++ b/source/blender/freestyle/intern/geometry/GeomCleaner.h @@ -13,9 +13,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -140,9 +138,7 @@ class GeomCleaner { uint *oVSize, uint **oIndices); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GeomCleaner") -#endif }; /** Binary operators */ @@ -225,9 +221,7 @@ class IndexedVertex { return (_Vector == v._Vector); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:IndexedVertex") -#endif }; #if 0 diff --git a/source/blender/freestyle/intern/geometry/Grid.h b/source/blender/freestyle/intern/geometry/Grid.h index 7655690bde4..36b9828191c 100644 --- a/source/blender/freestyle/intern/geometry/Grid.h +++ b/source/blender/freestyle/intern/geometry/Grid.h @@ -22,9 +22,7 @@ #include "BLI_utildefines.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -69,9 +67,7 @@ class Cell { Vec3r _orig; OccludersSet _occluders; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Cell") -#endif }; class GridVisitor { @@ -89,9 +85,7 @@ class GridVisitor { return false; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GridVisitor") -#endif }; /** Gathers all the occluders belonging to the cells traversed by the ray */ @@ -378,9 +372,7 @@ class Grid { // a ray OccludersSet _occluders; // List of all occluders inserted in the grid -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Grid") -#endif }; // @@ -400,9 +392,7 @@ class VirtualOccludersSet { Grid &grid; OccludersSet::iterator it, end; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:VirtualOccludersSet") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/GridHelpers.h b/source/blender/freestyle/intern/geometry/GridHelpers.h index 1cb7f14856f..f67c3866410 100644 --- a/source/blender/freestyle/intern/geometry/GridHelpers.h +++ b/source/blender/freestyle/intern/geometry/GridHelpers.h @@ -18,9 +18,7 @@ #include "../winged_edge/WEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -106,9 +104,7 @@ class Transform { virtual ~Transform() = 0; virtual Vec3r operator()(const Vec3r &point) const = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GridHelpers:Transform") -#endif }; inline bool insideProscenium(const real proscenium[4], const Polygon3r &polygon) diff --git a/source/blender/freestyle/intern/geometry/Noise.h b/source/blender/freestyle/intern/geometry/Noise.h index fceb3c5cd23..afa089584b3 100644 --- a/source/blender/freestyle/intern/geometry/Noise.h +++ b/source/blender/freestyle/intern/geometry/Noise.h @@ -13,9 +13,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -60,9 +58,7 @@ class Noise { /* UNUSED */ // int start; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Noise") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/Polygon.h b/source/blender/freestyle/intern/geometry/Polygon.h index 07fd532a0cc..2233c9f0233 100644 --- a/source/blender/freestyle/intern/geometry/Polygon.h +++ b/source/blender/freestyle/intern/geometry/Polygon.h @@ -14,9 +14,7 @@ #include "Geom.h" #include "GeomUtils.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -154,9 +152,7 @@ template class Polygon { Point _max; uint _id; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Geometry:Polygon") -#endif }; // diff --git a/source/blender/freestyle/intern/geometry/SweepLine.h b/source/blender/freestyle/intern/geometry/SweepLine.h index 7764add8874..0962f4cbbe8 100644 --- a/source/blender/freestyle/intern/geometry/SweepLine.h +++ b/source/blender/freestyle/intern/geometry/SweepLine.h @@ -12,9 +12,7 @@ #include #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -59,9 +57,7 @@ template class Intersection { real tA; // parameter defining the intersection point with respect to the segment EdgeA. real tB; // parameter defining the intersection point with respect to the segment EdgeB. -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Intersection") -#endif }; #ifdef _MSC_VER @@ -167,9 +163,7 @@ template class Segment { _Intersections; // list of intersections parameters bool _order; // true if A and B are in the same order than _edge.A and _edge.B. false otherwise. -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Segment") -#endif }; #ifdef _MSC_VER @@ -321,9 +315,7 @@ template class SweepLine { std::vector *> _IntersectedEdges; // the list of intersected edges std::vector> *> _Intersections; // the list of all intersections. -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SweepLine") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/geometry/VecMat.h b/source/blender/freestyle/intern/geometry/VecMat.h index ba5ad84a156..d788a83f226 100644 --- a/source/blender/freestyle/intern/geometry/VecMat.h +++ b/source/blender/freestyle/intern/geometry/VecMat.h @@ -13,9 +13,7 @@ #include #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -264,9 +262,7 @@ template class Vec { _dim = N, }; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:VecMat:Vec") -#endif }; // @@ -737,9 +733,7 @@ template class Matrix { protected: value_type _coord[_SIZE]; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:VecMat:Matrix") -#endif }; #undef _SIZE diff --git a/source/blender/freestyle/intern/geometry/normal_cycle.h b/source/blender/freestyle/intern/geometry/normal_cycle.h index cc4f0c33a12..17a03ac4cec 100644 --- a/source/blender/freestyle/intern/geometry/normal_cycle.h +++ b/source/blender/freestyle/intern/geometry/normal_cycle.h @@ -17,9 +17,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -101,9 +99,7 @@ class NormalCycle { real M_[6]; int i_[3]; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:OGF:NormalCycle") -#endif }; inline void NormalCycle::accumulate_dihedral_angle(const Vec3r &edge, diff --git a/source/blender/freestyle/intern/image/GaussianFilter.h b/source/blender/freestyle/intern/image/GaussianFilter.h index bb61c2a3752..9233b305433 100644 --- a/source/blender/freestyle/intern/image/GaussianFilter.h +++ b/source/blender/freestyle/intern/image/GaussianFilter.h @@ -14,9 +14,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -90,9 +88,7 @@ class GaussianFilter { protected: void computeMask(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GaussianFilter") -#endif }; /* diff --git a/source/blender/freestyle/intern/image/Image.h b/source/blender/freestyle/intern/image/Image.h index 548ccc3f357..9172d884b53 100644 --- a/source/blender/freestyle/intern/image/Image.h +++ b/source/blender/freestyle/intern/image/Image.h @@ -11,9 +11,7 @@ #include // for memcpy -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -159,9 +157,7 @@ class FrsImage { uint _Ox; // origin of the stored part uint _Oy; // origin of the stored part -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FrsImage") -#endif }; // diff --git a/source/blender/freestyle/intern/image/ImagePyramid.h b/source/blender/freestyle/intern/image/ImagePyramid.h index ed9556bbe92..9ea1bedce01 100644 --- a/source/blender/freestyle/intern/image/ImagePyramid.h +++ b/source/blender/freestyle/intern/image/ImagePyramid.h @@ -13,9 +13,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -63,9 +61,7 @@ class ImagePyramid { return _levels.size(); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ImagePyramid") -#endif }; class GaussianPyramid : public ImagePyramid { diff --git a/source/blender/freestyle/intern/scene_graph/DrawingStyle.h b/source/blender/freestyle/intern/scene_graph/DrawingStyle.h index 3be153bdb87..9c8f12cea1d 100644 --- a/source/blender/freestyle/intern/scene_graph/DrawingStyle.h +++ b/source/blender/freestyle/intern/scene_graph/DrawingStyle.h @@ -9,9 +9,7 @@ * \brief Class to define the drawing style of a node */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -85,9 +83,7 @@ class DrawingStyle { float PointSize; bool LightingEnabled; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:DrawingStyle") -#endif }; DrawingStyle::DrawingStyle(const DrawingStyle &iBrother) diff --git a/source/blender/freestyle/intern/scene_graph/FrsMaterial.h b/source/blender/freestyle/intern/scene_graph/FrsMaterial.h index 950cc1996be..e7d9052598d 100644 --- a/source/blender/freestyle/intern/scene_graph/FrsMaterial.h +++ b/source/blender/freestyle/intern/scene_graph/FrsMaterial.h @@ -11,9 +11,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -303,9 +301,7 @@ class FrsMaterial { float Shininess; int Priority; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FrsMaterial") -#endif }; FrsMaterial::FrsMaterial() diff --git a/source/blender/freestyle/intern/scene_graph/IndexedFaceSet.h b/source/blender/freestyle/intern/scene_graph/IndexedFaceSet.h index 9f30b61db8c..26ea474db11 100644 --- a/source/blender/freestyle/intern/scene_graph/IndexedFaceSet.h +++ b/source/blender/freestyle/intern/scene_graph/IndexedFaceSet.h @@ -292,9 +292,7 @@ class IndexedFaceSet : public Rep { uint _MISize; uint _TISize; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:IndexedFaceSet") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/LineRep.h b/source/blender/freestyle/intern/scene_graph/LineRep.h index e4264a1d401..9135e14b544 100644 --- a/source/blender/freestyle/intern/scene_graph/LineRep.h +++ b/source/blender/freestyle/intern/scene_graph/LineRep.h @@ -130,9 +130,7 @@ class LineRep : public Rep { vector _vertices; float _width; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:LineRep") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/Node.h b/source/blender/freestyle/intern/scene_graph/Node.h index 92d16682c25..68bd4e1674b 100644 --- a/source/blender/freestyle/intern/scene_graph/Node.h +++ b/source/blender/freestyle/intern/scene_graph/Node.h @@ -90,9 +90,7 @@ class Node : public BaseObject { private: BBox _BBox; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Node") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/NodeCamera.h b/source/blender/freestyle/intern/scene_graph/NodeCamera.h index 189f252c6ff..f3fabdc6d15 100644 --- a/source/blender/freestyle/intern/scene_graph/NodeCamera.h +++ b/source/blender/freestyle/intern/scene_graph/NodeCamera.h @@ -66,9 +66,7 @@ class NodeCamera : public Node { CameraType camera_type_; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:NodeCamera") -#endif }; class NodeOrthographicCamera : public NodeCamera { @@ -132,9 +130,7 @@ class NodeOrthographicCamera : public NodeCamera { double zNear_; double zFar_; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:NodeOrthographicCamera") -#endif }; class NodePerspectiveCamera : public NodeCamera { @@ -196,9 +192,7 @@ class NodePerspectiveCamera : public NodeCamera { NodePerspectiveCamera( double left, double right, double bottom, double top, double zNear, double zFar); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:NodePerspectiveCamera") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/NodeDrawingStyle.h b/source/blender/freestyle/intern/scene_graph/NodeDrawingStyle.h index d25ace53b26..2c1571b4914 100644 --- a/source/blender/freestyle/intern/scene_graph/NodeDrawingStyle.h +++ b/source/blender/freestyle/intern/scene_graph/NodeDrawingStyle.h @@ -83,9 +83,7 @@ class NodeDrawingStyle : public NodeGroup { private: DrawingStyle _DrawingStyle; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:NodeDrawingStyle") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/SceneHash.h b/source/blender/freestyle/intern/scene_graph/SceneHash.h index 16b13133f32..92b9f4840f7 100644 --- a/source/blender/freestyle/intern/scene_graph/SceneHash.h +++ b/source/blender/freestyle/intern/scene_graph/SceneHash.h @@ -15,9 +15,7 @@ #include "BLI_sys_types.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -57,9 +55,7 @@ class SceneHash : public SceneVisitor { uint32_t _sum; uint32_t _prevSum; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SceneHash") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/scene_graph/SceneVisitor.h b/source/blender/freestyle/intern/scene_graph/SceneVisitor.h index ca96452eaf6..72285b542d8 100644 --- a/source/blender/freestyle/intern/scene_graph/SceneVisitor.h +++ b/source/blender/freestyle/intern/scene_graph/SceneVisitor.h @@ -11,9 +11,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -78,9 +76,7 @@ class SceneVisitor { VISIT_COMPLETE_DEF(DrawingStyle) VISIT_COMPLETE_DEF(FrsMaterial) -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SceneVisitor") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Canvas.h b/source/blender/freestyle/intern/stroke/Canvas.h index c7ae8e4ed16..af299984a8a 100644 --- a/source/blender/freestyle/intern/stroke/Canvas.h +++ b/source/blender/freestyle/intern/stroke/Canvas.h @@ -21,9 +21,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -233,9 +231,7 @@ class Canvas { void causalStyleModules(std::vector &vec, uint index = 0); void setModified(uint index, bool iMod); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Canvas") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Chain.h b/source/blender/freestyle/intern/stroke/Chain.h index ce0bbd86ff0..372c1238604 100644 --- a/source/blender/freestyle/intern/stroke/Chain.h +++ b/source/blender/freestyle/intern/stroke/Chain.h @@ -90,9 +90,7 @@ class Chain : public Curve { return _splittingId; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Chain") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Curve.h b/source/blender/freestyle/intern/stroke/Curve.h index ab691e02fba..364ebe9785f 100644 --- a/source/blender/freestyle/intern/stroke/Curve.h +++ b/source/blender/freestyle/intern/stroke/Curve.h @@ -22,9 +22,7 @@ #include "../system/BaseIterator.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -334,9 +332,7 @@ class CurvePoint : public Interface0D { Vec2d directionFredo() const; #endif -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:CurvePoint") -#endif }; /**********************************/ @@ -583,9 +579,7 @@ class Curve : public Interface1D { */ virtual Interface0DIterator pointsEnd(float t = 0.0f); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Curve") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Modifiers.h b/source/blender/freestyle/intern/stroke/Modifiers.h index 5bae1c6e73e..d8926409497 100644 --- a/source/blender/freestyle/intern/stroke/Modifiers.h +++ b/source/blender/freestyle/intern/stroke/Modifiers.h @@ -11,9 +11,7 @@ #include "TimeStamp.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -33,9 +31,7 @@ template struct EdgeModifier : public unary_function { /** the () operator */ virtual void operator()(Edge &iEdge) {} -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:EdgeModifier") -#endif }; /** Modifier that sets the time stamp of an Interface1D to the time stamp of the system. */ diff --git a/source/blender/freestyle/intern/stroke/Module.h b/source/blender/freestyle/intern/stroke/Module.h index 1886023d971..7348ba87adf 100644 --- a/source/blender/freestyle/intern/stroke/Module.h +++ b/source/blender/freestyle/intern/stroke/Module.h @@ -12,9 +12,7 @@ #include "Canvas.h" #include "StyleModule.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -57,9 +55,7 @@ class Module { return canvas->getCurrentStyleModule(); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Module") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Operators.h b/source/blender/freestyle/intern/stroke/Operators.h index d8ef00a9c1c..b31260945b8 100644 --- a/source/blender/freestyle/intern/stroke/Operators.h +++ b/source/blender/freestyle/intern/stroke/Operators.h @@ -23,9 +23,7 @@ #include "../view_map/Interface1D.h" #include "../view_map/ViewMap.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -269,9 +267,7 @@ class Operators { static I1DContainer *_current_set; static StrokesContainer _current_strokes_set; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Operators") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/Predicates0D.h b/source/blender/freestyle/intern/stroke/Predicates0D.h index 925d3d8734c..f46bad83502 100644 --- a/source/blender/freestyle/intern/stroke/Predicates0D.h +++ b/source/blender/freestyle/intern/stroke/Predicates0D.h @@ -11,9 +11,7 @@ #include "../view_map/Functions0D.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -55,9 +53,7 @@ class UnaryPredicate0D { */ virtual int operator()(Interface0DIterator &it); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:UnaryPredicate0D") -#endif }; // @@ -100,9 +96,7 @@ class BinaryPredicate0D { */ virtual int operator()(Interface0D &inter1, Interface0D &inter2); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BinaryPredicate0D") -#endif }; // diff --git a/source/blender/freestyle/intern/stroke/Predicates1D.h b/source/blender/freestyle/intern/stroke/Predicates1D.h index 99e7e8ed702..660990d481f 100644 --- a/source/blender/freestyle/intern/stroke/Predicates1D.h +++ b/source/blender/freestyle/intern/stroke/Predicates1D.h @@ -18,9 +18,7 @@ #include "../view_map/Functions1D.h" #include "../view_map/Interface1D.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -62,9 +60,7 @@ class UnaryPredicate1D { */ virtual int operator()(Interface1D &inter); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:UnaryPredicate1D") -#endif }; // @@ -107,9 +103,7 @@ class BinaryPredicate1D { */ virtual int operator()(Interface1D &inter1, Interface1D &inter2); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BinaryPredicate1D") -#endif }; // diff --git a/source/blender/freestyle/intern/stroke/Stroke.h b/source/blender/freestyle/intern/stroke/Stroke.h index 72b9855af59..74459a3163b 100644 --- a/source/blender/freestyle/intern/stroke/Stroke.h +++ b/source/blender/freestyle/intern/stroke/Stroke.h @@ -20,9 +20,7 @@ #include "../system/FreestyleConfig.h" #include "../system/StringUtils.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" extern "C" { struct MTex; @@ -300,9 +298,7 @@ class StrokeAttribute { Vec2fMap *_userAttributesVec2f; Vec3fMap *_userAttributesVec3f; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeAttribute") -#endif }; // @@ -458,9 +454,7 @@ class StrokeVertex : public CurvePoint { /* interface definition */ /* inherited */ -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeVertex") -#endif }; // @@ -857,9 +851,7 @@ class Stroke : public Interface1D { virtual Interface0DIterator pointsBegin(float t = 0.0f); virtual Interface0DIterator pointsEnd(float t = 0.0f); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Stroke") -#endif }; // diff --git a/source/blender/freestyle/intern/stroke/StrokeLayer.h b/source/blender/freestyle/intern/stroke/StrokeLayer.h index 3b64234e7d8..d2202b228db 100644 --- a/source/blender/freestyle/intern/stroke/StrokeLayer.h +++ b/source/blender/freestyle/intern/stroke/StrokeLayer.h @@ -11,9 +11,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -81,9 +79,7 @@ class StrokeLayer { _strokes.push_back(iStroke); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeLayer") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/StrokeRenderer.h b/source/blender/freestyle/intern/stroke/StrokeRenderer.h index 7cfa644752b..9900d2a9935 100644 --- a/source/blender/freestyle/intern/stroke/StrokeRenderer.h +++ b/source/blender/freestyle/intern/stroke/StrokeRenderer.h @@ -20,9 +20,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -92,9 +90,7 @@ class TextureManager { static string _brushes_path; uint _defaultTextureId; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:TextureManager") -#endif }; /**********************************/ @@ -122,9 +118,7 @@ class StrokeRenderer { // static uint getTextureIndex(uint index); static TextureManager *_textureManager; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeRenderer") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/StrokeRep.h b/source/blender/freestyle/intern/stroke/StrokeRep.h index 7d7b282a15c..6eb93122a35 100644 --- a/source/blender/freestyle/intern/stroke/StrokeRep.h +++ b/source/blender/freestyle/intern/stroke/StrokeRep.h @@ -13,9 +13,7 @@ #include "../geometry/Geom.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "DNA_material_types.h" // for MAX_MTEX struct bNodeTree; @@ -113,9 +111,7 @@ class StrokeVertexRep { Vec3r _color; float _alpha; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeVertexRep") -#endif }; class Strip { @@ -156,9 +152,7 @@ class Strip { return _vertices; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Strip") -#endif }; class StrokeRep { @@ -255,9 +249,7 @@ class StrokeRep { } #endif -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeRep") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/StrokeShader.h b/source/blender/freestyle/intern/stroke/StrokeShader.h index 8b9c5358118..fc1dfa40eb6 100644 --- a/source/blender/freestyle/intern/stroke/StrokeShader.h +++ b/source/blender/freestyle/intern/stroke/StrokeShader.h @@ -12,9 +12,7 @@ #include #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -75,9 +73,7 @@ class StrokeShader { */ virtual int shade(Stroke &ioStroke) const; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeShader") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/StrokeTesselator.h b/source/blender/freestyle/intern/stroke/StrokeTesselator.h index 96b799dc27a..941e827fd30 100644 --- a/source/blender/freestyle/intern/stroke/StrokeTesselator.h +++ b/source/blender/freestyle/intern/stroke/StrokeTesselator.h @@ -13,9 +13,7 @@ #include "../scene_graph/LineRep.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -52,9 +50,7 @@ class StrokeTesselator { FrsMaterial _FrsMaterial; bool _overloadFrsMaterial; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StrokeTesselator") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/stroke/StyleModule.h b/source/blender/freestyle/intern/stroke/StyleModule.h index b7f4841d2e8..f6e898c754b 100644 --- a/source/blender/freestyle/intern/stroke/StyleModule.h +++ b/source/blender/freestyle/intern/stroke/StyleModule.h @@ -19,9 +19,7 @@ #include "../system/Interpreter.h" #include "../system/StringUtils.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -162,9 +160,7 @@ class StyleModule { protected: Interpreter *_inter; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:StyleModule") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/BaseIterator.h b/source/blender/freestyle/intern/system/BaseIterator.h index 28ee818f80f..42c95f118d6 100644 --- a/source/blender/freestyle/intern/system/BaseIterator.h +++ b/source/blender/freestyle/intern/system/BaseIterator.h @@ -11,9 +11,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -28,9 +26,7 @@ template class Const_traits { typedef ptrdiff_t difference_type; typedef Nonconst_traits Non_const_traits; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Const_traits") -#endif }; template class Nonconst_traits { @@ -41,27 +37,21 @@ template class Nonconst_traits { typedef ptrdiff_t difference_type; typedef Nonconst_traits Non_const_traits; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Nonconst_traits") -#endif }; class InputIteratorTag_Traits { public: typedef std::input_iterator_tag iterator_category; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:InputIteratorTag_Traits") -#endif }; class BidirectionalIteratorTag_Traits { public: typedef std::bidirectional_iterator_tag iterator_category; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BidirectionalIteratorTag_Traits") -#endif }; template class IteratorBase { @@ -80,9 +70,7 @@ template class IteratorBase { protected: IteratorBase() {} -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:IteratorBase") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/BaseObject.h b/source/blender/freestyle/intern/system/BaseObject.h index c10379a2339..e4f2d7f0def 100644 --- a/source/blender/freestyle/intern/system/BaseObject.h +++ b/source/blender/freestyle/intern/system/BaseObject.h @@ -10,9 +10,7 @@ * \brief Inspired by COM IUnknown system. */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "BLI_sys_types.h" @@ -53,9 +51,7 @@ class BaseObject { private: uint _ref_counter; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BaseObject") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/Exception.h b/source/blender/freestyle/intern/system/Exception.h index ed81c1344f5..3ba9202fa49 100644 --- a/source/blender/freestyle/intern/system/Exception.h +++ b/source/blender/freestyle/intern/system/Exception.h @@ -9,9 +9,7 @@ * \brief Singleton to manage exceptions */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -43,9 +41,7 @@ class Exception { private: static exception_type _exception; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Exception") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/Id.h b/source/blender/freestyle/intern/system/Id.h index 6f0d2b3c4f4..5dd5458ffdb 100644 --- a/source/blender/freestyle/intern/system/Id.h +++ b/source/blender/freestyle/intern/system/Id.h @@ -9,9 +9,7 @@ * \brief Identification system */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -112,9 +110,7 @@ class Id { id_type _first; id_type _second; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Id") -#endif }; // stream operator diff --git a/source/blender/freestyle/intern/system/Interpreter.h b/source/blender/freestyle/intern/system/Interpreter.h index af3fb1a5b53..61ab25e411c 100644 --- a/source/blender/freestyle/intern/system/Interpreter.h +++ b/source/blender/freestyle/intern/system/Interpreter.h @@ -11,9 +11,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -40,9 +38,7 @@ class Interpreter { protected: string _language; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Interpreter") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/Iterator.h b/source/blender/freestyle/intern/system/Iterator.h index 0b930940f40..8a36df2517c 100644 --- a/source/blender/freestyle/intern/system/Iterator.h +++ b/source/blender/freestyle/intern/system/Iterator.h @@ -11,9 +11,7 @@ #include #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -52,9 +50,7 @@ class Iterator { return false; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Iterator") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/PointerSequence.h b/source/blender/freestyle/intern/system/PointerSequence.h index 3dd224fb02c..ff4a702d5cb 100644 --- a/source/blender/freestyle/intern/system/PointerSequence.h +++ b/source/blender/freestyle/intern/system/PointerSequence.h @@ -48,9 +48,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -76,9 +74,7 @@ template class PointerSequence : public C { for_each(this->begin(), this->end(), destroyer); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:PointerSequence") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/ProgressBar.h b/source/blender/freestyle/intern/system/ProgressBar.h index 28225e5df6c..075149f3279 100644 --- a/source/blender/freestyle/intern/system/ProgressBar.h +++ b/source/blender/freestyle/intern/system/ProgressBar.h @@ -11,9 +11,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -71,9 +69,7 @@ class ProgressBar { uint _progress; string _label; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ProgressBar") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/PseudoNoise.h b/source/blender/freestyle/intern/system/PseudoNoise.h index 19850302b19..483d2f2945e 100644 --- a/source/blender/freestyle/intern/system/PseudoNoise.h +++ b/source/blender/freestyle/intern/system/PseudoNoise.h @@ -11,9 +11,7 @@ #include "Precision.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -33,9 +31,7 @@ class PseudoNoise { static const uint NB_VALUE_NOISE = 512; static real _values[NB_VALUE_NOISE]; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:PseudoNoise") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/RandGen.h b/source/blender/freestyle/intern/system/RandGen.h index 937f332b7c6..cb535540b5b 100644 --- a/source/blender/freestyle/intern/system/RandGen.h +++ b/source/blender/freestyle/intern/system/RandGen.h @@ -13,9 +13,7 @@ #include "../system/Precision.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -27,9 +25,7 @@ class RandGen { private: static void next(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:RandGen") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/RenderMonitor.h b/source/blender/freestyle/intern/system/RenderMonitor.h index c9f6ccffe6c..f228e454bbe 100644 --- a/source/blender/freestyle/intern/system/RenderMonitor.h +++ b/source/blender/freestyle/intern/system/RenderMonitor.h @@ -11,9 +11,7 @@ #include "render_types.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -50,9 +48,7 @@ class RenderMonitor { protected: Render *_re; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:RenderMonitor") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/TimeStamp.h b/source/blender/freestyle/intern/system/TimeStamp.h index 9c3e30c2561..ac434c95f53 100644 --- a/source/blender/freestyle/intern/system/TimeStamp.h +++ b/source/blender/freestyle/intern/system/TimeStamp.h @@ -9,9 +9,7 @@ * \brief Class defining a singleton used as timestamp */ -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" #include "BLI_sys_types.h" @@ -51,9 +49,7 @@ class TimeStamp { static TimeStamp _instance; uint _time_stamp; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:TimeStamp") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/system/TimeUtils.h b/source/blender/freestyle/intern/system/TimeUtils.h index 146818decbf..4024fb657eb 100644 --- a/source/blender/freestyle/intern/system/TimeUtils.h +++ b/source/blender/freestyle/intern/system/TimeUtils.h @@ -11,9 +11,7 @@ #include -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -37,9 +35,7 @@ class Chronometer { private: clock_t _start; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Chronometer") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/BoxGrid.h b/source/blender/freestyle/intern/view_map/BoxGrid.h index 852b740ddaf..b81e6305f27 100644 --- a/source/blender/freestyle/intern/view_map/BoxGrid.h +++ b/source/blender/freestyle/intern/view_map/BoxGrid.h @@ -31,9 +31,7 @@ #include "BKE_global.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -50,9 +48,7 @@ class BoxGrid { // temptation to save 4 or 8 bytes. WFace *face; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BoxGrid:OccluderData") -#endif }; private: @@ -113,9 +109,7 @@ class BoxGrid { // deque::iterator _current, _occludeeCandidate; vector::iterator _current, _occludeeCandidate; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BoxGrid:Iterator") -#endif }; class Transform : public GridHelpers::Transform { @@ -169,9 +163,7 @@ class BoxGrid { Vec3r _viewpoint; bool _enableQI; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:BoxGrid") -#endif }; inline void BoxGrid::Iterator::initBeforeTarget() diff --git a/source/blender/freestyle/intern/view_map/FEdgeXDetector.h b/source/blender/freestyle/intern/view_map/FEdgeXDetector.h index 5f20cb240ee..2c91f9efecb 100644 --- a/source/blender/freestyle/intern/view_map/FEdgeXDetector.h +++ b/source/blender/freestyle/intern/view_map/FEdgeXDetector.h @@ -20,9 +20,7 @@ #include "../winged_edge/Curvature.h" #include "../winged_edge/WXEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -223,9 +221,7 @@ class FEdgeXDetector { ProgressBar *_pProgressBar; RenderMonitor *_pRenderMonitor; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdgeXDetector") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/Functions0D.h b/source/blender/freestyle/intern/view_map/Functions0D.h index 8bfeb3a5f36..d2dbd996538 100644 --- a/source/blender/freestyle/intern/view_map/Functions0D.h +++ b/source/blender/freestyle/intern/view_map/Functions0D.h @@ -23,9 +23,7 @@ #include "../system/Exception.h" #include "../system/Precision.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -91,9 +89,7 @@ template class UnaryFunction0D { return Director_BPy_UnaryFunction0D___call__(this, py_uf0D, iter); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:UnaryFunction0D") -#endif }; #ifdef SWIG diff --git a/source/blender/freestyle/intern/view_map/Functions1D.h b/source/blender/freestyle/intern/view_map/Functions1D.h index f28868fc477..3909b43401c 100644 --- a/source/blender/freestyle/intern/view_map/Functions1D.h +++ b/source/blender/freestyle/intern/view_map/Functions1D.h @@ -19,9 +19,7 @@ #include "../python/Director.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -104,9 +102,7 @@ template class UnaryFunction1D { protected: IntegrationType _integration; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:UnaryFunction1D") -#endif }; class UnaryFunction1D_void { @@ -149,9 +145,7 @@ class UnaryFunction1D_void { protected: IntegrationType _integration; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:UnaryFunction1D_void") -#endif }; // diff --git a/source/blender/freestyle/intern/view_map/GridDensityProvider.h b/source/blender/freestyle/intern/view_map/GridDensityProvider.h index 84815906fd5..535ab3b8f9f 100644 --- a/source/blender/freestyle/intern/view_map/GridDensityProvider.h +++ b/source/blender/freestyle/intern/view_map/GridDensityProvider.h @@ -20,9 +20,7 @@ #include "BKE_global.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -117,9 +115,7 @@ class GridDensityProvider { float _cellSize; float _cellOrigin[2]; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GridDensityProvider") -#endif }; class GridDensityProviderFactory { @@ -142,9 +138,7 @@ class GridDensityProviderFactory { virtual ~GridDensityProviderFactory() {} -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:GridDensityProviderFactory") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/Interface0D.h b/source/blender/freestyle/intern/view_map/Interface0D.h index e7d425faa94..3890c8d657e 100644 --- a/source/blender/freestyle/intern/view_map/Interface0D.h +++ b/source/blender/freestyle/intern/view_map/Interface0D.h @@ -20,9 +20,7 @@ #include "../winged_edge/Nature.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -102,9 +100,7 @@ class Interface0D { /** Cast the Interface0D in TVertex if it can be. */ virtual TVertex *castToTVertex(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Interface0D") -#endif }; // diff --git a/source/blender/freestyle/intern/view_map/Interface1D.h b/source/blender/freestyle/intern/view_map/Interface1D.h index a99186f60be..33af70f7d99 100644 --- a/source/blender/freestyle/intern/view_map/Interface1D.h +++ b/source/blender/freestyle/intern/view_map/Interface1D.h @@ -20,9 +20,7 @@ #include "../winged_edge/Nature.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -199,9 +197,7 @@ class Interface1D { protected: uint _timeStamp; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Interface1D") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/OccluderSource.h b/source/blender/freestyle/intern/view_map/OccluderSource.h index ecf5c798ff3..e3e27f853d8 100644 --- a/source/blender/freestyle/intern/view_map/OccluderSource.h +++ b/source/blender/freestyle/intern/view_map/OccluderSource.h @@ -13,9 +13,7 @@ #include "../winged_edge/WEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -51,9 +49,7 @@ class OccluderSource { void buildCachedPolygon(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:OccluderSource") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/Silhouette.h b/source/blender/freestyle/intern/view_map/Silhouette.h index 8053500089a..17853a95f28 100644 --- a/source/blender/freestyle/intern/view_map/Silhouette.h +++ b/source/blender/freestyle/intern/view_map/Silhouette.h @@ -29,9 +29,7 @@ #include "../winged_edge/Curvature.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -439,9 +437,7 @@ class SVertex : public Interface0D { inline real curvature2d_as_angle() const; #endif -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SVertex") -#endif }; /**********************************/ @@ -952,9 +948,7 @@ class FEdge : public Interface1D { */ virtual inline Interface0DIterator pointsEnd(float t = 0.0f); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdge") -#endif }; // @@ -1265,9 +1259,7 @@ class FEdgeSharp : public FEdge { _bFaceMark = iFaceMark; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdgeSharp") -#endif }; /** Class defining a smooth edge. This kind of edge typically runs across a face of the input mesh. @@ -1380,9 +1372,7 @@ class FEdgeSmooth : public FEdge { _FrsMaterialIndex = i; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:FEdgeSmooth") -#endif }; /**********************************/ @@ -1935,9 +1925,7 @@ class SShape { _importance = importance; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SShape") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/SilhouetteGeomEngine.h b/source/blender/freestyle/intern/view_map/SilhouetteGeomEngine.h index 9ab5b69e72a..4a9f66428f0 100644 --- a/source/blender/freestyle/intern/view_map/SilhouetteGeomEngine.h +++ b/source/blender/freestyle/intern/view_map/SilhouetteGeomEngine.h @@ -16,9 +16,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -116,9 +114,7 @@ class SilhouetteGeomEngine { /** From camera to image */ static Vec3r CameraToImage(const Vec3r &M); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SilhouetteGeomEngine") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/SphericalGrid.h b/source/blender/freestyle/intern/view_map/SphericalGrid.h index fc265066dfc..fb0a2ae3863 100644 --- a/source/blender/freestyle/intern/view_map/SphericalGrid.h +++ b/source/blender/freestyle/intern/view_map/SphericalGrid.h @@ -31,9 +31,7 @@ #include "BKE_global.hh" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -50,9 +48,7 @@ class SphericalGrid { // temptation to save 4 or 8 bytes. WFace *face; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SphericalGrid:OccluderData") -#endif }; private: @@ -115,9 +111,7 @@ class SphericalGrid { // deque::iterator _current, _occludeeCandidate; vector::iterator _current, _occludeeCandidate; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SphericalGrid:Iterator") -#endif }; class Transform : public GridHelpers::Transform { @@ -171,9 +165,7 @@ class SphericalGrid { Vec3r _viewpoint; bool _enableQI; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SphericalGrid") -#endif }; inline void SphericalGrid::Iterator::initBeforeTarget() diff --git a/source/blender/freestyle/intern/view_map/SteerableViewMap.h b/source/blender/freestyle/intern/view_map/SteerableViewMap.h index 1fe7742cdb5..10d9dc37f3c 100644 --- a/source/blender/freestyle/intern/view_map/SteerableViewMap.h +++ b/source/blender/freestyle/intern/view_map/SteerableViewMap.h @@ -16,9 +16,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -137,9 +135,7 @@ class SteerableViewMap { void Clear(); void Build(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SteerableViewMap") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/ViewEdgeXBuilder.h b/source/blender/freestyle/intern/view_map/ViewEdgeXBuilder.h index da68bc712d3..92c0aa66f66 100644 --- a/source/blender/freestyle/intern/view_map/ViewEdgeXBuilder.h +++ b/source/blender/freestyle/intern/view_map/ViewEdgeXBuilder.h @@ -29,9 +29,7 @@ #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -104,9 +102,7 @@ class OWXFaceLayer { return !(*this == b); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:OWXFaceLayer") -#endif }; class WXEdge; @@ -146,9 +142,7 @@ class OWXEdge { return !(*this == b); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:OWXEdge") -#endif }; class WOEdge; @@ -271,9 +265,7 @@ class ViewEdgeXBuilder { SShape *_pCurrentSShape; ViewShape *_pCurrentVShape; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewEdgeXBuilder") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/ViewMap.h b/source/blender/freestyle/intern/view_map/ViewMap.h index d492073b95e..d9b55beb03f 100644 --- a/source/blender/freestyle/intern/view_map/ViewMap.h +++ b/source/blender/freestyle/intern/view_map/ViewMap.h @@ -20,9 +20,7 @@ #include "../system/BaseIterator.h" #include "../system/FreestyleConfig.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -221,9 +219,7 @@ class ViewMap { /* Clean temporary FEdges created by chaining */ virtual void Clean(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewMap") -#endif }; /**********************************/ @@ -354,9 +350,7 @@ class ViewVertex : public Interface0D { /** Returns an orientedViewEdgeIterator pointing to the ViewEdge given as argument. */ virtual ViewVertexInternal::orientedViewEdgeIterator edgesIterator(ViewEdge *iEdge) = 0; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewVertex") -#endif }; /**********************************/ @@ -638,9 +632,7 @@ class TVertex : public ViewVertex { /** Returns an orientedViewEdgeIterator pointing to the ViewEdge given as argument. */ virtual ViewVertexInternal::orientedViewEdgeIterator edgesIterator(ViewEdge *iEdge); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:TVertex") -#endif }; /**********************************/ @@ -857,9 +849,7 @@ class NonTVertex : public ViewVertex { /** Returns an orientedViewEdgeIterator pointing to the ViewEdge given as argument. */ virtual ViewVertexInternal::orientedViewEdgeIterator edgesIterator(ViewEdge *iEdge); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:NonTVertex") -#endif }; /**********************************/ @@ -1378,9 +1368,7 @@ class ViewEdge : public Interface1D { */ virtual Interface0DIterator pointsEnd(float t = 0.0f); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewEdge") -#endif }; /**********************************/ @@ -1619,9 +1607,7 @@ class ViewShape { /* removes the view vertex iViewVertex in the View Shape. */ void RemoveVertex(ViewVertex *iViewVertex); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewShape") -#endif }; /* diff --git a/source/blender/freestyle/intern/view_map/ViewMapBuilder.h b/source/blender/freestyle/intern/view_map/ViewMapBuilder.h index 6f6093a36b1..7011050ef2a 100644 --- a/source/blender/freestyle/intern/view_map/ViewMapBuilder.h +++ b/source/blender/freestyle/intern/view_map/ViewMapBuilder.h @@ -33,9 +33,7 @@ #include "../winged_edge/WEdge.h" #include "../winged_edge/WXEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -264,9 +262,7 @@ class ViewMapBuilder { Vec3r &edgeDir, vector &faceVertices); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewMapBuilder") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/view_map/ViewMapIterators.h b/source/blender/freestyle/intern/view_map/ViewMapIterators.h index 8d7a567b467..120a08bb779 100644 --- a/source/blender/freestyle/intern/view_map/ViewMapIterators.h +++ b/source/blender/freestyle/intern/view_map/ViewMapIterators.h @@ -212,9 +212,7 @@ class orientedViewEdgeIterator : public Iterator { return 0; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:orientedViewEdgeIterator") -#endif }; } // namespace ViewVertexInternal @@ -387,9 +385,7 @@ class SVertexIterator : public Interface0DIteratorNested { FEdge *_next_edge; float _t; // curvilinear abscissa -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:SVertexIterator") -#endif }; // @@ -561,9 +557,7 @@ class ViewEdgeIterator : public Iterator { ViewEdge *_edge; ViewEdge *_begin; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewEdgeIterator") -#endif }; } // end of namespace ViewEdgeInternal diff --git a/source/blender/freestyle/intern/view_map/ViewMapTesselator.h b/source/blender/freestyle/intern/view_map/ViewMapTesselator.h index c4af8f167ee..0194b1d6e08 100644 --- a/source/blender/freestyle/intern/view_map/ViewMapTesselator.h +++ b/source/blender/freestyle/intern/view_map/ViewMapTesselator.h @@ -20,9 +20,7 @@ #include "../winged_edge/WEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -84,9 +82,7 @@ class ViewMapTesselator { FrsMaterial _FrsMaterial; bool _overloadFrsMaterial; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewMapTesselator") -#endif }; /** Class to tessellate the 2D projected silhouette */ @@ -101,9 +97,7 @@ class ViewMapTesselator2D : public ViewMapTesselator { iLine->AddVertex(v->point2D()); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewMapTesselator2D") -#endif }; /** Class to tessellate the 3D silhouette */ @@ -118,9 +112,7 @@ class ViewMapTesselator3D : public ViewMapTesselator { iLine->AddVertex(v->point3D()); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:ViewMapTesselator3D") -#endif }; // diff --git a/source/blender/freestyle/intern/winged_edge/Curvature.h b/source/blender/freestyle/intern/winged_edge/Curvature.h index aad789604d3..d71ee2ec4e5 100644 --- a/source/blender/freestyle/intern/winged_edge/Curvature.h +++ b/source/blender/freestyle/intern/winged_edge/Curvature.h @@ -22,9 +22,7 @@ #include "../system/FreestyleConfig.h" #include "../system/Precision.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -75,9 +73,7 @@ class CurvatureInfo { real dKr; // radial curvature Vec3r er; // radial curvature direction -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:CurvatureInfo") -#endif }; class Face_Curvature_Info { @@ -98,9 +94,7 @@ class Face_Curvature_Info { vector vec_curvature_info; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:Face_Curvature_Info") -#endif }; /** diff --git a/source/blender/freestyle/intern/winged_edge/WEdge.h b/source/blender/freestyle/intern/winged_edge/WEdge.h index 9b15e3cd4ab..7a205cfca10 100644 --- a/source/blender/freestyle/intern/winged_edge/WEdge.h +++ b/source/blender/freestyle/intern/winged_edge/WEdge.h @@ -20,9 +20,7 @@ #include "BLI_math_base.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" using namespace std; @@ -212,9 +210,7 @@ class WVertex { protected: virtual void increment(); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WVertex:incoming_edge_iterator") -#endif }; class face_iterator { @@ -283,9 +279,7 @@ class WVertex { ++_edge_it; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WVertex:face_iterator") -#endif }; public: @@ -303,9 +297,7 @@ class WVertex { return face_iterator(incoming_edges_end()); } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WVertex") -#endif }; /********************************** @@ -484,9 +476,7 @@ class WOEdge { userdata = nullptr; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WOEdge") -#endif }; /********************************** @@ -673,9 +663,7 @@ class WEdge { userdata = nullptr; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WEdge") -#endif }; /********************************** @@ -972,9 +960,7 @@ class WFace { userdata = nullptr; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WFace") -#endif }; /********************************** @@ -1284,9 +1270,7 @@ class WShape { uint iMaterialIndex, WFace *face); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WShape") -#endif }; /********************************** @@ -1338,9 +1322,7 @@ class WingedEdge { vector _wshapes; uint _numFaces; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WingedEdge") -#endif }; /* diff --git a/source/blender/freestyle/intern/winged_edge/WFillGrid.h b/source/blender/freestyle/intern/winged_edge/WFillGrid.h index 96db9fe4d5e..4e02c1bf0bd 100644 --- a/source/blender/freestyle/intern/winged_edge/WFillGrid.h +++ b/source/blender/freestyle/intern/winged_edge/WFillGrid.h @@ -14,9 +14,7 @@ #include "../geometry/Grid.h" #include "../geometry/Polygon.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -64,9 +62,7 @@ class WFillGrid { WingedEdge *_winged_edge; uint _polygon_id; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WFillGrid") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/winged_edge/WSFillGrid.h b/source/blender/freestyle/intern/winged_edge/WSFillGrid.h index f27ceaf46e9..a1e6195e55d 100644 --- a/source/blender/freestyle/intern/winged_edge/WSFillGrid.h +++ b/source/blender/freestyle/intern/winged_edge/WSFillGrid.h @@ -60,9 +60,7 @@ class WSFillGrid { WingedEdge *_winged_edge; uint _polygon_id; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WSFillGrid") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/winged_edge/WXEdge.h b/source/blender/freestyle/intern/winged_edge/WXEdge.h index 1c9b7eb3a7d..2c2fc0e3f55 100644 --- a/source/blender/freestyle/intern/winged_edge/WXEdge.h +++ b/source/blender/freestyle/intern/winged_edge/WXEdge.h @@ -13,9 +13,7 @@ #include "Nature.h" #include "WEdge.h" -#ifdef WITH_CXX_GUARDEDALLOC -# include "MEM_guardedalloc.h" -#endif +#include "MEM_guardedalloc.h" namespace Freestyle { @@ -78,9 +76,7 @@ class WXVertex : public WVertex { return _curvatures; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXVertex") -#endif }; /********************************** @@ -182,9 +178,7 @@ class WXEdge : public WEdge { _order = i; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXEdge") -#endif }; /********************************** @@ -293,9 +287,7 @@ class WXSmoothEdge { _config = iConf; } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXSmoothEdge") -#endif }; /* Class to store a value per vertex and a smooth edge. @@ -474,9 +466,7 @@ class WXFaceLayer { } } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXFaceLayer") -#endif }; // namespace Freestyle class WXFace : public WFace { @@ -688,9 +678,7 @@ class WXFace : public WFace { } } -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXFace") -#endif }; /********************************** @@ -800,9 +788,7 @@ class WXShape : public WShape { } /** accessors */ -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXShape") -#endif }; /* diff --git a/source/blender/freestyle/intern/winged_edge/WXEdgeBuilder.h b/source/blender/freestyle/intern/winged_edge/WXEdgeBuilder.h index 5f801c892e3..6991ba38568 100644 --- a/source/blender/freestyle/intern/winged_edge/WXEdgeBuilder.h +++ b/source/blender/freestyle/intern/winged_edge/WXEdgeBuilder.h @@ -25,9 +25,7 @@ class WXEdgeBuilder : public WingedEdgeBuilder { protected: virtual void buildWVertices(WShape &shape, const float *vertices, uint vsize); -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WXEdgeBuilder") -#endif }; } /* namespace Freestyle */ diff --git a/source/blender/freestyle/intern/winged_edge/WingedEdgeBuilder.h b/source/blender/freestyle/intern/winged_edge/WingedEdgeBuilder.h index 75901c41ac0..16c57e2a874 100644 --- a/source/blender/freestyle/intern/winged_edge/WingedEdgeBuilder.h +++ b/source/blender/freestyle/intern/winged_edge/WingedEdgeBuilder.h @@ -153,9 +153,7 @@ class WingedEdgeBuilder : public SceneVisitor { Matrix44r *_current_matrix; vector _matrices_stack; -#ifdef WITH_CXX_GUARDEDALLOC MEM_CXX_CLASS_ALLOC_FUNCS("Freestyle:WingedEdgeBuilder") -#endif }; } /* namespace Freestyle */