From 0b3e9cddbce0c736992ef4eb9cd6a10f591dc688 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Sat, 18 Jun 2016 21:45:11 +0200 Subject: [PATCH] SceneGraph: ignore deprecated warnings in deprecated functions on GCC. Gaah, why GCC can't ignore that by itself -- nobody cares if a deprecated API uses another deprecated API. Clang does that right. --- src/Magnum/SceneGraph/AbstractTranslation.h | 7 +++ .../AbstractTranslationRotation2D.h | 14 +++++ .../AbstractTranslationRotation3D.h | 35 ++++++++++++ .../AbstractTranslationRotationScaling2D.h | 21 +++++++ .../AbstractTranslationRotationScaling3D.h | 42 ++++++++++++++ .../SceneGraph/DualComplexTransformation.h | 21 +++++++ .../SceneGraph/DualQuaternionTransformation.h | 42 ++++++++++++++ .../SceneGraph/MatrixTransformation2D.h | 35 ++++++++++++ .../SceneGraph/MatrixTransformation3D.h | 56 +++++++++++++++++++ .../SceneGraph/RigidMatrixTransformation2D.h | 28 ++++++++++ .../SceneGraph/RigidMatrixTransformation3D.h | 49 ++++++++++++++++ .../SceneGraph/TranslationTransformation.h | 14 +++++ 12 files changed, 364 insertions(+) diff --git a/src/Magnum/SceneGraph/AbstractTranslation.h b/src/Magnum/SceneGraph/AbstractTranslation.h index 834a3dfb4..bacbadf3e 100644 --- a/src/Magnum/SceneGraph/AbstractTranslation.h +++ b/src/Magnum/SceneGraph/AbstractTranslation.h @@ -82,6 +82,10 @@ class AbstractTranslation: public AbstractTransformation { } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -89,6 +93,9 @@ class AbstractTranslation: public AbstractTransformation { CORRADE_DEPRECATED("use translate() or translateLocal() instead") AbstractTranslation& translate(const VectorTypeFor& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ diff --git a/src/Magnum/SceneGraph/AbstractTranslationRotation2D.h b/src/Magnum/SceneGraph/AbstractTranslationRotation2D.h index f5a7bf747..266af3911 100644 --- a/src/Magnum/SceneGraph/AbstractTranslationRotation2D.h +++ b/src/Magnum/SceneGraph/AbstractTranslationRotation2D.h @@ -70,6 +70,10 @@ template class AbstractBasicTranslationRotation2D: public AbstractBasic } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -77,6 +81,9 @@ template class AbstractBasicTranslationRotation2D: public AbstractBasic CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") AbstractBasicTranslationRotation2D& rotate(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotate(angle) : rotateLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ @@ -94,6 +101,10 @@ template class AbstractBasicTranslationRotation2D: public AbstractBasic return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use translate() or translateLocal() instead") AbstractBasicTranslationRotation2D& translate(const Math::Vector2& vector, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -101,6 +112,9 @@ template class AbstractBasicTranslationRotation2D: public AbstractBasic AbstractBasicTranslation2D::translate(vector, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif #endif diff --git a/src/Magnum/SceneGraph/AbstractTranslationRotation3D.h b/src/Magnum/SceneGraph/AbstractTranslationRotation3D.h index 72a3bdef3..be8624a94 100644 --- a/src/Magnum/SceneGraph/AbstractTranslationRotation3D.h +++ b/src/Magnum/SceneGraph/AbstractTranslationRotation3D.h @@ -74,6 +74,10 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -81,6 +85,9 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") AbstractBasicTranslationRotation3D& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis, TransformationType type) { return type == TransformationType::Global ? rotate(angle, normalizedAxis) : rotateLocal(angle, normalizedAxis); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -112,6 +119,10 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateX() * @deprecated Use @ref rotateX() or @ref rotateXLocal() instead. @@ -119,6 +130,9 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic CORRADE_DEPRECATED("use rotateX() or rotateXLocal() instead") AbstractBasicTranslationRotation3D& rotateX(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateX(angle) : rotateXLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -150,6 +164,10 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateY() * @deprecated Use @ref rotateY() or @ref rotateYLocal() instead. @@ -157,6 +175,9 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic CORRADE_DEPRECATED("use rotateY() or rotateYLocal() instead") AbstractBasicTranslationRotation3D& rotateY(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateY(angle) : rotateYLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -188,6 +209,10 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateZ() * @deprecated Use @ref rotateZ() or @ref rotateZLocal() instead. @@ -195,6 +220,9 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic CORRADE_DEPRECATED("use rotateZ() or rotateZLocal() instead") AbstractBasicTranslationRotation3D& rotateZ(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateZ(angle) : rotateZLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ @@ -212,6 +240,10 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use translate() or translateLocal() instead") AbstractBasicTranslationRotation3D& translate(const Math::Vector3& vector, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -219,6 +251,9 @@ template class AbstractBasicTranslationRotation3D: public AbstractBasic AbstractBasicTranslation3D::translate(vector, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif #endif diff --git a/src/Magnum/SceneGraph/AbstractTranslationRotationScaling2D.h b/src/Magnum/SceneGraph/AbstractTranslationRotationScaling2D.h index e7a04425e..e7f21034f 100644 --- a/src/Magnum/SceneGraph/AbstractTranslationRotationScaling2D.h +++ b/src/Magnum/SceneGraph/AbstractTranslationRotationScaling2D.h @@ -70,6 +70,10 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief scale() * @deprecated Use @ref scale() or @ref scaleLocal() instead. @@ -77,6 +81,9 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra CORRADE_DEPRECATED("use scale() or scaleLocal() instead") AbstractBasicTranslationRotationScaling2D& scale(const Math::Vector2& vector, TransformationType type) { return type == TransformationType::Global ? scale(vector) : scaleLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ @@ -94,6 +101,10 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use translate() or translateLocal() instead") AbstractBasicTranslationRotationScaling2D& translate(const Math::Vector2& vector, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -101,6 +112,9 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra AbstractBasicTranslationRotation2D::translate(vector, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif AbstractBasicTranslationRotationScaling2D& rotate(Math::Rad angle) { AbstractBasicTranslationRotation2D::rotate(angle); @@ -111,6 +125,10 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") AbstractBasicTranslationRotationScaling2D& rotate(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -118,6 +136,9 @@ template class AbstractBasicTranslationRotationScaling2D: public Abstra AbstractBasicTranslationRotation2D::rotate(angle, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif #endif diff --git a/src/Magnum/SceneGraph/AbstractTranslationRotationScaling3D.h b/src/Magnum/SceneGraph/AbstractTranslationRotationScaling3D.h index f8078b880..2361c8316 100644 --- a/src/Magnum/SceneGraph/AbstractTranslationRotationScaling3D.h +++ b/src/Magnum/SceneGraph/AbstractTranslationRotationScaling3D.h @@ -70,6 +70,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief scale() * @deprecated Use @ref scale() or @ref scaleLocal() instead. @@ -80,6 +84,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra #endif return type == TransformationType::Global ? scale(vector) : scaleLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ @@ -97,6 +104,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use translate() or translateLocal() instead") AbstractBasicTranslationRotationScaling3D& translate(const Math::Vector3& vector, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -104,6 +115,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra AbstractBasicTranslationRotation3D::translate(vector, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif AbstractBasicTranslationRotationScaling3D& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis) { AbstractBasicTranslationRotation3D::rotate(angle, normalizedAxis); @@ -114,6 +128,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") AbstractBasicTranslationRotationScaling3D& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -121,6 +139,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra AbstractBasicTranslationRotation3D::rotate(angle, normalizedAxis, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif AbstractBasicTranslationRotationScaling3D& rotateX(Math::Rad angle) { AbstractBasicTranslationRotation3D::rotateX(angle); @@ -131,6 +152,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateX() or rotateXLocal() instead") AbstractBasicTranslationRotationScaling3D& rotateX(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -138,6 +163,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra AbstractBasicTranslationRotation3D::rotateX(angle, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif AbstractBasicTranslationRotationScaling3D& rotateY(Math::Rad angle) { AbstractBasicTranslationRotation3D::rotateY(angle); @@ -148,6 +176,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateY() or rotateYLocal() instead") AbstractBasicTranslationRotationScaling3D& rotateY(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -155,6 +187,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra AbstractBasicTranslationRotation3D::rotateY(angle, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif AbstractBasicTranslationRotationScaling3D& rotateZ(Math::Rad angle) { AbstractBasicTranslationRotation3D::rotateZ(angle); @@ -165,6 +200,10 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra return *this; } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateZ() or rotateZLocal() instead") AbstractBasicTranslationRotationScaling3D& rotateZ(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) @@ -172,6 +211,9 @@ template class AbstractBasicTranslationRotationScaling3D: public Abstra AbstractBasicTranslationRotation3D::rotateZ(angle, type); return *this; } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif #endif diff --git a/src/Magnum/SceneGraph/DualComplexTransformation.h b/src/Magnum/SceneGraph/DualComplexTransformation.h index 1df8a21d1..9c15382e1 100644 --- a/src/Magnum/SceneGraph/DualComplexTransformation.h +++ b/src/Magnum/SceneGraph/DualComplexTransformation.h @@ -110,6 +110,10 @@ template class BasicDualComplexTransformation: public AbstractBasicTran } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -117,6 +121,9 @@ template class BasicDualComplexTransformation: public AbstractBasicTran CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::DualComplex& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -143,6 +150,10 @@ template class BasicDualComplexTransformation: public AbstractBasicTran } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -150,6 +161,9 @@ template class BasicDualComplexTransformation: public AbstractBasicTran CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector2& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -175,6 +189,10 @@ template class BasicDualComplexTransformation: public AbstractBasicTran } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -182,6 +200,9 @@ template class BasicDualComplexTransformation: public AbstractBasicTran CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotate(angle) : rotateLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: diff --git a/src/Magnum/SceneGraph/DualQuaternionTransformation.h b/src/Magnum/SceneGraph/DualQuaternionTransformation.h index 364a87569..dc957df2c 100644 --- a/src/Magnum/SceneGraph/DualQuaternionTransformation.h +++ b/src/Magnum/SceneGraph/DualQuaternionTransformation.h @@ -110,6 +110,10 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -117,6 +121,9 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::DualQuaternion& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -142,6 +149,10 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -149,6 +160,9 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector3& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -177,6 +191,10 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -184,6 +202,9 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT CORRADE_DEPRECATED("usr rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis, TransformationType type) { return type == TransformationType::Global ? rotate(angle, normalizedAxis) : rotateLocal(angle, normalizedAxis); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /* Overloads to remove WTF-factor from method chaining order */ @@ -195,12 +216,19 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT return rotateLocal(angle, Math::Vector3::xAxis()); } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateX() or rotateXLocal() instead") Object>& rotateX(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) #endif return rotate(angle, Math::Vector3::xAxis(), type); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif Object>& rotateY(Math::Rad angle) { return rotate(angle, Math::Vector3::yAxis()); @@ -209,12 +237,19 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT return rotateLocal(angle, Math::Vector3::yAxis()); } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateY() or rotateYLocal() instead") Object>& rotateY(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) #endif return rotate(angle, Math::Vector3::yAxis(), type); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif Object>& rotateZ(Math::Rad angle) { return rotate(angle, Math::Vector3::zAxis()); @@ -223,12 +258,19 @@ template class BasicDualQuaternionTransformation: public AbstractBasicT return rotateLocal(angle, Math::Vector3::zAxis()); } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif CORRADE_DEPRECATED("use rotateZ() or rotateZLocal() instead") Object>& rotateZ(Math::Rad angle, TransformationType type) { #ifdef _MSC_VER #pragma warning(suppress: 4996) #endif return rotate(angle, Math::Vector3::zAxis(), type); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif #endif diff --git a/src/Magnum/SceneGraph/MatrixTransformation2D.h b/src/Magnum/SceneGraph/MatrixTransformation2D.h index 680c35f6a..840232f1b 100644 --- a/src/Magnum/SceneGraph/MatrixTransformation2D.h +++ b/src/Magnum/SceneGraph/MatrixTransformation2D.h @@ -87,6 +87,10 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -94,6 +98,9 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::Matrix3& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @copydoc AbstractTranslationRotationScaling2D::resetTransformation() */ @@ -125,6 +132,10 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -132,6 +143,9 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector2& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -158,6 +172,10 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -165,6 +183,9 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotate(angle) : rotateLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -191,6 +212,10 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief scale() * @deprecated Use @ref scale() or @ref scaleLocal() instead. @@ -198,6 +223,9 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla CORRADE_DEPRECATED("use scale() or scaleLocal() instead") Object>& scale(const Math::Vector2& vector, TransformationType type) { return type == TransformationType::Global ? scale(vector) : scaleLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -226,6 +254,10 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief reflect() * @deprecated Use @ref reflect() or @ref reflectLocal() instead. @@ -233,6 +265,9 @@ template class BasicMatrixTransformation2D: public AbstractBasicTransla CORRADE_DEPRECATED("use reflect() or reflectLocal() instead") Object>& reflect(const Math::Vector2& normal, TransformationType type) { return type == TransformationType::Global ? reflect(normal) : reflectLocal(normal); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: diff --git a/src/Magnum/SceneGraph/MatrixTransformation3D.h b/src/Magnum/SceneGraph/MatrixTransformation3D.h index 6dca54140..329214ce6 100644 --- a/src/Magnum/SceneGraph/MatrixTransformation3D.h +++ b/src/Magnum/SceneGraph/MatrixTransformation3D.h @@ -92,6 +92,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -99,6 +103,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::Matrix4& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -125,6 +132,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -132,6 +143,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector3& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -161,6 +175,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -168,6 +186,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis, TransformationType type) { return type == TransformationType::Global ? rotate(angle, normalizedAxis) : rotateLocal(angle, normalizedAxis); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -194,6 +215,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateX() * @deprecated Use @ref rotateX() or @ref rotateXLocal() instead. @@ -201,6 +226,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use rotateX() or rotateXLocal() instead") Object>& rotateX(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateX(angle) : rotateXLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -227,6 +255,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateY() * @deprecated Use @ref rotateY() or @ref rotateYLocal() instead. @@ -234,6 +266,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use rotateY() or rotateYLocal() instead") Object>& rotateY(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateY(angle) : rotateYLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -260,6 +295,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateZ() * @deprecated Use @ref rotateZ() or @ref rotateZLocal() instead. @@ -267,6 +306,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use rotateZ() or rotateZLocal() instead") Object>& rotateZ(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateZ(angle) : rotateZLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -293,6 +335,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief scale() * @deprecated Use @ref scale() or @ref scaleLocal() instead. @@ -300,6 +346,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use scale() or scaleLocal() instead") Object>& scale(const Math::Vector3& vector, TransformationType type) { return type == TransformationType::Global ? scale(vector) : scaleLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -327,6 +376,10 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief reflect() * @deprecated Use @ref reflect() or @ref reflectLocal() instead. @@ -334,6 +387,9 @@ template class BasicMatrixTransformation3D: public AbstractBasicTransla CORRADE_DEPRECATED("use reflect() or reflectLocal() instead") Object>& reflect(const Math::Vector3& normal, TransformationType type) { return type == TransformationType::Global ? reflect(normal) : reflectLocal(normal); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: diff --git a/src/Magnum/SceneGraph/RigidMatrixTransformation2D.h b/src/Magnum/SceneGraph/RigidMatrixTransformation2D.h index 81a55b41a..e5f313432 100644 --- a/src/Magnum/SceneGraph/RigidMatrixTransformation2D.h +++ b/src/Magnum/SceneGraph/RigidMatrixTransformation2D.h @@ -115,6 +115,10 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -122,6 +126,9 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::Matrix3& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -148,6 +155,10 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -155,6 +166,9 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector2& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -182,6 +196,10 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -189,6 +207,9 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotate(angle) : rotateLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -216,6 +237,10 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief reflect() * @deprecated Use @ref reflect() or @ref reflectLocal() instead. @@ -223,6 +248,9 @@ template class BasicRigidMatrixTransformation2D: public AbstractBasicTr CORRADE_DEPRECATED("use reflect() or reflectInternal() instead") Object>& reflect(const Math::Vector2& normal, TransformationType type) { return type == TransformationType::Global ? reflect(normal) : reflectLocal(normal); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: diff --git a/src/Magnum/SceneGraph/RigidMatrixTransformation3D.h b/src/Magnum/SceneGraph/RigidMatrixTransformation3D.h index 4d73c01e1..63c1713fe 100644 --- a/src/Magnum/SceneGraph/RigidMatrixTransformation3D.h +++ b/src/Magnum/SceneGraph/RigidMatrixTransformation3D.h @@ -114,6 +114,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief transform() * @deprecated Use @ref transform() or @ref transformLocal() instead. @@ -121,6 +125,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use transform() or transformLocal() instead") Object>& transform(const Math::Matrix4& transformation, TransformationType type) { return type == TransformationType::Global ? transform(transformation) : transformLocal(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -147,6 +154,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief translate() * @deprecated Use @ref translate() or @ref translateLocal() instead. @@ -154,6 +165,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use translate() or translateLocal() instead") Object>& translate(const Math::Vector3& vector, TransformationType type) { return type == TransformationType::Global ? translate(vector) : translateLocal(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -184,6 +198,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotate() * @deprecated Use @ref rotate() or @ref rotateLocal() instead. @@ -191,6 +209,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use rotate() or rotateLocal() instead") Object>& rotate(Math::Rad angle, const Math::Vector3& normalizedAxis, TransformationType type) { return type == TransformationType::Global ? rotate(angle, normalizedAxis) : rotateLocal(angle, normalizedAxis); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -217,6 +238,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateX() * @deprecated Use @ref rotateX() or @ref rotateXLocal() instead. @@ -224,6 +249,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use rotateX() or rotateXLocal() instead") Object>& rotateX(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateX(angle) : rotateXLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -250,6 +278,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateY() * @deprecated Use @ref rotateY() or @ref rotateYLocal() instead. @@ -257,6 +289,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use rotateY() or rotateYLocal() instead") Object>& rotateY(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateY(angle) : rotateYLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -283,6 +318,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief rotateZ() * @deprecated Use @ref rotateZ() or @ref rotateZLocal() instead. @@ -290,6 +329,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use rotateZ() or rotateZLocal() instead") Object>& rotateZ(Math::Rad angle, TransformationType type) { return type == TransformationType::Global ? rotateZ(angle) : rotateZLocal(angle); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -317,6 +359,10 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr } #ifdef MAGNUM_BUILD_DEPRECATED + #ifdef __GNUC__ + #pragma GCC diagnostic push + #pragma GCC diagnostic ignored "-Wdeprecated-declarations" + #endif /** * @copybrief reflect() * @deprecated Use @ref reflect() or @ref reflectLocal() instead. @@ -324,6 +370,9 @@ template class BasicRigidMatrixTransformation3D: public AbstractBasicTr CORRADE_DEPRECATED("use reflect() or reflectLocal() instead") Object>& reflect(const Math::Vector3& normal, TransformationType type) { return type == TransformationType::Global ? reflect(normal) : reflectLocal(normal); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: diff --git a/src/Magnum/SceneGraph/TranslationTransformation.h b/src/Magnum/SceneGraph/TranslationTransformation.h index c0b140391..85412211e 100644 --- a/src/Magnum/SceneGraph/TranslationTransformation.h +++ b/src/Magnum/SceneGraph/TranslationTransformation.h @@ -95,6 +95,10 @@ class TranslationTransformation: public AbstractTranslation>& transform(const VectorTypeFor& transformation, TransformationType) { return transform(transformation); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif /** @@ -119,6 +126,10 @@ class TranslationTransformation: public AbstractTranslation>& translate(const VectorTypeFor& vector, TransformationType) { return translate(vector); } + #ifdef __GNUC__ + #pragma GCC diagnostic pop + #endif #endif protected: