Browse Source

GL: removed deprecated aliases to GL functionality in the root namespace.

Deprecated for 2018.04, it's been almost a year since. Whoever is using
Magnum regularly updated already, and who not can always upgrade
gradually (2018.02, 2018.04, 2018.10, 2019.01 etc.).
pull/331/head
Vladimír Vondruš 7 years ago
parent
commit
930a323c05
  1. 8
      doc/changelog.dox
  2. 6
      doc/snippets/CMakeLists.txt
  3. 41
      src/Magnum/AbstractFramebuffer.h
  4. 41
      src/Magnum/AbstractObject.h
  5. 41
      src/Magnum/AbstractQuery.h
  6. 41
      src/Magnum/AbstractShaderProgram.h
  7. 41
      src/Magnum/AbstractTexture.h
  8. 41
      src/Magnum/Attribute.h
  9. 41
      src/Magnum/Buffer.h
  10. 41
      src/Magnum/BufferImage.h
  11. 41
      src/Magnum/BufferTexture.h
  12. 41
      src/Magnum/BufferTextureFormat.h
  13. 81
      src/Magnum/CMakeLists.txt
  14. 41
      src/Magnum/Context.h
  15. 41
      src/Magnum/CubeMapTexture.h
  16. 41
      src/Magnum/CubeMapTextureArray.h
  17. 41
      src/Magnum/DebugOutput.h
  18. 106
      src/Magnum/DebugTools/CompareImage.cpp
  19. 20
      src/Magnum/DebugTools/Test/CompareImageTest.cpp
  20. 40
      src/Magnum/DefaultFramebuffer.h
  21. 41
      src/Magnum/Extensions.h
  22. 41
      src/Magnum/Framebuffer.h
  23. 45
      src/Magnum/GL/AbstractFramebuffer.h
  24. 23
      src/Magnum/GL/AbstractObject.h
  25. 13
      src/Magnum/GL/AbstractQuery.h
  26. 13
      src/Magnum/GL/AbstractShaderProgram.h
  27. 13
      src/Magnum/GL/AbstractTexture.h
  28. 20
      src/Magnum/GL/Attribute.h
  29. 18
      src/Magnum/GL/Buffer.h
  30. 121
      src/Magnum/GL/BufferImage.h
  31. 13
      src/Magnum/GL/BufferTexture.h
  32. 13
      src/Magnum/GL/BufferTextureFormat.h
  33. 3
      src/Magnum/GL/CMakeLists.txt
  34. 34
      src/Magnum/GL/Context.h
  35. 18
      src/Magnum/GL/CubeMapTexture.h
  36. 13
      src/Magnum/GL/CubeMapTextureArray.h
  37. 23
      src/Magnum/GL/DebugOutput.h
  38. 9
      src/Magnum/GL/DefaultFramebuffer.cpp
  39. 18
      src/Magnum/GL/DefaultFramebuffer.h
  40. 13
      src/Magnum/GL/Extensions.h
  41. 13
      src/Magnum/GL/Framebuffer.h
  42. 18
      src/Magnum/GL/ImageFormat.h
  43. 11
      src/Magnum/GL/Mesh.cpp
  44. 13
      src/Magnum/GL/Mesh.h
  45. 17
      src/Magnum/GL/MeshView.h
  46. 30
      src/Magnum/GL/MultisampleTexture.h
  47. 20
      src/Magnum/GL/OpenGLTester.h
  48. 33
      src/Magnum/GL/PixelFormat.cpp
  49. 23
      src/Magnum/GL/PixelFormat.h
  50. 13
      src/Magnum/GL/PrimitiveQuery.h
  51. 13
      src/Magnum/GL/RectangleTexture.h
  52. 13
      src/Magnum/GL/Renderbuffer.h
  53. 13
      src/Magnum/GL/RenderbufferFormat.h
  54. 17
      src/Magnum/GL/Renderer.h
  55. 13
      src/Magnum/GL/SampleQuery.h
  56. 52
      src/Magnum/GL/Sampler.h
  57. 13
      src/Magnum/GL/Shader.h
  58. 15
      src/Magnum/GL/Test/MeshTest.cpp
  59. 209
      src/Magnum/GL/Test/PixelFormatTest.cpp
  60. 34
      src/Magnum/GL/Texture.h
  61. 27
      src/Magnum/GL/TextureArray.h
  62. 13
      src/Magnum/GL/TextureFormat.h
  63. 13
      src/Magnum/GL/TimeQuery.h
  64. 13
      src/Magnum/GL/TransformFeedback.h
  65. 34
      src/Magnum/GL/Version.h
  66. 93
      src/Magnum/Image.h
  67. 41
      src/Magnum/ImageFormat.h
  68. 33
      src/Magnum/ImageView.h
  69. 107
      src/Magnum/Magnum.h
  70. 25
      src/Magnum/Mesh.cpp
  71. 38
      src/Magnum/Mesh.h
  72. 41
      src/Magnum/MeshView.h
  73. 41
      src/Magnum/MultisampleTexture.h
  74. 42
      src/Magnum/OpenGL.h
  75. 41
      src/Magnum/OpenGLTester.h
  76. 184
      src/Magnum/PixelFormat.cpp
  77. 555
      src/Magnum/PixelFormat.h
  78. 66
      src/Magnum/PixelStorage.h
  79. 22
      src/Magnum/Platform/AbstractXApplication.cpp
  80. 43
      src/Magnum/Platform/AbstractXApplication.h
  81. 32
      src/Magnum/Platform/AndroidApplication.h
  82. 4
      src/Magnum/Platform/CMakeLists.txt
  83. 41
      src/Magnum/Platform/Context.h
  84. 7
      src/Magnum/Platform/GLContext.h
  85. 31
      src/Magnum/Platform/GlfwApplication.cpp
  86. 99
      src/Magnum/Platform/GlfwApplication.h
  87. 26
      src/Magnum/Platform/GlutApplication.cpp
  88. 71
      src/Magnum/Platform/GlutApplication.h
  89. 8
      src/Magnum/Platform/Platform.h
  90. 43
      src/Magnum/Platform/Sdl2Application.cpp
  91. 107
      src/Magnum/Platform/Sdl2Application.h
  92. 41
      src/Magnum/PrimitiveQuery.h
  93. 41
      src/Magnum/RectangleTexture.h
  94. 41
      src/Magnum/Renderbuffer.h
  95. 41
      src/Magnum/RenderbufferFormat.h
  96. 41
      src/Magnum/Renderer.h
  97. 41
      src/Magnum/SampleQuery.h
  98. 4
      src/Magnum/Sampler.h
  99. 41
      src/Magnum/Shader.h
  100. 19
      src/Magnum/Test/PixelFormatTest.cpp
  101. Some files were not shown because too many files have changed in this diff Show More

8
doc/changelog.dox

@ -264,6 +264,8 @@ See also:
@subsection changelog-latest-compatibility Potential compatibility breakages, removed APIs
- Removed all aliases to @ref GL library functionality in the root namespace
(and root include path) which were deprecated in 2018.04
- In order to be compatible with both Emscripten 1.38.27 and the versions
before, all Emscripten markup is now expected to have the HTML @cb{.html} <canvas> @ce element identified by @cb{.css} #canvas @ce. You need to:
- update your HTML markup to use
@ -1410,8 +1412,8 @@ Released 2018-05-01, tagged as
- Removed the @cpp Buffer::Usage @ce enum that was deprecated in 2014.01, use
the global @ref GL::BufferUsage enum instead
- Removed the `Magnum/Query.h` header that was deprecated in 2015.05, use one
of @ref Magnum/PrimitiveQuery.h, @ref Magnum/SampleQuery.h or
@ref Magnum/TimeQuery.h instead
of `Magnum/PrimitiveQuery.h`, `Magnum/SampleQuery.h` or
`Magnum/TimeQuery.h` instead
- Removed ability to use @ref GL::Buffer::Target as constructor or
@ref GL::Buffer::setTargetHint() parameter that was deprecated in 2015.05,
use @ref GL::Buffer::TargetHint instead
@ -2145,7 +2147,7 @@ a high-level overview.
- Removed `Context::majorVersion()` and `Context::minorVersion()` functions,
use @ref Context::version() instead
- Removed deprecated `Magnum/DebugMarker.h` header, use
@ref Magnum/DebugOutput.h and @ref GL::DebugMessage "DebugMessage" class
`Magnum/DebugOutput.h` and @ref GL::DebugMessage "DebugMessage" class
instead
- Removed deprecated `*Buffer` values from
@ref GL::FramebufferBlit "FramebufferBlit", use values without the `Buffer`

6
doc/snippets/CMakeLists.txt

@ -50,6 +50,9 @@ endif()
add_library(snippets-Magnum STATIC ${snippets_Magnum_SRCS})
target_link_libraries(snippets-Magnum PRIVATE Magnum)
if(MAGNUM_TARGET_GL)
target_link_libraries(snippets-Magnum PRIVATE MagnumGL)
endif()
set_target_properties(snippets-Magnum PROPERTIES FOLDER "Magnum/doc/snippets")
if(WITH_AUDIO)
@ -82,6 +85,9 @@ if(WITH_TRADE)
plugins.cpp
MagnumTrade.cpp)
target_link_libraries(snippets-MagnumTrade PRIVATE MagnumTrade)
if(MAGNUM_TARGET_GL)
target_link_libraries(snippets-MagnumTrade PRIVATE MagnumGL)
endif()
set_target_properties(snippets-MagnumTrade PROPERTIES FOLDER "Magnum/doc/snippets")
endif()

41
src/Magnum/AbstractFramebuffer.h

@ -1,41 +0,0 @@
#ifndef Magnum_AbstractFramebuffer_h
#define Magnum_AbstractFramebuffer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/AbstractFramebuffer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/AbstractFramebuffer.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/AbstractFramebuffer.h instead")
#else
#error use Magnum/GL/AbstractFramebuffer.h instead
#endif
#endif

41
src/Magnum/AbstractObject.h

@ -1,41 +0,0 @@
#ifndef Magnum_AbstractObject_h
#define Magnum_AbstractObject_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/AbstractObject.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/AbstractObject.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/AbstractObject.h instead")
#else
#error use Magnum/GL/AbstractObject.h instead
#endif
#endif

41
src/Magnum/AbstractQuery.h

@ -1,41 +0,0 @@
#ifndef Magnum_AbstractQuery_h
#define Magnum_AbstractQuery_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/AbstractQuery.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/AbstractQuery.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/AbstractQuery.h instead")
#else
#error use Magnum/GL/AbstractQuery.h instead
#endif
#endif

41
src/Magnum/AbstractShaderProgram.h

@ -1,41 +0,0 @@
#ifndef Magnum_AbstractShaderProgram_h
#define Magnum_AbstractShaderProgram_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/AbstractShaderProgram.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/AbstractShaderProgram.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/AbstractShaderProgram.h instead")
#else
#error use Magnum/GL/AbstractShaderProgram.h instead
#endif
#endif

41
src/Magnum/AbstractTexture.h

@ -1,41 +0,0 @@
#ifndef Magnum_AbstractTexture_h
#define Magnum_AbstractTexture_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/AbstractTexture.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/AbstractTexture.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/AbstractTexture.h instead")
#else
#error use Magnum/GL/AbstractTexture.h instead
#endif
#endif

41
src/Magnum/Attribute.h

@ -1,41 +0,0 @@
#ifndef Magnum_Attribute_h
#define Magnum_Attribute_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Attribute.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Attribute.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Attribute.h instead")
#else
#error use Magnum/GL/Attribute.h instead
#endif
#endif

41
src/Magnum/Buffer.h

@ -1,41 +0,0 @@
#ifndef Magnum_Buffer_h
#define Magnum_Buffer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Buffer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Buffer.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Buffer.h instead")
#else
#error use Magnum/GL/Buffer.h instead
#endif
#endif

41
src/Magnum/BufferImage.h

@ -1,41 +0,0 @@
#ifndef Magnum_BufferImage_h
#define Magnum_BufferImage_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/BufferImage.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/BufferImage.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/BufferImage.h instead")
#else
#error use Magnum/GL/BufferImage.h instead
#endif
#endif

41
src/Magnum/BufferTexture.h

@ -1,41 +0,0 @@
#ifndef Magnum_BufferTexture_h
#define Magnum_BufferTexture_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/BufferTexture.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/BufferTexture.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/BufferTexture.h instead")
#else
#error use Magnum/GL/BufferTexture.h instead
#endif
#endif

41
src/Magnum/BufferTextureFormat.h

@ -1,41 +0,0 @@
#ifndef Magnum_BufferTextureFormat_h
#define Magnum_BufferTextureFormat_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/BufferTextureFormat.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/BufferTextureFormat.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/BufferTextureFormat.h instead")
#else
#error use Magnum/GL/BufferTextureFormat.h instead
#endif
#endif

81
src/Magnum/CMakeLists.txt

@ -63,75 +63,6 @@ set(Magnum_HEADERS
Types.h
visibility.h)
# Compatibility headers for GL library
if(WITH_GL AND BUILD_DEPRECATED)
list(APPEND Magnum_HEADERS
AbstractFramebuffer.h
AbstractObject.h
AbstractShaderProgram.h
AbstractTexture.h
Attribute.h
Buffer.h
Context.h
CubeMapTexture.h
DefaultFramebuffer.h
Extensions.h
Framebuffer.h
MeshView.h
OpenGL.h
Renderbuffer.h
RenderbufferFormat.h
Renderer.h
Shader.h
Tags.h
Texture.h
TextureFormat.h
Version.h)
# Desktop-only stuff
if(NOT TARGET_GLES)
list(APPEND Magnum_HEADERS RectangleTexture.h)
endif()
# OpenGL ES 3.0 and WebGL 2.0 stuff
if(NOT TARGET_GLES2)
list(APPEND Magnum_HEADERS
BufferImage.h
PrimitiveQuery.h
TextureArray.h
TransformFeedback.h)
endif()
# Desktop and OpenGL ES stuff that is not available in WebGL
if(NOT TARGET_WEBGL)
list(APPEND Magnum_HEADERS
DebugOutput.h
TimeQuery.h)
# Desktop and OpenGL ES 3.0 stuff that is not available in ES2 and WebGL
if(NOT TARGET_GLES2)
list(APPEND Magnum_HEADERS
BufferTexture.h
BufferTextureFormat.h
CubeMapTextureArray.h
ImageFormat.h
MultisampleTexture.h)
endif()
endif()
# Desktop, OpenGL ES and WebGL 2.0 stuff that is not available in WebGL 1.0
if(NOT (TARGET_WEBGL AND TARGET_GLES2))
list(APPEND Magnum_HEADERS
AbstractQuery.h
SampleQuery.h)
endif()
endif()
# Compatibility headers for OpenGLTester
if(WITH_OPENGLTESTER AND BUILD_DEPRECATED)
list(APPEND Magnum_HEADERS OpenGLTester.h)
endif()
# Files shared between main library and math unit test library
set(MagnumMath_SRCS
Math/Angle.cpp
@ -164,10 +95,6 @@ target_include_directories(MagnumObjects PUBLIC
${PROJECT_SOURCE_DIR}/src
${PROJECT_BINARY_DIR}/src
$<TARGET_PROPERTY:Corrade::Utility,INTERFACE_INCLUDE_DIRECTORIES>)
if(BUILD_DEPRECATED AND TARGET_GL) # TODO: remove once compat gets dropped
target_include_directories(MagnumObjects PUBLIC
${PROJECT_SOURCE_DIR}/src/MagnumExternal/OpenGL)
endif()
if(NOT BUILD_STATIC)
target_compile_definitions(MagnumObjects PRIVATE "MagnumObjects_EXPORTS")
endif()
@ -192,10 +119,6 @@ endif()
target_include_directories(Magnum PUBLIC
${PROJECT_SOURCE_DIR}/src
${PROJECT_BINARY_DIR}/src)
if(BUILD_DEPRECATED AND TARGET_GL) # TODO: remove once compat gets dropped
target_include_directories(Magnum PUBLIC
${PROJECT_SOURCE_DIR}/src/MagnumExternal/OpenGL)
endif()
target_link_libraries(Magnum PUBLIC
Corrade::Utility)
@ -280,10 +203,6 @@ if(BUILD_TESTS)
target_include_directories(MagnumTestLib PUBLIC
${PROJECT_SOURCE_DIR}/src
${PROJECT_BINARY_DIR}/src)
if(BUILD_DEPRECATED AND TARGET_GL) # TODO: remove once compat gets dropped
target_include_directories(MagnumTestLib PUBLIC
${PROJECT_SOURCE_DIR}/src/MagnumExternal/OpenGL)
endif()
target_compile_definitions(MagnumTestLib PRIVATE
"CORRADE_GRACEFUL_ASSERT" "Magnum_EXPORTS")
set_target_properties(MagnumTestLib PROPERTIES

41
src/Magnum/Context.h

@ -1,41 +0,0 @@
#ifndef Magnum_Context_h
#define Magnum_Context_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Context.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Context.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Context.h instead")
#else
#error use Magnum/GL/Context.h instead
#endif
#endif

41
src/Magnum/CubeMapTexture.h

@ -1,41 +0,0 @@
#ifndef Magnum_CubeMapTexture_h
#define Magnum_CubeMapTexture_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/CubeMapTexture.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/CubeMapTexture.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/CubeMapTexture.h instead")
#else
#error use Magnum/GL/CubeMapTexture.h instead
#endif
#endif

41
src/Magnum/CubeMapTextureArray.h

@ -1,41 +0,0 @@
#ifndef Magnum_CubeMapTextureArray_h
#define Magnum_CubeMapTextureArray_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/CubeMapTextureArray.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/CubeMapTextureArray.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/CubeMapTextureArray.h instead")
#else
#error use Magnum/GL/CubeMapTextureArray.h instead
#endif
#endif

41
src/Magnum/DebugOutput.h

@ -1,41 +0,0 @@
#ifndef Magnum_DebugOutput_h
#define Magnum_DebugOutput_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/DebugOutput.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/DebugOutput.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/DebugOutput.h instead")
#else
#error use Magnum/GL/DebugOutput.h instead
#endif
#endif

106
src/Magnum/DebugTools/CompareImage.cpp

@ -136,61 +136,6 @@ std::tuple<std::vector<Float>, Float, Float> calculateImageDelta(const ImageView
case PixelFormat::RGBA16F:
CORRADE_ASSERT(false,
"DebugTools::CompareImage: half-float formats are not supported yet", {});
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
CORRADE_IGNORE_DEPRECATED_PUSH
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::Red:
#endif
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::Green:
case PixelFormat::Blue:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::Luminance:
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::RG:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::LuminanceAlpha:
#endif
case PixelFormat::RGB:
case PixelFormat::RGBA:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGR:
#endif
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::BGRA:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::SRGB:
case PixelFormat::SRGBAlpha:
#endif
#ifndef MAGNUM_TARGET_GLES2
case PixelFormat::RedInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::GreenInteger:
case PixelFormat::BlueInteger:
#endif
case PixelFormat::RGInteger:
case PixelFormat::RGBInteger:
case PixelFormat::RGBAInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGRInteger:
case PixelFormat::BGRAInteger:
#endif
#endif
case PixelFormat::DepthComponent:
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::StencilIndex:
#endif
case PixelFormat::DepthStencil:
/** @todo CORRADE_ASSERT_UNREACHABLE() with message here */
CORRADE_ASSERT(false,
"DebugTools::CompareImage: deprecated GL-specific formats are not supported", {});
CORRADE_IGNORE_DEPRECATED_POP
#endif
}
CORRADE_ASSERT(max == max,
@ -302,57 +247,6 @@ void printPixelAt(Debug& out, const char* const pixels, const std::size_t stride
case PixelFormat::RG16F:
case PixelFormat::RGB16F:
case PixelFormat::RGBA16F:
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
CORRADE_IGNORE_DEPRECATED_PUSH
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::Red:
#endif
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::Green:
case PixelFormat::Blue:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::Luminance:
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::RG:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::LuminanceAlpha:
#endif
case PixelFormat::RGB:
case PixelFormat::RGBA:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGR:
#endif
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::BGRA:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::SRGB:
case PixelFormat::SRGBAlpha:
#endif
#ifndef MAGNUM_TARGET_GLES2
case PixelFormat::RedInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::GreenInteger:
case PixelFormat::BlueInteger:
#endif
case PixelFormat::RGInteger:
case PixelFormat::RGBInteger:
case PixelFormat::RGBAInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGRInteger:
case PixelFormat::BGRAInteger:
#endif
#endif
case PixelFormat::DepthComponent:
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::StencilIndex:
#endif
case PixelFormat::DepthStencil:
CORRADE_IGNORE_DEPRECATED_POP
#endif
/* Already handled by a printing assert before */
CORRADE_ASSERT_UNREACHABLE(); /* LCOV_EXCL_LINE */
}

20
src/Magnum/DebugTools/Test/CompareImageTest.cpp

@ -49,9 +49,6 @@ struct CompareImageTest: TestSuite::Tester {
void formatUnknown();
void formatHalf();
void formatImplementationSpecific();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void formatDeprecated();
#endif
void calculateDelta();
void calculateDeltaStorage();
@ -101,9 +98,6 @@ CompareImageTest::CompareImageTest() {
addTests({&CompareImageTest::formatUnknown,
&CompareImageTest::formatHalf,
&CompareImageTest::formatImplementationSpecific,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&CompareImageTest::formatDeprecated,
#endif
&CompareImageTest::calculateDelta,
&CompareImageTest::calculateDeltaStorage,
@ -218,20 +212,6 @@ void CompareImageTest::formatImplementationSpecific() {
CORRADE_COMPARE(out.str(), "DebugTools::CompareImage: can't compare implementation-specific pixel formats\n");
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void CompareImageTest::formatDeprecated() {
std::ostringstream out;
Error redirectError{&out};
CORRADE_IGNORE_DEPRECATED_PUSH
ImageView2D image{PixelFormat::RGB, PixelType::UnsignedByte, {}};
CORRADE_IGNORE_DEPRECATED_POP
Implementation::calculateImageDelta(image, image);
CORRADE_COMPARE(out.str(), "DebugTools::CompareImage: deprecated GL-specific formats are not supported\n");
}
#endif
void CompareImageTest::calculateDelta() {
std::vector<Float> delta;
Float max, mean;

40
src/Magnum/DefaultFramebuffer.h

@ -1,40 +0,0 @@
#ifndef Magnum_DefaultFramebuffer_h
#define Magnum_DefaultFramebuffer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/DefaultFramebuffer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/DefaultFramebuffer.h"
#else
#error use Magnum/GL/DefaultFramebuffer.h instead
#endif
#endif

41
src/Magnum/Extensions.h

@ -1,41 +0,0 @@
#ifndef Magnum_Extensions_h
#define Magnum_Extensions_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Extensions.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Extensions.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Extensions.h instead")
#else
#error use Magnum/GL/Extensions.h instead
#endif
#endif

41
src/Magnum/Framebuffer.h

@ -1,41 +0,0 @@
#ifndef Magnum_Framebuffer_h
#define Magnum_Framebuffer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Framebuffer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Framebuffer.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Framebuffer.h instead")
#else
#error use Magnum/GL/Framebuffer.h instead
#endif
#endif

45
src/Magnum/GL/AbstractFramebuffer.h

@ -869,49 +869,6 @@ CORRADE_ENUMSET_OPERATORS(FramebufferClearMask)
CORRADE_ENUMSET_OPERATORS(FramebufferBlitMask)
#endif
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::FramebufferClear
* @deprecated Use @ref GL::FramebufferClear instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferClear instead") Magnum::GL::FramebufferClear FramebufferClear;
/** @brief @copybrief GL::FramebufferClearMask
* @deprecated Use @ref GL::FramebufferClearMask instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferClearMask instead") Magnum::GL::FramebufferClearMask FramebufferClearMask;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
/** @brief @copybrief GL::FramebufferBlit
* @deprecated Use @ref GL::FramebufferBlit instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferBlit instead") Magnum::GL::FramebufferBlit FramebufferBlit;
/** @brief @copybrief GL::FramebufferBlitMask
* @deprecated Use @ref GL::FramebufferBlitMask instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferBlitMask instead") Magnum::GL::FramebufferBlitMask FramebufferBlitMask;
/** @brief @copybrief GL::FramebufferBlitFilter
* @deprecated Use @ref GL::FramebufferBlitFilter instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferBlitFilter instead") Magnum::GL::FramebufferBlitFilter FramebufferBlitFilter;
#endif
/** @brief @copybrief GL::FramebufferTarget
* @deprecated Use @ref GL::FramebufferTarget instead.
*/
typedef CORRADE_DEPRECATED("use GL::FramebufferTarget instead") Magnum::GL::FramebufferTarget FramebufferTarget;
/** @brief @copybrief GL::AbstractFramebuffer
* @deprecated Use @ref GL::AbstractFramebuffer instead.
*/
typedef CORRADE_DEPRECATED("use GL::AbstractFramebuffer instead") Magnum::GL::AbstractFramebuffer AbstractFramebuffer;
#endif
}
}}
#endif

23
src/Magnum/GL/AbstractObject.h

@ -131,27 +131,6 @@ class MAGNUM_GL_EXPORT AbstractObject {
CORRADE_ENUMSET_OPERATORS(ObjectFlags)
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::ObjectFlag
* @deprecated Use @ref GL::ObjectFlag instead.
*/
typedef CORRADE_DEPRECATED("use GL::ObjectFlag instead") Magnum::GL::ObjectFlag ObjectFlag;
/** @brief @copybrief GL::ObjectFlags
* @deprecated Use @ref GL::ObjectFlags instead.
*/
typedef CORRADE_DEPRECATED("use GL::ObjectFlags instead") Magnum::GL::ObjectFlags ObjectFlags;
/** @brief @copybrief GL::AbstractObject
* @deprecated Use @ref GL::AbstractObject instead.
*/
typedef CORRADE_DEPRECATED("use GL::AbstractObject instead") Magnum::GL::AbstractObject AbstractObject;
#endif
}
}}
#endif

13
src/Magnum/GL/AbstractQuery.h

@ -226,18 +226,7 @@ inline GLuint AbstractQuery::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::AbstractQuery
* @deprecated Use @ref GL::AbstractQuery instead.
*/
typedef CORRADE_DEPRECATED("use GL::AbstractQuery instead") Magnum::GL::AbstractQuery AbstractQuery;
#endif
}
}}
#else
#error this header is not available in WebGL 1.0 build
#endif

13
src/Magnum/GL/AbstractShaderProgram.h

@ -1288,17 +1288,6 @@ class MAGNUM_GL_EXPORT AbstractShaderProgram: public AbstractObject {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::AbstractShaderProgram
* @deprecated Use @ref GL::AbstractShaderProgram instead.
*/
typedef CORRADE_DEPRECATED("use GL::AbstractShaderProgram instead") Magnum::GL::AbstractShaderProgram AbstractShaderProgram;
#endif
}
}}
#endif

13
src/Magnum/GL/AbstractTexture.h

@ -809,17 +809,6 @@ inline GLuint AbstractTexture::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::AbstractTexture
* @deprecated Use @ref GL::AbstractTexture instead.
*/
typedef CORRADE_DEPRECATED("use GL::AbstractTexture instead") Magnum::GL::AbstractTexture AbstractTexture;
#endif
}
}}
#endif

20
src/Magnum/GL/Attribute.h

@ -799,24 +799,6 @@ template<class T> struct Attribute<Math::Matrix4<T>>: Attribute<Math::Matrix<4,
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Attribute
* @deprecated Use @ref GL::Attribute instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt location, class T> using Attribute CORRADE_DEPRECATED_ALIAS("use GL::Attribute instead") = Magnum::GL::Attribute<location, T>;
#endif
/** @brief @copybrief GL::DynamicAttribute
* @deprecated Use @ref GL::DynamicAttribute instead.
*/
typedef CORRADE_DEPRECATED("use GL::DynamicAttribute instead") Magnum::GL::DynamicAttribute DynamicAttribute;
#endif
}
}}
#endif

18
src/Magnum/GL/Buffer.h

@ -1354,22 +1354,6 @@ template<class T> Containers::Array<T> inline Buffer::subData(const GLintptr off
CORRADE_IGNORE_DEPRECATED_POP
#endif
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::BufferUsage
* @deprecated Use @ref GL::BufferUsage instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferUsage instead") Magnum::GL::BufferUsage BufferUsage;
/** @brief @copybrief GL::Buffer
* @deprecated Use @ref GL::Buffer instead.
*/
typedef CORRADE_DEPRECATED("use GL::Buffer instead") Magnum::GL::Buffer Buffer;
#endif
}
}}
#endif

121
src/Magnum/GL/BufferImage.h

@ -115,23 +115,6 @@ template<UnsignedInt dimensions> class BufferImage {
*/
explicit BufferImage(PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Containers::ArrayView<const void> data, BufferUsage usage): BufferImage{{}, format, type, size, data, usage} {}
#ifdef MAGNUM_BUILD_DEPRECATED
/**
* @brief Constructor
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
explicit CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(PixelStorage storage, Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Containers::ArrayView<const void> data, BufferUsage usage): BufferImage{storage, PixelFormat(UnsignedInt(format)), type, size, data, usage} {}
/**
* @brief Constructor
*
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
explicit CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Containers::ArrayView<const void> data, BufferUsage usage): BufferImage{PixelFormat(UnsignedInt(format)), type, size, data, usage} {}
#endif
/**
* @brief Constructor
* @param storage Storage of pixel data
@ -185,22 +168,6 @@ template<UnsignedInt dimensions> class BufferImage {
*/
explicit BufferImage(PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Buffer&& buffer, std::size_t dataSize) noexcept: BufferImage{{}, format, type, size, std::move(buffer), dataSize} {}
#ifdef MAGNUM_BUILD_DEPRECATED
/**
* @brief Construct from existing buffer
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
explicit CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(PixelStorage storage, Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Buffer&& buffer, std::size_t dataSize) noexcept: BufferImage{storage, PixelFormat(UnsignedInt(format)), type, size, std::move(buffer), dataSize} {}
/**
* @brief Construct from existing buffer
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
explicit CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Buffer&& buffer, std::size_t dataSize) noexcept: BufferImage{PixelFormat(UnsignedInt(format)), type, size, std::move(buffer), dataSize} {}
#endif
/**
* @brief Construct from existing buffer
* @param storage Storage of pixel data
@ -248,22 +215,6 @@ template<UnsignedInt dimensions> class BufferImage {
*/
/*implicit*/ BufferImage(PixelFormat format, PixelType type): BufferImage{{}, format, type} {}
#ifdef MAGNUM_BUILD_DEPRECATED
/**
* @brief Construct an image placeholder
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
/*implicit*/ CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(PixelStorage storage, Magnum::PixelFormat format, PixelType type): BufferImage{storage, PixelFormat(UnsignedInt(format)), type} {}
/**
* @brief Construct an image placeholder
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
/*implicit*/ CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") BufferImage(Magnum::PixelFormat format, PixelType type): BufferImage{PixelFormat(UnsignedInt(format)), type} {}
#endif
/**
* @brief Construct an image placeholder
* @param storage Storage of pixel data
@ -371,26 +322,6 @@ template<UnsignedInt dimensions> class BufferImage {
setData({}, format, type, size, data, usage);
}
#ifdef MAGNUM_BUILD_DEPRECATED
/**
* @brief Set image data
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") void setData(PixelStorage storage, Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Containers::ArrayView<const void> data, BufferUsage usage) {
setData(storage, PixelFormat(UnsignedInt(format)), type, size, data, usage);
}
/**
* @brief Set image data
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") void setData(Magnum::PixelFormat format, PixelType type, const VectorTypeFor<dimensions, Int>& size, Containers::ArrayView<const void> data, BufferUsage usage) {
setData({}, PixelFormat(UnsignedInt(format)), type, size, data, usage);
}
#endif
/**
* @brief Set image data
* @param storage Storage of pixel data
@ -794,57 +725,7 @@ template<UnsignedInt dimensions> inline CompressedBufferImage<dimensions>& Compr
return *this;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::BufferImage
* @deprecated Use @ref GL::BufferImage instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt dimensions> using BufferImage CORRADE_DEPRECATED_ALIAS("use GL::BufferImage instead") = Magnum::GL::BufferImage<dimensions>;
#endif
/** @brief @copybrief GL::BufferImage1D
* @deprecated Use @ref GL::BufferImage1D instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferImage1D instead") Magnum::GL::BufferImage1D BufferImage1D;
/** @brief @copybrief GL::BufferImage2D
* @deprecated Use @ref GL::BufferImage2D instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferImage2D instead") Magnum::GL::BufferImage2D BufferImage2D;
/** @brief @copybrief GL::BufferImage3D
* @deprecated Use @ref GL::BufferImage3D instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferImage3D instead") Magnum::GL::BufferImage3D BufferImage3D;
/** @brief @copybrief GL::CompressedBufferImage
* @deprecated Use @ref GL::CompressedBufferImage instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt dimensions> using CompressedBufferImage CORRADE_DEPRECATED_ALIAS("use GL::CompressedBufferImage instead") = Magnum::GL::BufferImage<dimensions>;
#endif
/** @brief @copybrief GL::CompressedBufferImage1D
* @deprecated Use @ref GL::CompressedBufferImage1D instead.
*/
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage1D instead") Magnum::GL::CompressedBufferImage1D CompressedBufferImage1D;
/** @brief @copybrief GL::CompressedBufferImage2D
* @deprecated Use @ref GL::CompressedBufferImage2D instead.
*/
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage2D instead") Magnum::GL::CompressedBufferImage2D CompressedBufferImage2D;
/** @brief @copybrief GL::CompressedBufferImage3D
* @deprecated Use @ref GL::CompressedBufferImage3D instead.
*/
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage3D instead") Magnum::GL::CompressedBufferImage3D CompressedBufferImage3D;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 build
#endif

13
src/Magnum/GL/BufferTexture.h

@ -247,18 +247,7 @@ class MAGNUM_GL_EXPORT BufferTexture: public AbstractTexture {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::BufferTexture
* @deprecated Use @ref GL::BufferTexture instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferTexture instead") Magnum::GL::BufferTexture BufferTexture;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 and WebGL build
#endif

13
src/Magnum/GL/BufferTextureFormat.h

@ -171,18 +171,7 @@ enum class BufferTextureFormat: GLenum {
RGBA32F = GL_RGBA32F
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::BufferTextureFormat
* @deprecated Use @ref GL::BufferTextureFormat instead.
*/
typedef CORRADE_DEPRECATED("use GL::BufferTextureFormat instead") Magnum::GL::BufferTextureFormat BufferTextureFormat;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 and WebGL build
#endif

3
src/Magnum/GL/CMakeLists.txt

@ -263,9 +263,6 @@ if(WITH_OPENGLTESTER)
target_link_libraries(MagnumOpenGLTester Magnum Corrade::TestSuite ${OPENGLTESTER_APPLICATION})
install(FILES ${MagnumOpenGLTester_HEADERS} DESTINATION ${MAGNUM_INCLUDE_INSTALL_DIR}/GL)
if(BUILD_DEPRECATED)
install(FILES ${MagnumOpenGLTester_DEPRECATED_HEADERS} DESTINATION ${MAGNUM_INCLUDE_INSTALL_DIR}/Test)
endif()
install(TARGETS MagnumOpenGLTester
RUNTIME DESTINATION ${MAGNUM_BINARY_INSTALL_DIR}
LIBRARY DESTINATION ${MAGNUM_LIBRARY_INSTALL_DIR}

34
src/Magnum/GL/Context.h

@ -152,7 +152,7 @@ class MAGNUM_GL_EXPORT Context {
* @brief Context flag
*
* @see @ref Flags, @ref flags(),
* @ref Platform::Sdl2Application::Configuration::setFlags() "Platform::*Application::Configuration::setFlags()"
* @ref Platform::Sdl2Application::GLConfiguration::setFlags() "Platform::*Application::GLConfiguration::setFlags()"
* @m_enum_values_as_keywords
* @requires_gles Context flags are not available in WebGL.
*/
@ -806,36 +806,6 @@ Example usage:
} while(0)
#endif
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Extension
* @deprecated Use @ref GL::Extension instead.
*/
typedef CORRADE_DEPRECATED("use GL::Extension instead") Magnum::GL::Extension Extension;
/** @brief @copybrief GL::Context
* @deprecated Use @ref GL::Context instead.
*/
typedef CORRADE_DEPRECATED("use GL::Context instead") Magnum::GL::Context Context;
/** @brief @copybrief MAGNUM_ASSERT_GL_VERSION_SUPPORTED()
* @deprecated Use @ref MAGNUM_ASSERT_GL_VERSION_SUPPORTED()
*/
#define MAGNUM_ASSERT_VERSION_SUPPORTED(version) \
CORRADE_DEPRECATED_MACRO(MAGNUM_ASSERT_VERSION_SUPPORTED(), "use MAGNUM_ASSERT_GL_VERSION_SUPPORTED() instead") \
MAGNUM_ASSERT_GL_VERSION_SUPPORTED(version)
/** @brief @copybrief MAGNUM_ASSERT_GL_EXTENSION_SUPPORTED()
* @deprecated Use @ref MAGNUM_ASSERT_GL_EXTENSION_SUPPORTED()
*/
#define MAGNUM_ASSERT_EXTENSION_SUPPORTED(extension) \
CORRADE_DEPRECATED_MACRO(MAGNUM_ASSERT_EXTENSION_SUPPORTED(), "use MAGNUM_ASSERT_GL_EXTENSION_SUPPORTED() instead") \
MAGNUM_ASSERT_GL_EXTENSION_SUPPORTED(extension)
#endif
}
}}
#endif

18
src/Magnum/GL/CubeMapTexture.h

@ -1191,22 +1191,6 @@ class MAGNUM_GL_EXPORT CubeMapTexture: public AbstractTexture {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::CubeMapCoordinate
* @deprecated Use @ref GL::CubeMapCoordinate instead.
*/
typedef CORRADE_DEPRECATED("use GL::CubeMapCoordinate instead") Magnum::GL::CubeMapCoordinate CubeMapCoordinate;
/** @brief @copybrief GL::CubeMapTexture
* @deprecated Use @ref GL::CubeMapTexture instead.
*/
typedef CORRADE_DEPRECATED("use GL::CubeMapTexture instead") Magnum::GL::CubeMapTexture CubeMapTexture;
#endif
}
}}
#endif

13
src/Magnum/GL/CubeMapTextureArray.h

@ -843,18 +843,7 @@ class MAGNUM_GL_EXPORT CubeMapTextureArray: public AbstractTexture {
explicit CubeMapTextureArray(GLuint id, ObjectFlags flags) noexcept: AbstractTexture{id, GL_TEXTURE_CUBE_MAP_ARRAY, flags} {}
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::CubeMapTextureArray
* @deprecated Use @ref GL::CubeMapTextureArray instead.
*/
typedef CORRADE_DEPRECATED("use GL::CubeMapTextureArray instead") Magnum::GL::CubeMapTextureArray CubeMapTextureArray;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 and WebGL build
#endif

23
src/Magnum/GL/DebugOutput.h

@ -805,28 +805,7 @@ class MAGNUM_GL_EXPORT DebugGroup {
/** @debugoperatorclassenum{DebugGroup,DebugGroup::Source} */
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, DebugGroup::Source value);
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::DebugOutput
* @deprecated Use @ref GL::DebugOutput instead.
*/
typedef CORRADE_DEPRECATED("use GL::DebugOutput instead") Magnum::GL::DebugOutput DebugOutput;
/** @brief @copybrief GL::DebugMessage
* @deprecated Use @ref GL::DebugMessage instead.
*/
typedef CORRADE_DEPRECATED("use GL::DebugMessage instead") Magnum::GL::DebugMessage DebugMessage;
/** @brief @copybrief GL::DebugGroup
* @deprecated Use @ref GL::DebugGroup instead.
*/
typedef CORRADE_DEPRECATED("use GL::DebugGroup instead") Magnum::GL::DebugGroup DebugGroup;
#endif
}
}}
#else
#error this header is not available in WebGL build
#endif

9
src/Magnum/GL/DefaultFramebuffer.cpp

@ -35,14 +35,7 @@
#include "Magnum/Math/Color.h"
#endif
namespace Magnum {
#ifdef MAGNUM_BUILD_DEPRECATED
/* Variable defined in Magnum/DefaultFramebuffer.h */
MAGNUM_GL_EXPORT GL::DefaultFramebuffer& defaultFramebuffer = GL::defaultFramebuffer;
#endif
namespace GL {
namespace Magnum { namespace GL {
DefaultFramebuffer defaultFramebuffer;

18
src/Magnum/GL/DefaultFramebuffer.h

@ -509,22 +509,6 @@ extern DefaultFramebuffer MAGNUM_GL_EXPORT defaultFramebuffer;
/** @debugoperatorclassenum{DefaultFramebuffer,DefaultFramebuffer::Status} */
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, DefaultFramebuffer::Status value);
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::DefaultFramebuffer
* @deprecated Use @ref GL::DefaultFramebuffer instead.
*/
typedef CORRADE_DEPRECATED("use GL::DefaultFramebuffer instead") Magnum::GL::DefaultFramebuffer DefaultFramebuffer;
/** @brief @copybrief GL::defaultFramebuffer
* @deprecated Use @ref GL::defaultFramebuffer instead.
*/
extern CORRADE_DEPRECATED("use GL::defaultFramebuffer instead") MAGNUM_EXPORT Magnum::GL::DefaultFramebuffer& defaultFramebuffer;
#endif
}
}}
#endif

13
src/Magnum/GL/Extensions.h

@ -477,17 +477,6 @@ namespace ANDROID {
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief GL::Extensions
* @deprecated Use @ref GL::Extensions instead.
*/
namespace CORRADE_DEPRECATED_NAMESPACE("use GL::Extensions instead") Extensions {
namespace GL = Magnum::GL::Extensions;
}
#endif
}
}}
#endif

13
src/Magnum/GL/Framebuffer.h

@ -915,17 +915,6 @@ inline GLuint Framebuffer::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Framebuffer
* @deprecated Use @ref GL::Framebuffer instead.
*/
typedef CORRADE_DEPRECATED("use GL::Framebuffer instead") Magnum::GL::Framebuffer Framebuffer;
#endif
}
}}
#endif

18
src/Magnum/GL/ImageFormat.h

@ -309,23 +309,7 @@ enum class ImageFormat: GLenum {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::ImageAccess
* @deprecated Use @ref GL::ImageAccess instead.
*/
typedef CORRADE_DEPRECATED("use GL::ImageAccess instead") Magnum::GL::ImageAccess ImageAccess;
/** @brief @copybrief GL::ImageFormat
* @deprecated Use @ref GL::ImageFormat instead.
*/
typedef CORRADE_DEPRECATED("use GL::ImageFormat instead") Magnum::GL::ImageFormat ImageFormat;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 and WebGL build
#endif

11
src/Magnum/GL/Mesh.cpp

@ -66,17 +66,6 @@ constexpr MeshIndexType IndexTypeMapping[]{
}
MeshPrimitive meshPrimitive(const Magnum::MeshPrimitive primitive) {
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
CORRADE_IGNORE_DEPRECATED_PUSH
if(primitive == Magnum::MeshPrimitive::LinesAdjacency ||
primitive == Magnum::MeshPrimitive::LineStripAdjacency ||
primitive == Magnum::MeshPrimitive::TrianglesAdjacency ||
primitive == Magnum::MeshPrimitive::TriangleStripAdjacency ||
primitive == Magnum::MeshPrimitive::Patches)
return MeshPrimitive(UnsignedInt(primitive));
CORRADE_IGNORE_DEPRECATED_POP
#endif
CORRADE_ASSERT(UnsignedInt(primitive) < Containers::arraySize(PrimitiveMapping),
"GL::meshPrimitive(): invalid primitive" << primitive, {});
return PrimitiveMapping[UnsignedInt(primitive)];

13
src/Magnum/GL/Mesh.h

@ -1195,17 +1195,6 @@ inline GLuint Mesh::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Mesh
* @deprecated Use @ref GL::Mesh instead.
*/
typedef CORRADE_DEPRECATED("use GL::Mesh instead") Magnum::GL::Mesh Mesh;
#endif
}
}}
#endif

17
src/Magnum/GL/MeshView.h

@ -37,10 +37,6 @@
#include "Magnum/GL/OpenGL.h"
#include "Magnum/GL/visibility.h"
#ifdef MAGNUM_BUILD_DEPRECATED
#include <Corrade/Utility/Macros.h>
#endif
namespace Magnum { namespace GL {
namespace Implementation { struct MeshState; }
@ -322,17 +318,6 @@ inline MeshView& MeshView::setIndexRange(Int first, UnsignedInt start, UnsignedI
return *this;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::MeshView
* @deprecated Use @ref GL::MeshView instead.
*/
typedef CORRADE_DEPRECATED("use GL::MeshView instead") Magnum::GL::MeshView MeshView;
#endif
}
}}
#endif

30
src/Magnum/GL/MultisampleTexture.h

@ -335,35 +335,7 @@ typedef MultisampleTexture<2> MultisampleTexture2D;
*/
typedef MultisampleTexture<3> MultisampleTexture2DArray;
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::MultisampleTextureSampleLocations
* @deprecated Use @ref GL::MultisampleTextureSampleLocations instead.
*/
typedef CORRADE_DEPRECATED("use GL::MultisampleTextureSampleLocations instead") Magnum::GL::MultisampleTextureSampleLocations MultisampleTextureSampleLocations;
/** @brief @copybrief GL::MultisampleTexture
* @deprecated Use @ref GL::MultisampleTexture instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt dimensions> using MultisampleTexture CORRADE_DEPRECATED_ALIAS("use GL::MultisampleTexture instead") = Magnum::GL::MultisampleTexture<dimensions>;
#endif
/** @brief @copybrief GL::MultisampleTexture2D
* @deprecated Use @ref GL::MultisampleTexture2D instead.
*/
typedef CORRADE_DEPRECATED("use GL::MultisampleTexture2D instead") Magnum::GL::MultisampleTexture2D MultisampleTexture2D;
/** @brief @copybrief GL::MultisampleTexture2DArray
* @deprecated Use @ref GL::MultisampleTexture2DArray instead.
*/
typedef CORRADE_DEPRECATED("use GL::MultisampleTexture2DArray instead") Magnum::GL::MultisampleTexture2DArray MultisampleTexture2DArray;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 and WebGL build
#endif

20
src/Magnum/GL/OpenGLTester.h

@ -285,25 +285,7 @@ Equivalent to
*/
#define MAGNUM_VERIFY_NO_GL_ERROR() CORRADE_COMPARE(Magnum::GL::Renderer::error(), Magnum::GL::Renderer::Error::NoError)
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::OpenGLTester
* @deprecated Use @ref GL::OpenGLTester instead.
*/
typedef CORRADE_DEPRECATED("use GL::OpenGLTester instead") Magnum::GL::OpenGLTester OpenGLTester;
/** @brief @copybrief MAGNUM_VERIFY_NO_GL_ERROR()
* @deprecated Use @ref MAGNUM_VERIFY_NO_GL_ERROR() instead.
*/
#define MAGNUM_VERIFY_NO_ERROR() \
CORRADE_DEPRECATED_MACRO(MAGNUM_VERIFY_NO_ERROR(),"use MAGNUM_VERIFY_NO_GL_ERROR() instead") \
MAGNUM_VERIFY_NO_GL_ERROR()
#endif
}
}}
#else
#error this header is available only in the OpenGL build
#endif

33
src/Magnum/GL/PixelFormat.cpp

@ -54,13 +54,6 @@ bool hasPixelFormat(const Magnum::PixelFormat format) {
if(isPixelFormatImplementationSpecific(format))
return true;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* See GL/Test/PixelFormatTest.cpp for more information. Returning true
unconditionally here as unsupported enum values shouldn't even be
compiled. */
if(UnsignedInt(format) > 0x1000) return true;
#endif
CORRADE_ASSERT(UnsignedInt(format) < Containers::arraySize(FormatMapping),
"GL::hasPixelFormat(): invalid format" << format, {});
return UnsignedInt(FormatMapping[UnsignedInt(format)].format);
@ -70,12 +63,6 @@ PixelFormat pixelFormat(const Magnum::PixelFormat format) {
if(isPixelFormatImplementationSpecific(format))
return pixelFormatUnwrap<GL::PixelFormat>(format);
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* See GL/Test/PixelFormatTest.cpp for more information */
if(UnsignedInt(format) > 0x1000)
return PixelFormat(UnsignedInt(format));
#endif
CORRADE_ASSERT(UnsignedInt(format) < Containers::arraySize(FormatMapping),
"GL::pixelFormat(): invalid format" << format, {});
const PixelFormat out = FormatMapping[UnsignedInt(format)].format;
@ -85,12 +72,7 @@ PixelFormat pixelFormat(const Magnum::PixelFormat format) {
}
PixelType pixelType(const Magnum::PixelFormat format, const UnsignedInt extra) {
if(isPixelFormatImplementationSpecific(format)
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* See GL/Test/PixelFormatTest.cpp for more information */
|| UnsignedInt(format) > 0x1000
#endif
) {
if(isPixelFormatImplementationSpecific(format)) {
CORRADE_ASSERT(extra,
"GL::pixelType(): format is implementation-specific, but no additional type specifier was passed", {});
return PixelType(extra);
@ -363,13 +345,6 @@ bool hasCompressedPixelFormat(const Magnum::CompressedPixelFormat format) {
if(isCompressedPixelFormatImplementationSpecific(format))
return true;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* See GL/Test/PixelFormatTest.cpp for more information. Returning true
unconditionally here as unsupported enum values shouldn't even be
compiled. */
if(UnsignedInt(format) > 0x1000) return true;
#endif
CORRADE_ASSERT(UnsignedInt(format) < Containers::arraySize(CompressedFormatMapping),
"GL::hasCompressedPixelFormat(): invalid format" << format, {});
return UnsignedInt(CompressedFormatMapping[UnsignedInt(format)]);
@ -379,12 +354,6 @@ CompressedPixelFormat compressedPixelFormat(const Magnum::CompressedPixelFormat
if(isCompressedPixelFormatImplementationSpecific(format))
return compressedPixelFormatUnwrap<GL::CompressedPixelFormat>(format);
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* See GL/Test/PixelFormatTest.cpp for more information */
if(UnsignedInt(format) > 0x1000)
return CompressedPixelFormat(UnsignedInt(format));
#endif
CORRADE_ASSERT(UnsignedInt(format) < Containers::arraySize(CompressedFormatMapping),
"GL::compressedPixelFormat(): invalid format" << format, {});
const CompressedPixelFormat out = CompressedFormatMapping[UnsignedInt(format)];

23
src/Magnum/GL/PixelFormat.h

@ -663,16 +663,6 @@ MAGNUM_GL_EXPORT PixelType pixelType(Magnum::PixelFormat format, UnsignedInt ext
*/
MAGNUM_GL_EXPORT UnsignedInt pixelSize(PixelFormat format, PixelType type);
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief pixelSize(PixelFormat, PixelType)
* @deprecated Use either @ref GL::PixelFormat together with
* @ref GL::PixelType or just @ref Magnum::PixelFormat instead
*/
inline CORRADE_DEPRECATED("use either GL::PixelFormat together with GL::PixelType or just Magnum::PixelFormat instead") UnsignedInt pixelSize(Magnum::PixelFormat format, PixelType type) {
return pixelSize(PixelFormat(UnsignedInt(format)), type);
}
#endif
/** @debugoperatorenum{PixelFormat} */
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, PixelFormat value);
@ -1356,17 +1346,6 @@ MAGNUM_GL_EXPORT CompressedPixelFormat compressedPixelFormat(Magnum::CompressedP
/** @debugoperatorenum{CompressedPixelFormat} */
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, CompressedPixelFormat value);
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::PixelType
* @deprecated Use @ref GL::PixelType instead.
*/
typedef CORRADE_DEPRECATED("use GL::PixelType instead") Magnum::GL::PixelType PixelType;
#endif
}
}}
#endif

13
src/Magnum/GL/PrimitiveQuery.h

@ -218,18 +218,7 @@ class MAGNUM_GL_EXPORT PrimitiveQuery: public AbstractQuery {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::PrimitiveQuery
* @deprecated Use @ref GL::PrimitiveQuery instead.
*/
typedef CORRADE_DEPRECATED("use GL::PrimitiveQuery instead") Magnum::GL::PrimitiveQuery PrimitiveQuery;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 build
#endif

13
src/Magnum/GL/RectangleTexture.h

@ -659,18 +659,7 @@ class MAGNUM_GL_EXPORT RectangleTexture: public AbstractTexture {
explicit RectangleTexture(GLuint id, ObjectFlags flags) noexcept: AbstractTexture{id, GL_TEXTURE_RECTANGLE, flags} {}
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::RectangleTexture
* @deprecated Use @ref GL::RectangleTexture instead.
*/
typedef CORRADE_DEPRECATED("use GL::RectangleTexture instead") Magnum::GL::RectangleTexture RectangleTexture;
#endif
}
}}
#else
#error this header is not available in OpenGL ES build
#endif

13
src/Magnum/GL/Renderbuffer.h

@ -295,17 +295,6 @@ inline GLuint Renderbuffer::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Renderbuffer
* @deprecated Use @ref GL::Renderbuffer instead.
*/
typedef CORRADE_DEPRECATED("use GL::Renderbuffer instead") Magnum::GL::Renderbuffer Renderbuffer;
#endif
}
}}
#endif

13
src/Magnum/GL/RenderbufferFormat.h

@ -639,17 +639,6 @@ enum class RenderbufferFormat: GLenum {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::RenderbufferFormat
* @deprecated Use @ref GL::RenderbufferFormat instead.
*/
typedef CORRADE_DEPRECATED("use GL::RenderbufferFormat instead") Magnum::GL::RenderbufferFormat RenderbufferFormat;
#endif
}
}}
#endif

17
src/Magnum/GL/Renderer.h

@ -36,6 +36,10 @@
#include "Magnum/GL/OpenGL.h"
#include "Magnum/GL/visibility.h"
#ifdef MAGNUM_BUILD_DEPRECATED
#include <Corrade/Utility/Macros.h>
#endif
namespace Magnum { namespace GL {
namespace Implementation { struct RendererState; }
@ -1706,17 +1710,6 @@ MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, Renderer::ResetNotificationStra
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, Renderer::GraphicsResetStatus value);
#endif
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Renderer
* @deprecated Use @ref GL::Renderer instead.
*/
typedef CORRADE_DEPRECATED("use GL::Renderer instead") Magnum::GL::Renderer Renderer;
#endif
}
}}
#endif

13
src/Magnum/GL/SampleQuery.h

@ -262,18 +262,7 @@ class SampleQuery: public AbstractQuery {
explicit SampleQuery(GLuint id, Target target, ObjectFlags flags) noexcept: AbstractQuery{id, GLenum(target), flags} {}
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::SampleQuery
* @deprecated Use @ref GL::SampleQuery instead.
*/
typedef CORRADE_DEPRECATED("use GL::SampleQuery instead") Magnum::GL::SampleQuery SampleQuery;
#endif
}
}}
#else
#error this header is not available in WebGL 1.0 build
#endif

52
src/Magnum/GL/Sampler.h

@ -347,56 +347,6 @@ class MAGNUM_GL_EXPORT Sampler {
/* This class is currently a placeholder for GL sampler objects */
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief Texture sampler
* @deprecated Use @ref GL::Sampler, @ref SamplerFilter, @ref GL::SamplerFilter, @ref SamplerMipmap, @ref GL::SamplerMipmap, @ref SamplerWrapping, @ref GL::SamplerWrapping, @ref GL::SamplerCompareMode, @ref GL::SamplerCompareFunction or @ref GL::SamplerDepthStencilMode instead.
*/
struct CORRADE_DEPRECATED("use GL::Sampler, SamplerFilter, GL::SamplerFilter, SamplerMipmap, GL::SamplerMipmap, SamplerWrapping, GL::SamplerWrapping, GL::SamplerCompareMode, GL::SamplerCompareFunction or GL::SamplerDepthStencilMode instead") Sampler {
/** @brief @copybrief SamplerFilter
* @deprecated Use @ref SamplerFilter or @ref GL::SamplerFilter instead.
*/
typedef CORRADE_DEPRECATED("use SamplerFilter or GL::SamplerFilter instead") SamplerFilter Filter;
/** @brief @copybrief SamplerMipmap
* @deprecated Use @ref SamplerMipmap or @ref GL::SamplerMipmap instead.
*/
typedef CORRADE_DEPRECATED("use SamplerMipmap or GL::SamplerMipmap instead") SamplerMipmap Mipmap;
/** @brief @copybrief SamplerWrapping
* @deprecated Use @ref SamplerMipmap or @ref GL::SamplerWrapping instead.
*/
typedef CORRADE_DEPRECATED("use SamplerWrapping or GL::SamplerWrapping instead") SamplerWrapping Wrapping;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
/** @brief @copybrief GL::SamplerCompareMode
* @deprecated Use @ref GL::SamplerCompareMode instead.
*/
typedef CORRADE_DEPRECATED("use GL::SamplerCompareMode instead") GL::SamplerCompareMode CompareMode;
/** @brief @copybrief GL::SamplerCompareFunction
* @deprecated Use @ref GL::SamplerCompareFunction instead.
*/
typedef CORRADE_DEPRECATED("use GL::SamplerCompareFunction instead") GL::SamplerCompareFunction CompareFunction;
#endif
#if !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
/** @brief @copybrief GL::SamplerDepthStencilMode
* @deprecated Use @ref GL::SamplerDepthStencilMode instead.
*/
typedef CORRADE_DEPRECATED("use GL::SamplerDepthStencilMode instead") GL::SamplerDepthStencilMode DepthStencilMode;
#endif
/** @brief @copybrief GL::Sampler::maxMaxAnisotropy()
* @deprecated Use @ref GL::Sampler::maxMaxAnisotropy() instead.
*/
static Float maxMaxAnisotropy() {
return GL::Sampler::maxMaxAnisotropy();
}
};
#endif
}
}}
#endif

13
src/Magnum/GL/Shader.h

@ -644,17 +644,6 @@ inline Shader& Shader::operator=(Shader&& other) noexcept {
return *this;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Shader
* @deprecated Use @ref GL::Shader instead.
*/
typedef CORRADE_DEPRECATED("use GL::Shader instead") Magnum::GL::Shader Shader;
#endif
}
}}
#endif

15
src/Magnum/GL/Test/MeshTest.cpp

@ -53,9 +53,6 @@ struct MeshTest: TestSuite::Tester {
#endif
void mapPrimitive();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
void mapPrimitiveDeprecated();
#endif
void mapPrimitiveInvalid();
void mapIndexType();
void mapIndexTypeInvalid();
@ -79,9 +76,6 @@ MeshTest::MeshTest() {
#endif
&MeshTest::mapPrimitive,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
&MeshTest::mapPrimitiveDeprecated,
#endif
&MeshTest::mapPrimitiveInvalid,
&MeshTest::mapIndexType,
&MeshTest::mapIndexTypeInvalid,
@ -178,15 +172,6 @@ void MeshTest::mapPrimitive() {
CORRADE_COMPARE(meshPrimitive(Magnum::MeshPrimitive::TriangleFan), MeshPrimitive::TriangleFan);
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
void MeshTest::mapPrimitiveDeprecated() {
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(meshPrimitive(Magnum::MeshPrimitive::TriangleStripAdjacency),
MeshPrimitive::TriangleStripAdjacency);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
void MeshTest::mapPrimitiveInvalid() {
std::ostringstream out;
Error redirectError{&out};

209
src/Magnum/GL/Test/PixelFormatTest.cpp

@ -29,10 +29,6 @@
#include "Magnum/PixelFormat.h"
#include "Magnum/GL/PixelFormat.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/PixelStorage.h"
#endif
namespace Magnum { namespace GL { namespace Test { namespace {
struct PixelFormatTest: TestSuite::Tester {
@ -40,30 +36,18 @@ struct PixelFormatTest: TestSuite::Tester {
void mapFormatType();
void mapFormatImplementationSpecific();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void mapFormatDeprecated();
#endif
void mapFormatUnsupported();
void mapFormatInvalid();
void mapTypeImplementationSpecific();
void mapTypeImplementationSpecificZero();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void mapTypeDeprecated();
#endif
void mapTypeUnsupported();
void mapTypeInvalid();
void size();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void sizeDataPropertiesDeprecated();
#endif
void sizeInvalid();
void mapCompressedFormat();
void mapCompressedFormatImplementationSpecific();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void mapCompressedFormatDeprecated();
#endif
void mapCompressedFormatUnsupported();
void mapCompressedFormatInvalid();
@ -76,30 +60,18 @@ struct PixelFormatTest: TestSuite::Tester {
PixelFormatTest::PixelFormatTest() {
addTests({&PixelFormatTest::mapFormatType,
&PixelFormatTest::mapFormatImplementationSpecific,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&PixelFormatTest::mapFormatDeprecated,
#endif
&PixelFormatTest::mapFormatUnsupported,
&PixelFormatTest::mapFormatInvalid,
&PixelFormatTest::mapTypeImplementationSpecific,
&PixelFormatTest::mapTypeImplementationSpecificZero,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&PixelFormatTest::mapTypeDeprecated,
#endif
&PixelFormatTest::mapTypeUnsupported,
&PixelFormatTest::mapTypeInvalid,
&PixelFormatTest::size,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&PixelFormatTest::sizeDataPropertiesDeprecated,
#endif
&PixelFormatTest::sizeInvalid,
&PixelFormatTest::mapCompressedFormat,
&PixelFormatTest::mapCompressedFormatImplementationSpecific,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&PixelFormatTest::mapCompressedFormatDeprecated,
#endif
&PixelFormatTest::mapCompressedFormatUnsupported,
&PixelFormatTest::mapCompressedFormatInvalid,
@ -148,67 +120,6 @@ void PixelFormatTest::mapFormatType() {
#include "Magnum/GL/Implementation/pixelFormatMapping.hpp"
#undef _s
#undef _c
/* Here to silence unhandled value warnings and to verify that all
GL-specific formats are larger than a particular value. This
value is used in pixelFormat() and pixelType() to detect
deprecated GL-specific values and convert them properly. */
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#define _c(value) \
case Magnum::PixelFormat::value: \
CORRADE_VERIFY(UnsignedInt(Magnum::PixelFormat::value) >= 0x1000); \
continue;
CORRADE_IGNORE_DEPRECATED_PUSH
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
_c(Red)
#endif
#ifndef MAGNUM_TARGET_GLES
_c(Green)
_c(Blue)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(Luminance)
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
_c(RG)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(LuminanceAlpha)
#endif
_c(RGB)
_c(RGBA)
#ifndef MAGNUM_TARGET_GLES
_c(BGR)
#endif
#ifndef MAGNUM_TARGET_WEBGL
_c(BGRA)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(SRGB)
_c(SRGBAlpha)
#endif
#ifndef MAGNUM_TARGET_GLES2
_c(RedInteger)
#ifndef MAGNUM_TARGET_GLES
_c(GreenInteger)
_c(BlueInteger)
#endif
_c(RGInteger)
_c(RGBInteger)
_c(RGBAInteger)
#ifndef MAGNUM_TARGET_GLES
_c(BGRInteger)
_c(BGRAInteger)
#endif
#endif
_c(DepthComponent)
#ifndef MAGNUM_TARGET_WEBGL
_c(StencilIndex)
#endif
_c(DepthStencil)
#undef _c
CORRADE_IGNORE_DEPRECATED_POP
#endif
}
/* Not handled by any value, remember -- we might either be at the end
@ -226,15 +137,6 @@ void PixelFormatTest::mapFormatImplementationSpecific() {
PixelFormat::RGBA);
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void PixelFormatTest::mapFormatDeprecated() {
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(pixelFormat(Magnum::PixelFormat::RGBA),
PixelFormat::RGBA);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
void PixelFormatTest::mapFormatUnsupported() {
#ifndef MAGNUM_TARGET_GLES2
CORRADE_SKIP("All pixel formats are supported on ES3+.");
@ -271,15 +173,6 @@ void PixelFormatTest::mapTypeImplementationSpecificZero() {
CORRADE_COMPARE(out.str(), "GL::pixelType(): format is implementation-specific, but no additional type specifier was passed\n");
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void PixelFormatTest::mapTypeDeprecated() {
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(pixelType(Magnum::PixelFormat::RGBA, GL_UNSIGNED_BYTE),
PixelType::UnsignedByte);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
void PixelFormatTest::mapTypeUnsupported() {
#ifndef MAGNUM_TARGET_GLES2
CORRADE_SKIP("All pixel formats are supported on ES3+");
@ -316,24 +209,6 @@ void PixelFormatTest::size() {
#endif
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void PixelFormatTest::sizeDataPropertiesDeprecated() {
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(PixelStorage::pixelSize(PixelFormat::RGBA, PixelType::UnsignedShort4444), 2);
CORRADE_IGNORE_DEPRECATED_POP
PixelStorage storage;
storage.setAlignment(4)
.setRowLength(15)
.setSkip({3, 7, 0});
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(storage.dataProperties(PixelFormat::RGBA, PixelType::UnsignedByte, Vector3i{1}),
(std::tuple<Math::Vector3<std::size_t>, Math::Vector3<std::size_t>, std::size_t>{{3*4, 7*15*4, 0}, {60, 1, 1}, 4}));
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
void PixelFormatTest::sizeInvalid() {
std::ostringstream out;
Error redirectError{&out};
@ -378,80 +253,6 @@ void PixelFormatTest::mapCompressedFormat() {
#include "Magnum/GL/Implementation/compressedPixelFormatMapping.hpp"
#undef _s
#undef _c
/* Here to silence unhandled value warnings and to verify that all
GL-specific formats are larger than a particular value. This
value is used in compressedPixelFormat() to detect deprecated
GL-specific values and convert them properly. */
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#define _c(value) \
case Magnum::CompressedPixelFormat::value: \
CORRADE_VERIFY(UnsignedInt(Magnum::CompressedPixelFormat::value) >= 0x1000); \
continue;
CORRADE_IGNORE_DEPRECATED_PUSH
#ifndef MAGNUM_TARGET_GLES
_c(Red)
_c(RG)
_c(RGB)
_c(RGBA)
_c(RedRgtc1)
_c(RGRgtc2)
_c(SignedRedRgtc1)
_c(SignedRGRgtc2)
_c(RGBBptcUnsignedFloat)
_c(RGBBptcSignedFloat)
_c(RGBABptcUnorm)
_c(SRGBAlphaBptcUnorm)
#endif
#ifndef MAGNUM_TARGET_GLES2
_c(RGB8Etc2)
_c(SRGB8Etc2)
_c(RGB8PunchthroughAlpha1Etc2)
_c(SRGB8PunchthroughAlpha1Etc2)
_c(RGBA8Etc2Eac)
_c(SRGB8Alpha8Etc2Eac)
_c(R11Eac)
_c(SignedR11Eac)
_c(RG11Eac)
_c(SignedRG11Eac)
#endif
_c(RGBS3tcDxt1)
_c(RGBAS3tcDxt1)
_c(RGBAS3tcDxt3)
_c(RGBAS3tcDxt5)
#ifndef MAGNUM_TARGET_WEBGL
_c(RGBAAstc4x4)
_c(SRGB8Alpha8Astc4x4)
_c(RGBAAstc5x4)
_c(SRGB8Alpha8Astc5x4)
_c(RGBAAstc5x5)
_c(SRGB8Alpha8Astc5x5)
_c(RGBAAstc6x5)
_c(SRGB8Alpha8Astc6x5)
_c(RGBAAstc6x6)
_c(SRGB8Alpha8Astc6x6)
_c(RGBAAstc8x5)
_c(SRGB8Alpha8Astc8x5)
_c(RGBAAstc8x6)
_c(SRGB8Alpha8Astc8x6)
_c(RGBAAstc8x8)
_c(SRGB8Alpha8Astc8x8)
_c(RGBAAstc10x5)
_c(SRGB8Alpha8Astc10x5)
_c(RGBAAstc10x6)
_c(SRGB8Alpha8Astc10x6)
_c(RGBAAstc10x8)
_c(SRGB8Alpha8Astc10x8)
_c(RGBAAstc10x10)
_c(SRGB8Alpha8Astc10x10)
_c(RGBAAstc12x10)
_c(SRGB8Alpha8Astc12x10)
_c(RGBAAstc12x12)
_c(SRGB8Alpha8Astc12x12)
#endif
#undef _c
CORRADE_IGNORE_DEPRECATED_POP
#endif
}
/* Not handled by any value, remember -- we might either be at the end
@ -468,16 +269,6 @@ void PixelFormatTest::mapCompressedFormatImplementationSpecific() {
CORRADE_COMPARE(compressedPixelFormat(Magnum::compressedPixelFormatWrap(CompressedPixelFormat::RGBAS3tcDxt1)),
CompressedPixelFormat::RGBAS3tcDxt1);
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void PixelFormatTest::mapCompressedFormatDeprecated() {
CORRADE_IGNORE_DEPRECATED_PUSH
CORRADE_COMPARE(compressedPixelFormat(Magnum::CompressedPixelFormat::RGBAS3tcDxt1),
CompressedPixelFormat::RGBAS3tcDxt1);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
void PixelFormatTest::mapCompressedFormatUnsupported() {
#if 1
CORRADE_SKIP("All compressed pixel formats are currently supported everywhere.");

34
src/Magnum/GL/Texture.h

@ -1334,38 +1334,6 @@ typedef Texture<2> Texture2D;
typedef Texture<3> Texture3D;
#endif
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Texture
* @deprecated Use @ref GL::Texture instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt dimensions> using Texture CORRADE_DEPRECATED_ALIAS("use GL::Texture instead") = Magnum::GL::Texture<dimensions>;
#endif
#ifndef MAGNUM_TARGET_GLES
/** @brief @copybrief GL::Texture1D
* @deprecated Use @ref GL::Texture1D instead.
*/
typedef CORRADE_DEPRECATED("use GL::Texture1D instead") Magnum::GL::Texture1D Texture1D;
#endif
/** @brief @copybrief GL::Texture2D
* @deprecated Use @ref GL::Texture2D instead.
*/
typedef CORRADE_DEPRECATED("use GL::Texture2D instead") Magnum::GL::Texture2D Texture2D;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
/** @brief @copybrief GL::Texture3D
* @deprecated Use @ref GL::Texture3D instead.
*/
typedef CORRADE_DEPRECATED("use GL::Texture3D instead") Magnum::GL::Texture3D Texture3D;
#endif
#endif
}
}}
#endif

27
src/Magnum/GL/TextureArray.h

@ -907,32 +907,7 @@ typedef TextureArray<1> Texture1DArray;
*/
typedef TextureArray<2> Texture2DArray;
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::TextureArray
* @deprecated Use @ref GL::TextureArray instead.
*/
#ifndef CORRADE_MSVC2015_COMPATIBILITY /* Multiple definitions still broken */
template<UnsignedInt dimensions> using TextureArray CORRADE_DEPRECATED_ALIAS("use GL::TextureArray instead") = Magnum::GL::TextureArray<dimensions>;
#endif
#ifndef MAGNUM_TARGET_GLES
/** @brief @copybrief GL::Texture1DArray
* @deprecated Use @ref GL::Texture1DArray instead.
*/
typedef CORRADE_DEPRECATED("use GL::Texture1DArray instead") Magnum::GL::Texture1DArray Texture1DArray;
#endif
/** @brief @copybrief GL::Texture2DArray
* @deprecated Use @ref GL::Texture2DArray instead.
*/
typedef CORRADE_DEPRECATED("use GL::Texture2DArray instead") Magnum::GL::Texture2DArray Texture2DArray;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 build
#endif

13
src/Magnum/GL/TextureFormat.h

@ -1757,17 +1757,6 @@ enum class TextureFormat: GLenum {
#endif
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::TextureFormat
* @deprecated Use @ref GL::TextureFormat instead.
*/
typedef CORRADE_DEPRECATED("use GL::TextureFormat instead") Magnum::GL::TextureFormat TextureFormat;
#endif
}
}}
#endif

13
src/Magnum/GL/TimeQuery.h

@ -173,18 +173,7 @@ class TimeQuery: public AbstractQuery {
explicit TimeQuery(GLuint id, Target target, ObjectFlags flags) noexcept: AbstractQuery{id, GLenum(target), flags} {}
};
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::TimeQuery
* @deprecated Use @ref GL::TimeQuery instead.
*/
typedef CORRADE_DEPRECATED("use GL::TimeQuery instead") Magnum::GL::TimeQuery TimeQuery;
#endif
}
}}
#else
#error this header is not available in WebGL build
#endif

13
src/Magnum/GL/TransformFeedback.h

@ -459,18 +459,7 @@ inline GLuint TransformFeedback::release() {
return id;
}
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::TransformFeedback
* @deprecated Use @ref GL::TransformFeedback instead.
*/
typedef CORRADE_DEPRECATED("use GL::TransformFeedback instead") Magnum::GL::TransformFeedback TransformFeedback;
#endif
}
}}
#else
#error this header is not available in OpenGL ES 2.0 build
#endif

34
src/Magnum/GL/Version.h

@ -160,38 +160,6 @@ constexpr bool isVersionES(Version) { return true; }
/** @debugoperatorenum{Version} */
MAGNUM_GL_EXPORT Debug& operator<<(Debug& debug, Version value);
}
#ifdef MAGNUM_BUILD_DEPRECATED
/* Note: needs to be prefixed with Magnum:: otherwise Doxygen can't find it */
/** @brief @copybrief GL::Version
* @deprecated Use @ref GL::Version instead.
*/
typedef CORRADE_DEPRECATED("use GL::Version instead") Magnum::GL::Version Version;
#ifdef DOXYGEN_GENERATING_OUTPUT
/** @brief @copybrief GL::version(Int, Int)
* @deprecated Use @ref GL::version(Int, Int) instead.
*/
constexpr CORRADE_DEPRECATED("use GL::version() instead") GL::Version version(Int major, Int minor);
/** @brief @copybrief GL::version(GL::Version)
* @deprecated Use @ref GL::version(GL::Version) instead.
*/
CORRADE_DEPRECATED("use GL::version() instead") std::pair<Int, Int> version(GL::Version version);
/** @brief @copybrief GL::isVersionES()
* @deprecated Use @ref GL::isVersionES() instead.
*/
constexpr CORRADE_DEPRECATED("use GL::isVersionES() instead") bool isVersionES(GL::Version version);
#else
/* Defining the functions here again would cause ambiguity due to ADL */
using GL::version;
using GL::isVersionES;
#endif
#endif
}
}}
#endif

93
src/Magnum/Image.h

@ -302,14 +302,6 @@ template<UnsignedInt dimensions> class Image {
*/
UnsignedInt formatExtra() const { return _formatExtra; }
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/**
* @brief Data type of pixel data
* @deprecated Cast @ref formatExtra() to @ref GL::PixelType instead.
*/
CORRADE_DEPRECATED("cast formatExtra() to GL::PixelType instead") GL::PixelType type() const { return GL::PixelType(_formatExtra); }
#endif
/**
* @brief Pixel size (in bytes)
*
@ -351,42 +343,6 @@ template<UnsignedInt dimensions> class Image {
return reinterpret_cast<const T*>(_data.data());
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/**
* @brief Set image data
* @param storage Storage of pixel data
* @param format Format of pixel data
* @param formatExtra Additional pixel format specifier
* @param size Image size
* @param data Image data
*
* @deprecated Move-assign a new instance instead.
*
* Deletes previous data and replaces them with new. The @p data array
* is expected to be of proper size for given parameters.
* @see @ref release()
*/
template<class T, class U> CORRADE_DEPRECATED("move-assign a new instance instead") void setData(PixelStorage storage, T format, U formatExtra, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) {
*this = Image<dimensions>{storage, format, formatExtra, size, std::move(data)};
}
/**
* @brief Set image data
* @param format Format of pixel data
* @param formatExtra Additional pixel format specifier
* @param size Image size
* @param data Image data
*
* @deprecated Move-assign a new instance instead.
*
* Equivalent to calling @ref setData(PixelStorage, T, U, const VectorTypeFor<dimensions, Int>&, Containers::Array<char>&&)
* with default-constructed @ref PixelStorage.
*/
template<class T, class U> CORRADE_DEPRECATED("move-assign a new instance instead") void setData(T format, U formatExtra, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) {
*this = Image<dimensions>{format, formatExtra, size, std::move(data)};
}
#endif
/**
* @brief Release data storage
*
@ -575,39 +531,6 @@ template<UnsignedInt dimensions> class CompressedImage {
return reinterpret_cast<const T*>(_data.data());
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/**
* @brief Set image data
* @param storage Storage of compressed pixel data
* @param format Format of compressed pixel data
* @param size Image size
* @param data Image data
*
* @deprecated Move-assign a new instance instead.
*
* Deletes previous data and replaces it with @p data.
* @see @ref release()
*/
CORRADE_DEPRECATED("move-assign a new instance instead") void setData(CompressedPixelStorage storage, CompressedPixelFormat format, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) {
*this = CompressedImage<dimensions>{storage, GL::CompressedPixelFormat(format), size, std::move(data)};
}
/**
* @brief Set image data
* @param format Format of compressed pixel data
* @param size Image size
* @param data Image data
*
* @deprecated Move-assign a new instance instead.
*
* Equivalent to calling @ref setData(CompressedPixelStorage, CompressedPixelFormat, const VectorTypeFor<dimensions, Int>&, Containers::Array<char>&&)
* with default-constructed @ref CompressedPixelStorage.
*/
CORRADE_DEPRECATED("move-assign a new instance instead") void setData(CompressedPixelFormat format, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) {
*this = CompressedImage<dimensions>{GL::CompressedPixelFormat(format), size, std::move(data)};
}
#endif
/**
* @brief Release data storage
*
@ -688,13 +611,7 @@ template<UnsignedInt dimensions> inline Containers::Array<char> CompressedImage<
return data;
}
template<UnsignedInt dimensions> template<class T, class U> inline Image<dimensions>::Image(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) noexcept: Image{storage,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Implementation::wrapPixelFormatIfNotGLSpecific(format),
#else
UnsignedInt(format),
#endif
UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size, std::move(data)} {
template<UnsignedInt dimensions> template<class T, class U> inline Image<dimensions>::Image(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size, Containers::Array<char>&& data) noexcept: Image{storage, UnsignedInt(format), UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size, std::move(data)} {
static_assert(sizeof(T) <= 4 && sizeof(U) <= 4,
"format types larger than 32bits are not supported");
}
@ -704,13 +621,7 @@ template<UnsignedInt dimensions> template<class T> inline Image<dimensions>::Im
"format types larger than 32bits are not supported");
}
template<UnsignedInt dimensions> template<class T, class U> inline Image<dimensions>::Image(const PixelStorage storage, const T format, const U formatExtra) noexcept: Image{storage,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Implementation::wrapPixelFormatIfNotGLSpecific(format),
#else
UnsignedInt(format),
#endif
UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra)} {
template<UnsignedInt dimensions> template<class T, class U> inline Image<dimensions>::Image(const PixelStorage storage, const T format, const U formatExtra) noexcept: Image{storage, UnsignedInt(format), UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra)} {
static_assert(sizeof(T) <= 4 && sizeof(U) <= 4,
"format types larger than 32bits are not supported");
}

41
src/Magnum/ImageFormat.h

@ -1,41 +0,0 @@
#ifndef Magnum_ImageFormat_h
#define Magnum_ImageFormat_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/ImageFormat.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/ImageFormat.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/ImageFormat.h instead")
#else
#error use Magnum/GL/ImageFormat.h instead
#endif
#endif

33
src/Magnum/ImageView.h

@ -35,10 +35,6 @@
#include "Magnum/PixelStorage.h"
#include "Magnum/Math/Vector3.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/PixelFormat.h"
#endif
namespace Magnum {
/**
@ -350,14 +346,6 @@ template<UnsignedInt dimensions> class ImageView {
*/
UnsignedInt formatExtra() const { return _formatExtra; }
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/**
* @brief Data type of pixel data
* @deprecated Cast @ref formatExtra() to @ref GL::PixelType instead.
*/
CORRADE_DEPRECATED("cast formatExtra() to GL::PixelType instead") GL::PixelType type() const { return GL::PixelType(_formatExtra); }
#endif
/**
* @brief Pixel size (in bytes)
*
@ -639,22 +627,11 @@ namespace Implementation {
}
template<class T, class U> inline UnsignedInt pixelSizeAdl(T format, U formatExtra) {
/* So it doesn't warn when the deprecated
pixelSize(PixelFormat, GL::PixelType) overload is called
indirectly */
CORRADE_IGNORE_DEPRECATED_PUSH
return pixelSize(format, formatExtra);
CORRADE_IGNORE_DEPRECATED_POP
}
}
template<UnsignedInt dimensions> template<class T, class U> inline ImageView<dimensions>::ImageView(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size, const Containers::ArrayView<const void> data) noexcept: ImageView{storage,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Implementation::wrapPixelFormatIfNotGLSpecific(format),
#else
UnsignedInt(format),
#endif
UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size, data} {
template<UnsignedInt dimensions> template<class T, class U> inline ImageView<dimensions>::ImageView(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size, const Containers::ArrayView<const void> data) noexcept: ImageView{storage, UnsignedInt(format), UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size, data} {
static_assert(sizeof(T) <= 4 && sizeof(U) <= 4,
"format types larger than 32bits are not supported");
}
@ -664,13 +641,7 @@ template<UnsignedInt dimensions> template<class T> inline ImageView<dimensions>:
"format types larger than 32bits are not supported");
}
template<UnsignedInt dimensions> template<class T, class U> inline ImageView<dimensions>::ImageView(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size) noexcept: ImageView{storage,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Implementation::wrapPixelFormatIfNotGLSpecific(format),
#else
UnsignedInt(format),
#endif
UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size} {
template<UnsignedInt dimensions> template<class T, class U> inline ImageView<dimensions>::ImageView(const PixelStorage storage, const T format, const U formatExtra, const VectorTypeFor<dimensions, Int>& size) noexcept: ImageView{storage, UnsignedInt(format), UnsignedInt(formatExtra), Implementation::pixelSizeAdl(format, formatExtra), size} {
static_assert(sizeof(T) <= 4 && sizeof(U) <= 4,
"format types larger than 32bits are not supported");
}

107
src/Magnum/Magnum.h

@ -34,14 +34,6 @@
#include "Magnum/Types.h"
#include "Magnum/Math/Math.h"
#ifdef MAGNUM_BUILD_DEPRECATED
#include <Corrade/Utility/Macros.h>
#ifdef MAGNUM_TARGET_GL
#include "Magnum/GL/GL.h"
#endif
#endif
namespace Magnum {
/* Bring whole Corrade namespace */
@ -740,105 +732,6 @@ enum class SamplerMipmap: UnsignedInt;
enum class SamplerWrapping: UnsignedInt;
class Timeline;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
typedef CORRADE_DEPRECATED("use GL::AbstractFramebuffer instead") GL::AbstractFramebuffer AbstractFramebuffer;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
typedef CORRADE_DEPRECATED("use GL::AbstractQuery instead") GL::AbstractQuery AbstractQuery;
#endif
typedef CORRADE_DEPRECATED("use GL::AbstractShaderProgram instead") GL::AbstractShaderProgram AbstractShaderProgram;
typedef CORRADE_DEPRECATED("use GL::AbstractTexture instead") GL::AbstractTexture AbstractTexture;
template<UnsignedInt location, class T> using Attribute CORRADE_DEPRECATED_ALIAS("use GL::Attribute instead") = GL::Attribute<location, T>;
typedef CORRADE_DEPRECATED("use GL::BufferUsage instead") GL::BufferUsage BufferUsage;
typedef CORRADE_DEPRECATED("use GL::Buffer instead") GL::Buffer Buffer;
#ifndef MAGNUM_TARGET_GLES2
template<UnsignedInt dimensions> using BufferImage CORRADE_DEPRECATED_ALIAS("use GL::BufferImage instead") = GL::BufferImage<dimensions>;
typedef CORRADE_DEPRECATED("use GL::BufferImage1D instead") GL::BufferImage1D BufferImage1D;
typedef CORRADE_DEPRECATED("use GL::BufferImage2D instead") GL::BufferImage2D BufferImage2D;
typedef CORRADE_DEPRECATED("use GL::BufferImage3D instead") GL::BufferImage3D BufferImage3D;
template<UnsignedInt dimensions> using CompressedBufferImage CORRADE_DEPRECATED_ALIAS("use GL::CompressedBufferImage instead") = GL::BufferImage<dimensions>;
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage1D instead") GL::CompressedBufferImage1D CompressedBufferImage1D;
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage2D instead") GL::CompressedBufferImage2D CompressedBufferImage2D;
typedef CORRADE_DEPRECATED("use GL::CompressedBufferImage3D instead") GL::CompressedBufferImage3D CompressedBufferImage3D;
#endif
#if !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
typedef CORRADE_DEPRECATED("use GL::BufferTexture instead") GL::BufferTexture BufferTexture;
typedef CORRADE_DEPRECATED("use GL::BufferTextureFormat instead") GL::BufferTextureFormat BufferTextureFormat;
#endif
typedef CORRADE_DEPRECATED("use GL::Context instead") GL::Context Context;
typedef CORRADE_DEPRECATED("use GL::CubeMapTexture instead") GL::CubeMapTexture CubeMapTexture;
typedef CORRADE_DEPRECATED("use GL::CubeMapCoordinate instead") GL::CubeMapCoordinate CubeMapCoordinate;
#if !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
typedef CORRADE_DEPRECATED("use GL::CubeMapTextureArray instead") GL::CubeMapTextureArray CubeMapTextureArray;
#endif
typedef CORRADE_DEPRECATED("use GL::Extension instead") GL::Extension Extension;
typedef CORRADE_DEPRECATED("use GL::Framebuffer instead") GL::Framebuffer Framebuffer;
#if !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
typedef CORRADE_DEPRECATED("use GL::ImageAccess instead") GL::ImageAccess ImageAccess;
typedef CORRADE_DEPRECATED("use GL::ImageFormat instead") GL::ImageFormat ImageFormat;
#endif
typedef CORRADE_DEPRECATED("use GL::Mesh instead") GL::Mesh Mesh;
typedef CORRADE_DEPRECATED("use GL::MeshView instead") GL::MeshView MeshView;
#if !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
/* MultisampleTextureSampleLocations enum used only in the function */
template<UnsignedInt dimensions> using MultisampleTexture CORRADE_DEPRECATED_ALIAS("use GL::MultisampleTexture instead") = GL::MultisampleTexture<dimensions>;
typedef CORRADE_DEPRECATED("use GL::MultisampleTexture2D instead") GL::MultisampleTexture2D MultisampleTexture2D;
typedef CORRADE_DEPRECATED("use GL::MultisampleTexture2DArray instead") GL::MultisampleTexture2DArray MultisampleTexture2DArray;
#endif
typedef CORRADE_DEPRECATED("use GL::PixelType instead") GL::PixelType PixelType;
typedef CORRADE_DEPRECATED("use GL::PrimitiveQuery instead") GL::PrimitiveQuery PrimitiveQuery;
typedef CORRADE_DEPRECATED("use GL::SampleQuery instead") GL::SampleQuery SampleQuery;
typedef CORRADE_DEPRECATED("use GL::TimeQuery instead") GL::TimeQuery TimeQuery;
#ifndef MAGNUM_TARGET_GLES
typedef CORRADE_DEPRECATED("use GL::RectangleTexture instead") GL::RectangleTexture RectangleTexture;
#endif
typedef CORRADE_DEPRECATED("use GL::Renderbuffer instead") GL::Renderbuffer Renderbuffer;
typedef CORRADE_DEPRECATED("use GL::RenderbufferFormat instead") GL::RenderbufferFormat RenderbufferFormat;
struct CORRADE_DEPRECATED("use GL::Sampler, SamplerFilter, GL::SamplerFilter, SamplerMipmap, GL::SamplerMipmap, SamplerWrapping, GL::SamplerWrapping, GL::SamplerCompareMode, GL::SamplerCompareFunction or GL::SamplerDepthStencilMode instead") Sampler;
typedef CORRADE_DEPRECATED("use GL::Shader instead") GL::Shader Shader;
template<UnsignedInt dimensions> using Texture CORRADE_DEPRECATED_ALIAS("use GL::Texture instead") = GL::Texture<dimensions>;
#ifndef MAGNUM_TARGET_GLES
typedef CORRADE_DEPRECATED("use GL::Texture1D instead") GL::Texture1D Texture1D;
#endif
typedef CORRADE_DEPRECATED("use GL::Texture2D instead") GL::Texture2D Texture2D;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
typedef CORRADE_DEPRECATED("use GL::Texture3D instead") GL::Texture3D Texture3D;
#endif
#ifndef MAGNUM_TARGET_GLES2
template<UnsignedInt dimensions> using TextureArray CORRADE_DEPRECATED_ALIAS("use GL::TextureArray instead") = GL::TextureArray<dimensions>;
#ifndef MAGNUM_TARGET_GLES
typedef CORRADE_DEPRECATED("use GL::Texture1DArray instead") GL::Texture1DArray Texture1DArray;
#endif
typedef CORRADE_DEPRECATED("use GL::Texture2DArray instead") GL::Texture2DArray Texture2DArray;
#endif
typedef CORRADE_DEPRECATED("use GL::TextureFormat instead") GL::TextureFormat TextureFormat;
#ifndef MAGNUM_TARGET_GLES2
typedef CORRADE_DEPRECATED("use GL::TransformFeedback instead") GL::TransformFeedback TransformFeedback;
#endif
typedef CORRADE_DEPRECATED("use GL::Version instead") GL::Version Version;
#endif
#endif
}

25
src/Magnum/Mesh.cpp

@ -53,20 +53,6 @@ Debug& operator<<(Debug& debug, MeshPrimitive value) {
_c(TriangleStrip)
_c(TriangleFan)
#undef _c
/* Here mainly to suppress compiler warnings about unhandled cases and
also to check that there are no accidentally conflicting values. */
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
CORRADE_IGNORE_DEPRECATED_PUSH
#define _c(value) case MeshPrimitive::value: return debug << "GL::MeshPrimitive::" #value;
_c(LinesAdjacency)
_c(LineStripAdjacency)
_c(TrianglesAdjacency)
_c(TriangleStripAdjacency)
_c(Patches)
#undef _c
CORRADE_IGNORE_DEPRECATED_POP
#endif
/* LCOV_EXCL_STOP */
}
@ -104,17 +90,6 @@ std::string ConfigurationValue<Magnum::MeshPrimitive>::toString(Magnum::MeshPrim
_c(TriangleStrip)
_c(TriangleFan)
#undef _c
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
CORRADE_IGNORE_DEPRECATED_PUSH
case Magnum::MeshPrimitive::LinesAdjacency:
case Magnum::MeshPrimitive::LineStripAdjacency:
case Magnum::MeshPrimitive::TrianglesAdjacency:
case Magnum::MeshPrimitive::TriangleStripAdjacency:
case Magnum::MeshPrimitive::Patches:
return {};
CORRADE_IGNORE_DEPRECATED_POP
#endif
/* LCOV_EXCL_STOP */
}

38
src/Magnum/Mesh.h

@ -34,10 +34,6 @@
#include "Magnum/Magnum.h"
#include "Magnum/visibility.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Mesh.h"
#endif
namespace Magnum {
/**
@ -111,39 +107,7 @@ enum class MeshPrimitive: UnsignedInt {
* Corresponds to @ref GL::MeshPrimitive::TriangleFan /
* @def_vk_keyword{PRIMITIVE_TOPOLOGY_TRIANGLE_FAN,PrimitiveTopology}.
*/
TriangleFan,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(MAGNUM_TARGET_GLES2) && !defined(MAGNUM_TARGET_WEBGL)
/**
* Lines with adjacency information.
* @deprecated Use @ref GL::MeshPrimitive::LinesAdjacency instead.
*/
LinesAdjacency CORRADE_DEPRECATED_ENUM("use GL::MeshPrimitive::LinesAdjacency instead") = UnsignedInt(GL::MeshPrimitive::LinesAdjacency),
/**
* Line strip with adjacency information.
* @deprecated Use @ref GL::MeshPrimitive::LineStripAdjacency instead.
*/
LineStripAdjacency CORRADE_DEPRECATED_ENUM("use GL::MeshPrimitive::LineStripAdjacency instead") = UnsignedInt(GL::MeshPrimitive::LineStripAdjacency),
/**
* Triangles with adjacency information.
* @deprecated Use @ref GL::MeshPrimitive::TrianglesAdjacency instead.
*/
TrianglesAdjacency CORRADE_DEPRECATED_ENUM("use GL::MeshPrimitive::TrianglesAdjacency instead") = UnsignedInt(GL::MeshPrimitive::TrianglesAdjacency),
/**
* Triangle strip with adjacency information.
* @deprecated Use @ref GL::MeshPrimitive::TriangleStripAdjacency instead.
*/
TriangleStripAdjacency CORRADE_DEPRECATED_ENUM("use GL::MeshPrimitive::TriangleStripAdjacency instead") = UnsignedInt(GL::MeshPrimitive::TriangleStripAdjacency),
/**
* Patches.
* @deprecated Use @ref GL::MeshPrimitive::Patches instead.
*/
Patches CORRADE_DEPRECATED_ENUM("use GL::MeshPrimitive::Patches instead") = UnsignedInt(GL::MeshPrimitive::Patches)
#endif
TriangleFan
};
/** @debugoperatorenum{MeshPrimitive} */

41
src/Magnum/MeshView.h

@ -1,41 +0,0 @@
#ifndef Magnum_MeshView_h
#define Magnum_MeshView_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/MeshView.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/MeshView.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/MeshView.h instead")
#else
#error use Magnum/GL/MeshView.h instead
#endif
#endif

41
src/Magnum/MultisampleTexture.h

@ -1,41 +0,0 @@
#ifndef Magnum_MultisampleTexture_h
#define Magnum_MultisampleTexture_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/MultisampleTexture.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/MultisampleTexture.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/MultisampleTexture.h instead")
#else
#error use Magnum/GL/MultisampleTexture.h instead
#endif
#endif

42
src/Magnum/OpenGL.h

@ -1,42 +0,0 @@
#ifndef Magnum_OpenGL_h
#define Magnum_OpenGL_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/OpenGL.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include <Corrade/Utility/Macros.h>
#include "Magnum/GL/OpenGL.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/OpenGL.h instead")
#else
#error use Magnum/GL/OpenGL.h instead
#endif
#endif

41
src/Magnum/OpenGLTester.h

@ -1,41 +0,0 @@
#ifndef Magnum_OpenGLTester_h
#define Magnum_OpenGLTester_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/OpenGLTester.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/OpenGLTester.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/OpenGLTester.h instead")
#else
#error use Magnum/GL/OpenGLTester.h instead
#endif
#endif

184
src/Magnum/PixelFormat.cpp

@ -91,61 +91,6 @@ UnsignedInt pixelSize(const PixelFormat format) {
case PixelFormat::RGBA32I:
case PixelFormat::RGBA32F:
return 16;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
CORRADE_IGNORE_DEPRECATED_PUSH
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::Red:
#endif
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::Green:
case PixelFormat::Blue:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::Luminance:
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
case PixelFormat::RG:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::LuminanceAlpha:
#endif
case PixelFormat::RGB:
case PixelFormat::RGBA:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGR:
#endif
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::BGRA:
#endif
#ifdef MAGNUM_TARGET_GLES2
case PixelFormat::SRGB:
case PixelFormat::SRGBAlpha:
#endif
#ifndef MAGNUM_TARGET_GLES2
case PixelFormat::RedInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::GreenInteger:
case PixelFormat::BlueInteger:
#endif
case PixelFormat::RGInteger:
case PixelFormat::RGBInteger:
case PixelFormat::RGBAInteger:
#ifndef MAGNUM_TARGET_GLES
case PixelFormat::BGRInteger:
case PixelFormat::BGRAInteger:
#endif
#endif
case PixelFormat::DepthComponent:
#ifndef MAGNUM_TARGET_WEBGL
case PixelFormat::StencilIndex:
#endif
case PixelFormat::DepthStencil:
/** @todo CORRADE_ASSERT_UNREACHABLE() with message here */
CORRADE_ASSERT(false,
"pixelSize(): called with deprecated GL-specific format, use GL::pixelSize() instead", {});
CORRADE_IGNORE_DEPRECATED_POP
#endif
}
CORRADE_ASSERT_UNREACHABLE(); /* LCOV_EXCL_LINE */
@ -209,64 +154,6 @@ Debug& operator<<(Debug& debug, const PixelFormat value) {
_c(RGB32F)
_c(RGBA32F)
#undef _c
/* Verbatim copy from GL/PixelFormat.cpp. Here mainly to suppress
compiler warnings about unhandled cases, to check that all values
from the original enum are present and also to check that there are
no accidentally conflicting values. */
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
CORRADE_IGNORE_DEPRECATED_PUSH
#define _c(value) case PixelFormat::value: return debug << "GL::PixelFormat::" #value;
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
_c(Red)
#endif
#ifndef MAGNUM_TARGET_GLES
_c(Green)
_c(Blue)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(Luminance)
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
_c(RG)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(LuminanceAlpha)
#endif
_c(RGB)
_c(RGBA)
#ifndef MAGNUM_TARGET_GLES
_c(BGR)
#endif
#ifndef MAGNUM_TARGET_WEBGL
_c(BGRA)
#endif
#ifdef MAGNUM_TARGET_GLES2
_c(SRGB)
_c(SRGBAlpha)
#endif
#ifndef MAGNUM_TARGET_GLES2
_c(RedInteger)
#ifndef MAGNUM_TARGET_GLES
_c(GreenInteger)
_c(BlueInteger)
#endif
_c(RGInteger)
_c(RGBInteger)
_c(RGBAInteger)
#ifndef MAGNUM_TARGET_GLES
_c(BGRInteger)
_c(BGRAInteger)
#endif
#endif
_c(DepthComponent)
#ifndef MAGNUM_TARGET_WEBGL
_c(StencilIndex)
#endif
_c(DepthStencil)
#undef _c
CORRADE_IGNORE_DEPRECATED_POP
#endif
/* LCOV_EXCL_STOP */
}
@ -288,77 +175,6 @@ Debug& operator<<(Debug& debug, const CompressedPixelFormat value) {
_c(Bc2RGBAUnorm)
_c(Bc3RGBAUnorm)
#undef _c
/* Verbatim copy from GL/PixelFormat.cpp. Here mainly to suppress
compiler warnings about unhandled cases, to check that all values
from the original enum are present and also to check that there are
no accidentally conflicting values. */
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
CORRADE_IGNORE_DEPRECATED_PUSH
#define _c(value) case CompressedPixelFormat::value: return debug << "GL::CompressedPixelFormat::" #value;
#ifndef MAGNUM_TARGET_GLES
_c(Red)
_c(RG)
_c(RGB)
_c(RGBA)
_c(RedRgtc1)
_c(RGRgtc2)
_c(SignedRedRgtc1)
_c(SignedRGRgtc2)
_c(RGBBptcUnsignedFloat)
_c(RGBBptcSignedFloat)
_c(RGBABptcUnorm)
_c(SRGBAlphaBptcUnorm)
#endif
#ifndef MAGNUM_TARGET_GLES2
_c(RGB8Etc2)
_c(SRGB8Etc2)
_c(RGB8PunchthroughAlpha1Etc2)
_c(SRGB8PunchthroughAlpha1Etc2)
_c(RGBA8Etc2Eac)
_c(SRGB8Alpha8Etc2Eac)
_c(R11Eac)
_c(SignedR11Eac)
_c(RG11Eac)
_c(SignedRG11Eac)
#endif
_c(RGBS3tcDxt1)
_c(RGBAS3tcDxt1)
_c(RGBAS3tcDxt3)
_c(RGBAS3tcDxt5)
#ifndef MAGNUM_TARGET_WEBGL
_c(RGBAAstc4x4)
_c(SRGB8Alpha8Astc4x4)
_c(RGBAAstc5x4)
_c(SRGB8Alpha8Astc5x4)
_c(RGBAAstc5x5)
_c(SRGB8Alpha8Astc5x5)
_c(RGBAAstc6x5)
_c(SRGB8Alpha8Astc6x5)
_c(RGBAAstc6x6)
_c(SRGB8Alpha8Astc6x6)
_c(RGBAAstc8x5)
_c(SRGB8Alpha8Astc8x5)
_c(RGBAAstc8x6)
_c(SRGB8Alpha8Astc8x6)
_c(RGBAAstc8x8)
_c(SRGB8Alpha8Astc8x8)
_c(RGBAAstc10x5)
_c(SRGB8Alpha8Astc10x5)
_c(RGBAAstc10x6)
_c(SRGB8Alpha8Astc10x6)
_c(RGBAAstc10x8)
_c(SRGB8Alpha8Astc10x8)
_c(RGBAAstc10x10)
_c(SRGB8Alpha8Astc10x10)
_c(RGBAAstc12x10)
_c(SRGB8Alpha8Astc12x10)
_c(RGBAAstc12x12)
_c(SRGB8Alpha8Astc12x12)
#undef _c
#endif
CORRADE_IGNORE_DEPRECATED_POP
#endif
/* LCOV_EXCL_STOP */
}

555
src/Magnum/PixelFormat.h

@ -34,10 +34,6 @@
#include "Magnum/Magnum.h"
#include "Magnum/visibility.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/PixelFormat.h"
#endif
namespace Magnum {
/**
@ -496,205 +492,9 @@ enum class PixelFormat: UnsignedInt {
* @ref GL::PixelType::Float, @ref GL::TextureFormat::RGBA32F /
* @def_vk_keyword{FORMAT_R32G32B32A32_SFLOAT,Format}.
*/
RGBA32F,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
/**
* Floating-point red channel.
* @deprecated Use @ref GL::PixelFormat::Red or any of the complete
* single-channel formats instead.
*/
Red CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::Red or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::Red),
#endif
#ifndef MAGNUM_TARGET_GLES
/**
* Floating-point green channel.
* @deprecated Use @ref GL::PixelFormat::Green or any of the complete
* single-channel formats instead.
*/
Green CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::Green or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::Green),
/**
* Floating-point blue channel.
* @deprecated Use @ref GL::PixelFormat::Blue or any of the complete
* single-channel formats instead.
*/
Blue CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::Blue or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::Blue),
#endif
#if defined(MAGNUM_TARGET_GLES2) || defined(DOXYGEN_GENERATING_OUTPUT)
/**
* Floating-point luminance channel. The value is used for all RGB
* channels.
* @deprecated Use @ref GL::PixelFormat::Luminance or any of the complete
* single-channel formats instead.
*/
Luminance CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::Luminance or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::Luminance),
#endif
#if !(defined(MAGNUM_TARGET_WEBGL) && defined(MAGNUM_TARGET_GLES2))
/**
* Floating-point red and green channel.
* @deprecated Use @ref GL::PixelFormat::RG or any of the complete
* two-channel formats instead.
*/
RG CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RG or any of the complete two-channel formats instead") = UnsignedInt(GL::PixelFormat::RG),
#endif
#if defined(MAGNUM_TARGET_GLES2) || defined(DOXYGEN_GENERATING_OUTPUT)
/**
* Floating-point luminance and alpha channel. First value is used for all
* RGB channels, second value is used for alpha channel.
* @deprecated Use @ref GL::PixelFormat::LuminanceAlpha or any of the
* complete two-channel formats instead.
*/
LuminanceAlpha CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::LuminanceAlpha or any of the complete two-channel formats instead") = UnsignedInt(GL::PixelFormat::LuminanceAlpha),
#endif
/**
* Floating-point RGB.
* @deprecated Use @ref GL::PixelFormat::RGB or any of the complete
* three-channel formats instead.
*/
RGB CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RGB or any of the complete three-channel formats instead") = UnsignedInt(GL::PixelFormat::RGB),
/**
* Floating-point RGBA.
* @deprecated Use @ref GL::PixelFormat::RGBA or any of the complete
* four-channel formats instead.
*/
RGBA CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RGBA or any of the complete four-channel formats instead") = UnsignedInt(GL::PixelFormat::RGBA),
#ifndef MAGNUM_TARGET_GLES
/**
* Floating-point BGR.
* @deprecated Use @ref GL::PixelFormat::BGR or any of the complete
* three-channel formats instead.
*/
BGR CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::BGR or any of the complete three-channel formats instead") = UnsignedInt(GL::PixelFormat::BGR),
#endif
#ifndef MAGNUM_TARGET_WEBGL
/**
* Floating-point BGRA.
* @deprecated Use @ref GL::PixelFormat::BGRA or any of the complete
* four-channel formats instead.
*/
BGRA CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::BGRA or any of the complete four-channel formats instead") = UnsignedInt(GL::PixelFormat::BGRA),
#endif
#if defined(MAGNUM_TARGET_GLES2) || defined(DOXYGEN_GENERATING_OUTPUT)
/**
* Floating-point sRGB.
* @deprecated Use @ref GL::PixelFormat::SRGB or any of the complete
* three-channel formats instead.
*/
SRGB CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::SRGB or any of the complete three-channel formats instead") = UnsignedInt(GL::PixelFormat::SRGB),
/**
* Floating-point sRGB + alpha.
* @deprecated Use @ref GL::PixelFormat::SRGBAlpha or any of the complete
* four-channel formats instead.
*/
SRGBAlpha CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::SRGBAlpha or any of the complete four-channel formats instead") = UnsignedInt(GL::PixelFormat::SRGBAlpha),
#endif
#ifndef MAGNUM_TARGET_GLES2
/**
* Integer red channel.
* @deprecated Use @ref GL::PixelFormat::RedInteger or any of the complete
* single-channel formats instead.
*/
RedInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RedInteger or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::RedInteger),
#ifndef MAGNUM_TARGET_GLES
/**
* Integer green channel.
* @deprecated Use @ref GL::PixelFormat::GreenInteger or any of the
* complete single-channel formats instead.
*/
GreenInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::GreenInteger or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::GreenInteger),
/**
* Integer blue channel.
* @deprecated Use @ref GL::PixelFormat::BlueInteger or any of the complete
* single-channel formats instead.
*/
BlueInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::BlueInteger or any of the complete single-channel formats instead") = UnsignedInt(GL::PixelFormat::BlueInteger),
#endif
/**
* Integer red and green channel.
* @deprecated Use @ref GL::PixelFormat::RGInteger or any of the complete
* two-channel formats instead.
*/
RGInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RGInteger or any of the complete two-channel formats instead") = UnsignedInt(GL::PixelFormat::RGInteger),
/**
* Integer RGB.
* @deprecated Use @ref GL::PixelFormat::RGBInteger or any of the complete
* three-channel formats instead.
*/
RGBInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RGBInteger or any of the complete three-channel formats instead") = UnsignedInt(GL::PixelFormat::RGBInteger),
/**
* Integer RGBA.
* @deprecated Use @ref GL::PixelFormat::RGBAInteger or any of the complete
* four-channel formats instead.
*/
RGBAInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::RGBAInteger or any of the complete four-channel formats instead") = UnsignedInt(GL::PixelFormat::RGBAInteger),
#ifndef MAGNUM_TARGET_GLES
/**
* Integer BGR.
* @deprecated Use @ref GL::PixelFormat::BGRInteger or any of the complete
* three-channel formats instead.
*/
BGRInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::BGRInteger or any of the complete three-channel formats instead") = UnsignedInt(GL::PixelFormat::BGRInteger),
/**
* Integer BGRA.
* @deprecated Use @ref GL::PixelFormat::BGRAInteger or any of the complete
* four-channel formats instead.
*/
BGRAInteger CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::BGRAInteger or any of the complete four-channel formats instead") = UnsignedInt(GL::PixelFormat::BGRAInteger),
#endif
#endif
/**
* Depth component.
* @deprecated Use @ref GL::PixelFormat::DepthComponent or any of the
* complete depth formats instead.
*/
DepthComponent CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::DepthComponent or any of the complete depth formats instead") = UnsignedInt(GL::PixelFormat::DepthComponent),
#ifndef MAGNUM_TARGET_WEBGL
/**
* Stencil index.
* @deprecated Use @ref GL::PixelFormat::StencilIndex or any of the
* complete stencil formats instead.
*/
StencilIndex CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::StencilIndex or any of the complete stencil formats instead") = UnsignedInt(GL::PixelFormat::StencilIndex),
#endif
/**
* Depth and stencil.
* @deprecated Use @ref GL::PixelFormat::DepthStencil or any of the
* complete depth+stencil formats instead.
*/
DepthStencil CORRADE_DEPRECATED_ENUM("use GL::PixelFormat::DepthStencil or any of the complete depth+stencil formats instead") = UnsignedInt(GL::PixelFormat::DepthStencil)
#endif
RGBA32F
};
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief GL::PixelType
* @deprecated Use @ref GL::PixelType instead.
*/
typedef CORRADE_DEPRECATED("use GL::PixelType instead") GL::PixelType PixelType;
#endif
/**
@brief Pixel size
@ -804,345 +604,7 @@ enum class CompressedPixelFormat: UnsignedInt {
* @ref GL::TextureFormat::RGBAS3tcDxt5 /
* @def_vk_keyword{FORMAT_BC3_UNORM_BLOCK,Format}.
*/
Bc3RGBAUnorm,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#ifndef MAGNUM_TARGET_GLES
/**
* Compressed red channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::Red instead.
*/
Red CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::Red instead") = UnsignedInt(GL::CompressedPixelFormat::Red),
/**
* Compressed red and green channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RG instead.
*/
RG CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RG instead") = UnsignedInt(GL::CompressedPixelFormat::RG),
/**
* Compressed RGB, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGB instead.
*/
RGB CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGB instead") = UnsignedInt(GL::CompressedPixelFormat::RGB),
/**
* Compressed RGBA, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBA instead.
*/
RGBA CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBA instead") = UnsignedInt(GL::CompressedPixelFormat::RGBA),
/**
* RGTC compressed red channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RedRgtc1 instead.
*/
RedRgtc1 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RedRgtc1 instead") = UnsignedInt(GL::CompressedPixelFormat::RedRgtc1),
/**
* RGTC compressed red and green channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGRgtc2 instead.
*/
RGRgtc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGRgtc2 instead") = UnsignedInt(GL::CompressedPixelFormat::RGRgtc2),
/**
* RGTC compressed red channel, normalized signed.
* @deprecated Use @ref GL::CompressedPixelFormat::SignedRedRgtc1 instead.
*/
SignedRedRgtc1 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SignedRedRgtc1 instead") = UnsignedInt(GL::CompressedPixelFormat::SignedRedRgtc1),
/**
* RGTC compressed red and green channel, normalized signed.
* @deprecated Use @ref GL::CompressedPixelFormat::SignedRGRgtc2 instead.
*/
SignedRGRgtc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SignedRGRgtc2 instead") = UnsignedInt(GL::CompressedPixelFormat::SignedRGRgtc2),
/**
* BPTC compressed RGB, unsigned float.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBBptcUnsignedFloat instead.
*/
RGBBptcUnsignedFloat CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBBptcUnsignedFloat instead") = UnsignedInt(GL::CompressedPixelFormat::RGBBptcUnsignedFloat),
/**
* BPTC compressed RGB, signed float.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBBptcSignedFloat instead.
*/
RGBBptcSignedFloat CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBBptcSignedFloat instead") = UnsignedInt(GL::CompressedPixelFormat::RGBBptcSignedFloat),
/**
* BPTC compressed RGBA, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBABptcUnorm instead.
*/
RGBABptcUnorm CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBABptcUnorm instead") = UnsignedInt(GL::CompressedPixelFormat::RGBABptcUnorm),
/**
* BPTC compressed sRGBA, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGBAlphaBptcUnorm instead.
*/
SRGBAlphaBptcUnorm CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGBAlphaBptcUnorm instead") = UnsignedInt(GL::CompressedPixelFormat::SRGBAlphaBptcUnorm),
#endif
#ifndef MAGNUM_TARGET_GLES2
/**
* ETC2 compressed RGB, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGB8Etc2 instead.
*/
RGB8Etc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGB8Etc2 instead") = UnsignedInt(GL::CompressedPixelFormat::RGB8Etc2),
/**
* ETC2 compressed sRGB, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Etc2 instead.
*/
SRGB8Etc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Etc2 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Etc2),
/**
* ETC2 compressed RGB with punchthrough (single-bit) alpha, normalized
* unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGB8PunchthroughAlpha1Etc2 instead.
*/
RGB8PunchthroughAlpha1Etc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGB8PunchthroughAlpha1Etc2 instead") = UnsignedInt(GL::CompressedPixelFormat::RGB8PunchthroughAlpha1Etc2),
/**
* ETC2 compressed sRGB with punchthrough (single-bit) alpha, normalized
* unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8PunchthroughAlpha1Etc2 instead.
*/
SRGB8PunchthroughAlpha1Etc2 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8PunchthroughAlpha1Etc2 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8PunchthroughAlpha1Etc2),
/**
* ETC2/EAC compressed RGBA, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBA8Etc2Eac instead.
*/
RGBA8Etc2Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBA8Etc2Eac instead") = UnsignedInt(GL::CompressedPixelFormat::RGBA8Etc2Eac),
/**
* ETC2/EAC compressed sRGB with alpha, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Etc2Eac instead.
*/
SRGB8Alpha8Etc2Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Etc2Eac instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Etc2Eac),
/**
* EAC compressed red channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::R11Eac instead.
*/
R11Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::R11Eac instead") = UnsignedInt(GL::CompressedPixelFormat::R11Eac),
/**
* EAC compressed red channel, normalized signed.
* @deprecated Use @ref GL::CompressedPixelFormat::SignedR11Eac instead.
*/
SignedR11Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SignedR11Eac instead") = UnsignedInt(GL::CompressedPixelFormat::SignedR11Eac),
/**
* EAC compressed red and green channel, normalized unsigned.
* @deprecated Use @ref GL::CompressedPixelFormat::RG11Eac instead.
*/
RG11Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RG11Eac instead") = UnsignedInt(GL::CompressedPixelFormat::RG11Eac),
/**
* EAC compressed red and green channel, normalized signed.
* @deprecated Use @ref GL::CompressedPixelFormat::SignedRG11Eac instead.
*/
SignedRG11Eac CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SignedRG11Eac instead") = UnsignedInt(GL::CompressedPixelFormat::SignedRG11Eac),
#endif
/**
* S3TC DXT1 compressed RGB.
* @deprecated Use @ref CompressedPixelFormat::Bc1RGBUnorm or
* @ref GL::CompressedPixelFormat::RGBS3tcDxt1 instead.
*/
RGBS3tcDxt1 CORRADE_DEPRECATED_ENUM("use CompressedPixelFormat::Bc1RGBUnorm or GL::CompressedPixelFormat::RGBS3tcDxt1 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBS3tcDxt1),
/**
* S3TC DXT1 compressed RGBA.
* @deprecated Use @ref CompressedPixelFormat::Bc1RGBAUnorm or
* @ref GL::CompressedPixelFormat::RGBAS3tcDxt1 instead.
*/
RGBAS3tcDxt1 CORRADE_DEPRECATED_ENUM("use CompressedPixelFormat::Bc1RGBAUnorm or GL::CompressedPixelFormat::RGBAS3tcDxt1 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAS3tcDxt1),
/**
* S3TC DXT3 compressed RGBA.
* @deprecated Use @ref CompressedPixelFormat::Bc2RGBAUnorm or
* @ref GL::CompressedPixelFormat::RGBAS3tcDxt3 instead.
*/
RGBAS3tcDxt3 CORRADE_DEPRECATED_ENUM("use CompressedPixelFormat::Bc2RGBAUnorm or GL::CompressedPixelFormat::RGBAS3tcDxt3 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAS3tcDxt3),
/**
* S3TC DXT5 compressed RGBA.
* @deprecated Use @ref CompressedPixelFormat::Bc3RGBAUnorm or
* @ref GL::CompressedPixelFormat::RGBAS3tcDxt5 instead.
*/
RGBAS3tcDxt5 CORRADE_DEPRECATED_ENUM("use CompressedPixelFormat::Bc3RGBAUnorm or GL::CompressedPixelFormat::RGBAS3tcDxt5 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAS3tcDxt5),
#ifndef MAGNUM_TARGET_WEBGL
/**
* ASTC compressed RGBA with 4x4 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc4x4 instead.
*/
RGBAAstc4x4 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc4x4 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc4x4),
/**
* ASTC compressed sRGB with alpha with 4x4 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc4x4 instead.
*/
SRGB8Alpha8Astc4x4 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc4x4 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc4x4),
/**
* ASTC compressed RGBA with 5x4 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc5x4 instead.
*/
RGBAAstc5x4 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc5x4 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc5x4),
/**
* ASTC compressed sRGB with alpha with 5x4 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc5x4 instead.
*/
SRGB8Alpha8Astc5x4 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc5x4 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc5x4),
/**
* ASTC compressed RGBA with 5x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc5x5 instead.
*/
RGBAAstc5x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc5x5 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc5x5),
/**
* ASTC compressed sRGB with alpha with 5x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc5x5 instead.
*/
SRGB8Alpha8Astc5x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc5x5 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc5x5),
/**
* ASTC compressed RGBA with 6x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc6x5 instead.
*/
RGBAAstc6x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc6x5 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc6x5),
/**
* ASTC compressed sRGB with alpha with 6x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc6x5 instead.
*/
SRGB8Alpha8Astc6x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc6x5 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc6x5),
/**
* ASTC compressed RGBA with 6x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc6x6 instead.
*/
RGBAAstc6x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc6x6 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc6x6),
/**
* ASTC compressed sRGB with alpha with 6x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc6x6 instead.
*/
SRGB8Alpha8Astc6x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc6x6 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc6x6),
/**
* ASTC compressed RGBA with 8x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc8x5 instead.
*/
RGBAAstc8x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc8x5 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc8x5),
/**
* ASTC compressed sRGB with alpha with 8x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc8x5 instead.
*/
SRGB8Alpha8Astc8x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc8x5 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc8x5),
/**
* ASTC compressed RGBA with 8x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc8x6 instead.
*/
RGBAAstc8x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc8x6 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc8x6),
/**
* ASTC compressed sRGB with alpha with 8x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc8x6 instead.
*/
SRGB8Alpha8Astc8x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc8x6 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc8x6),
/**
* ASTC compressed RGBA with 8x8 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc8x8 instead.
*/
RGBAAstc8x8 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc8x8 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc8x8),
/**
* ASTC compressed sRGB with alpha with 8x8 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc8x8 instead.
*/
SRGB8Alpha8Astc8x8 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc8x8 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc8x8),
/**
* ASTC compressed RGBA with 10x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc10x5 instead.
*/
RGBAAstc10x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc10x5 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc10x5),
/**
* ASTC compressed sRGB with alpha with 10x5 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc10x5 instead.
*/
SRGB8Alpha8Astc10x5 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc10x5 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc10x5),
/**
* ASTC compressed RGBA with 10x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc10x6 instead.
*/
RGBAAstc10x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc10x6 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc10x6),
/**
* ASTC compressed sRGB with alpha with 10x6 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc10x6 instead.
*/
SRGB8Alpha8Astc10x6 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc10x6 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc10x6),
/**
* ASTC compressed RGBA with 10x8 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc10x8 instead.
*/
RGBAAstc10x8 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc10x8 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc10x8),
/**
* ASTC compressed sRGB with alpha with 10x8 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc10x8 instead.
*/
SRGB8Alpha8Astc10x8 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc10x8 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc10x8),
/**
* ASTC compressed RGBA with 10x10 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc10x10 instead.
*/
RGBAAstc10x10 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc10x10 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc10x10),
/**
* ASTC compressed sRGB with alpha with 10x10 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc10x10 instead.
*/
SRGB8Alpha8Astc10x10 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc10x10 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc10x10),
/**
* ASTC compressed RGBA with 12x10 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc12x10 instead.
*/
RGBAAstc12x10 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc12x10 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc12x10),
/**
* ASTC compressed sRGB with alpha with 12x10 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc12x10 instead.
*/
SRGB8Alpha8Astc12x10 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc12x10 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc12x10),
/**
* ASTC compressed RGBA with 12x12 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::RGBAAstc12x12 instead.
*/
RGBAAstc12x12 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::RGBAAstc12x12 instead") = UnsignedInt(GL::CompressedPixelFormat::RGBAAstc12x12),
/**
* ASTC compressed sRGB with alpha with 12x12 blocks.
* @deprecated Use @ref GL::CompressedPixelFormat::SRGB8Alpha8Astc12x12 instead.
*/
SRGB8Alpha8Astc12x12 CORRADE_DEPRECATED_ENUM("use GL::CompressedPixelFormat::SRGB8Alpha8Astc12x12 instead") = UnsignedInt(GL::CompressedPixelFormat::SRGB8Alpha8Astc12x12)
#endif
#endif
Bc3RGBAUnorm
};
/** @debugoperatorenum{CompressedPixelFormat} */
@ -1190,19 +652,6 @@ template<class T = UnsignedInt> constexpr T compressedPixelFormatUnwrap(Compress
T(UnsignedInt(format) & ~(1u << 31));
}
namespace Implementation {
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
template<class T> inline typename std::enable_if<!std::is_same<T, PixelFormat>::value, UnsignedInt>::type wrapPixelFormatIfNotGLSpecific(T format) {
return UnsignedInt(format);
}
inline PixelFormat wrapPixelFormatIfNotGLSpecific(PixelFormat format) {
return format;
}
#endif
}
}
#endif

66
src/Magnum/PixelStorage.h

@ -35,12 +35,6 @@
#include "Magnum/Magnum.h"
#include "Magnum/Math/Vector3.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/PixelFormat.h"
#include <tuple>
#endif
namespace Magnum {
/**
@ -53,24 +47,6 @@ Descibes how to interpret data which are read from or stored into @ref Image,
*/
class MAGNUM_EXPORT PixelStorage {
public:
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief Pixel size
* @deprecated Use @ref Magnum::pixelSize() or @ref GL::pixelSize()
* instead.
*/
template<class = void> static CORRADE_DEPRECATED("use GL::pixelSize() instead") std::size_t pixelSize(GL::PixelFormat format, GL::PixelType type);
/** @brief Pixel size
* @deprecated Use @ref Magnum::pixelSize() or @ref GL::pixelSize()
* instead.
*/
template<class T = void> static CORRADE_DEPRECATED("use GL::pixelSize() instead") std::size_t pixelSize(PixelFormat format, GL::PixelType type) {
CORRADE_IGNORE_DEPRECATED_PUSH
return pixelSize<T>(GL::PixelFormat(format), type);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
/**
* @brief Default constructor
*
@ -156,32 +132,6 @@ class MAGNUM_EXPORT PixelStorage {
*/
std::pair<Math::Vector3<std::size_t>, Math::Vector3<std::size_t>> dataProperties(std::size_t pixelSize, const Vector3i& size) const;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief dataProperties(std::size_t, const Vector3i&) const
*
* Returns byte offset in each direction, (row length, row count, layer
* count) and pixel size for image of given @p size with current pixel
* storage parameters, @p format and @p type.
* @deprecated Use @ref dataProperties(std::size_t, const Vector3i&) const
* instead.
*/
template<class = void> CORRADE_DEPRECATED("use dataProperties(std::size_t, const Vector3i&) instead") std::tuple<Math::Vector3<std::size_t>, Math::Vector3<std::size_t>, std::size_t> dataProperties(GL::PixelFormat format, GL::PixelType type, const Vector3i& size) const;
/** @brief @copybrief dataProperties(std::size_t, const Vector3i&) const
*
* Returns byte offset in each direction, (row length, row count, layer
* count) and pixel size for image of given @p size with current pixel
* storage parameters, @p format and @p type.
* @deprecated Use @ref dataProperties(std::size_t, const Vector3i&) const
* instead.
*/
template<class T = void> CORRADE_DEPRECATED("use dataProperties(std::size_t, const Vector3i&) instead") std::tuple<Math::Vector3<std::size_t>, Math::Vector3<std::size_t>, std::size_t> dataProperties(PixelFormat format, GL::PixelType type, const Vector3i& size) const {
CORRADE_IGNORE_DEPRECATED_PUSH
return dataProperties<T>(GL::PixelFormat(format), type, size);
CORRADE_IGNORE_DEPRECATED_POP
}
#endif
#ifndef DOXYGEN_GENERATING_OUTPUT
protected:
#else
@ -295,22 +245,6 @@ class MAGNUM_EXPORT CompressedPixelStorage: public PixelStorage {
constexpr PixelStorage::PixelStorage() noexcept: _rowLength{0}, _imageHeight{0}, _skip{0}, _alignment{4} {}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* These have to be in the header because GL::pixelSize() is in Magnum::GL and
putting that in the source would mean undefined reference. And MSVC would
instantiate them in the source if these wouldn't be templated. */
template<class> inline std::size_t PixelStorage::pixelSize(const GL::PixelFormat format, const GL::PixelType type) {
return GL::pixelSize(format, type);
}
template<class> inline std::tuple<Math::Vector3<std::size_t>, Math::Vector3<std::size_t>, std::size_t> PixelStorage::dataProperties(const GL::PixelFormat format, const GL::PixelType type, const Vector3i& size) const {
const std::size_t pixelSize = GL::pixelSize(format, type);
Math::Vector3<std::size_t> offset, dataSize;
std::tie(offset, dataSize) = dataProperties(pixelSize, size);
return std::make_tuple(offset, dataSize, pixelSize);
}
#endif
namespace Implementation {
/* Used in *Image::dataProperties() */
template<std::size_t dimensions, class T> std::pair<Math::Vector<dimensions, std::size_t>, Math::Vector<dimensions, std::size_t>> imageDataProperties(const T& image) {

22
src/Magnum/Platform/AbstractXApplication.cpp

@ -57,21 +57,7 @@ bool AbstractXApplication::tryCreate(const Configuration& configuration) {
return tryCreate(configuration, GLConfiguration{});
}
bool AbstractXApplication::tryCreate(const Configuration& configuration, const GLConfiguration&
#ifndef MAGNUM_BUILD_DEPRECATED
glConfiguration
#else
_glConfiguration
#endif
) {
#ifdef MAGNUM_BUILD_DEPRECATED
GLConfiguration glConfiguration{_glConfiguration};
CORRADE_IGNORE_DEPRECATED_PUSH
if(configuration.version() != GL::Version::None && glConfiguration.version() == GL::Version::None)
glConfiguration.setVersion(configuration.version());
CORRADE_IGNORE_DEPRECATED_POP
#endif
bool AbstractXApplication::tryCreate(const Configuration& configuration, const GLConfiguration& glConfiguration) {
CORRADE_ASSERT(_context->version() == GL::Version::None, "Platform::AbstractXApplication::tryCreate(): context already created", false);
_windowSize = configuration.size();
@ -215,11 +201,7 @@ AbstractXApplication::GLConfiguration::GLConfiguration(): _version(GL::Version::
AbstractXApplication::GLConfiguration::~GLConfiguration() = default;
AbstractXApplication::Configuration::Configuration():
_title("Magnum X Application"), _size(800, 600)
#ifdef MAGNUM_BUILD_DEPRECATED
, _version(GL::Version::None)
#endif
{}
_title("Magnum X Application"), _size(800, 600) {}
AbstractXApplication::Configuration::~Configuration() = default;
}}

43
src/Magnum/Platform/AbstractXApplication.h

@ -143,22 +143,6 @@ class AbstractXApplication {
*/
void create();
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief create(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref create(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use create(const Configuration&, const GLConfiguration&) instead") void createContext(const Configuration& configuration) {
create(configuration);
}
/** @brief @copybrief create()
* @deprecated Use @ref create() instead.
*/
CORRADE_DEPRECATED("use create() instead") void createContext() {
create();
}
#endif
/**
* @brief Try to create context with given configuration for OpenGL context
*
@ -176,15 +160,6 @@ class AbstractXApplication {
*/
bool tryCreate(const Configuration& configuration);
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief tryCreate(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref tryCreate(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use tryCreate(const Configuration&) instead") bool tryCreateContext(const Configuration& configuration) {
return tryCreate(configuration);
}
#endif
/** @{ @name Screen handling */
public:
@ -363,27 +338,9 @@ class AbstractXApplication::Configuration {
return *this;
}
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief GLConfiguration::version()
* @deprecated Use @ref GLConfiguration::version() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::version() instead") GL::Version version() const { return _version; }
/** @brief @copybrief GLConfiguration::setVersion()
* @deprecated Use @ref GLConfiguration::setVersion() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setVersion() instead") Configuration& setVersion(GL::Version version) {
_version = version;
return *this;
}
#endif
private:
std::string _title;
Vector2i _size;
#ifdef MAGNUM_BUILD_DEPRECATED
GL::Version _version;
#endif
};
/**

32
src/Magnum/Platform/AndroidApplication.h

@ -266,22 +266,6 @@ class AndroidApplication {
*/
void create();
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief create(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref create(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use create(const Configuration&, const GLConfiguration&) instead") void createContext(const Configuration& configuration) {
create(configuration);
}
/** @brief @copybrief create()
* @deprecated Use @ref create() instead.
*/
CORRADE_DEPRECATED("use create() instead") void createContext() {
create();
}
#endif
/**
* @brief Try to create context with given configuration for OpenGL context
*
@ -299,15 +283,6 @@ class AndroidApplication {
*/
bool tryCreate(const Configuration& configuration);
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief tryCreate(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref tryCreate(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use tryCreate(const Configuration&) instead") bool tryCreateContext(const Configuration& configuration) {
return tryCreate(configuration);
}
#endif
/** @{ @name Screen handling */
public:
@ -563,13 +538,6 @@ class AndroidApplication::Configuration {
return *this;
}
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief GLConfiguration::setVersion()
* @deprecated Use @ref GLConfiguration::setVersion() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setVersion() instead") Configuration& setVersion(GL::Version) { return *this; }
#endif
private:
Vector2i _size;
};

4
src/Magnum/Platform/CMakeLists.txt

@ -35,10 +35,6 @@ set(MagnumPlatform_HEADERS
set(MagnumPlatform_PRIVATE_HEADERS )
if(BUILD_DEPRECATED AND TARGET_GL)
list(APPEND MagnumPlatform_HEADERS Context.h)
endif()
# DPI scaling queries only for Sdl2Application and GlfwApplication at the
# moment, build the files only then
if(WITH_GLFWAPPLICATION OR WITH_SDL2APPLICATION)

41
src/Magnum/Platform/Context.h

@ -1,41 +0,0 @@
#ifndef Magnum_Platform_Context_h
#define Magnum_Platform_Context_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/Platform/GLContext.h instead.
*/
#include "Magnum/configure.h"
#ifdef MAGNUM_BUILD_DEPRECATED
#include "Magnum/Platform/GLContext.h"
CORRADE_DEPRECATED_FILE("use Magnum/Platform/GLContext.h instead")
#else
#error use Magnum/Platform/GLContext.h instead
#endif
#endif

7
src/Magnum/Platform/GLContext.h

@ -151,13 +151,6 @@ class GLContext: public GL::Context {
bool tryCreate() { return GL::Context::tryCreate(); }
};
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief Platform::GLContext
* @deprecated Use @ref Platform::GLContext instead.
*/
typedef CORRADE_DEPRECATED("use Platform::GLContext instead") GLContext Context;
#endif
}}
#else
#error this header is available only in the OpenGL build

31
src/Magnum/Platform/GlfwApplication.cpp

@ -296,27 +296,7 @@ GlfwApplication::InputEvent::Modifiers currentGlfwModifiers(GLFWwindow* window)
}
#ifdef MAGNUM_TARGET_GL
bool GlfwApplication::tryCreate(const Configuration& configuration, const GLConfiguration&
#ifndef MAGNUM_BUILD_DEPRECATED
glConfiguration
#else
_glConfiguration
#endif
) {
#ifdef MAGNUM_BUILD_DEPRECATED
GLConfiguration glConfiguration{_glConfiguration};
CORRADE_IGNORE_DEPRECATED_PUSH
if(configuration.flags() && !glConfiguration.flags())
glConfiguration.setFlags(configuration.flags());
if(configuration.version() != GL::Version::None && glConfiguration.version() == GL::Version::None)
glConfiguration.setVersion(configuration.version());
if(configuration.sampleCount() && !glConfiguration.sampleCount())
glConfiguration.setSampleCount(configuration.sampleCount());
if(configuration.isSRGBCapable() && !glConfiguration.isSRGBCapable())
glConfiguration.setSRGBCapable(configuration.isSRGBCapable());
CORRADE_IGNORE_DEPRECATED_POP
#endif
bool GlfwApplication::tryCreate(const Configuration& configuration, const GLConfiguration& glConfiguration) {
CORRADE_ASSERT(!_window && _context->version() == GL::Version::None, "Platform::GlfwApplication::tryCreate(): window with OpenGL context already created", false);
/* Scale window based on DPI */
@ -659,14 +639,7 @@ GlfwApplication::Configuration::Configuration():
_size{800, 600},
_windowFlags{WindowFlag::Focused},
_dpiScalingPolicy{DpiScalingPolicy::Default},
_cursorMode{CursorMode::Normal}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/* Deliberately not setting _flags to ForwardCompatible to avoid them
having higher priority over GLConfiguration flags, appending that flag
later */
, _sampleCount{0}, _version{GL::Version::None}, _srgbCapable{false}
#endif
{}
_cursorMode{CursorMode::Normal} {}
GlfwApplication::Configuration::~Configuration() = default;

99
src/Magnum/Platform/GlfwApplication.h

@ -303,22 +303,6 @@ class GlfwApplication {
*/
void create();
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief create(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref create(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use create(const Configuration&, const GLConfiguration&) instead") void createContext(const Configuration& configuration) {
create(configuration);
}
/** @brief @copybrief create()
* @deprecated Use @ref create() instead.
*/
CORRADE_DEPRECATED("use create() instead") void createContext() {
create();
}
#endif
#ifdef MAGNUM_TARGET_GL
/**
* @brief Try to create context with given configuration for OpenGL context
@ -342,15 +326,6 @@ class GlfwApplication {
*/
bool tryCreate(const Configuration& configuration);
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief tryCreate(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref tryCreate(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use tryCreate(const Configuration&) instead") bool tryCreateContext(const Configuration& configuration) {
return tryCreate(configuration);
}
#endif
/** @{ @name Screen handling */
public:
@ -828,18 +803,6 @@ namespace Implementation {
*/
class GlfwApplication::Configuration {
public:
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief GLConfiguration::Flag
* @deprecated Use @ref GLConfiguration::Flag instead.
*/
typedef GLConfiguration::Flag Flag;
/** @brief @copybrief GLConfiguration::Flags
* @deprecated Use @ref GLConfiguration::Flags instead.
*/
typedef GLConfiguration::Flags Flags;
#endif
/**
* @brief Window flag
*
@ -1067,62 +1030,6 @@ class GlfwApplication::Configuration {
return *this;
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief GLConfiguration::flags()
* @deprecated Use @ref GLConfiguration::flags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::flags() instead") GLConfiguration::Flags flags() const { return _flags; }
/** @brief @copybrief GLConfiguration::setFlags()
* @deprecated Use @ref GLConfiguration::setFlags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setFlags() instead") Configuration& setFlags(GLConfiguration::Flags flags) {
_flags = flags;
return *this;
}
/** @brief @copybrief GLConfiguration::version()
* @deprecated Use @ref GLConfiguration::version() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::version() instead") GL::Version version() const { return _version; }
/** @brief @copybrief GLConfiguration::setVersion()
* @deprecated Use @ref GLConfiguration::setVersion() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setVersion() instead") Configuration& setVersion(GL::Version version) {
_version = version;
return *this;
}
/** @brief @copybrief GLConfiguration::sampleCount()
* @deprecated Use @ref GLConfiguration::sampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::sampleCount() instead") Int sampleCount() const { return _sampleCount; }
/** @brief @copybrief GLConfiguration::setSampleCount()
* @deprecated Use @ref GLConfiguration::setSampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setSampleCount() instead") Configuration& setSampleCount(Int count) {
_sampleCount = count;
return *this;
}
/** @brief @copybrief GLConfiguration::isSrgbCapable()
* @deprecated Use @ref GLConfiguration::isSrgbCapable() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::isSRGBCapable() instead") bool isSRGBCapable() const {
return _srgbCapable;
}
/** @brief @copybrief GLConfiguration::setSrgbCapable()
* @deprecated Use @ref GLConfiguration::setSrgbCapable() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setSrgbCapable() instead") Configuration& setSRGBCapable(bool enabled) {
_srgbCapable = enabled;
return *this;
}
#endif
private:
std::string _title;
Vector2i _size;
@ -1130,12 +1037,6 @@ class GlfwApplication::Configuration {
DpiScalingPolicy _dpiScalingPolicy;
Vector2 _dpiScaling;
CursorMode _cursorMode;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Int _sampleCount;
GL::Version _version;
Flags _flags;
bool _srgbCapable;
#endif
};
CORRADE_ENUMSET_OPERATORS(GlfwApplication::Configuration::WindowFlags)

26
src/Magnum/Platform/GlutApplication.cpp

@ -71,25 +71,7 @@ bool GlutApplication::tryCreate(const Configuration& configuration) {
return tryCreate(configuration, GLConfiguration{});
}
bool GlutApplication::tryCreate(const Configuration& configuration, const GLConfiguration&
#ifndef MAGNUM_BUILD_DEPRECATED
glConfiguration
#else
_glConfiguration
#endif
) {
#ifdef MAGNUM_BUILD_DEPRECATED
GLConfiguration glConfiguration{_glConfiguration};
CORRADE_IGNORE_DEPRECATED_PUSH
if(configuration.flags() && !glConfiguration.flags())
glConfiguration.setFlags(configuration.flags());
if(configuration.version() != GL::Version::None && glConfiguration.version() == GL::Version::None)
glConfiguration.setVersion(configuration.version());
if(configuration.sampleCount() && !glConfiguration.sampleCount())
glConfiguration.setSampleCount(configuration.sampleCount());
CORRADE_IGNORE_DEPRECATED_POP
#endif
bool GlutApplication::tryCreate(const Configuration& configuration, const GLConfiguration& glConfiguration) {
CORRADE_ASSERT(_context->version() == GL::Version::None, "Platform::GlutApplication::tryCreate(): context already created", false);
unsigned int flags = GLUT_DOUBLE|GLUT_RGBA|GLUT_DEPTH|GLUT_STENCIL;
@ -195,11 +177,7 @@ GlutApplication::GLConfiguration::GLConfiguration(): _sampleCount(0), _version(G
GlutApplication::GLConfiguration::~GLConfiguration() = default;
GlutApplication::Configuration::Configuration():
_title("Magnum GLUT Application"), _size(800, 600)
#ifdef MAGNUM_BUILD_DEPRECATED
, _sampleCount(0), _version(GL::Version::None)
#endif
{}
_title("Magnum GLUT Application"), _size(800, 600) {}
GlutApplication::Configuration::~Configuration() = default;
template class BasicScreen<GlutApplication>;

71
src/Magnum/Platform/GlutApplication.h

@ -244,22 +244,6 @@ class CORRADE_DEPRECATED("scheduled for removal, consider switching to Sdl2Appli
*/
void create();
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief create(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref create(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use create(const Configuration&, const GLConfiguration&) instead") void createContext(const Configuration& configuration) {
create(configuration);
}
/** @brief @copybrief create()
* @deprecated Use @ref create() instead.
*/
CORRADE_DEPRECATED("use create() instead") void createContext() {
create();
}
#endif
/**
* @brief Try to create context with given configuration for OpenGL context
*
@ -277,15 +261,6 @@ class CORRADE_DEPRECATED("scheduled for removal, consider switching to Sdl2Appli
*/
bool tryCreate(const Configuration& configuration);
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief tryCreate(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref tryCreate(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use tryCreate(const Configuration&) instead") bool tryCreateContext(const Configuration& configuration) {
return tryCreate(configuration);
}
#endif
/** @{ @name Screen handling */
public:
@ -555,55 +530,9 @@ class GlutApplication::Configuration {
return *this;
}
#ifdef MAGNUM_BUILD_DEPRECATED
/** @brief @copybrief GLConfiguration::flags()
* @deprecated Use @ref GLConfiguration::flags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::flags() instead") GLConfiguration::Flags flags() const { return _flags; }
/** @brief @copybrief GLConfiguration::setFlags()
* @deprecated Use @ref GLConfiguration::setFlags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setFlags() instead") Configuration& setFlags(GLConfiguration::Flags flags) {
_flags = flags;
return *this;
}
/** @brief @copybrief GLConfiguration::version()
* @deprecated Use @ref GLConfiguration::version() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::version() instead") GL::Version version() const { return _version; }
/** @brief @copybrief GLConfiguration::setVersion()
* @deprecated Use @ref GLConfiguration::setVersion() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setVersion() instead") Configuration& setVersion(GL::Version version) {
_version = version;
return *this;
}
/** @brief @copybrief GLConfiguration::sampleCount()
* @deprecated Use @ref GLConfiguration::sampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::sampleCount() instead") Int sampleCount() const { return _sampleCount; }
/** @brief @copybrief GLConfiguration::setSampleCount()
* @deprecated Use @ref GLConfiguration::setSampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setSampleCount() instead") Configuration& setSampleCount(Int count) {
_sampleCount = count;
return *this;
}
#endif
private:
std::string _title;
Vector2i _size;
#ifdef MAGNUM_BUILD_DEPRECATED
Int _sampleCount;
GL::Version _version;
Flags _flags;
#endif
};
/**

8
src/Magnum/Platform/Platform.h

@ -31,10 +31,6 @@
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include <Corrade/Utility/Macros.h>
#endif
namespace Magnum { namespace Platform {
#ifndef DOXYGEN_GENERATING_OUTPUT
@ -43,10 +39,6 @@ template<class> class BasicScreenedApplication;
#ifdef MAGNUM_TARGET_GL
class GLContext;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
typedef CORRADE_DEPRECATED("use Platform::GLContext instead") GLContext Context;
#endif
#endif
#endif

43
src/Magnum/Platform/Sdl2Application.cpp

@ -300,36 +300,7 @@ bool Sdl2Application::tryCreate(const Configuration& configuration) {
}
#ifdef MAGNUM_TARGET_GL
bool Sdl2Application::tryCreate(const Configuration& configuration, const GLConfiguration&
#ifndef MAGNUM_BUILD_DEPRECATED
glConfiguration
#else
_glConfiguration
#endif
) {
#ifdef MAGNUM_BUILD_DEPRECATED
GLConfiguration glConfiguration{_glConfiguration};
CORRADE_IGNORE_DEPRECATED_PUSH
#ifndef CORRADE_TARGET_EMSCRIPTEN
#ifndef MAGNUM_TARGET_GLES
if(configuration.flags() && glConfiguration.flags() == GLConfiguration::Flag::ForwardCompatible)
glConfiguration.setFlags(configuration.flags()|GLConfiguration::Flag::ForwardCompatible);
#else
if(configuration.flags() && !glConfiguration.flags())
glConfiguration.setFlags(configuration.flags());
#endif
if(configuration.version() != GL::Version::None && glConfiguration.version() == GL::Version::None)
glConfiguration.setVersion(configuration.version());
#endif
if(configuration.sampleCount() && !glConfiguration.sampleCount())
glConfiguration.setSampleCount(configuration.sampleCount());
#ifndef CORRADE_TARGET_EMSCRIPTEN
if(configuration.isSRGBCapable() && !glConfiguration.isSRGBCapable())
glConfiguration.setSRGBCapable(configuration.isSRGBCapable());
#endif
CORRADE_IGNORE_DEPRECATED_POP
#endif
bool Sdl2Application::tryCreate(const Configuration& configuration, const GLConfiguration& glConfiguration) {
CORRADE_ASSERT(_context->version() == GL::Version::None, "Platform::Sdl2Application::tryCreate(): context already created", false);
/* Enable double buffering, set up buffer sizes */
@ -936,17 +907,7 @@ Sdl2Application::Configuration::Configuration():
#else
_size{}, /* SDL2 detects someting for us */
#endif
_dpiScalingPolicy{DpiScalingPolicy::Default}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
, _sampleCount(0)
#ifndef CORRADE_TARGET_EMSCRIPTEN
/* Deliberately not setting _flags to ForwardCompatible to avoid them
having higher priority over GLConfiguration flags, appending that flag
later */
, _version(GL::Version::None), _srgbCapable{false}
#endif
#endif
{}
_dpiScalingPolicy{DpiScalingPolicy::Default} {}
Sdl2Application::Configuration::~Configuration() = default;

107
src/Magnum/Platform/Sdl2Application.h

@ -600,22 +600,6 @@ class Sdl2Application {
*/
void create();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief create(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref create(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use create(const Configuration&, const GLConfiguration&) instead") void createContext(const Configuration& configuration) {
create(configuration);
}
/** @brief @copybrief create()
* @deprecated Use @ref create() instead.
*/
CORRADE_DEPRECATED("use create() instead") void createContext() {
create();
}
#endif
#ifdef MAGNUM_TARGET_GL
/**
* @brief Try to create context with given configuration for OpenGL context
@ -639,15 +623,6 @@ class Sdl2Application {
*/
bool tryCreate(const Configuration& configuration);
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
/** @brief @copybrief tryCreate(const Configuration&, const GLConfiguration&)
* @deprecated Use @ref tryCreate(const Configuration&, const GLConfiguration&) instead.
*/
CORRADE_DEPRECATED("use tryCreate(const Configuration&, const GLConfiguration&) instead") bool tryCreateContext(const Configuration& configuration) {
return tryCreate(configuration);
}
#endif
/** @{ @name Screen handling */
public:
@ -1327,18 +1302,6 @@ namespace Implementation {
*/
class Sdl2Application::Configuration {
public:
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL) && !defined(CORRADE_TARGET_EMSCRIPTEN)
/** @brief @copybrief GLConfiguration::Flag
* @deprecated Use @ref GLConfiguration::Flag instead.
*/
typedef GLConfiguration::Flag Flag;
/** @brief @copybrief GLConfiguration::Flags
* @deprecated Use @ref GLConfiguration::Flags instead.
*/
typedef GLConfiguration::Flags Flags;
#endif
/**
* @brief Window flag
*
@ -1601,68 +1564,6 @@ class Sdl2Application::Configuration {
return *this;
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#ifndef CORRADE_TARGET_EMSCRIPTEN
/** @brief @copybrief GLConfiguration::flags()
* @deprecated Use @ref GLConfiguration::flags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::flags() instead") GLConfiguration::Flags flags() const { return _flags; }
/** @brief @copybrief GLConfiguration::setFlags()
* @deprecated Use @ref GLConfiguration::setFlags() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setFlags() instead") Configuration& setFlags(GLConfiguration::Flags flags) {
_flags = flags;
return *this;
}
/** @brief @copybrief GLConfiguration::version()
* @deprecated Use @ref GLConfiguration::version() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::version() instead") GL::Version version() const { return _version; }
#endif
/** @brief @copybrief GLConfiguration::setVersion()
* @deprecated Use @ref GLConfiguration::setVersion() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setVersion() instead") Configuration& setVersion(GL::Version version) {
#ifndef CORRADE_TARGET_EMSCRIPTEN
_version = version;
#else
static_cast<void>(version);
#endif
return *this;
}
/** @brief @copybrief GLConfiguration::sampleCount()
* @deprecated Use @ref GLConfiguration::sampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::sampleCount() instead") Int sampleCount() const { return _sampleCount; }
/** @brief @copybrief GLConfiguration::setSampleCount()
* @deprecated Use @ref GLConfiguration::setSampleCount() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setSampleCount() instead") Configuration& setSampleCount(Int count) {
_sampleCount = count;
return *this;
}
#ifndef CORRADE_TARGET_EMSCRIPTEN
/** @brief @copybrief GLConfiguration::isSrgbCapable()
* @deprecated Use @ref GLConfiguration::isSrgbCapable() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::isSrgbCapable() instead") bool isSRGBCapable() const { return _srgbCapable; }
/** @brief @copybrief GLConfiguration::setSrgbCapable()
* @deprecated Use @ref GLConfiguration::setSrgbCapable() instead.
*/
CORRADE_DEPRECATED("use GLConfiguration::setSrgbCapable() instead") Configuration& setSRGBCapable(bool enabled) {
_srgbCapable = enabled;
return *this;
}
#endif
#endif
private:
#if !defined(CORRADE_TARGET_EMSCRIPTEN) && !defined(CORRADE_TARGET_IOS)
std::string _title;
@ -1671,14 +1572,6 @@ class Sdl2Application::Configuration {
DpiScalingPolicy _dpiScalingPolicy;
WindowFlags _windowFlags;
Vector2 _dpiScaling;
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
Int _sampleCount;
#ifndef CORRADE_TARGET_EMSCRIPTEN
GL::Version _version;
Flags _flags;
bool _srgbCapable;
#endif
#endif
};
/**

41
src/Magnum/PrimitiveQuery.h

@ -1,41 +0,0 @@
#ifndef Magnum_PrimitiveQuery_h
#define Magnum_PrimitiveQuery_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/PrimitiveQuery.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/PrimitiveQuery.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/PrimitiveQuery.h instead")
#else
#error use Magnum/GL/PrimitiveQuery.h instead
#endif
#endif

41
src/Magnum/RectangleTexture.h

@ -1,41 +0,0 @@
#ifndef Magnum_RectangleTexture_h
#define Magnum_RectangleTexture_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/RectangleTexture.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/RectangleTexture.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/RectangleTexture.h instead")
#else
#error use Magnum/GL/RectangleTexture.h instead
#endif
#endif

41
src/Magnum/Renderbuffer.h

@ -1,41 +0,0 @@
#ifndef Magnum_Renderbuffer_h
#define Magnum_Renderbuffer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Renderbuffer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Renderbuffer.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Renderbuffer.h instead")
#else
#error use Magnum/GL/Renderbuffer.h instead
#endif
#endif

41
src/Magnum/RenderbufferFormat.h

@ -1,41 +0,0 @@
#ifndef Magnum_RenderbufferFormat_h
#define Magnum_RenderbufferFormat_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/RenderbufferFormat.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/RenderbufferFormat.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/RenderbufferFormat.h instead")
#else
#error use Magnum/GL/RenderbufferFormat.h instead
#endif
#endif

41
src/Magnum/Renderer.h

@ -1,41 +0,0 @@
#ifndef Magnum_Renderer_h
#define Magnum_Renderer_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Renderer.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Renderer.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Renderer.h instead")
#else
#error use Magnum/GL/Renderer.h instead
#endif
#endif

41
src/Magnum/SampleQuery.h

@ -1,41 +0,0 @@
#ifndef Magnum_SampleQuery_h
#define Magnum_SampleQuery_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/SampleQuery.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/SampleQuery.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/SampleQuery.h instead")
#else
#error use Magnum/GL/SampleQuery.h instead
#endif
#endif

4
src/Magnum/Sampler.h

@ -32,10 +32,6 @@
#include "Magnum/Magnum.h"
#include "Magnum/visibility.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Sampler.h"
#endif
namespace Magnum {
/**

41
src/Magnum/Shader.h

@ -1,41 +0,0 @@
#ifndef Magnum_Shader_h
#define Magnum_Shader_h
/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019
Vladimír Vondruš <mosra@centrum.cz>
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the "Software"),
to deal in the Software without restriction, including without limitation
the rights to use, copy, modify, merge, publish, distribute, sublicense,
and/or sell copies of the Software, and to permit persons to whom the
Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included
in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.
*/
/** @file
* @deprecated Use @ref Magnum/GL/Shader.h instead.
*/
#include "Magnum/configure.h"
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
#include "Magnum/GL/Shader.h"
CORRADE_DEPRECATED_FILE("use Magnum/GL/Shader.h instead")
#else
#error use Magnum/GL/Shader.h instead
#endif
#endif

19
src/Magnum/Test/PixelFormatTest.cpp

@ -34,9 +34,6 @@ struct PixelFormatTest: TestSuite::Tester {
explicit PixelFormatTest();
void size();
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void sizeDeprecated();
#endif
void sizeImplementationSpecific();
void isImplementationSpecific();
@ -60,9 +57,6 @@ struct PixelFormatTest: TestSuite::Tester {
PixelFormatTest::PixelFormatTest() {
addTests({&PixelFormatTest::size,
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
&PixelFormatTest::sizeDeprecated,
#endif
&PixelFormatTest::sizeImplementationSpecific,
&PixelFormatTest::isImplementationSpecific,
@ -95,19 +89,6 @@ void PixelFormatTest::size() {
CORRADE_COMPARE(pixelSize(PixelFormat::RGBA32F), 16);
}
#if defined(MAGNUM_BUILD_DEPRECATED) && defined(MAGNUM_TARGET_GL)
void PixelFormatTest::sizeDeprecated() {
std::ostringstream out;
Error redirectError{&out};
CORRADE_IGNORE_DEPRECATED_PUSH
pixelSize(PixelFormat::RGBA);
CORRADE_IGNORE_DEPRECATED_POP
CORRADE_COMPARE(out.str(), "pixelSize(): called with deprecated GL-specific format, use GL::pixelSize() instead\n");
}
#endif
void PixelFormatTest::sizeImplementationSpecific() {
std::ostringstream out;
Error redirectError{&out};

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save