Skip to content

OpenToonz - An open-source full-featured 2D animation creation software

C

Include memory, needed for auto_ptr references

Campbell Barton40cabe2c5656
diff --git a/toonz/sources/common/expressions/tgrammar.cpp b/toonz/sources/common/expressions/tgrammar.cpp
index 6d5de6b73..f77d87be6 100644
--- a/toonz/sources/common/expressions/tgrammar.cpp
+++ b/toonz/sources/common/expressions/tgrammar.cpp
@@ -16,6 +16,7 @@
#include <map>
#include <math.h>
#include <functional>
+#include <memory>
// Qt includes
#include <QString>
diff --git a/toonz/sources/common/tcolor/tcolorfunctions.cpp b/toonz/sources/common/tcolor/tcolorfunctions.cpp
index fddfeeedd..75e1c747a 100644
--- a/toonz/sources/common/tcolor/tcolorfunctions.cpp
+++ b/toonz/sources/common/tcolor/tcolorfunctions.cpp
@@ -1,5 +1,5 @@
-
+#include <cstring>
#include "tcolorfunctions.h"
#include "tpixelutils.h"
diff --git a/toonz/sources/common/trop/brush.cpp b/toonz/sources/common/trop/brush.cpp
index e83f093df..eb335dbef 100644
--- a/toonz/sources/common/trop/brush.cpp
+++ b/toonz/sources/common/trop/brush.cpp
@@ -1,5 +1,5 @@
-
+#include <cstring>
#include "trop.h"
//=======================================================================
diff --git a/toonz/sources/common/tsound/tsop.cpp b/toonz/sources/common/tsound/tsop.cpp
index b3207a240..68c194fbb 100644
--- a/toonz/sources/common/tsound/tsop.cpp
+++ b/toonz/sources/common/tsound/tsop.cpp
@@ -1,5 +1,7 @@
+#include <cstring>
+
#include "tsop.h"
#include "tsound_t.h"
diff --git a/toonz/sources/common/tstream/tstream.cpp b/toonz/sources/common/tstream/tstream.cpp
index 8e48833c8..38d06b88d 100644
--- a/toonz/sources/common/tstream/tstream.cpp
+++ b/toonz/sources/common/tstream/tstream.cpp
@@ -14,6 +14,7 @@
#endif
#include <sstream>
+#include <memory>
using namespace std;
diff --git a/toonz/sources/common/tvectorimage/tvectorimage.cpp b/toonz/sources/common/tvectorimage/tvectorimage.cpp
index f6c3572c6..21ab700d6 100644
--- a/toonz/sources/common/tvectorimage/tvectorimage.cpp
+++ b/toonz/sources/common/tvectorimage/tvectorimage.cpp
@@ -14,6 +14,9 @@
#include "tpaletteutil.h"
#include "tthreadmessage.h"
#include "tsimplecolorstyles.h"
+
+#include <memory>
+
//=============================================================================
typedef TVectorImage::IntersectionBranch IntersectionBranch;
diff --git a/toonz/sources/common/tvrender/tpalette.cpp b/toonz/sources/common/tvrender/tpalette.cpp
index c8efb7851..3ff2167c2 100644
--- a/toonz/sources/common/tvrender/tpalette.cpp
+++ b/toonz/sources/common/tvrender/tpalette.cpp
@@ -14,6 +14,8 @@
#include "tpalette.h"
+#include <memory>
+
PERSIST_IDENTIFIER(TPalette, "palette")
TPersistDeclarationT<TPalette> auxPaletteDeclaration("vectorpalette");
diff --git a/toonz/sources/include/tcg/hpp/triangulate.hpp b/toonz/sources/include/tcg/hpp/triangulate.hpp
index 5b51bd926..b0c6799cf 100644
--- a/toonz/sources/include/tcg/hpp/triangulate.hpp
+++ b/toonz/sources/include/tcg/hpp/triangulate.hpp
@@ -15,6 +15,7 @@
#include <GLUT/glut.h>
#elif LINUX
#include <GL/glut.h>
+#include <cstring>
#endif
#ifndef TCG_GLU_CALLBACK
diff --git a/toonz/sources/include/tpersistset.h b/toonz/sources/include/tpersistset.h
index cea3766f1..230d97e89 100644
--- a/toonz/sources/include/tpersistset.h
+++ b/toonz/sources/include/tpersistset.h
@@ -9,6 +9,8 @@
//STD includes
#include <vector>
+#include <memory>
+
//**************************************************************************************
// TPersistSet declaration
//**************************************************************************************
diff --git a/toonz/sources/tnztools/autofilltlv.cpp b/toonz/sources/tnztools/autofilltlv.cpp
index 263d6a141..45d992921 100644
--- a/toonz/sources/tnztools/autofilltlv.cpp
+++ b/toonz/sources/tnztools/autofilltlv.cpp
@@ -10,7 +10,7 @@
#include <stdlib.h>
#include <math.h>
#include "toonz/toonzimageutils.h"
-#include "Tw/Tw.h"
+#include "tw/tw.h"
#include "toonz/fill.h"
#include "toonz/ttilesaver.h"
#include "toonz4.6/tmacro.h"
diff --git a/toonz/sources/toonz/columncommand.cpp b/toonz/sources/toonz/columncommand.cpp
index 074f694c4..7b51021c7 100644
--- a/toonz/sources/toonz/columncommand.cpp
+++ b/toonz/sources/toonz/columncommand.cpp
@@ -52,6 +52,8 @@
// tcg includes
#include "tcg/tcg_function_types.h"
+#include <memory>
+
//*************************************************************************
// Local Namespace stuff
//*************************************************************************
diff --git a/toonz/sources/toonz/insertfxpopup.cpp b/toonz/sources/toonz/insertfxpopup.cpp
index 3732f3ff9..104d24498 100644
--- a/toonz/sources/toonz/insertfxpopup.cpp
+++ b/toonz/sources/toonz/insertfxpopup.cpp
@@ -52,6 +52,8 @@
#include <QContextMenuEvent>
#include <QMainWindow>
+#include <memory>
+
using namespace DVGui;
//=============================================================================
diff --git a/toonz/sources/toonz/vectorizerswatch.h b/toonz/sources/toonz/vectorizerswatch.h
index 65d13156f..01ebd4f65 100644
--- a/toonz/sources/toonz/vectorizerswatch.h
+++ b/toonz/sources/toonz/vectorizerswatch.h
@@ -13,6 +13,8 @@
//Qt includes
#include <QFrame>
+#include <memory>
+
//*****************************************************************************
// VectorizerSwatchArea declaration
//*****************************************************************************
diff --git a/toonz/sources/toonzlib/fxcommand.cpp b/toonz/sources/toonzlib/fxcommand.cpp
index ac7e12ef2..5f1b2488b 100644
--- a/toonz/sources/toonzlib/fxcommand.cpp
+++ b/toonz/sources/toonzlib/fxcommand.cpp
@@ -38,6 +38,8 @@
#include "tcg/tcg_function_types.h"
#include "tcg/tcg_iterator_ops.h"
+#include <memory>
+
/*
Toonz currently has THREE different APIs to deal with scene objects commands:
diff --git a/toonz/sources/toonzlib/txsheetexpr.cpp b/toonz/sources/toonzlib/txsheetexpr.cpp
index f0195fa7d..7ac9138a0 100644
--- a/toonz/sources/toonzlib/txsheetexpr.cpp
+++ b/toonz/sources/toonzlib/txsheetexpr.cpp
@@ -29,6 +29,8 @@
#include "toonz/txsheetexpr.h"
+#include <memory>
+
using namespace TSyntax;
//******************************************************************************
diff --git a/toonz/sources/toonzqt/keyframenavigator.cpp b/toonz/sources/toonzqt/keyframenavigator.cpp
index 51f1c5551..1666a22dc 100644
--- a/toonz/sources/toonzqt/keyframenavigator.cpp
+++ b/toonz/sources/toonzqt/keyframenavigator.cpp
@@ -23,6 +23,8 @@
#pragma warning(disable : 4251)
#endif
+#include <memory>
+
#include <QAction>
#include <QMouseEvent>
diff --git a/toonz/sources/toonzqt/rasterimagedata.cpp b/toonz/sources/toonzqt/rasterimagedata.cpp
index 7a7235ea7..c400cd974 100644
--- a/toonz/sources/toonzqt/rasterimagedata.cpp
+++ b/toonz/sources/toonzqt/rasterimagedata.cpp
@@ -12,6 +12,8 @@
#include "toonz/sceneproperties.h"
#include "toonz/fullcolorpalette.h"
+#include <memory>
+
namespace
{
TVectorImageP vectorize(const TImageP &source, const TRectD &rect, const VectorizerConfiguration &config, TAffine transform)