You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

3547 lines
208 KiB

/*
This file is part of Magnum.
Copyright © 2010, 2011, 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019,
2020 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.
*/
namespace Magnum {
/** @page changelog Changelog
@tableofcontents
See also:
- @subpage changelog-plugins "Plugins changelog"
- @subpage changelog-integration "Integration changelog"
- @subpage changelog-extras "Extras changelog"
- @subpage changelog-examples "Examples changelog"
@section changelog-latest Changes since 2019.10
- Clang-CL is now a supported compiler on Windows. See also
@ref platforms-windows-clang-cl.
@subsection changelog-latest-new New features
- New @ref Vector2h, @ref Vector3h, @ref Vector4h, @ref Vector2ub,
@ref Vector3ub, @ref Vector4ub, @ref Vector2b, @ref Vector3b,
@ref Vector4b, @ref Vector2us, @ref Vector3us, @ref Vector4us,
@ref Vector2s, @ref Vector3s, @ref Vector4s, @ref Color3h, @ref Color4h,
@ref Color3us, @ref Color4us convenience typedefs for half-float, 8- and
16-bit integer vector and color types
- New storage-only @ref Matrix2x2h, @ref Matrix2x2b, @ref Matrix2x2s,
@ref Matrix2x3h, @ref Matrix2x3b, @ref Matrix2x3s, @ref Matrix2x4h,
@ref Matrix2x4b, @ref Matrix2x4s, @ref Matrix3x2h, @ref Matrix3x2b,
@ref Matrix3x2s, @ref Matrix3x3h. @ref Matrix3x3b, @ref Matrix3x3s,
@ref Matrix3x4h, @ref Matrix3x4b, @ref Matrix3x4s, @ref Matrix4x2h,
@ref Matrix4x2b, @ref Matrix4x2s, @ref Matrix4x3h, @ref Matrix4x3b,
@ref Matrix4x3s, @ref Matrix4x4h, @ref Matrix4x4b, @ref Matrix4x4s
convenience typedefs for half-float, 8- and 16-bit packed matrix types
- New @ref VertexFormat enum for vertex formats and related utilities
- New @ref MeshPrimitive::Instances, @ref MeshPrimitive::Faces and
@ref MeshPrimitive::Edges primitive types for describing per-instance,
per-face and per-edge data. Those don't map to any common GPU API, but can
be used by various importers to provide access to mesh data that is not
necessarily GPU-friendly.
@subsubsection changelog-latest-new-animation Animation library
- Added a @ref Animation::TrackViewStorage::values() getter for type-erased
access to track values
@subsubsection changelog-latest-new-audio Audio library
- Added a @ref Audio::Buffer::frequency() getter
@subsubsection changelog-latest-new-debugtools DebugTools library
- New @ref DebugTools::ColorMap namespace containing a few presets for
gradient visualization
- New @ref DebugTools::FrameProfiler utility for CPU and GPU profiling
@subsubsection changelog-latest-new-gl GL library
- Exposed new entry points. Note that no wrapper API in the @ref GL namespace
is provided for the extensions listed below, at the moment:
- Desktop / ES @gl_extension{OVR,multiview} and
@gl_extension{OVR,multiview2} extensions and the WebGL
@webgl_extension{OVR,multiview2} extension. See also
[mosra/magnum#385](https://github.com/mosra/magnum/issues/385).
- @gl_extension{ARB,sample_locations} and
@gl_extension{AMD,sample_positions} desktop extensions;
@gl_extension{NV,sample_locations} desktop and ES extension
- Implemented @gl_extension{EXT,draw_buffers2},
@gl_extension{ARB,draw_buffers_blend} desktop extensions,
@gl_extension{EXT,draw_buffers_indexed} ES extension and
@webgl_extension{EXT,draw_buffers_indexed} WebGL 2 extension in
@ref GL::Renderer
- Implemented @ref GL::Renderer::setPatchVertexCount(),
@ref GL::Renderer::setPatchDefaultInnerLevel() and
@ref GL::Renderer::setPatchDefaultOuterLevel() as the last missing bits for
@gl_extension{ARB,tessellation_shader} / @gl_extension{EXT,tessellation_shader}
support (see [mosra/magnum#164](https://github.com/mosra/magnum/issues/164))
- Implemented @ref GL::PipelineStatisticsQuery from GL 4.6
- Implemented @ref GL:Renderer::Feature::ClipDistance0 through
@ref GL:Renderer::Feature::ClipDistance7 and related limit queries as well
as exposing the @gl_extension{APPLE,clip_distance} /
@gl_extension{EXT,clip_cull_distance} ES and
@webgl_extension{EXT,clip_cull_distance} WebGL extensions
- Recognizing @gl_extension{AMD,shader_explicit_vertex_parameter} desktop
and @gl_extension{NV,fragment_shader_barycentric} desktop / ES extensions.
These add only shading language features.
- A @cpp "intel-windows-crazy-broken-buffer-dsa" @ce and
@cpp "intel-windows-crazy-broken-vao-dsa" @ce workarounds for Intel
Windows drivers, disabling @gl_extension{ARB,direct_state_access} code
paths in everything releated to buffers and meshes. There are several
issues occuring only in heavier apps, impossible to track down and
reproduce in a controlled environment. These two replace the previous
@cpp "intel-windows-buggy-dsa-bufferdata-for-index-buffers" @ce workaround
that attempted to fix this by doing an explicit buffer binding in some
cases. See @ref opengl-workarounds and [mosra/magnum#405](https://github.com/mosra/magnum/pull/405)
for more information.
- A @cpp "apple-buffer-texture-unbind-on-buffer-modify" @ce workaround that
fixes crashes on Apple macOS when attempting to modify a @ref GL::Buffer
when a @ref GL::BufferTexture is bound. See @ref opengl-workarounds for
more information.
- New @ref GL::Buffer::Buffer(Containers::ArrayView<const void>, BufferUsage)
constructor for directly creating buffers filled with data.
- New @ref GL::Mesh::maxVertexAttributeStride() and
@ref GL::AbstractShaderProgram::maxGeometryOutputVertices() limit queries
- Added a @ref GL::Shader::Shader(NoCreateT) constructor for consistency with
other OpenGL wrapper objects
@subsubsection changelog-latest-new-math Math library
- New @ref Magnum/Math/PackingBatch.h header with batch
@ref Math::packInto(), @ref Math::unpackInto(),
@ref Math::packHalfInto(), @ref Math::unpackHalfInto() and
@ref Math::castInto() functions for optimized (un)packing and casting of
large amounts of data (see also [mosra/magnum#275](https://github.com/mosra/magnum/pull/275))
- Added @ref Math::Quaternion::toEuler() and documented how to convert Euler
angles to a quaternion (see [mosra/magnum#397](https://github.com/mosra/magnum/pull/397))
- Added @ref Math::DualComplex::transformVector(),
@ref Math::DualQuaternion::transformVector(),
@ref Math::DualQuaternion::transformVectorNormalized() delegating to
respective APIs in the underlying @ref Complex / @ref Quaternion to make
the transformation API more consistent with @ref Matrix3 / @ref Matrix4
- Added @ref Math::reflect() and @ref Math::refract() (see
[mosra/magnum#420](https://github.com/mosra/magnum/pull/420))
@subsubsection changelog-latest-new-meshtools MeshTools library
- Added @ref MeshTools::compile(const Trade::MeshData&) operating on the new
@ref Trade::MeshData API
- New @ref MeshTools::isInterleaved() and @ref MeshTools::interleavedData()
utilities for checking if @ref Trade::MeshData is interleaved and for
getting an interleaved view
- Added @ref MeshTools::interleavedLayout() for convenient creation of an
interleaved mesh layout using the new @ref Trade::MeshData API
- Added @ref MeshTools::interleave(const Trade::MeshData&, Containers::ArrayView<const Trade::MeshAttributeData>),
@ref MeshTools::duplicate(const Trade::MeshData&, Containers::ArrayView<const Trade::MeshAttributeData>),
@ref MeshTools::compressIndices(const Trade::MeshData&, MeshIndexType)
and @ref MeshTools::removeDuplicates(const Trade::MeshData&) that work
directly on the new @ref Trade::MeshData API
- Added @ref MeshTools::subdivideInPlace() for allocation-less mesh
subdivision
- New @ref MeshTools::removeDuplicatesInPlace() variant that works on
discrete data in addition to floating-point
- New @ref MeshTools::combineIndexedAttributes() tool for combining
differently indexed attributes into a single index buffer, and
@ref MeshTools::combineFaceAttributes() for converting per-face attributes
into per-vertex
- New @ref MeshTools::concatenate() and @ref MeshTools::concatenateInto()
tool for batching multiple generic meshes together
- @ref MeshTools::primitiveCount() for calculating number of generated
primitives for a particular primitive type
- New family of @ref MeshTools::generateLineStripIndices(),
@ref MeshTools::generateLineLoopIndices(),
@ref MeshTools::generateTriangleStripIndices() and
@ref MeshTools::generateTriangleFanIndices() utilities for converting
various mesh types to plain indexed @ref MeshPrimitive::Lines and
@ref MeshPrimitive::Triangles, as well as @ref MeshTools::generateIndices()
operating directly on a @ref Trade::MeshData
@subsubsection changelog-latest-new-platform Platform libraries
- Cursor management using @ref Platform::Sdl2Application::setCursor(),
@ref Platform::GlfwApplication::setCursor() and
@ref Platform::EmscriptenApplication::setCursor() (see
[mosra/magnum#383](https://github.com/mosra/magnum/pull/383) and
[mosra/magnum#415](https://github.com/mosra/magnum/pull/415))
- Added @ref Platform::GlfwApplication::setWindowSize() and
@ref Platform::Sdl2Application::setWindowSize()
- Window icon management using @ref Platform::Sdl2Application::setWindowIcon()
and @ref Platform::GlfwApplication::setWindowIcon() (see
[mosra/magnum#393](https://github.com/mosra/magnum/issues/393))
- Added @ref Platform::GlfwApplication::warpCursor() to match the equivalent
API in @ref Platform::Sdl2Application (see
[mosra/magnum#383](https://github.com/mosra/magnum/pull/383))
- Implemented @ref Platform::GlfwApplication::mainLoopIteration() and
@ref Platform::AbstractXApplication::mainLoopIteration() for consistency
with @ref Platform::Sdl2Application (see
[mosra/magnum#387](https://github.com/mosra/magnum/pull/387))
- Added @ref Platform::Sdl2Application::KeyEvent::Key::Quote "Key::Quote",
@ref Platform::Sdl2Application::KeyEvent::Key::LeftBracket "Key::LeftBracket",
@ref Platform::Sdl2Application::KeyEvent::Key::RightBracket "Key::RightBracket",
@ref Platform::Sdl2Application::KeyEvent::Key::Backslash "Key::Backslash" and
@ref Platform::Sdl2Application::KeyEvent::Key::Backquote "Key::Backquote"
keys to @ref Platform::Sdl2Application::KeyEvent and
@ref Platform::GlfwApplication::KeyEvent
- Added @ref Platform::GlfwApplication::KeyEvent::Key::World1 and
@ref Platform::GlfwApplication::KeyEvent::Key::World2
- Added @ref Platform::EmscriptenApplication::KeyEvent::Key::Semicolon
- New [base-gtkmm](https://github.com/mosra/magnum-bootstrap/tree/base-gtkmm)
bootstrap project for using Magnum together with gtkmm (see
[mosra/magnum-bootstrap#24](https://github.com/mosra/magnum-bootstrap/pull/24))
- Context sharing in @ref Platform::WindowlessCglApplication,
@ref Platform::WindowlessEglApplication,
@ref Platform::WindowlessGlxApplication,
@ref Platform::WindowlessWglApplication and
@ref Platform::WindowlessWindowsEglApplication (see [mosra/magnum#433](https://github.com/mosra/magnum/pull/433)
and [mosra/magnum#437](https://github.com/mosra/magnum/pull/437))
- Added @ref Platform::GlfwApplication::Configuration::WindowFlag::Borderless
- Added @ref Platform::Sdl2Application::Configuration::WindowFlag::FullscreenDesktop,
@ref Platform::Sdl2Application::Configuration::WindowFlag::AlwaysOnTop "AlwaysOnTop",
@ref Platform::Sdl2Application::Configuration::WindowFlag::SkipTaskbar "SkipTaskbar",
@ref Platform::Sdl2Application::Configuration::WindowFlag::Utility "Utility",
@ref Platform::Sdl2Application::Configuration::WindowFlag::Tooltip "Tooltip"
and @ref Platform::Sdl2Application::Configuration::WindowFlag::PopupMenu "PopupMenu"
- Added @ref Platform::Sdl2Application::Configuration::addWindowFlags() and
@ref Platform::Sdl2Application::Configuration::clearWindowFlags() "clearWindowFlags()"
for consistency with similar functions in
@ref Platform::Sdl2Application::GLConfiguration; same done for
@ref Platform::GlfwApplication as well
@subsubsection changelog-latest-new-primitives Primitives library
- @ref Primitives::capsule3DSolid(), @ref Primitives::circle3DSolid(),
@ref Primitives::coneSolid(), @ref Primitives::cylinderSolid(),
@ref Primitives::grid3DSolid(), @ref Primitives::planeSolid() and
@ref Primitives::uvSphereSolid() can now have tangents as well
- Added @ref Primitives::icosphereWireframe()
@subsubsection changelog-latest-new-scenegraph SceneGraph library
- All 2D transformation implementations that support rotation now have a
@ref SceneGraph::AbstractBasicTranslationRotation2D::rotate(const Math::Complex<T>&) "rotate()"
and @ref SceneGraph::AbstractBasicTranslationRotation2D::rotateLocal(const Math::Complex<T>&) "rotateLocal()"
overloads taking a @ref Math::Complex
- All 3D transformation implementations that support rotation now have a
@ref SceneGraph::AbstractBasicTranslationRotation3D::rotate(const Math::Quaternion<T>&) "rotate()"
and @ref SceneGraph::AbstractBasicTranslationRotation3D::rotateLocal(const Math::Quaternion<T>&) "rotateLocal()"
overloads taking a @ref Math::Quaternion
@subsubsection changelog-latest-new-shaders Shaders library
- New @ref Shaders::MeshVisualizer2D for 2D mesh visualization
- Tangent space visualization in @ref Shaders::MeshVisualizer3D
- Object, vertex and primitive ID visualization in
@ref Shaders::MeshVisualizer2D and @ref Shaders::MeshVisualizer3D
- Texture coordinate transformation in @ref Shaders::DistanceFieldVector,
@ref Shaders::Flat, @ref Shaders::Phong and @ref Shaders::Vector
- Ability to render Per-instance / per-vertex object ID in @ref Shaders::Flat
and @ref Shaders::Phong, in addition to uniform object ID
- New attribute definitions and an location allocation scheme in
@ref Shaders::Generic --- @ref Shaders::Generic::Tangent4,
@ref Shaders::Generic::Bitangent, @ref Shaders::Generic::ObjectId plus
@ref Shaders::Generic::TransformationMatrix,
@ref Shaders::Generic::NormalMatrix and
@ref Shaders::Generic::TextureOffset for instancing
- Instancing in @ref Shaders::Flat and @ref Shaders::Phong
@subsubsection changelog-latest-new-trade Trade library
- A new, redesigned @ref Trade::MeshData class that allows much more flexible
access to vertex/index data without unnecessary allocations and data
conversions or copies. Importers expose it through the new
@ref Trade::AbstractImporter::mesh() family of APIs. See
[mosra/magnum#371](https://github.com/mosra/magnum/pull/371).
- New @ref magnum-sceneconverter "magnum-sceneconverter" tool, similar to
@ref magnum-imageconverter "magnum-imageconverter" but suited for general
scene formats
- New @ref Trade::AbstractSceneConverter plugin interface and an
@ref Trade::AnySceneConverter "AnySceneConverter" plugin
- Ability to import image mip levels via an additional parameter in
@ref Trade::AbstractImporter::image2D(),
@ref Trade::AbstractImporter::image2DLevelCount() and similar APIs for 1D
and 3D images
- The @ref Trade::AnimationData class received support for mutable data
access with new constructors and the
@ref Trade::AnimationData::mutableData() "mutableData()" and
@ref Trade::AnimationData::mutableTrack() "mutableTrack()" accessors.
Equivalent APIs are exposed in both @ref Trade::ImageData and
@ref Trade::MeshData as well. See @ref Trade-AnimationData-usage-mutable
for more information.
- New convenience @ref Trade::AbstractImporter::material(const std::string&)
etc. APIs allowing to directly get a data using a string name
- @ref Trade::PhongMaterialData now supports both color and texture instead
of just one or the other, can reference normal textures as well and
specfify texture coordinate transform
- @ref Trade::PhongMaterialData now supports non-default texture coordinate
sets (see [mosra/magnum#278](https://github.com/mosra/magnum/pull/278),
[mosra/magnum#438](https://github.com/mosra/magnum/pull/438))
- Added @ref Trade::AbstractImporter::setFlags() and
@ref Trade::AbstractImageConverter::setFlags() for configuring common
plugin behavior such as output verbosity level; exposed also via a new
`--verbose` option in @ref magnum-imageconverter "magnum-imageconverter"
and @ref magnum-sceneconverter "magnum-sceneconverter"
- @ref magnum-imageconverter "magnum-imageconverter" has a new `--info`
option for printing detailed info about a particular file
- RLE compression support in @ref Trade::TgaImporter "TgaImporter"
@subsubsection changelog-latest-new-vk Vk library
- Updated Vulkan headers for version 1.2
- Conversion of @ref VertexFormat values to the @type_vk{Format} enum using
@ref Vk::vkFormat(Magnum::VertexFormat)
@subsection changelog-latest-changes Changes and improvements
- The @ref MeshPrimitive type can now store implementation-specific primitive
types similarly to @ref PixelFormat and the new @ref VertexFormat.
Implementation-specific types are then simply passed through in
@ref GL::meshPrimitive() and @ref Vk::vkPrimitiveTopology().
- The @ref PixelFormat and @ref CompressedPixelFormat enums can now be saved
and retrieved from @ref Corrade::Utility::Configuration /
@ref Corrade::Utility::Arguments
- @ref Resource is now nothrow-movable and thus can be used with growable
6 years ago
@ref Corrade::Containers::Array instances
- Reworked plugin search paths to prefer autodetection based on library or
executable location where possible and use hardcoded paths only if
explicitly specified. See @ref Trade::AbstractImporter::pluginSearchPaths()
for more information.
- Added an ability to disable unique globals across shared libraries using
@ref MAGNUM_BUILD_STATIC_UNIQUE_GLOBALS on static builds that don't need it
- Library version is now exposed through `MAGNUM_VERSION_YEAR`,
`MAGNUM_VERSION_MONTH`, `MAGNUM_VERSION_COMMIT`, `MAGNUM_VERSION_HASH`
and `MAGNUM_VERSION_STRING` preprocessor defines in a new
`Magnum/version.h` header. This header is not included by any other header
to avoid trigerring a full rebuild when Git commit changes. If Git is not
found, only the first two defines are present.
@subsubsection changelog-latest-changes-audio Audio library
- @ref Audio::WavImporter "WavAudioImporter" now supports also Big-Endian
`RIFX` files and was fixed to work on Big-Endian platforms (see
[mosra/corrade#87](https://github.com/mosra/corrade/issues/87))
@subsubsection changelog-latest-changes-gl GL library
- Added @ref GL::AbstractTexture::bind(),
@ref GL::AbstractTexture::bindImages() and
@ref GL::AbstractShaderProgram::draw() overloads taking a
@ref Corrade::Containers::ArrayView instead of @ref std::initializer_list
in order to allow passing runtime-sized lists (see also
[mosra/magnum#403](https://github.com/mosra/magnum/pull/403))
- Added an ability to remove a buffer from a @ref GL::BufferTexture using
@ref GL::BufferTexture::resetBuffer() "resetBuffer()"
- Matrix @ref GL::Attribute instances can now specify custom stride between
column vectors in order to control alignment in packed 8- and 16-bit types
- @ref GL::DynamicAttribute can now describe matrix attributes similarly to
@ref GL::Attribute, previously this was possible only by specifying each
column vector separately
- Added @ref GL::Context::State::UnbindPixelBuffer that's now implicitly
included in @ref GL::Context::State::EnterExternal to make Magnum work
correctly with 3rd party code that's not aware of PBOs.
- The @cpp "intel-windows-explicit-uniform-location-is-less-explicit-than-you-hoped" @ce
workaround now unconditionally disables @gl_extension{ARB,explicit_uniform_location}
on Intel Windows drivers because it was discovered to be too buggy to be
useful, affecting most shaders from the @ref Shaders library. See also
@ref opengl-workarounds.
@subsubsection changelog-latest-changes-math Math library
- Functions in @ref Magnum/Math/FunctionsBatch.h now accept any type that's
convertible to a @ref Corrade::Containers::StridedArrayView without having
to add explicit casts or template parameters
- @ref Math::slerp(const Quaternion<T>&, const Quaternion<T>&, T) and
@ref Math::slerpShortestPath(const Quaternion<T>&, const Quaternion<T>&, T)
now fall back to linear interpolation when the quaternions are close to
each other, instead of unconditionally returning the first argument
- Added non-const overloads to @ref Math::Frustum::operator[]() and
@ref Math::Frustum::front() etc. accessors, returning references (see
[mosra/magnum#425](https://github.com/mosra/magnum/pull/425))
@subsubsection changelog-latest-changes-meshtools MeshTools library
- Added @ref MeshTools::compressIndices() that takes a
@ref Corrade::Containers::StridedArrayView instead of a @ref std::vector
and additionally allows you to specify the smallest allowed type, offset to
apply to each index and is working with 8- and 16-byte index types as well
- Added @ref MeshTools::subdivide() that operates on a (growable)
@ref Corrade::Containers::Array instead of a @ref std::vector
- Added @ref MeshTools::subdivideInPlace() that operates on a partially
filled array view instead of a @ref std::vector
- Added @ref MeshTools::removeDuplicatesIndexedInPlace() that operates
in-place on an indexed array view and a STL-less
@ref MeshTools::removeDuplicatesInPlace() variant
- Added @ref MeshTools::duplicateInto() variants that take type-erased
2D strided array views
- @ref MeshTools::flipNormalsInPlace() and @ref MeshTools::flipFaceWindingInPlace()
were renamed for clarity and now accept a
@ref Corrade::Containers::StridedArrayView instead of a @ref std::vector,
additionally working on 8- and 16-byte index types as well
- @ref MeshTools::tipsifyInPlace() was renamed for clarity and now accepts a
@ref Corrade::Containers::StridedArrayView instead of a @ref std::vector,
additionally working on 8- and 16-byte index types as well
- Added @ref MeshTools::generateSmoothNormals() and
@ref MeshTools::generateSmoothNormalsInto() variants taking type-erased
index arrays
@subsubsection changelog-latest-changes-platform Platform libraries
6 years ago
- @ref Platform::GlfwApplication now gracefully handles monitor sizes of zero
when calculating DPI scaling (see [mosra/magnum#388](https://github.com/mosra/magnum/pull/388))
- Ability to specify application return code in
@ref Platform::AbstractXApplication::exit()
- Worked around @ref Platform::GlfwApplication crash while creating GL
context on a hidden window on Wayland (see
[mosra/magnum#392](https://github.com/mosra/magnum/pull/392),
[mosra/magnum#400](https://github.com/mosra/magnum/issues/400),
7 years ago
[mosra/magnum#401](https://github.com/mosra/magnum/pull/401))
- HiDPI capability checking on macOS and iOS got fixed to behave correctly
when the capability is explicitly set to @cb{.xml} <false/> @ce in the
`Info.plist` file and additionally, unless overriden, it's assumed to be
enabled by default on macOS 10.15+ and iOS 13+. Applications running on
these platforms no longer need to supply a custom `Info.plist` in order to
enable HiDPI. See @ref platforms-macos-hidpi for more information.
- Implemented virtual DPI scaling in @ref Platform::GlfwApplication on
Windows (was behaving like physical before) and physical DPI scaling in
@ref Platform::Sdl2Application (which was behaving like virtual before)
(see [mosra/magnum#243](https://github.com/mosra/magnum/issues/243))
- Undefining more noise from `Xlib.h` (see [mosra/magnum#430](https://github.com/mosra/magnum/pull/430))
- Calling @ref Platform::Sdl2Application::exit() "Platform::*Application::exit()"
directly in the application constructor will now make it exit right after
constructor finished, without any event processing (see [mosra/magnum#429](https://github.com/mosra/magnum/issues/429))
- @ref Platform::AndroidApplication, @ref Platform::EmscriptenApplication,
@ref Platform::GlfwApplication and @ref Platform::Sdl2Application now
default to 32-bit RGBA color buffer instead of 24-bit RGB, to avoid the
framebuffer degrading to 16-bit colors on some platforms (see
[mosra/magnum-integration#59](https://github.com/mosra/magnum-integration/issues/59))
- Added @ref Platform::BasicScreenedApplication::globalBeforeDrawEvent()
- @ref Platform::WindowlessGlxApplication now handles `GLXBadFBConfig` errors
gracefully, making the fallback compatibility context creation work even in
those cases. This makes it work with Mesa's Zink GL-over-Vulkan driver.
- Following all other application implementations,
@ref Platform::WindowlessEglApplication now implements the
@cpp "no-forward-compatible-core-context" @ce workaround as well, giving
back latest OpenGL version on proprietary NVidia and AMD drivers instead of
OpenGL 3.0. The newly added fallback also makes the application work with
Mesa's Zink GL-over-Vulkan driver that has just GL 2.1. See also
@ref opengl-workarounds.
@subsubsection changelog-latest-changes-trade Trade library
- For better usability, the @ref magnum-imageconverter "magnum-imageconverter"
utility now prints available importer/converter plugins when loading a
plugin fails
- @ref magnum-imageconverter "magnum-imageconverter" can load a
tightly-packed square of raw pixels instead of going through an importer
plugin if you specify `--importer raw:&lt;format&gt;`; and save raw
imported data instead of going through a converter plugin if you specify
`--converter raw`
- @ref magnum-imageconverter "magnum-imageconverter" can be told to load a
particular image and level using the `--image` and `--level` options
- New convenience @ref Trade::AnimationTrackData constructor taking a
templated @ref Animation::TrackView type, autodetecting value and result
@ref Trade::AnimationTrackType out of it
- New convenience @ref Trade::AnimationData constructors taking an
@ref std::initializer_list of @ref Trade::AnimationTrackData
- Recognizing `*.ico` and `*.cur` files in
@ref Trade::AnyImageImporter "AnyImageImporter"
@subsection changelog-latest-buildsystem Build system
- Fixed a bad interaction between @ref Magnum/Platform/AbstractXApplication.h
and @ref Magnum/Platform/GlfwApplication.h (see [mosra/magnum#389](https://github.com/mosra/magnum/pull/389))
- `FindSDL2.cmake` got updated to link to all dependencies when using a
statically built SDL on Windows
- `FindSDL2.cmake` now links to Metal in addition to other frameworks on iOS
and is updated to link to these only if SDL is statically built (see
[mosra/magnum#410](https://github.com/mosra/magnum/issues/410))
- `FindMagnum.cmake` now properly recognizes an optional dependency between
@ref DebugTools and @ref Trade on GL-less builds
- Various compiler warning fixes (see [mosra/magnum#406](https://github.com/mosra/magnum/pull/406))
- Added a 32-bit Windows build to the CI matrix to avoid random compilation
issues (see [mosra/magnum#421](https://github.com/mosra/magnum/issues/421))
- The library again compiles and tests cleanly with @ref CORRADE_NO_ASSERT
enabled, and this setup is verified on the CI to avoid further regressions
- Worked around a regression in MSVC 2017 causing a compiler crash (see
[mosra/magnum#440](https://github.com/mosra/magnum/issues/440))
- Linker fixes for MinGW Clang (see [mosra/magnum#417](https://github.com/mosra/magnum/pull/417))
- Properly installing plugin binaries in Gentoo packages (see
[mosra/magnum-plugins#85](https://github.com/mosra/magnum-plugins/issues/85))
- Warning fixes for MSVC (see [mosra/magnum#445](https://github.com/mosra/magnum/pull/445))
@subsection changelog-latest-bugfixes Bug fixes
- The variadic versions of @ref GL::Mesh::addVertexBuffer() and
@ref GL::Mesh::addVertexBufferInstanced() were sometimes errorneously
picked up instead of the @ref GL::DynamicAttribute overloads when stride
and offset were of a slightly different type.
- @ref Platform::Sdl2Application::viewportEvent() gets properly fired also
when window size changes programmatically (such as through
@ref Platform::Sdl2Application::setMinWindowSize() "setMinWindowSize()")
- @ref Platform::GlfwApplication::setMinWindowSize() /
@ref Platform::GlfwApplication::setMaxWindowSize() and equivalent APIs in
@ref Platform::Sdl2Application now correctly take DPI scaling into account
- The @ref Primitives::cylinderSolid() and @ref Primitives::coneSolid()
primitives were missing a face when both caps and texture coordinates were
enabled (see [mosra/magnum#386](https://github.com/mosra/magnum/issues/386))
- @ref Platform::Sdl2Application::Configuration::WindowFlag::Vulkan was
enabled conditionally only for SDL >= 2.0.6, but the version defines were
never included so it was always disabled
- Fixed missing handling of
@ref Platform::EmscriptenApplication::KeyEvent::Key::LeftBracket "Key::LeftBracket",
@ref Platform::EmscriptenApplication::KeyEvent::Key::RightBracket "Key::RightBracket",
@ref Platform::EmscriptenApplication::KeyEvent::Key::Semicolon "Key::Semicolon" and
@ref Platform::EmscriptenApplication::KeyEvent::Key::Backquote "Key::Backquote"
in @ref Platform::EmscriptenApplication
- Fixed broken @ref Platform::EmscriptenApplication mouse event coordinates
when `-s DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1` is enabled (see
[mosra/magnum#408](https://github.com/mosra/magnum/issues/408))
- Fixed compilation of @ref Platform::EmscriptenApplication on recent
Emscripten versions (see [mosra/magnum#434](https://github.com/mosra/magnum/pull/434))
- Due to Windows- and macOS-specific issues in GLFW,
@ref Platform::GlfwApplication::viewportEvent() and/or
@ref Platform::GlfwApplication::drawEvent() could get fired already during
class construction, potentially causing crashes or
`pure virtual method call` aborts. To prevent these issues, event callback
setup is delayed to the first time the application main loop is entered.
- @ref Platform::GlfwApplication was polling for events instead of waiting,
using 100% CPU even if not constantly redrawing
- In 2019.01 @ref Magnum/Platform/Sdl2Application.h went through an include
cleanup, removing 50k lines; but unfortunately we forgot to add back
@cpp #include <SDL_main.h> @ce, causing iOS builds to fail to initialize.
The include got added back and initialization failures are reported with
more information now.
- Calling @ref Platform::Sdl2Application::setSwapInterval() with @cpp 0 @ce
caused @ref Platform::Sdl2Application::setMinimalLoopPeriod() "setMinimalLoopPeriod()"
to be ignored even though Vsync was in fact not enabled.
- It was not possible to override DPI scaling using
@ref Platform::Sdl2Application::Configuration as command-line arguments
always got a priority (see [mosra/magnum#416](https://github.com/mosra/magnum/issues/416))
- Fixed an otherwise harmless OOB access in @ref MeshTools::tipsifyInPlace()
that could trigger ASan or debug iterator errors
- With @ref Corrade/Utility/DebugStl.h not being included, @ref std::string
instances could get accidentally printed as @ref ResourceKey instances.
Added and explicit header dependency to avoid such cases.
- The @ref Magnum/Image.h, @ref Magnum/ImageView.h and
@ref Magnum/Trade/ImageData.h headers required
@ref Corrade/Containers/StridedArrayView.h to be included *before* in order
to use the @ref ImageView::pixels() "pixels()" function. Now it's enough
to just include it at any point, with no order dependency anymore.
- Dynamic plugins on static Magnum builds on Windows were accidentally
searched for in the `lib/` directory instead of `bin/`, and in some cases
in `bin/` instead of `lib/` on Unix platforms.
- @ref Resource was unnecessarily querying the @ref ResourceManager for
updated data even in cases where no resource update was done since last
check
- For a @ref Shaders::Phong with zero lights, alpha mask default value was
incorrectly @cpp 0.0f @ce instead of @cpp 0.5f @ce on OpenGL ES
- @ref Shaders::MeshVisualizer3D accidentally didn't enable
@glsl noperspective @ce interpolation on desktop, resulting in minor
wireframe rendering artifacts
- @ref Math::angle() got fixed to not produce NaN results for vectors,
complex numbers or quaternions very close to each other
- @ref Math::Range was made to be implicitly convertible from @ref std::pair
in 2018.10, but the @ref Math::Range2D and @ref Math::Range3D were only
explicitly, and even that only by an accident
- Fixed various cases where @ref GL::Context would call GL 3+ APIs on GL 2.1
contexts, causing GL errors. This makes context creation completely
error-free on Mesa's Zink GL-over-Vulkan driver.
@subsection changelog-latest-deprecated Deprecated APIs
- @cpp GL::Mesh::draw() @ce and @cpp GL::MeshView::draw() @ce are deprecated
in favor of @ref GL::AbstractShaderProgram::draw() and
@ref GL::AbstractShaderProgram::drawTransformFeedback(), as the API makes
much more sense to have on a shader and not on a mesh
- @cpp GL::Attribute::DataType::HalfFloat @ce,
@cpp GL::DynamicAttribute::DataType::HalfFloat @ce and
@cpp GL::PixelType::HalfFloat @ce is deprecated in favor of
@ref GL::Attribute::DataType::Half,
@ref GL::DynamicAttribute::DataType::Half and @ref GL::PixelType::Half that
are consistent with the @ref Half type used elsewhere.
- @cpp GL::Attribute::vectorSize() @ce is deprecated as the name is
misleading now, use @ref GL::Attribute::vectorStride() instead
- @cpp GL::Attribute::VectorCount @ce is deprecated in favor of
@ref GL::Attribute::Vectors to have a name consistent with
@ref GL::Attribute::components()
- @cpp Trade::AbstractImporter::mesh2D() @ce,
@cpp Trade::MeshData2D @ce, @cpp Trade::MeshData3D @ce,
@cpp Trade::AbstractImporter::mesh2D() @ce,
@cpp Trade::AbstractImporter::mesh3D() @ce and related APIs are
deprecated in favor of @ref Trade::AbstractImporter::mesh() and the new
@ref Trade::MeshData API. For backwards compatibility, importers
implementing the new API have it exposed through @cpp mesh3D() @ce as well,
returning a subset of @ref Trade::MeshData functionality supported by the
old @cpp Trade::MeshData3D @ce APIs
- @cpp Platform::GlfwApplication::Configuration::setCursorMode() @ce and
related enum & getter are deprecated in favor of the new extended and more
flexible @ref Platform::GlfwApplication::setCursor(). The setting didn't
allow changing the cursor later, which made it pretty useless.
- @cpp Platform::Sdl2Application::Configuration::setMouseLocked() @ce and
@cpp Platform::Sdl2Application::Configuration::isMouseLocked() @ce is
deprecated in favor of the new @ref Platform::Sdl2Application::setCursor()
together with @ref Platform::Sdl2Application::Cursor::HiddenLocked
- @cpp Platform::GlfwApplication::Configuration::WindowFlag::Floating @ce is
deprecated in favor of a more descriptive
@ref Platform::GlfwApplication::Configuration::WindowFlag::AlwaysOnTop,
which is also consistent with @ref Platform::Sdl2Application
- @cpp Audio::AbstractImporter::Features @ce,
@cpp Text::AbstractFont::Features @ce,
@cpp Text::AbstractFontConverter::Features @ce,
@cpp Trade::AbstractImporter::Features @ce,
@cpp Trade::AbstractImageConverter::Features @ce enum sets and their
corresponding `Feature` enums are deprecated in favor of
@ref Audio::ImporterFeatures, @ref Text::FontFeatures,
@ref Text::FontConverterFeatures, @ref Trade::ImporterFeatures,
@ref Trade::ImageConverterFeatures enum sets and their corresponding enums
placed directly in the namespace to have them shorter and unambiguous
- @cpp MeshTools::compressIndices() @ce taking a @ref std::vector is
deprecated in favor of @ref MeshTools::compressIndices(const Containers::StridedArrayView1D<const UnsignedInt>&, MeshIndexType, Long)
and its 8- and 16-byte overloads
- @cpp MeshTools::flipNormals() @ce and @cpp MeshTools::flipFaceWinding() @ce
and @cpp MeshTools::tipsify() @ce are deprecated in favor of
@ref MeshTools::flipNormalsInPlace(),
@ref MeshTools::flipFaceWindingInPlace() and @ref MeshTools::tipsifyInPlace()
that accept a @ref Corrade::Containers::StridedArrayView instead of a
@ref std::vector and work with 8- and 16-byte index types as well.
- `Magnum/MeshTools/CombineIndexedArrays.h`,
@cpp MeshTools::combineIndexArrays() @ce and
@cpp MeshTools::combineIndexedArrays() @ce are deprecated in favor of a more
flexible @ref MeshTools::combineIndexedAttributes() in the
@ref Magnum/MeshTools/Combine.h header
- @cpp MeshTools::compressIndicesAs() @ce, @cpp MeshTools::duplicate() @ce,
@cpp MeshTools::removeDuplicates() @ce and @cpp MeshTools::subdivide() @ce
operating on a @ref std::vector are deprecated, use the STL-free
@ref MeshTools::compressIndices(), @ref MeshTools::duplicate(),
@ref MeshTools::removeDuplicatesFuzzyInPlace() and
@ref MeshTools::subdivide() / @ref MeshTools::subdivideInPlace() overloads
instead
- @cpp Primitives::CapsuleTextureCoords @ce,
@cpp Primitives::CircleTextureCoords @ce,
@cpp Primitives::PlaneTextureCoords @ce,
@cpp Primitives::SquareTextureCoords @ce,
@cpp Primitives::UVSphereTextureCoords @ce enums and
@ref Primitives::capsule3DSolid(), @ref Primitives::circle2DSolid(),
@ref Primitives::circle3DSolid(), @ref Primitives::planeSolid(),
@ref Primitives::squareSolid() and @ref Primitives::uvSphereSolid()
overloads taking those are deprecated in favor of
@ref Primitives::CapsuleFlags, @ref Primitives::Circle2DFlags,
@ref Primitives::Circle3DFlags, @ref Primitives::PlaneFlags,
@ref Primitives::SquareFlags and @ref Primitives::UVSphereFlags
- @cpp Primitives::ConeFlag::GenerateTextureCoords @ce,
@cpp Primitives::CylinderFlag::GenerateTextureCoords @ce,
@cpp Primitives::GridFlag::GenerateTextureCoords @ce and
@cpp Primitives::GridFlag::GenerateNormals @ce is deprecated in favor of
@ref Primitives::ConeFlag::TextureCoordinates,
@ref Primitives::CylinderFlag::TextureCoordinates,
@ref Primitives::GridFlag::TextureCoordinates and
@ref Primitives::GridFlag::Normals for naming consistency
- @cpp Shaders::MeshVisualizer @ce is deprecated as the shader can now handle
both 2D and 3D, use @ref Shaders::MeshVisualizer3D instead
- Default constructor of @ref Shaders::MeshVisualizer3D is deprecated, you're
now required to enable at least one visualization feature when constructing
it
- @cpp Shaders::MeshVisualizer::setTransformationProjectionMatrix() @ce is
deprecated on the 3D variant, use separate
@ref Shaders::MeshVisualizer3D::setTransformationMatrix() and
@ref Shaders::MeshVisualizer3D::setProjectionMatrix() instead
- The unprefixed and alien-looking @cpp FLOAT_EQUALITY_PRECISION @ce,
@cpp DOUBLE_EQUALITY_PRECISION @ce and @cpp LONG_DOUBLE_EQUALITY_PRECISION @ce
macros are no longer used by any code and thus deprecated in favor of using
@ref Math::TypeTraits::epsilon() instead, which is also consistent with how
This also means it's no longer
possible to override equality comparison epsilons at compile time, but that
was a rarely (if ever) used feature.
- @cpp DebugTools::Profiler @ce is obsolete, replaced with a much more
flexible and extensible @ref DebugTools::FrameProfiler
@subsection changelog-latest-compatibility Potential compatibility breakages, removed APIs
- @ref Animation::TrackView "TrackView" in the still-experimental
@ref Animation library was changed to allow mutable access to the keys &
values it references. Existing code needs to be changed to say
@cpp TrackView<const K, const V> @ce instead of @cpp TrackView<K, V> @ce.
Following this change, @ref Trade::AnimationData now also return instances
with @cpp const @ce types and the non-const
@ref Trade::AnimationData::data() was renamed to
@ref Trade::AnimationData::mutableData() "mutableData()".
- The 4-argument @ref GL::DynamicAttribute constructor was not marked as
@cpp explicit @ce by mistake, it's done now to enforce readability in long
expressions.
- The @ref Magnum/Math/FunctionsBatch.h header is no longer included from
@ref Magnum/Math/Functions.h for backwards compatibility in order to speed
up compile times.
- @ref Trade::AnimationTrackData constructors are now explicit as that
enforces better readability in long initializer expressions
- Non-const @ref Trade::ImageData::data() and @ref Trade::ImageData::pixels()
were renamed to @ref Trade::ImageData::mutableData() and
@ref Trade::ImageData::mutablePixels() to follow the new
@ref Trade::MeshData API and similar changes in @ref Trade::AnimationData.
- @ref Platform::GlfwApplication::setMinWindowSize() /
@ref Platform::GlfwApplication::setMaxWindowSize() and equivalent APIs in
@ref Platform::Sdl2Application now premultiply the value with
@ref Platform::GlfwApplication::dpiScaling() "dpiScaling()" to work
independently on display DPI. This might break existing uses.
- @ref Primitives::uvSphereWireframe() now correctly asserts when the
@p segments parameter isn't divisible by four. Before it mistakenly
asserted only if @p segments wasn't divisible by two, and now code that
mistakenly used a disallowed value will start asserting.
- @ref ResourceManager singleton accessible through @cpp instance() @ce that
was deprecated in 2019.10 is now removed. Usually a deprecated feature is
kept for at least a year before removal, but in this case it was severely
limiting multithreaded applications and removing it was necessary.
- Locations of generic shader attributes was changed in order to accomodate
for new attributes and use cases. This may break custom shaders if these
rely on generic attribute definitions or are used together with
@ref MeshTools::compile(). To avoid further breakages you're advised to
reuse the definitions from @ref Shaders::Generic (and propagating them to
shader code as well) instead of hardcoding the locations directly.
- @ref Shaders::Generic::Color3 / @ref Shaders::Generic::Color4 location
changed from @cpp 3 @ce to @cpp 2 @ce
- @ref Shaders::Generic::Normal location changed from @cpp 2 @ce to
@cpp 5 @ce
- @ref Shaders::Generic::Tangent location changed from @cpp 4 @ce to
@cpp 3 @ce
- Removed remaining APIs deprecated in version 2018.04:
- @cpp Audio::Buffer::Format @ce, use @ref Audio::BufferFormat instead
- @cpp Shaders::*Vector::setVectorTexture() @ce,
@cpp Shaders::Flat::setTexture() @ce,
@cpp Shaders::Phong::setAmbientTexture() @ce,
@cpp Shaders::Phong::setDiffuseTexture() @ce,
@cpp Shaders::Phong::setSpecularTexture() @ce and
@cpp Shaders::Phong::setTextures() @ce, use
@ref Shaders::AbstractVector::bindVectorTexture() "Shaders::*Vector::bindVectorTexture()",
@ref Shaders::Flat::bindTexture(),
@ref Shaders::Phong::bindAmbientTexture(),
@ref Shaders::Phong::bindDiffuseTexture(),
@ref Shaders::Phong::bindSpecularTexture() and
@ref Shaders::Phong::bindTextures() instead
- @ref MeshPrimitive is now four bytes instead of one, to allow wrapping
implementation-specific values using @ref meshPrimitiveWrap() and
@ref meshPrimitiveUnwrap()
- @ref MeshPrimitive and @ref MeshIndexType now reserve the zero value to
indicate an invalid primitive / type, better catching accidentally
forgotten initialization. Valid code shouldn't be affected by this change,
but broken code that seemingly worked before might start throwing
assertions now. In contrast, @ref SamplerFilter, @ref SamplerMipmap and
@ref SamplerWrapping keep the zero value as a reasonable default. This
follows a similar change done for @ref PixelFormat and
@ref CompressedPixelFormat in 2019.10.
@subsection changelog-latest-documentation Documentation
- Various fixes, improvements and clarifications (see
[mosra/magnum#390](https://github.com/mosra/magnum/pull/390),
[mosra/magnum#394](https://github.com/mosra/magnum/pull/394),
[mosra/magnum#418](https://github.com/mosra/magnum/pull/418),
[mosra/magnum#424](https://github.com/mosra/magnum/pull/424))
- @ref Shaders::Generic now shows the recommended way how to propagate
generic attribute locations to custom shader code (see
[mosra/magnum#443](https://github.com/mosra/magnum/issues/443))
@section changelog-2019-10 2019.10
Released 2019-10-24, tagged as
[v2019.10](https://github.com/mosra/magnum/releases/tag/v2019.10).
@subsection changelog-2019-10-dependencies Dependency changes
- Minimal supported CMake version is now 3.4. Older versions are not
supported anymore and all workarounds for them were removed. Download a
prebuilt release of a newer version if you need to use Corrade on older
systems (such as Ubuntu 14.04 or Debian 8). This is a conservative change
that shouldn't affect any additional distribution compared to the CMake 3.1
requirement in 2019.01.
@subsection changelog-2019-10-new New features
- MSVC 2019 compatibility, with slightly less workarounds needed compared to
7 years ago
MSVC 2017. See also [mosra/magnum-bootstrap#18](https://github.com/mosra/magnum-bootstrap/issues/18),
[mosra/magnum#343](https://github.com/mosra/magnum/pull/343) and
[mosra/magnum#354](https://github.com/mosra/magnum/issues/354).
- When using Magnum as a CMake subproject, it now puts all binaries into a
common directory to simplify `PATH` handling and dynamic plugin loading.
For more information see @ref cmake-subproject,
[mosra/magnum#357](https://github.com/mosra/magnum/issues/357) and
[mosra/magnum-plugins#63](https://github.com/mosra/magnum-plugins/issues/63).
- New @ref Image::pixels(), @ref ImageView::pixels() and
@ref Trade::ImageData::pixels() accessors for convenient direct access to
pixel data of any image
- New @ref BasicMutableImageView "MutableImageView*D" and
@ref BasicMutableCompressedImageView "MutableCompressedImageView*D" types
for mutable views onto image data
- Added sRGB BC1-3, BC4, BC5, BC6h, BC7, ETC2, EAC, 2D/3D ASTC and PVRTC
formats to @ref CompressedPixelFormat as well as their conversion to
corresponding GL/Vulkan formats in @ref GL::compressedPixelFormat() and
@ref Vk::vkFormat(Magnum::CompressedPixelFormat)
- New @ref PixelFormat::R8Srgb, @ref PixelFormat::RG8Srgb,
@ref PixelFormat::RGB8Srgb and @ref PixelFormat::RGBA8Srgb sRGB pixel
formats as well as their conversion to corresponding GL/Vulkan formats in
@ref GL::pixelFormat() and @ref Vk::vkFormat(Magnum::PixelFormat)
- New @ref compressedBlockSize() and @ref compressedBlockDataSize() utilities
for querying parameters of @ref CompressedPixelFormat entries, similar to
what @ref pixelSize() is for @ref PixelFormat
@subsubsection changelog-2019-10-new-audio Audio library
- Ability to (un)queue buffers in @ref Audio::Source (see
[mosra/magnum#338](https://github.com/mosra/magnum/pull/338))
- Added getters for basic @ref Audio::Buffer properties (see
[mosra/magnum#342](https://github.com/mosra/magnum/pull/342))
- Implemented support for @al_extension{SOFT,loop_points} in
@ref Audio::Buffer (see [mosra/magnum#342](https://github.com/mosra/magnum/pull/342))
- @ref Audio::Context can now take command-line arguments and supports
the `--magnum-log` and `--magnum-disable-extensions` options similarly to
@ref GL::Context (see
[mosra/magnum#362](https://github.com/mosra/magnum/pull/362))
@subsubsection changelog-2019-10-new-debugtools DebugTools library
- New @ref DebugTools::screenshot() function for convenient saving of
screenshots
- @ref DebugTools::CompareImage and variants now properly handle
floating-point specials such as NaN or @f$ \infty @f$ in compared data
- @ref DebugTools::CompareImageFile and @ref DebugTools::CompareImageToFile
now support the new @ref TestSuite-Tester-save-diagnostic "--save-diagnostic option",
making it possible to save images when a comparison fails
- @ref DebugTools::CompareImage and variants can now print a verbose
diagnostic also if the `--verbose` @ref TestSuite-Tester-command-line "command-line option"
is specified and comparison delta is non-zero
- @ref DebugTools::CompareImage and @ref DebugTools::CompareImageToFile now
accept also @ref Corrade::Containers::StridedArrayView2D on the left side
of the comparison for added flexibility. See
@ref DebugTools-CompareImage-pixels for more infromation.
@subsubsection changelog-2019-10-new-gl GL library
- Additions to @ref GL::CompressedPixelFormat and compressed
@link GL::TextureFormat @endlink:
- sRGB S3TC formats as defined by the @gl_extension{EXT,texture_sRGB}
desktop, @gl_extension{EXT,texture_compression_s3tc_srgb} ES and
@webgl_extension{WEBGL,compressed_texture_s3tc_srgb} WebGL extension
- Recognizing @gl_extension{EXT,texture_compression_dxt1} desktop and ES
extension and the @gl_extension2{ANGLE,texture_compression_dxt1,ANGLE_texture_compression_dxt} /
@gl_extension2{ANGLE,texture_compression_dxt3,ANGLE_texture_compression_dxt} /
@gl_extension2{ANGLE,texture_compression_dxt5,ANGLE_texture_compression_dxt}
family of extensions in order to enable S3TC formats on a wider range
of OpenGL ES devices
- Recognizing the @gl_extension{KHR,texture_compression_astc_sliced_3d}
extension
- @gl_extension{EXT,texture_compression_rgtc} /
@gl_extension{EXT,texture_compression_bptc} OpenGL ES and
@webgl_extension{EXT,texture_compression_rgtc} /
@webgl_extension{EXT,texture_compression_bptc} WebGL extensions,
complementing the desktop support for BC4, BC5, BC6H and BC7 formats
- @webgl_extension{WEBGL,texture_compression_astc} WebGL extension,
complementing the desktop and ES support for ASTC
- @gl_extension{OES,texture_compression_astc} OpenGL ES extension, adding
3D ASTC compression (unfortunately there's no desktop equivalent yet)
- PVRTC formats defined by the @gl_extension{IMG,texture_compression_pvrtc}
/ @gl_extension{IMG,pvrtc_sRGB} OpenGL ES and
@webgl_extension{WEBGL,compressed_texture_pvrtc} WebGL extensions
- Implemented @gl_extension{EXT,texture_sRGB_R8} and
@gl_extension{EXT,texture_sRGB_RG8} extensions adding
@ref GL::TextureFormat::SR8 and @ref GL::TextureFormat::SRG8 formats to
complement new sRGB formats in @ref GL::PixelFormat
- Added ES-only @ref GL::TextureFormat::BGRA and @ref GL::TextureFormat::BGRA8
and clarified their purpose in relation to @ref GL::PixelFormat::BGRA
- New @ref GL::AbstractFramebuffer::implementationColorReadFormat() and
@ref GL::AbstractFramebuffer::implementationColorReadType() queries for
more robust checks when doing framebuffer readbacks; together with three
new workarounds @cpp "nv-implementation-color-read-format-dsa-broken" @ce,
@cpp "intel-windows-implementation-color-read-format-completely-broken" @ce
and @cpp "mesa-implementation-color-read-format-dsa-explicit-binding" @ce,
because it's 2019 and GL drivers are *still* awful. See
@ref opengl-workarounds for more information.
- Added @ref GL::BufferTexture::size() as it was the only texture type were
this query was missing.
- New @cpp "swiftshader-no-es2-draw-instanced-entrypoints" @ce and
@cpp "swiftshader-no-es2-oes-texture-3d-entrypoints" @ce workarounds
disabling @gl_extension{ANGLE,instanced_arrays} and
@gl_extension{OES,texture_3D} extensions on SwiftShader due to missing
suffixed entry points. See @ref opengl-workarounds for more information.
- New @cpp "swiftshader-broken-xfb-buffer-binding-target" @ce workaround
that's fixing misbehaving buffers when using
@ref GL::Buffer::TargetHint::TransformFeedback. See @ref opengl-workarounds
for more information.
- New pseudo-extension `GL_MAGNUM_shader_vertex_id` denoting support of the
@glsl gl_VertexID @ce shader builtin. Present on all GL 3.0+, GLES 3.0+ and
WebGL 2 contexts, but disabled for SwiftShader as its support is broken
(see the @cpp "swiftshader-broken-shader-vertex-id" @ce workaround in
@ref opengl-workarounds for more information). This pseudo-extension can be
also explicitly disabled using the usual `--magnum-disable-extensions`
@ref GL-Context-command-line "command-line option" for testing purposes.
- An assorted collection of workarounds for Intel Windows drivers "fixing"
various issues related to @gl_extension{ARB,direct_state_access} by using a
non-DSA code path in the affected cases --- see
@ref opengl-workarounds for more information:
- @cpp "intel-windows-buggy-dsa-bufferdata-for-index-buffers" @ce
fixing a nasty hard-to-reproduce synchronization bug when
@ref GL::Buffer::setData() is followed by
@ref GL::Mesh::setIndexBuffer()
- @cpp "intel-windows-broken-dsa-for-cubemaps" @ce fixing everything
about @ref GL::CubeMapTexture (see [mosra/magnum-examples#55](https://github.com/mosra/magnum-examples/issues/55))
- @cpp "intel-windows-half-baked-dsa-texture-bind" @ce fixing texture
binding inconsistencies (affected [mosra/magnum-examples#55](https://github.com/mosra/magnum-examples/issues/55)
as well)
- @cpp "intel-windows-broken-dsa-layered-cubemap-array-framebuffer-attachment" @ce
fixing @ref GL::Framebuffer::attachLayeredTexture() with
@ref GL::CubeMapTextureArray
- @cpp "intel-windows-broken-dsa-framebuffer-clear" @ce
fixing @ref GL::Framebuffer::clearColor()
- @cpp "intel-windows-broken-dsa-indexed-queries" @ce fixing
@ref GL::PrimitiveQuery::begin(UnsignedInt)
- @cpp "intel-windows-broken-dsa-integer-vertex-attributes" @ce fixing
@ref GL::Mesh::addVertexBuffer() with @ref Magnum::Short "Short"
attributes
- New AMD Windows driver workarounds, related to
@gl_extension{ARB,direct_state_access} as well --- see
@ref opengl-workarounds for more information:
- @cpp "amd-windows-cubemap-image3d-slice-by-slice" @ce for broken
handling of cube map image download and upload in DSA APIs
- @cpp "amd-windows-broken-dsa-cubemap-copy" @ce for broken
framebuffer-to-cubemap copies in DSA APIs
- @cpp "amd-windows-dsa-createquery-except-xfb-overflow" @ce using a
non-DSA code path for creating
7 years ago
@ref GL::PrimitiveQuery::Target::TransformFeedbackOverflow queries
- New @cpp "arm-mali-timer-queries-oom-in-shell" @ce workaround for
@ref GL::Context::DetectedDriver::ArmMali "ARM Mali" drivers on Android
disabling the @gl_extension{EXT,disjoint_timer_query} extension in Android
shell (as opposed to an APK) because using it causes the
@ref GL::Renderer::Error::OutOfMemory error. See @ref opengl-workarounds
for more information.
- Implemented @webgl_extension{EXT,disjoint_timer_query} and
@webgl_extension{EXT,disjoint_timer_query_webgl2} for WebGL, together with
a new @cpp "firefox-fake-disjoint-timer-query-webgl2" @ce workaround. See
@ref opengl-workarounds, @ref platforms-html5-webgl-timer-queries and
@ref platforms-html5-webgl-queries-zero for more information about various
caveats.
- Explicitly calling @cpp glEnable(GL_POINT_SPRITE) @ce on compatibility
contexts in order to ensure the GLSL @cpp gl_PointCoord @ce variable has
a defined output. On core and ES/WebGL contexts this is enabled implicitly,
but for example NVidia drivers have @cpp gl_PointCoord @ce undefined when
`GL_POINT_SPRITE` is not enabled on compatibility contexts.
- New `--magnum-gpu-validation` @ref GL-Context-command-line "command-line option"
and a corresponding environment variable to conveniently enable
@gl_extension{KHR,debug} debug output. This flag also causes
@ref Platform::Sdl2Application::GLConfiguration::Flag::Debug "GLConfiguration::Flag::Debug"
to be enabled for context creation on both windowed and windowless
applications
- Detection of SwiftShader and ARM Mali drivers with
@ref GL::Context::DetectedDriver::SwiftShader and
@ref GL::Context::DetectedDriver::ArmMali
- It's now possible to pass @ref std::initializer_list to
@ref GL::Buffer::setData() / @ref GL::Buffer::setSubData() for a succint
upload of basic types
- Added an ability to use Magnum with multiple OpenGL contexts using
@ref GL::Context::makeCurrent(), see @ref GL-Context-multiple for more
information
- @ref GL::AbstractFramebuffer::read(), @ref GL::Texture::image(),
@ref GL::Texture::subImage(), @ref GL::Texture::compressedImage(),
@ref GL::Texture::setCompressedSubImage() and equivalent APIs in other
texture classes now can read the pixels into
@ref BasicMutableImageView "MutableImageView*D" and
@ref BasicMutableCompressedImageView "MutableCompressedImageView*D" as well
- @ref GL::hasTextureFormat() and @ref GL::textureFormat() helpers for
converting @ref PixelFormat / @ref CompressedPixelFormat to
@ref GL::TextureFormat, similar to @ref GL::hasPixelFormat() /
@ref GL::pixelFormat() used for converting to @ref GL::PixelFormat
@subsubsection changelog-2019-10-new-math Math library
- @ref Math::Frustum::begin() / @ref Math::Frustum::end() accessors for
easy range-for access to @ref Math::Frustum planes
- New @ref Math::Matrix4::perspectiveProjection(const Vector2<T>&, const Vector2<T>&, T, T)
overload for calculating off-center projection matrices
- @ref Color3ub and @ref Color4ub can be printed with
@ref Corrade::Utility::Debug as actual colors using the
@ref Corrade::Utility::Debug::color modifier
- Added convenience @ref BoolVector2, @ref BoolVector3 and @ref BoolVector4
typedefs to the root namespace
- New @ref Math::IsScalar, @ref Math::IsVector, @ref Math::IsIntegral,
@ref Math::IsFloatingPoint and @ref Math::IsUnitless type traits and a
@ref Math::UnderlyingTypeOf utility
- Added batch versions of @ref Math::isInf() and @ref Math::isNan()
- Scalar and vector @ref Math::equal() and @ref Math::notEqual() which do a
component-wise comparison in the vector case, as the equality/non-equality
operators return a single @cpp bool @ce
7 years ago
- @ref Math::scatter() as an inverse operation to @ref Math::gather(), both
functions now support addressing via component indices as well
- Added @ref Math::Matrix::cofactor(), @ref Math::Matrix::comatrix() and
a new @ref Math::Matrix4::normalMatrix() accessor that implements a faster
and more robust normal matrix calculation; and mainly for testing purposes
exposed @ref Math::Matrix::adjugate() that was an internal part of
@ref Math::Matrix::inverted() before
@subsubsection changelog-2019-10-new-meshtools MeshTools library
- @ref MeshTools::duplicateInto() alternative to @ref MeshTools::duplicate()
that writes the output to an existing location
- @ref MeshTools::generateFlatNormalsInto() alternative to
@ref MeshTools::generateFlatNormals() that writes the output to an existing
location
- @ref MeshTools::generateSmoothNormals() for generating weighted smooth
normals of indexed meshes (see [mosra/magnum#229](https://github.com/mosra/magnum/pull/229))
- @cpp MeshTools::compile(const Trade::MeshData3D&, CompileFlags) @ce now
accepts optional flags to control normal generation
@subsubsection changelog-2019-10-new-platform Platform libraries
- Added @ref Platform::EmscriptenApplication, implementing a lightweight and
more flexible alternative to @ref Platform::Sdl2Application for Emscripten.
This is now the recommended application to use for WebGL builds. See
[mosra/magnum#300](https://github.com/mosra/magnum/pull/300) and
[mosra/magnum-bootstrap#17](https://github.com/mosra/magnum-bootstrap/pull/17).
- @ref Platform::Sdl2Application and @ref Platform::GlfwApplication are now
DPI-aware on Windows as well. See their documentation,
@ref platforms-windows-hidpi, [mosra/magnum#243](https://github.com/mosra/magnum/issues/243)
and [mosra/magnum#349](https://github.com/mosra/magnum/pull/349) for more
information.
- Added @ref Platform::Sdl2Application::glContext() to access the underlying
`SDL_GLContext` (see [mosra/magnum#325](https://github.com/mosra/magnum/pull/325))
- Added @ref Platform::Sdl2Application::setMinWindowSize() and
@ref Platform::Sdl2Application::setMinWindowSize() + equivalent APIs for
@ref Platform::GlfwApplication (see [mosra/magnum#335](https://github.com/mosra/magnum/pull/335))
- New [base-wxwidgets](https://github.com/mosra/magnum-bootstrap/tree/base-wxwidgets)
bootstrap project for using Magnum together with wxWidgets (see
[mosra/magnum-bootstrap#19](https://github.com/mosra/magnum-bootstrap/pull/19))
- Added @ref Platform::Sdl2Application::setWindowTitle() (and equivalents
in @ref Platform::GlfwApplication and @ref Platform::EmscriptenApplication)
for changing window title at runtime as opposed to setting them on
application startup
- Added @ref Platform::Sdl2Application::Configuration::WindowFlag::OpenGL and
@ref Platform::Sdl2Application::Configuration::WindowFlag::Vulkan "WindowFlag::Vulkan",
meant to be used together with @ref Platform::Sdl2Application::Configuration::WindowFlag::Contextless for
manual creation of OpenGL contexts and Vulkan instances
- @ref Platform::WindowlessEglApplication now uses the
@m_class{m-doc-external} [EGL_EXT_device_enumeration](https://www.khronos.org/registry/EGL/extensions/EXT/EGL_EXT_device_enumeration.txt),
@m_class{m-doc-external} [EGL_EXT_platform_base](https://www.khronos.org/registry/EGL/extensions/EXT/EGL_EXT_platform_base.txt) and
@m_class{m-doc-external} [EGL_EXT_platform_device](https://www.khronos.org/registry/EGL/extensions/EXT/EGL_EXT_platform_device.txt) extensions where
available instead of `EGL_DEFAULT_DISPLAY`, working better on headless
setups and allowing selection of an arbitrary GPU device on multi-GPU
systems
@subsubsection changelog-2019-10-new-primitives Primitives library
- @ref Primitives::circle2DSolid() and @ref Primitives::circle3DSolid()
can now generate a textured mesh
@subsubsection changelog-2019-10-new-scenegraph SceneGraph library
- Added @ref SceneGraph::AbstractObject::Type /
@ref SceneGraph::AbstractFeature::Type /
@ref SceneGraph::AbstractFeatureGroup::Type typedefs and
@ref SceneGraph::AbstractObject::Dimensions /
@ref SceneGraph::AbstractFeature::Dimensions /
@ref SceneGraph::AbstractFeatureGroup::Dimensions constants for querying
underlying type and dimension template parameters
@subsubsection changelog-2019-10-new-shaders Shaders library
- Normal texture support in @ref Shaders::Phong
- Added @ref Shaders::Generic3D::Tangent generic vertex attribute definition
- Object ID output in @ref Shaders::Flat and @ref Shaders::Phong
- Vertex color support in @ref Shaders::Flat and @ref Shaders::Phong
@subsubsection changelog-2019-10-new-text Text library
- A new @ref Text::AbstractGlyphCache base now makes @ref Text::AbstractFont
and @ref Text::AbstractFontConverter independent on the graphics API used,
meaning the @ref Text library now has just an optional dependency on
@ref GL. The @ref Text::Renderer, @ref Text::GlyphCache and
@ref Text::DistanceFieldGlyphCache classes are now built only if
`TARGET_GL` is enabled (done by default).
- New @ref Text::AbstractFont::setFileCallback() to allow opening multi-file
fonts with an API similar to @ref Trade::AbstractImporter
@subsubsection changelog-2019-10-new-trade Trade library
- The @ref magnum-imageconverter "magnum-imageconverter" utility now
implements new `-i` / `--importer-options` and `-c` / `--converter-options`
command-line options for setting plugin-specific configuration
@subsection changelog-2019-10-changes Changes and improvements
- The @ref ResourceManager class now accepts also
@ref Corrade::Containers::Pointer instances in addition to raw pointers
- The @ref AbstractResourceLoader::set() function now accepts also
@cpp nullptr @ce for explicitly setting @ref ResourceDataState::Loading or
@ref ResourceDataState::NotFound resources
- Added comparison operators to @ref Resource (see
[mosra/magnum#346](https://github.com/mosra/magnum/pull/346))
- @ref ImageView and @ref CompressedImageView of smaller dimension count are
now implicitly convertible to views of higher dimension count to make
slice-by-slice uploads to @ref GL::TextureArray and others easier
- @ref Image::data(), @ref CompressedImage::data() and
@ref Trade::ImageData::data() called on a r-value now return
@ref Corrade::Containers::Array instead of being deleted
- Global state used by @ref GL::Context and @ref Audio::Context is no longer
duplicated when Magnum is built statically and linked to more than one
dynamic library or executable. This works on all platforms except for
Python bindings on Windows at the moment, where the workaround is to build
both Corrade and Magnum dynamically.
- The [base-qt](https://github.com/mosra/magnum-bootstrap/tree/base-qt)
bootstrap project is fixed to use OpenGL 4.1 on macOS instead of being
stuck on 2.1 (see [mosra/magnum-bootstrap#22](https://github.com/mosra/magnum-bootstrap/issues/22))
- Since asm.js days are long over and WebAssembly supports 64-bit integers
natively, the @ref UnsignedLong and @ref Long types are now exposed on
@ref CORRADE_TARGET_EMSCRIPTEN "Emscripten" as well
7 years ago
@subsubsection changelog-2019-10-changes-animation Animation library
7 years ago
- Default extrapolation of @ref Animation::TrackView was changed from
@ref Animation::Extrapolation::Extrapolated to
@ref Animation::Extrapolation::Constant to be consistent with
@ref Animation::Track
@subsubsection changelog-2019-10-changes-audio Audio library
- The @ref Audio::AnyImporter "AnyAudioImporter" plugin now correctly
recognizes also uppercase file extensions (see
[mosra/magnum#312](https://github.com/mosra/magnum/pull/312))
@subsubsection changelog-2019-10-changes-debugtools DebugTools library
- @ref DebugTools::CompareImage, @ref DebugTools::CompareImageToFile and
other variants are now usable directly through @ref CORRADE_COMPARE_AS(),
no need to pass an explicit instance to @ref CORRADE_COMPARE_WITH() when
just the default parameters are needed
- @ref DebugTools::textureSubImage() for float textures was updated to work
with SwiftShader (which has broken @glsl gl_VertexID @ce)
@subsubsection changelog-2019-10-changes-gl GL library
- Fully dropped support for @gl_extension{EXT,direct_state_access}. All
contemporary drivers supporting @gl_extension{EXT,direct_state_access}
support the (newer and better designed) @gl_extension{ARB,direct_state_access},
while drivers that don't support the ARB version don't support the EXT
flavor either. See also [mosra/magnum#81](https://github.com/mosra/magnum/issues/81).
- Reworked @ref GL::Mesh internals to make use of
@gl_extension{ARB,direct_state_access} instead of being the last code path
stuck on @gl_extension{EXT,direct_state_access}
- @ref GL::DebugOutput::setCallback() no longer assumes the debug message
callback is called from the same thread as the one with the corresponding
GL context (which is the case on Mesa AMD drivers). The documentation was
updated to reflect that as well.
- @ref GL::AbstractTexture::unbindImage() "GL::*Texture::unbindImage()" now
uses a RGBA format instead of a single-channel format because
@ref GL::Context::DetectedDriver::ArmMali "ARM Mali" drivers complain about
R8 not being renderable (even though the format shouldn't matter when
unbinding a texture)
- The engine was silently doing an explicit initial call to @fn_gl{Viewport}
when it detected it's running under ApiTrace, because otherwise ApiTrace
would assume a zero-sized framebuffer. This behavior is no longer silent
but advertised as a @cpp "apitrace-zero-initial-viewport" @ce workaround.
See @ref opengl-workarounds for more information.
- @ref GL::OpenGLTester no longer implicitly enables @ref GL::DebugOutput as
it can be quite spammy when complex shaders or benchmarks are allowed. For
easier debugging, users are encouraged to use the new
`--magnum-gpu-validation` @ref GL-Context-command-line "command line option"
instead.
- Added an ability to create @ref GL::DynamicAttribute directly from a
@ref GL::Attribute
@subsubsection changelog-2019-10-changes-math Math library
7 years ago
- @ref Math::BoolVector now implements component-wise @cpp && @ce,
@cpp || @ce and @cpp ! @ce for better consistency with boolean operations
done on scalar types
- Construction using @ref Math::ZeroInit and @ref Math::IdentityInit is
now explicit, to be consistent with @ref Math::NoInit construction and
avoid ambiguous cases
- All scalar/vector functions in the @ref Math namespace now work also with
special types such as @ref Deg or @ref Rad --- the only exception is
power functions such as @ref Math::sqrt() or @ref Math::log(), as the
resulting unit can't be represented. Those accept only unitless types.
- All batch functions in @ref Magnum/Math/FunctionsBatch.h now accept
@ref Corrade::Containers::StridedArrayView instead of a dense array view to
make them usable in more contexts
- @ref Math::Vector::min(), @ref Math::Vector::max(),
@ref Math::Vector::minmax() and batch
@ref Math::min(const Containers::StridedArrayView1D<const T>&),
@ref Math::max(const Containers::StridedArrayView1D<const T>&) and
@ref Math::minmax(const Containers::StridedArrayView1D<const T>&) functions now
ignore NaNs in the data, if possible. Use
@ref Math::isNan(const Vector<size, T>&) or the batch
@ref Math::isNan(const Containers::StridedArrayView1D<const T>&) to detect
presence of NaN values if needed.
- Changed the way @ref Math::operator<<(Corrade::Utility::Debug&, const BoolVector<size>&)
works --- the output now has the same bit order as when constructing it
using binary literals
- @ref Math::sincos() now uses the `__builtin_sincos` intrinsic on GCC,
making it potentially faster in case the optimizer doesn't figure out the
same
- @ref Math::Vector::operator-() and @ref Math::Vector2::perpendicular() are
now enabled only for signed types to prevent accidents
7 years ago
@subsubsection changelog-2019-10-changes-meshtools MeshTools library
- @ref MeshTools::fullScreenTriangle() was updated to work on ES3 SwiftShader
contexts (which have broken @glsl gl_VertexID @ce)
- @ref MeshTools::interleave() and @ref MeshTools::interleaveInto() now works
also with @ref Corrade::Containers::ArrayView,
@ref Corrade::Containers::StridedArrayView and friends
@subsubsection changelog-2019-10-changes-shaders Shaders library
- All shaders now have rendering output tests, making them more robust for
future additions and refactorings. See also [mosra/magnum#382](https://github.com/mosra/magnum/pull/382).
- @ref Shaders::Phong now clamps the specular factor to minimize artifacts
when shininess is near zero
- @ref Shaders::Phong can now handle zero lights, in which case its output is
equivalent to @ref Shaders::Flat3D. See @ref Shaders-Phong-zero-lights for
more information.
- @ref Shaders::MeshVisualizer is fixed to work properly on Intel Windows
drivers, adding a new
@cpp "intel-windows-explicit-uniform-location-is-less-explicit-than-you-hoped" @ce
workaround
@subsubsection changelog-2019-10-changes-texturetools TextureTools library
- @ref TextureTools::DistanceField was updated to work on ES3 SwiftShader
contexts (which have broken @glsl gl_VertexID @ce)
@subsubsection changelog-2019-10-changes-platform Platform libraries
- @ref Platform::Sdl2Application::anyEvent() is now fired also for window
events that are not exposed through
@ref Platform::Sdl2Application::viewportEvent() "viewportEvent()" or
@ref Platform::Sdl2Application::exitEvent() "exitEvent()"
- On OpenGL ES builds, @ref Platform::Sdl2Application now tells SDL whether
to use a system GL driver or a dedicated GLES driver based on whether
@ref MAGNUM_TARGET_DESKTOP_GLES is defined. This allows for a smoother
experience for example when using ANGLE on Windows. See
@ref Platform-Sdl2Application-usage-gles for more information.
- Replaced uses of `Pointer_stringify()` in @ref Platform::Sdl2Application
which was removed in Emscripten 1.38.27
- @ref Platform::Sdl2Application and all Emscripten markup was updated to
work correctly both with the
[`-s DISABLE_DEPRECATED_FIND_EVENT_TARGET_BEHAVIOR=1`](https://github.com/emscripten-core/emscripten/pull/7977)
option available since Emscripten 1.38.27 and with older versions
- @ref Platform::WindowlessEglApplication was adapted to properly create
WebGL 2 contexts both in Emscripten 1.38.24 and in older versions
- @ref Platform::Sdl2Application::exit() and
@ref Platform::GlfwApplication::exit() now have an optional parameter to
specify the actual application return code (see
[mosra/magnum#332](https://github.com/mosra/magnum/pull/332))
- @ref Platform::Sdl2Application::mainLoopIteration() now returns a
@cpp bool @ce to indicate if the application should exit
- @ref Platform::GlfwApplication, @ref Platform::EmscriptenApplication and
@ref Platform::AndroidApplication now implement
@ref Platform::GlfwApplication::MouseMoveEvent::relativePosition() as well
for better compatibility with @ref Platform::Sdl2Application. The relative
position is not supplied by the underlying toolkits, so it's emulated on
the application side.
- Extended @ref Platform::BasicScreen with
@ref Platform::BasicScreen::mouseScrollEvent() "mouseScrollEvent()",
@ref Platform::BasicScreen::textInputEvent() "textInputEvent()" and
@ref Platform::BasicScreen::textEditingEvent() "textEditingEvent()" on
application implementations that provide such events
- @ref Platform::BasicScreenedApplication is now available also for
@ref Platform::AndroidApplication
7 years ago
- New @ref Platform::BasicScreen::BasicScreen(BasicScreenedApplication<Application>&, PropagatedEvents)
constructor that directly adds the newly-created screen to an application
in a RAII manner, without needing to explicitly call
@ref Platform::BasicScreenedApplication::addScreen() and
@ref Platform::BasicScreen::setPropagatedEvents() later
- @ref Platform::BasicScreen::application() now returns a reference instead
of a pointer, checking that the screen is actually added to the
application. Users are encouraged to call
@ref Platform::BasicScreen::hasApplication() to check if the application is
accessible.
@subsubsection changelog-2019-10-changes-text Text library
- For consistency with @ref Trade::AbstractImporter, @ref Text::AbstractFont
now doesn't fail when opening empty files --- instead this is handled in
the particular plugin implementations
- @ref Text::AbstractFont::size(), @ref Text::AbstractFont::ascent(),
@ref Text::AbstractFont::descent() and @ref Text::AbstractFont::lineHeight()
now expect that a font is opened, consistently with other accessor
functions
@subsubsection changelog-2019-10-changes-trade Trade library
- The @ref Trade::AnyImageImporter "AnyImageImporter",
@ref Trade::AnyImageConverter "AnyImageConverter" and
@ref Trade::AnySceneImporter "AnySceneImporter" plugins now correctly
recognize also uppercase file extensions (see
[mosra/magnum#312](https://github.com/mosra/magnum/pull/312))
- @ref Trade::TgaImporter "TgaImporter" now properly reports an error message
when opening an empty file
- @ref Trade::AbstractImporter::setFileCallback() now accepts callbacks with
@cpp const @ce references to user data as well
- @ref Trade::AnyImageImporter "AnyImageImporter" and
@ref Trade::AnyImageConverter "AnyImageConverter" plugins now recognize
Basis Universal files (see [mosra/magnum#370](https://github.com/mosra/magnum/pull/370))
@subsection changelog-2019-10-buildsystem Build system
- @ref building-packages-msys "MSYS2 packages" are now in official
repositories, installable directly via `pacman`
- Plugin search path on Windows is now discovered relative to location of the
@ref Trade, @ref Text or @ref Audio library DLL instead of executable
location. That makes it behave better in case Magnum is installed via a
package and the installation directory hardcoded at build time doesn't
exist on the target machine (which is the case of MSYS2 packages).
- `FindSDL2.cmake` was updated to work with MinGW version 2.0.5 and newer,
since these dropped the old directory hierarchy. Older versions have both
the original and the new hierarchy, so it should work with these as well.
- When using Magnum as a CMake subproject, @ref Platform::GlfwApplication and
@ref Platform::Sdl2Application now copy the GLFW / SDL2 DLLs to
`CMAKE_RUNTIME_OUTPUT_DIRECTORY` (if set) as a post-build step. The DLL
location, if found, is also available through `GLFW_DLL` and
`SDL2_DLL_RELEASE` / `SDL2_DLL_DEBUG` variables for use by 3rd party code.
See also [mosra/magnum#347](https://github.com/mosra/magnum/pull/347) for
more information.
- Updated *extremely* outdated Emscripten boilerplate from the
[base-emscripten bootstrap project](https://github.com/mosra/magnum-bootstrap/tree/base-emscripten)
(the HTML markup was unchanged since 2013, heh)
- ES 2.0 and ES 3.0 subset of tests requiring GL context is now run on Travis
CI using SwiftShader for better code coverage (see
[mosra/magnum#207](https://github.com/mosra/magnum/issues/207))
- On CMake 3.13 and up, WebGL2 build on Emscripten (and the `-s USE_WEBGL2=1`
flag in particular) is now handled by the `FindOpenGLES3.cmake` module
and the new `INTERFACE_LINK_OPTIONS` property instead of `FindMagnum.cmake`. On older versions this is handled in `FindMagnum.cmake` by modifying the
global `CMAKE_EXE_LINKER_FLAGS` variable.
- It's now possible to use Magnum as a CMake subproject also when building
for Emscripten (see [mosra/magnum#219](https://github.com/mosra/magnum/issues/219))
- Updated the Vcpkg package to work correctly with Vcpkg's own SDL2 (see
[Microsoft/vcpkg#5730](https://github.com/Microsoft/vcpkg/pull/5730))
- Updated bundled GL headers to properly define the `GL_VERSION_*` macros to
avoid conflicting `GLintptr` and `GLsizeiptr` type definitions on Windows
when using Magnum together with Qt
- It's now possible to override CMake's
[OpenGL_GL_PREFERENCE](https://cmake.org/cmake/help/v3.11/module/FindOpenGL.html#linux-specific)
from outside on systems where GLVND doesn't work properly (before the build
scripts and `FindMagnum.cmake` always forced GLVND)
- `FindMagnum.cmake` now correctly finds debug versions of statically built
plugins when using Vcpkg
- `FindEGL.cmake`, `FindOpenAL.cmake`, `FindOpenGLES2.cmake` and
`FindOpenGLES3.cmake` now explicitly link to the `GL` and `openal`
libraries on Emscripten, which is needed for `MINIMAL_BUILD`
- `FindOpenGLES2.cmake` and `FindOpenGLES3.cmake` don't require GL ES headers
to be installed on the system anymore, as Magnum uses its own copies
- Fixed linking of static `Any*` plugins when the libraries are otherwise
build as dynamic
- Removed mention of the outdated Ubuntu PPA from @ref building as it doesn't
seem to be maintained anymore (see
[mosra/magnum-examples#61](https://github.com/mosra/magnum-examples/issues/61))
- Worked around a bug in the NVCC compiler on Windows involving
@ref Math::RectangularMatrix::DiagonalSize to make Magnum usable with CUDA
(see [mosra/magnum#345](https://github.com/mosra/magnum/issues/345))
- Fixed a 64-to-32-bit conversion warning on MSVC in @ref GL::Mesh internals
(see [mosra/magnum#352](https://github.com/mosra/magnum/issues/352))
- Emscripten builds now have the `-fPIC` option disabled by default as it
causes linker errors related to `__memory_base` on 1.38.36 (see also
[emscripten-core/emscripten#8761](https://github.com/emscripten-core/emscripten/issues/8761))
- Fixed the `Magnum::Application`, `Magnum::WindowlessApplication` and
`Magnum::GLContext` aliases in `FindMagnum.cmake` to propagate the values
from the target they alias also across directories, instead of failing with
e.g.
Error evaluating generator expression:
$<TARGET_PROPERTY:Magnum::Sdl2Application,INTERFACE_INCLUDE_DIRECTORIES>
Target "Magnum::Sdl2Application" not found.
@subsection changelog-2019-10-bugfixes Bug fixes
- Fixed compilation of the @ref Vk library on 32-bit Windows
- @ref Math::pack() was incorrectly not selecting the nearest integral value,
causing @ref Math::Color3::toSrgbInt() to not roundtrip, among other
things.
- The @cb{.cmake} android_create_apk() @ce macro for
@ref platforms-android-apps-cmake "Gradle-less Android builds" now properly
creates the library output directory beforehand
- Fixed a bad interaction of @ref GL::Mesh and @ref GL::Buffer state trackers
resulting in corrupted rendering on ES/WebGL platforms and systems without
@gl_extension{ARB,direct_state_access}
- Fixed @ref GL::Mesh instanced drawing to properly take into account all
five @gl_extension{ANGLE,instanced_arrays},
@gl_extension{EXT,instanced_arrays}, @gl_extension{EXT,draw_instanced},
@gl_extension{NV,instanced_arrays} and @gl_extension{NV,draw_instanced}
extensions
- @ref Platform::GLContext would crash on destruction if it was constructed
with @ref NoCreate but @ref Platform::GLContext::create() was never called
(see [mosra/magnum#331](https://github.com/mosra/magnum/pull/331)
- Reading of float textures on ES3 contexts using
@ref DebugTools::textureSubImage() returned a zero-sized image by accident
- @ref MeshTools::compile() was producing an incorrect mesh when
@cpp Trade::MeshData @ce had both colors and texture coordinates
- Properly zero-initializing the UTF-8 buffer in
@ref Platform::GlfwApplication::textInputEvent() (see
[mosra/magnum#324](https://github.com/mosra/magnum/pull/324))
- @ref Platform::Sdl2Application::viewportEvent() and
@ref Platform::GlfwApplication::viewportEvent() is fixed to behave
correctly with @ref platforms-macos-hidpi "Retina-aware" apps on macOS/iOS
7 years ago
- @ref Text::AbstractFontConverter::exportFontToFile() and
@ref Text::AbstractFontConverter::exportGlyphCacheToFile() now properly
returns failure when the underlying data export function returns an empty
list of files
- Updated the `base-qt` bootstrap project to correctly reset state tracker
when going from and back to Qt code, and to use the framebuffer provided by
Qt instead of @ref GL::defaultFramebuffer (see
[mosra/magnum#322](https://github.com/mosra/magnum/issues/322) and
[mosra/magnum-bootstrap#15](https://github.com/mosra/magnum-bootstrap/pull/15))
- @ref Trade::TgaImporter "TgaImporter" now properly handles files with too
short data (see [mosra/magnum#359](https://github.com/mosra/magnum/issues/359))
- When context creation fails *really bad* with
@ref Platform::Sdl2Application, @ref Platform::GlfwApplication,
@ref Platform::WindowlessGlxApplication or
@ref Platform::WindowlessWglApplication, driver detection for the
@cpp "no-forward-compatible-core-context" @ce now properly handles
@fn_gl{GetString} returning a @cpp nullptr @ce
- @ref GL::Texture::imageSize() was present on WebGL 2 by mistake (see
[mosra/magnum#365](https://github.com/mosra/magnum/pull/365))
- @ref GL::BufferTexture::setBuffer() now creates the passed buffer if not
already (and if it was not created by @fn_gl{CreateBuffers}). Before that,
passing a freshly created @ref GL::Buffer to it was causing
@ref GL::Renderer::Error::InvalidOperation on systems without
@gl_extension{ARB,direct_state_access}.
- Fixed @ref Shaders::Vector and @ref Shaders::DistanceFieldVector to work
on iOS, which has only 8 texture binding slots in total (see
[mosra/magnum-examples#65](https://github.com/mosra/magnum-examples/issues/65)
and [mosra/magnum#374](https://github.com/mosra/magnum/pull/374))
@subsection changelog-2019-10-docs Documentation
- Extended @ref platforms-html5-code-size "Emscripten" documentation with
available compiler switches for code size / compile time tradeoffs (instead
of unconditionally enabling them by default, see
[mosra/magnum#211](https://github.com/mosra/magnum/issues/211))
- Fixed Gentoo build instructions (see
[mosra/magnum#344](https://github.com/mosra/magnum/pull/344))
- Various documentation improvements and copy editing (see
[mosra/magnum#341](https://github.com/mosra/magnum/issues/341),
[mosra/magnum#361](https://github.com/mosra/magnum/pull/361))
- Populating the Troubleshooting section of
@ref platforms-windows "Windows-specific platform notes" (see
[mosra/magnum#355](https://github.com/mosra/magnum/issues/355))
- Extended info about the `--head` option in @ref building-packages-vcpkg
(see [mosra/magnum#367](https://github.com/mosra/magnum/issues/367))
- The @ref getting-started "Getting Started Guide" was rewritten to be easier
to follow for Windows users, removing usual pain points (see
[mosra/magnum#377](https://github.com/mosra/magnum/issues/377) and
[mosra/magnum#378](https://github.com/mosra/magnum/issues/378))
@subsection changelog-2019-10-deprecated Deprecated APIs
- @cpp Math::Color3::Hsv @ce and @cpp Math::Color4::Hsv @ce tuple typedefs
are deprecated in favor of tuple-less @ref Math::ColorHsv, working
correctly with the usual @ref Math::NoInit / @ref Math::ZeroInit tags while
being faster to compile
- @cpp Math::Frustum::planes() @ce are deprecated due to redundancy, use
either @ref Math::Frustum::operator[](), @ref Math::Frustum::data() or
range access using @ref Math::Frustum::begin() / @ref Math::Frustum::end()
- Batch @ref Math::min(const Containers::StridedArrayView1D<const T>&),
@ref Math::max(const Containers::StridedArrayView1D<const T>&) and
@ref Math::minmax(const Containers::StridedArrayView1D<const T>&) are moved
to a new @ref Magnum/Math/FunctionsBatch.h header in order to speed up
compile times. This header is included from @ref Magnum/Math/FunctionsBatch.h
when building with @ref MAGNUM_BUILD_DEPRECATED enabled, include it
explicitly to ensure forward compatibility
- @cpp Trade::ImporterFileCallbackPolicy @ce is deprecated as it was moved
to @ref InputFileCallbackPolicy in the root namespace to be shared with
APIs outside of the @ref Trade namespace. Moreover,
@cpp InputFileCallbackPolicy::LoadPernament @ce is deprecated due to a
typo, use @ref InputFileCallbackPolicy::LoadPermanent instead.
- @cpp DebugTools::ForceRendererOptions::scale() @ce is deprecated in favor
of @ref DebugTools::ForceRendererOptions::size(), as that's more consistent
with the documentation and the corresponding setter.
- @cpp Text::AbstractFont::openSingleData() @ce and
@cpp Text::AbstractFont::openData() @ce taking a list of files are
deprecated in favor of
@ref Text::AbstractFont::openData(Containers::ArrayView<const char>, Float)
and @ref Text::AbstractFont::setFileCallback()
- @ref GL::Buffer::setData() and @ref GL::Buffer::setSubData() no longer has
overloads taking @ref std::vector / @ref std::array, but instead relies on
@ref Corrade/Containers/ArrayViewStl.h to provide conversion from these to
@ref Corrade::Containers::ArrayView. This header is included automatically
when @ref MAGNUM_BUILD_DEPRECATED is enabled, include it explicitly to stay
forward compatible.
- @cpp GL::TextureFormat::R3B3G2 @ce had a misleading typo in the name, use
@ref GL::TextureFormat::R3G3B2 instead.
- @ref GL::AbstractTexture destructor is now @cpp protected @ce on builds
with @ref MAGNUM_BUILD_DEPRECATED disabled in order to avoid accidents with
subclass destructors not being called. Right now all subclasses themselves
have trivial destruction, but that may change in the future due to driver
workarounds being added.
- @cpp Magnum/MeshTools/GenerateFlatNormals.h @ce is deprecated, use
@ref Magnum/MeshTools/GenerateNormals.h instead
- @cpp MeshTools::generateFlatNormals(const std::vector<UnsignedInt>&, const std::vector<Vector3>&) @ce
is deprecated for doing too many things at once and being too tied to one
particular STL container, use @ref MeshTools::generateFlatNormals(const Containers::StridedArrayView1D<const Vector3>&)
instead
- Templated versions of @ref Image::data(), @ref ImageView::data(),
@ref CompressedImage::data(), @ref CompressedImageView::data() and
@ref Trade::ImageData::data() that returned a raw pointer are deprecated,
use the non-templated version together with
@ref Corrade::Containers::arrayCast() instead for properly bounds-checked
type conversion
- Passing @cpp nullptr @ce to @ref ImageView constructors is deprecated and
will print a warning at runtime. Use a constructor without the @p data
parameter instead.
- The @cpp ResourceManager::instance() @ce singleton (and its implicit use in
@ref DebugTools::ForceRenderer and @ref DebugTools::ObjectRenderer) is
deprecated as it makes some use cases harder than they should be. Make your
own singleton or explicitly pass a @ref ResourceManager reference around
instead.
- @ref Platform::BasicScreen::application() now returns a reference instead
of a pointer and together with @ref Platform::BasicScreen::redraw() checks
that the screen is actually added to the application instead of returning
@cpp nullptr @ce (and requiring excessive error checking in user code) or,
in case of @ref Platform::BasicScreen::redraw() "redraw()" silently doing
the wrong thing. For backwards compatibility
@ref Platform::BasicScreenedApplication is convertible to a pointer and
implements @cpp operator-> @ce, but this conversion is deprecated.
- @cpp Math::swizzle() @ce is deprecated, use @ref Math::gather() instead as
that fits better with the new @ref Math::scatter()
@subsection changelog-2019-10-compatibility Potential compatibility breakages, removed APIs
- Configuration value parsers and writers for @ref Math types were moved to
a dedicated @ref Magnum/Math/ConfigurationValue.h header in order to speed
up compile times. Backwards compatibility is not provided, when using
@ref Math types with @ref Corrade::Utility::Configuration or
@ref Corrade::Utility::Arguments you have to include the header explicitly
- @ref Audio::Extension::extensions() and @ref GL::Extension::extensions()
now return a @ref Corrade::Containers::ArrayView instead of a reference to
@ref std::vector in order to reduce binary bloat and compile times
- Removed all aliases to @ref GL library functionality in the root namespace
(and root include path) which were deprecated in 2018.04 and everything
related to this change:
- @cpp GL::Mesh::IndexType @ce and @cpp GL::Mesh::indexSize() @ce,
use @ref GL::MeshIndexType and @ref GL::Mesh::indexTypeSize() instead
- Removed @cpp Primitives::Capsule2D @ce, @cpp Primitives::Capsule3D @ce,
@cpp Primitives::Circle @ce, @cpp Primitives::Crosshair2D @ce,
@cpp Primitives::Crosshair3D @ce, @cpp Primitives::Cube @ce,
@cpp Primitives::Cylinder @ce, @cpp Primitives::Icosphere @ce,
@cpp Primitives::Line @ce, @cpp Primitives::Plane @ce,
@cpp Primitives::Square @ce and @cpp Primitives::UVSphere @ce classes
deprecated in 2018.04. The same functionality is available through free
functions in the @ref Primitives namespace, use those instead.
- Removed templated overloads of @ref GL::Buffer::data(),
@ref GL::Buffer::subData() and @ref GL::Buffer::map() deprecated
since 2017. Use the non-templated versions together with
@ref Corrade::Containers::arrayCast().
- Removed @cpp GL::Context::DetectedDriver::AMD @ce and
@cpp GL::Context::DetectedDriver::ProbablyAngle @ce aliases deprecated
since 2017, use consistently-named @ref GL::Context::DetectedDriver::Amd
and @ref GL::Context::DetectedDriver::Angle instead
- Removed @cpp GL::CubeMapTexture::Coordinate @ce deprecated since 2016, use
@ref GL::CubeMapCoordinate instead
- Removed remaining @ref Platform::Sdl2Application "Platform::*Application"
constructors taking @cpp nullptr @ce instead of @ref NoCreate, deprecated
since 2017
- Removed compatibility code in @ref Audio::Context where
@ref Audio::Context::current() would be usable with both @cpp . @ce and
@cpp -> @ce, deprecated since 2017
- Removed @cpp Audio::Context::hrtfSpecifier() @ce deprecated since 2018.02.
Use @ref Audio::Context::hrtfSpecifierString() instead.
- Removed the `Shapes` library together with `DebugTools::ShapeRenderer`,
which was a failed design experiment deprecated since version 2018.10
(see [mosra/magnum#148](https://github.com/mosra/magnum/issues/148))
- Removed the `Platform::GlutApplication` as it was based on an outdated
toolkit and deprecated since version 2018.10 (see
[mosra/magnum#148](https://github.com/mosra/magnum/issues/148) and
[mosra/magnum#195](https://github.com/mosra/magnum/pull/195))
- 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
@cb{.html} <canvas id="canvas"> @ce instead of
@cb{.html} <canvas id="module"> @ce
- in case you have a copy or a fork of the JS driver file, it needs to
define @cb{.js} Module.canvas @ce as
@cb{.js} document.getElementById('canvas') @ce (instead of
@cb{.js} 'module' @ce)
- and for CSS files, all references to @cb{.css} #module @ce need to be
@cb{.css} #canvas @ce now
- The `BUILD_MULTITHREADED` CMake option and `MAGNUM_BUILD_MULTITHREADED`
CMake / preprocessor variable has been moved to Corrade --- you need to
toggle it when building Corrade and use @ref CORRADE_BUILD_MULTITHREADED
instead
- @ref PixelFormat and @ref CompressedPixelFormat now reserve the zero value
to indicate an invalid format, better catching accidentally forgotten
initialization. Valid code shouldn't be affected by this change, but broken
code that seemingly worked before might start throwing assertions now.
- @ref Shaders::MeshVisualizer now asserts if its wireframe-related setters
are called when the @ref Shaders::MeshVisualizer::Flag::Wireframe flag was
not set, consistently with other shaders. This might cause failures in code
that was calling them unnecessarily before.
@section changelog-2019-01 2019.01
Released 2019-02-04, tagged as
[v2019.01](https://github.com/mosra/magnum/releases/tag/v2019.01).
@subsection changelog-2019-01-dependencies Dependency changes
- Minimal supported GCC version is now 4.8.1, GCC 4.7 is not supported
anymore. Minimal Clang version is now 3.3, since that's the first version
with a complete C++11 support. See also
[mosra/magnum#274](https://github.com/mosra/magnum/issues/274).
- Minimal supported CMake version is now 3.1. Older versions are not
supported anymore and all workarounds for them were removed. Download a
prebuilt release of a newer version if you need to use Corrade on older
systems (such as Ubuntu 14.04 or Debian 8). See also
[mosra/magnum#274](https://github.com/mosra/magnum/issues/274).
@subsection changelog-2019-01-new New features
@subsubsection changelog-2019-01-new-animation Animation library
- New @ref Animation::Easing namespace with a collection of well-documented
easing functions
- New @ref Animation::ease(), @ref Animation::easeClamped(),
@ref Animation::unpack(), @ref Animation::unpackEase() and
@ref Animation::unpackEaseClamped() utilities for combining interpolators
with easing functions and/or unpackers
- @ref Animation::Player::resume() that acts the same as
@ref Animation::Player::play() "play()" except it doesn't restart the
animation from the start if it is already playing
- Added @ref Animation::Player::advance(T, std::initializer_list<Containers::Reference<Player<T, K>>>)
for advancing multiple players at the same time
@subsubsection changelog-2019-01-new-math Math library
- Support for using the @ref Math::Deg, @ref Math::Rad, @ref Math::Half,
@ref Math::Color3 and @ref Math::Color4 literals with the new experimental
@ref Corrade::Utility::Tweakable utility. See also @ref tweakableliterals.
- New @ref Math::StrictWeakOrdering functor making it possible to use Magnum
math types as keys in ordered STL containers such as @ref std::map or
@ref std::set (see also [mosra/magnum#299](https://github.com/mosra/magnum/pull/299))
@subsubsection changelog-2019-01-new-platform Platform libraries
- Added @ref Platform::AndroidApplication::framebufferSize(),
@ref Platform::AndroidApplication::dpiScaling(),
@ref Platform::AndroidApplication::ViewportEvent::dpiScaling(),
@ref Platform::GlfwApplication::ViewportEvent::framebufferSize() and
@ref Platform::GlfwApplication::ViewportEvent::dpiScaling() to ensure
feature parity with @ref Platform::Sdl2Application
- Clarified HiDPI behavior of Android apps and mentioning
@ref platforms-android-apps-manifest-screen-compatibility-mode "the necessary steps"
in the docs
- Implemented handling of @ref Platform::AndroidApplication::viewportEvent()
and documenting how to get Android to call it instead of relaunching the
app from scratch
- New @ref Platform::Sdl2Application::exitEvent() and
@ref Platform::GlfwApplication::exitEvent() events for responding to
application window close and possibility to cancel it (for example to
show an exit confirmation dialog)
- New @ref Platform::Sdl2Application::anyEvent() event together with
@ref Platform::Sdl2Application::InputEvent::event() "event()" accessors to
make it possible to access raw `SDL_Event` data
@subsubsection changelog-2019-01-new-vk Vk library
- Conversion between Magnum math types and math-related Vulkan types in a
new @ref Magnum/Vk/Integration.h header
@subsection changelog-2019-01-changes Changes and improvements
@subsubsection changelog-2019-01-changes-audio Audio library
- @ref Audio::Source::play(), @ref Audio::Source::pause(),
@ref Audio::Source::rewind() and @ref Audio::Source::stop() now return
a self-reference like all other methods for easier method chaining
@subsubsection changelog-2019-01-changes-gl GL library
- Added a @cpp "nv-egl-incorrect-gl11-function-pointers" @ce workaround that
explicitly loads OpenGL 1.0 and 1.1 function pointers on contexts created
using EGL on NVidia drivers, because there functions such as
@fn_gl{GetString} behave incorrectly when linked statically. See also
[mosra/magnum#308](https://github.com/mosra/magnum/pull/308).
- New @ref GL::Context::State::BindScratchVao state to make external OpenGL
code that's not VAO-aware working on core GL profiles (which don't allow
default VAOs being used for drawing)
@subsubsection changelog-2019-01-changes-platform Platform libraries
- @ref Platform::Sdl2Application::swapBuffers(), "Platform::*Application::swapBuffers()"
@ref Platform::Sdl2Application::swapInterval() "swapInterval() const" const,
@ref Platform::Sdl2Application::setSwapInterval() "setSwapInterval()",
@ref Platform::Sdl2Application::setMinimalLoopPeriod() "setMinimalLoopPeriod()" and
@ref Platform::Sdl2Application::redraw() "redraw()" were changed from
protected to public to allow calling them from outside
@subsubsection changelog-2019-01-changes-text Text library
- The @ref Text::AbstractFont and @ref Text::AbstractFontConverter plugin
APIs now return @ref Corrade::Containers::Pointer instead of
@ref std::unique_ptr for improved compile times
@subsubsection changelog-2019-01-changes-texturetools TextureTools library
- Further performance and output quality improvements for
@ref TextureTools::DistanceField, making the ES2/WebGL 1 consistent with
desktop and speeding up the processing to take only 60% of the time
compared to before. It's now also possible to reuse the internal state for
batch processing.
@subsubsection changelog-2019-01-changes-trade Trade library
- The @ref Trade::AbstractImporter plugin API now returns
@ref Corrade::Containers::Pointer instead of @ref std::unique_ptr for
improved compile times
@subsection changelog-2019-01-buildsystem Build system
- Experimental support for creating Android APKs directly using CMake without
Gradle involved. See @ref platforms-android-apps for more information. See
7 years ago
also [mosra/toolchains#5](https://github.com/mosra/toolchains/pull/5) and
[mosra/toolchains#6](https://github.com/mosra/toolchains/pull/6).
- Initial scaffolding for [Hunter](https://hunter.sh) package support (see
[mosra/magnum#298](https://github.com/mosra/magnum/pull/298))
- The `package/msys` directory now contains `PKGBUILD`s for
[MSYS2](https://www.msys2.org/). See @ref building-packages-msys for more
information. See also [mosra/magnum#307](https://github.com/mosra/magnum/pull/307).
- The `Magnum::AndroidApplication` target was missing a few dependency
libraries when Magnum was used as a CMake subproject
- Fixed an ambiguous overload error in @ref Text::GlyphCache when compiling
this library under C++17 (see
[mosra/magnum#297](https://github.com/mosra/magnum/pull/297))
- Imroved initial Emscripten setup on Windows to be more frictionless (see
[mosra/toolchains#4](https://github.com/mosra/toolchains/pull/4))
- @ref DebugTools no longer unconditionally requires the @ref Trade library
in case @ref Corrade::TestSuite is found. The @ref DebugTools::CompareImage
documentation was updated to mention the optionality.
@subsection changelog-2019-01-bugfixes Bug fixes
- Fixed @ref Platform::Sdl2Application and @ref Platform::GlfwApplication to
properly support the @cb{.sh} $MAGNUM_DPI_SCALING @ce environment variable
as an alternative to `--magnum-dpi-scaling` command-line parameter. It was
also not documented anywhere. Besides that, the default `--magnum-dpi-scaling`
value should have been `default` as documented, not `virtual`.
- Don't assert in DPI scaling detection in @ref Platform::Sdl2Application and
@ref Platform::GlfwApplication on X11 DEs that don't create any
`RESOURCE_MANAGER` (see [mosra/magnum#290](https://github.com/mosra/magnum/issues/290))
- Properly escaping log output on Emscripten @ref Platform::WindowlessEglApplication
- The @ref GL::Context::States enum set was missing value combining operators
- Fixed @ref Text::DistanceFieldGlyphCache internal formats on ES2 devices
that support @gl_extension{EXT,texture_storage} (see
[mosra/magnum#289](https://github.com/mosra/magnum/pull/289))
- @ref PixelStorage::imageHeight() and Z value of @ref PixelStorage::skip()
was not properly handled on ES3 / WebGL 2 builds.
@subsection changelog-2019-01-docs Documentation
- Fixed various broken links (see [mosra/magnum#291](https://github.com/mosra/magnum/issues/291))
- A dedicated @ref types-thirdparty-integration section listing all
provided integrations with 3rd party math APIs
@subsection changelog-2019-01-deprecated Deprecated APIs
- All uses of @ref std::unique_ptr in @ref Text::AbstractFont,
@ref Text::AbstractFontConverter and @ref Trade::AbstractImporter are
replaced with @ref Corrade::Containers::Pointer. The types are implicitly
move-convertible to each other if the
@ref Corrade/Containers/PointerStl.h header is included. The header is
included where needed if @ref MAGNUM_BUILD_DEPRECATED is enabled. To ensure
your code keeps with future versions of Magnum, either switch your
code to use @ref Corrade::Containers::Pointer as well or include the
@ref Corrade/Containers/PointerStl.h header explicitly.
- @cpp TextureTools::distanceField() @ce is deprecated due to inefficiency of
its statelessness when doing batch processing. Use the
@ref TextureTools::DistanceField class instead.
- @cpp Platform::GlfwApplication::KeyEvent::Key::Smicolon @ce has a typo and
so is deprecated in favor of
@ref Platform::GlfwApplication::KeyEvent::Key::Semicolon
@subsection changelog-2019-01-compatibility Potential compatibility breakages, removed APIs
- The @ref MeshTools::fullScreenTriangle() function now returns just a
@ref GL::Mesh instead of @ref std::pair of a mesh and a buffer, as the
buffer is now owned by the mesh. This change was not possible to be done in
a backwards-compatible way.
- @ref Animation::Player, @ref Audio::Listener, @ref GL::AbstractShaderProgram,
@ref GL::MeshView and @ref GL::Shader APIs that take a
@ref std::initializer_list of references were changed to use
@ref Corrade::Containers::Reference instead of a @ref std::reference_wrapper.
This change should be fully transparent to the user as the type conversion
is done implicitly in both cases, but you may need to add an
@cpp #include <Corrade/Containers/Reference.h> @ce where appropriate.
- Removed deprecated implicit conversion @ref Corrade::Containers::Optional
to @ref std::optional, deprecated in January 2018. The class now contains
an *explicit* and opt-in STL compatibility, see its documentation for more
information. You may need to add an
@cpp #include <Corrade/Containers/Optional.h> @ce where appropriate.
- Removed the `Magnum/Test/AbstractOpenGLTester.h` header that was deprecated
in January 2017. Use @ref Magnum/GL/OpenGLTester.h and the
@ref GL::OpenGLTester library instead. Note that the deprecated
`Magnum/OpenGLTester.h` header is still present, along with all other
deprecated GL-specific headers and APIs in the project root.
- Removed five-argument @cpp Trade::MeshData2D @ce and six-argument
@cpp Trade::MeshData3D @ce constructors that were deprecated since February
2017. Use the full six/seven-argument versions instead.
- Removed @ref Platform application constructors taking @cpp nullptr @ce,
deprecated in June 2016 for windowless apps and in March 2017 for windowed
apps. Use constructors taking the @ref NoCreate tag instead.
- Removed availability of @ref Math::Color3 and @ref Math::Color4 literals in
the root namespace, deprecated since April 2016. Explicitly call
@cpp using namespace Math::Literals; @ce instead.
- Removed uppercase `*HSV` APIs from @ref Math::Color3 and @ref Math::Color4,
deprecated since December 2016. Use the CamelCased `*Hsv` APIs instead.
- Removed @cpp Math::normalize() @ce and @cpp Math::denormalize() @ce
functions, deprecated since December 2016. Use @ref Math::pack() and
@ref Math::unpack() instead.
- Removed @cpp Platform::*Application::MouseEvent::Button::WheelUp @ce and
@cpp Platform::*Application::MouseEvent::Button::WheelDown @ce, deprecated
since June 2016. Use the dedicated
@ref Platform::Sdl2Application::mouseScrollEvent() "mouseScrollEvent()"
API instead.
- Removed @cpp Platform::GlfwApplication::Configuration::WindowFlag::Resizeable @ce,
deprecated since February 2017. Use @ref Platform::GlfwApplication::Configuration::WindowFlag::Resizable
instead.
- Removed `MAGNUM_*_LIBRARIES` and `MAGNUM_*_INCLUDE_DIRS` CMake variables,
which were deprecated in favor of `Magnum::*` imported targets in
February 2016.
@section changelog-2018-10 2018.10
Released 2018-10-23, tagged as
[v2018.10](https://github.com/mosra/magnum/releases/tag/v2018.10).
@subsection changelog-2018-10-new New features
@subsubsection changelog-2018-10-new-animation Animation library
- New experimental @ref Animation library for keyframe-based animation
playback (see [mosra/magnum#191](https://github.com/mosra/magnum/pull/191),
[mosra/magnum#267](https://github.com/mosra/magnum/pull/267))
@subsubsection changelog-2018-10-new-debugtools DebugTools library
- New @ref DebugTools::CompareImageFile, @ref DebugTools::CompareImageToFile
and @ref DebugTools::CompareFileToImage comparators extending
@ref DebugTools::CompareImage with convenient image file loading
@subsubsection changelog-2018-10-new-gl GL library
- Exposing @ref GL::Context::Flag::ForwardCompatible through
@ref GL::Context::flags(), which was deliberately ignored before.
- New @ref GL::Renderer::lineWidthRange() limit query. The reported maximum
can be over @cpp 1.0f @ce only in non-forward-compatible contexts, a new
@cpp "mesa-forward-compatible-line-width-range" @ce workaround fixes that
for Mesa. See @ref opengl-workarounds for more information.
- Implemented the @gl_extension{ARB,sample_shading} desktop extension and the
equivalent functionality in OpenGL ES 3.2 / @gl_extension{OES,sample_shading}
ES3 extension
@subsubsection changelog-2018-10-new-math Math library
- New @ref Math::CubicHermite class for cubic Hermite spline interpolation,
convertible to and from cubic Bézier curves using
@ref Math::Bezier::fromCubicHermite() and @ref Math::CubicHermite::fromBezier()
(see [mosra/magnum#267](https://github.com/mosra/magnum/pull/267))
- Added @ref Math::Intersection::rangeFrustum(),
@ref Math::Intersection::aabbFrustum(),
@ref Math::Intersection::sphereFrustum(),
@ref Math::Intersection::pointCone(),
@ref Math::Intersection::pointDoubleCone(),
@ref Math::Intersection::sphereConeView(),
@ref Math::Intersection::sphereCone(),
@ref Math::Intersection::aabbCone(),
@ref Math::Intersection::rangeCone() (see
[mosra/magnum#226](https://github.com/mosra/magnum/pull/226))
- Added @ref Math::Matrix3::rotationShear(),
@ref Math::Matrix4::rotationShear(), @ref Math::Matrix3::scalingSquared(),
@ref Math::Matrix4::scalingSquared(), @ref Math::Matrix3::scaling() const
and @ref Math::Matrix4::scaling() const getters for extracting further
properties from the rotation/scaling part of a matrix
- Added @ref Math::Color3::fromSrgb(UnsignedInt),
@ref Math::Color4::fromSrgbAlpha(UnsignedInt),
@ref Math::Color4::fromSrgb(UnsignedInt, T), @ref Math::Color3::toSrgbInt(),
and @ref Math::Color4::toSrgbAlphaInt() for easier conversion of packed
24-/32-bit sRGB colors to and from @ref Math::Color3 / @ref Math::Color4
- Added @ref Math::lerp(const Complex<T>&, const Complex<T>&, T) and
@ref Math::slerp(const Complex<T>&, const Complex<T>&, T) for feature
parity with @ref Math::Quaternion
- Added @ref Math::lerpShortestPath(const Quaternion<T>&, const Quaternion<T>&, T),
@ref Math::slerpShortestPath(const Quaternion<T>&, const Quaternion<T>&, T)
and @ref Math::sclerpShortestPath(const DualQuaternion<T>&, const DualQuaternion<T>&, T)
variants; clarified that the original versions are explicitly *not*
shortest-path
- Added @ref Math::Range2D::x(), @ref Math::Range3D::x(),
@ref Math::Range2D::y(), @ref Math::Range3D::y(), @ref Math::Range3D::z()
and @ref Math::Range3D::xy() for slicing ranges into lower dimensions
- Added @ref Math::intersect() and @ref Math::intersects() as a counterpart
to @ref Math::join() for operating with @ref Math::Range instances
- Added @ref Math::Range::contains() overloading taking a range, in addition
to vector
- Added @ref Math::Range::fromCenter() and documented a hint how to create
integral centered ranges
- Added @ref Math::Range::scaledFromCenter() as a counterpart to
@ref Math::Range::scaled()
- @ref Math::Range is now constructible from a @ref std::pair of values,
making it usable in combination with @ref Math::minmax(), for example
- Added @ref Math::Constants::piQuarter(), @ref Math::Constants::sqrtHalf()
- Added a convenience function @ref Math::select() as a constant
interpolation counterpart to @ref Math::lerp()
- Added a convenience function @ref Math::planeEquation() to aid with passing
passing parameters to @ref Math::Intersection::planeLine(),
@ref Math::Distance::pointPlane() and others
- Ability to convert @ref Math::BoolVector from and to external
representation
- Ability to construct @ref Math::Matrix from a smaller or larger square
matrix by slicing or expanding it
- Mutable overloads for @ref Math::Complex::real(),
@ref Math::Complex::imaginary(), @ref Math::Dual::real(),
@ref Math::Dual::dual(), @ref Math::Quaternion::vector() and
@ref Math::Quaternion::scalar()
- Ability to do a component-wise multiply and divide of @ref Math::Complex
and a @ref Math::Vector2, in addition to multiplication/division with a
scalar
- Ability to use @ref Math::Complex, @ref Math::DualComplex,
@ref Math::Quaternion, @ref Math::DualQuaternion with
@ref Corrade::Utility::Configuration and @ref Corrade::Utility::Arguments
- Added @ref Math::Complex::data(), @ref Math::Quaternion::data(),
@ref Math::DualComplex::data(), @ref Math::DualQuaternion::data(),
@ref Math::Bezier::data() and @ref Math::CubicHermite::data() for simple
access to underlying memory like with other math types
- New @ref Math::min(), @ref Math::max() and @ref Math::minmax() overloads
taking plain C arrays
- Vector overloads for @ref Math::isInf() and @ref Math::isNan()
@subsubsection changelog-2018-10-new-platform Platform libraries
Platform: initial HiDPI support in SDL2 app on Linux and Emscripten. This is quite complex, actually. The end goal is: when I request an 800x600 window, it should create a window of the same physical size as an 800x600 window would have on a system default DPI. After that, the actual window size (for events), framebuffer size and DPI scaling value (to correctly scale the contents relative to window size) are platform-dependent. On macOS and iOS, the DPI scaling is done simply by having the framebuffer twice the size while the window size (for events) remains the same. Easy to support. On Linux, a non-DPI-aware app is simply having a really tiny window. The worst behavior of all systems. Next to that, SDL_GetDisplayDPI() returns physical DPI, which is quite useless as the value is usually coming from Xorg display autodetection and is usually just 96, unless one goes extra lengths and supplies a correct value via an xorg.conf. The DE is using a different, user-configurable value for scaling the visuals and this one is available through a Xft.dpi property. To get it, we dlopen() self and dlsym() X11 symbols to get this property. If this fails, it might mean the app doesn't run on X11 (maybe Wayland, maybe something's just messed up, who knows) and then we fall back to SDL_GetDisplayDPI(). Which is usually very wrong, so this is also why I'm implementing two ways to override this -- either via the app Configuration or via a command-line / environment variable. On Emscripten / HTML5, all that's needed is querying device pixel ratio and then requesting canvas size scaled by that. The event coordinates are relative to this size, so there's not much more to handle. Physical canvas size on the page is controlled via CSS, so no issues with stuff being too big or too small apply -- in the worst case, things may be blurry. On Windows, the DPI scaling is something in-between -- if the app presents itself as DPI-aware, window size is treated as real pixels (so one gets really what is asked for, i.e. an 800x600 window on a system with 240 DPI is maybe four centimeters wide). If not, the window is upscaled (and blurried) by the compositor. In order to have correct behavior, I first need to query if the app is DPI-aware and then either scale the requested size or not (to avoid extra huge windows when the app is not marked as DPI aware). That will be done in a later commit.
8 years ago
- Initial HiDPI support for Linux and Emscripten in
@ref Platform::Sdl2Application and @ref Platform::GlfwApplication
- Implemented missing resize event support in @ref Platform::Sdl2Application
on @ref CORRADE_TARGET_EMSCRIPTEN "Emscripten"
- Ability to modify CSS classes that control layout of
@ref CORRADE_TARGET_EMSCRIPTEN "Emscripten" app canvas using
@ref Platform::Sdl2Application::setContainerCssClass()
- Implemented @ref Platform::GlfwApplication::MouseMoveEvent::buttons() for
feature parity with @ref Platform::Sdl2Application (see
[mosra/magnum#256](https://github.com/mosra/magnum/issues/256))
- Added @ref Platform::Sdl2Application::MouseScrollEvent::position() and
@ref Platform::GlfwApplication::MouseScrollEvent::position()
- Added @ref Platform::Sdl2Application::GLConfiguration::setColorBufferSize() "GLConfiguration::setColorBufferSize()",
@ref Platform::Sdl2Application::GLConfiguration::setDepthBufferSize() "GLConfiguration::setDepthBufferSize()",
@ref Platform::Sdl2Application::GLConfiguration::setStencilBufferSize() "GLConfiguration::setStencilBufferSize()",
to @ref Platform::Sdl2Application, @ref Platform::GlfwApplication and
@ref Platform::AndroidApplication. This also makes the default framebuffer
parameters consistent across the implementations.
- Added numpad keys to @ref Platform::Sdl2Application::KeyEvent::Key,
consistent with GLFW key mapping
- Exposed enabled-by-default @ref Platform::Sdl2Application::GLConfiguration::Flag::ForwardCompatible "GLConfiguration::Flag::ForwardCompatible"
flag in @ref Platform::Sdl2Application and @ref Platform::GlfwApplication,
added @ref Platform::Sdl2Application::GLConfiguration::addFlags() "GLConfiguration::addFlags()"
and @ref Platform::Sdl2Application::GLConfiguration::clearFlags() "GLConfiguration::clearFlags()"
for easier flag handling
- Exposed enabled-by-default @ref Platform::WindowlessEglApplication::Configuration::Flag::ForwardCompatible "Configuration::Flag::ForwardCompatible"
flag in @ref Platform::WindowlessEglApplication,
@ref Platform::WindowlessGlxApplication and
@ref Platform::WindowlessWglApplication,
added @ref Platform::WindowlessEglApplication::Configuration::addFlags() "Configuration::addFlags()"
and @ref Platform::WindowlessEglApplication::Configuration::clearFlags() "Configuration::clearFlags()"
for easier flag handling
@subsubsection changelog-2018-10-new-primitives Primitives library
- New @ref Primitives::gradient2D(), @ref Primitives::gradient2DHorizontal(),
@ref Primitives::gradient2DVertical(), @ref Primitives::gradient3D(),
@ref Primitives::gradient3DHorizontal() and
@ref Primitives::gradient3DVertical() primitives
- New @ref Primitives::line2D(const Vector2&, const Vector2&) and
@ref Primitives::line3D(const Vector3&, const Vector3&) overloads for
easier creation of arbitrary lines, as transforming the line identities is
not worth the mental overhead
@subsubsection changelog-2018-10-new-scenegraph SceneGraph library
- New @ref SceneGraph::TranslationRotationScalingTransformation2D and
@ref SceneGraph::TranslationRotationScalingTransformation3D transformation
implementations that store separate translation, rotation and scaling
parameters for easier use with animated scenes
- Ability to affect order of items drawn by @ref SceneGraph::Camera --- see
@ref SceneGraph-Drawable-draw-order for more information
@subsubsection changelog-2018-10-new-shaders Shaders library
- New dedicated @ref Shaders::VertexColor::Color3 and
@ref Shaders::VertexColor::Color4 attribute specifiers for more convenient
distinction between three- and four-component vertex color attribute.
- Support for multiple lights in @ref Shaders::Phong
- Classical alpha masking support in @ref Shaders::Flat and
@ref Shaders::Phong
- Debug output for the @ref Shaders::Flat::Flag / @ref Shaders::Flat::Flags,
@ref Shaders::MeshVisualizer::Flag / @ref Shaders::MeshVisualizer::Flags
and @ref Shaders::Phong::Flag / @ref Shaders::Phong::Flags enums / enum
sets
@subsubsection changelog-2018-10-new-trade Trade library
- @ref Trade::AnimationData class and animation import interface in
@ref Trade::AbstractImporter::animation() and related functions
- New @ref Trade::AbstractMaterialData::flags(),
@ref Trade::AbstractMaterialData::alphaMode() and
@ref Trade::AbstractMaterialData::alphaMask() material properties
- New @ref Trade::CameraData::type(), @ref Trade::CameraData::aspectRatio()
and @ref Trade::CameraData::size() properties, ability to describe 2D
cameras
- @ref Trade::ObjectData2D and @ref Trade::ObjectData3D now support also
separate translation / rotation / scaling specification instead of a
combined transformation matrix. See @ref Trade::ObjectData2D::transformation()
and @ref Trade::ObjectData3D::transformation() for more information.
- Support for file loading callbacks in @ref Trade::AbstractImporter
- Debug output for @cpp Trade::AbstractImporter::Feature @ce,
@cpp Trade::AbstractImageConverter::Feature @ce enums and
@cpp Trade::AbstractImporter::Features @ce,
@cpp Trade::AbstractImageConverter::Features @ce enum sets
- @ref Trade::AnyImageImporter "AnyImageImporter" plugin now supports
detection and loading of DDS, EXR, HDR, JPEG, PNG and TGA files from data
next to file type detection based on filename
- @ref Trade::AnyImageConverter "AnyImageConverter" learned detection of JPEG
output
- @ref Trade::AnySceneImporter "AnySceneImporter" gained support for
animation import
@subsubsection changelog-2018-10-new-vk Vk library
- New @ref Vk library that'll be the home of a Vulkan graphics backend in the
future
- New functions @ref Vk::hasVkPrimitiveTopology(),
@ref Vk::vkPrimitiveTopology(), @ref Vk::hasVkIndexType(),
@ref Vk::vkIndexType(), @ref Vk::hasVkFormat(), @ref Vk::vkFormat(),
@ref Vk::vkFilter(), @ref Vk::vkSamplerMipmapMode(),
@ref Vk::hasVkSamplerAddressMode(), @ref Vk::vkSamplerAddressMode() for
converting generic @ref MeshPrimitive, @ref MeshIndexType,
@ref PixelFormat, @ref CompressedPixelFormat, @ref SamplerFilter,
@ref SamplerMipmap and @ref SamplerWrapping enums to Vulkan-specific values
@subsection changelog-2018-10-changes Changes and improvements
@subsubsection changelog-2018-10-changes-audio Audio library
- Ability to specify initial source direction using
@ref Audio::Playable::Playable(SceneGraph::AbstractObject<dimensions, Float>&, const VectorTypeFor<dimensions, Float>&, PlayableGroup<dimensions>*)
@subsubsection changelog-2018-10-changes-gl GL library
- To prevent nothing being rendered by accident, @ref GL::Mesh::setCount()
and @ref GL::MeshView::setCount() now has always to be called, even just to
set the count to @cpp 0 @ce.
- @ref GL::Mesh::addVertexBuffer(), @ref GL::Mesh::addVertexBufferInstanced()
@ref GL::Mesh::setIndexBuffer() can now take ownership of a passed
@ref GL::Buffer to simplify resource management on user side. See
@ref GL-Mesh-buffer-ownership for more information.
- @cpp GL::Mesh::draw() @ce and @cpp GL::MeshView::draw() @ce now return a
reference to self to make method-chained draws (for example using a
different shader) possible as well
- The @ref GL::BufferUsage parameter in @ref GL::Buffer::setData() is now
optional, defaults to @ref GL::BufferUsage::StaticDraw
@subsubsection changelog-2018-10-changes-math Math library
- All assertions in the @ref Math namespace now helpfully print the offending
value that caused the assert for easier debugging
- @ref Math::Matrix3::rotation() const and @ref Math::Matrix4::rotation() const
now allow non-uniform scaling, but expect the roation/scaling part to be
orthogonal after normalization
- @ref Math::angle(), @ref Math::Vector::lengthInverted(),
@ref Math::Vector::normalized(), @ref Math::Vector::resized(),
@ref Math::Vector::projected(), @ref Math::Vector::projectedOntoNormalized()
and @ref Math::Vector2::aspectRatio() are now enabled only for
floating-point types to avoid errors when using these functions
accidentally on integral vectors (see
[mosra/magnum#251](https://github.com/mosra/magnum/issues/251))
@subsubsection changelog-2018-10-changes-meshtools MeshTools library
- @ref MeshTools::compile() API got simplified to make use of the new buffer
ownership feature of @ref GL::Mesh
- @ref MeshTools::compile() learned to handle vertex color attributes as well
(see [mosra/magnum#284](https://github.com/mosra/magnum/pull/284))
@subsubsection changelog-2018-10-changes-platform Platform libraries
- @ref Platform::Sdl2Application::viewportEvent() "Platform::*Application::viewportEvent()"
now gets all information needed for DPI-aware rendering instead of just
a framebuffer size --- now also window size and the DPI scaling value
- Overhauled the builtin @ref platforms-html5 "Emscripten" HTML markup and
styling for HTML5/WebGL apps:
- the builtin style now matches the dark theme of the Magnum website
- canvas is responsively sized and preserves aspect ratio when scaled
down
- when the app aborts, a helpful message is printed instead of everything
getting stuck
- it's possible to override the default canvas size and aspect ratio,
see @ref platforms-html5-layout
- documentation explaining quirks of event handling, see
@ref platforms-html5-events
- @ref Platform::GlfwApplication now behaves the same as
@ref Platform::Sdl2Application when creating an OpenGL context: first it
attempts to create a forward-compatible core OpenGL 3.2+ context and if
that fails, falls back to 2.1+ compatibility context. The
@cpp "no-forward-compatible-core-context" @ce workaround is implemented as
well, see @ref opengl-workarounds for more information.
- @ref Platform::GlfwApplication no longer stores a needless global window
pointer
- @ref Platform::GlfwApplication now loads modifiers for mouse move and mouse
scroll events lazily, only when needed
- @ref Platform::BasicScreen::viewportEvent() "Platform::Screen::viewportEvent()"
is no longer pure virtual to be consistent with all `*Application`
implementations
- @ref Platform::Sdl2Application now defaults to the actual canvas size
on @ref CORRADE_TARGET_EMSCRIPTEN "Emscripten", instead of hardcoded
@cpp {640, 480} @ce
- @ref Platform::Sdl2Application::Configuration::WindowFlags values that make
no sense on Emscripten are not available there anymore
- When using SDL 2.0.8 and newer, @ref Platform::Sdl2Application no longer
attempts to disable compositing on Linux. See @ref Platform-Sdl2Application-usage-linux
for more information. See also [mosra/magnum#184](https://github.com/mosra/magnum/issues/184).
- New @cpp "swiftshader-no-empty-egl-context-flags" @ce and
@cpp "swiftshader-egl-context-needs-pbuffer" @ce workarounds to make
@ref Platform::WindowlessEglApplication working with
[SwiftShader](https://github.com/google/swiftshader). See
@ref opengl-workarounds for more information.
@subsubsection changelog-2018-10-changes-shaders Shaders library
- All shaders now have reasonable default values for uniforms in order to
further simplify and remove friction from quick prototyping use cases
- @ref Shaders::Flat::bindTexture(), @ref Shaders::Phong::bindAmbientTexture(),
@ref Shaders::Phong::bindDiffuseTexture(),
@ref Shaders::Phong::bindSpecularTexture() and
@ref Shaders::Phong::bindTextures() now assert that the shader was created
with the corresponding flag enabled to prevent accidental "black screen of
death" errors.
- Ambient color in untextured @ref Shaders::Phong now defaults to
@cpp 0x00000000_rgbaf @ce in order to support alpha-masked drawing out of
the box
@subsubsection changelog-2018-10-changes-texturetools TextureTools library
- Fixed @cpp TextureTools::distanceField() @ce to not require more than 8
texture units, which is the limit on all iOS ES2 contexts, independently on
the device (ES3 contexts have 16).
@subsubsection changelog-2018-10-changes-trade Trade library
- @ref Trade::PhongMaterialData now contains well-defined color values
instead of random memory after construction
@subsection changelog-2018-10-buildsystem Build system
- There's now a PPA for Ubuntu packages. See @ref building-packages-deb
for more information. See also [mosra/magnum#248](https://github.com/mosra/magnum/issues/248)
and [mosra/magnum#249](https://github.com/mosra/magnum/pull/249).
- Fixed various issues preventing to build and use the base libraries with
OpenGL support disabled (see [mosra/magnum#255](https://github.com/mosra/magnum/pull/255))
- Magnum now links to GLVND on Linux instead of the old libGL ABI if using
CMake 3.11 and newer
- Using official Apple OpenGL include paths on iOS (see
[mosra/magnum#253](https://github.com/mosra/magnum/pull/253))
- @ref cmake "FindMagnum.cmake" now allows to use the @ref DebugTools library
even if some of its optional dependencies are not compiled in
- `FindSDL2.cmake` now properly links to `dl` and `pthread` libraries when
using a static build of SDL2 on Linux
- `FindSDL2.cmake` is now able to properly find a debug build of SDL, which
enables Vcpkg to properly copy all dependency DLLs on Windows
(see [mosra/magnum-examples#42](https://github.com/mosra/magnum-examples/issues/42),
[mosra/magnum-examples#45](https://github.com/mosra/magnum-examples/pull/45))
- `FindGLFW.cmake` is now preferring GLFW CMake config file to pick up the
imported target, if available (see
[mosra/magnum#194](https://github.com/mosra/magnum/pull/194))
- `FindMagnum.cmake` now provides full paths to application JS/CSS files on
@ref platforms-html5 "Emscripten" builds through new `MAGNUM_EMSCRIPTENAPPLICATION_JS`,
`MAGNUM_WINDOWLESSEMSCRIPTENAPPLICATION_JS` and `MAGNUM_WEBAPPLICATION_CSS`
CMake variables. These files are now installed unconditionally even if no
`Platform::*Application` library is built to allow them to be used with
third-party application implementations.
8 years ago
- @ref Trade::ObjImporter "ObjImporter" didn't work with CMake subprojects
due to an embarrassing typo (see
[mosra/magnum#259](https://github.com/mosra/magnum/issues/259))
- @ref Audio::AnyImporter "AnyAudioImporter",
@ref Trade::AnyImageConverter "AnyImageConverter",
@ref Trade::AnyImageImporter "AnyImageImporter" and
@ref Trade::AnySceneImporter "AnySceneImporter" plugins were not correctly
updated for subproject support after moving them out of the `magnum-plugins`
repository
- Improved out-of-the-box behavior with Emscripten toolchains (see
[mosra/magnum#283](https://github.com/mosra/magnum/issues/283))
@subsection changelog-2018-10-bugfixes Bug fixes
- MSVC 15.8 (released on Aug 14, 2018) has a regression causing the compiler
to crash with an ICE (C1001) on @ref Math::Color4 constructors that have a
default alpha parameter. This is only only when the `/permissive-` flag is
specified (which is done by default for projects created directly using
Visual Studio but not for projects using CMake). This has been worked
around, but can't be guaranteed it was the only case. In case you're
experiencing a similar issue somewhere else, please try to disable the
`/permissive-` flag first.
- An assert was firing during @ref Platform::GlfwApplication initialization
due to a pointer not being properly initialized after the
@ref Platform::GlfwApplication::GLConfiguration "GLConfiguration" rework in
2018.04 (see [mosra/magnum#246](https://github.com/mosra/magnum/pull/246),
[mosra/magnum#247](https://github.com/mosra/magnum/issue/247))
- Vertex attribute divisor in @ref GL::Mesh::addVertexBufferInstanced() was
not properly cleaned up after when @gl_extension{ARB,vertex_array_object}
was disabled, causing subsequent draws to misbehave
- Fixed @ref Shaders::DistanceFieldVector and @ref Shaders::Vector to be
properly movable
- Restored backwards compatibility to the templated @ref GL::Buffer::map()
overload --- it was not possible to call it with @cpp void @ce template
parameter
- @gl_extension{ARB,direct_state_access} versions of
@ref GL::Framebuffer::clearColor(), @ref GL::Framebuffer::clearDepth(),
@ref GL::Framebuffer::clearStencil() and @ref GL::Framebuffer::clearDepthStencil()
were binding the framebuffer for drawing, which was completely unnecessary
- Deprecation status of GL-specific values of the generic @ref MeshPrimitive
enum was not properly reflected in the documentation
- @ref Platform::GlfwApplication::InputEvent::Modifier::Super is properly
reported for both left and right modifier (Windows/⌘) key instead of just
the right one
- @ref Platform::GlfwApplication::exec() now asserts instead of crashing if
the constructor fails to create a window (see [mosra/magnum#192](https://github.com/mosra/magnum/issues/192),
[mosra/magnum#272](https://github.com/mosra/magnum/pull/272))
- @ref Platform::GlfwApplication::GLConfiguration::isSrgbCapable() has now
a proper documented default value instead of being left uninitialized.
- @ref Math::sclerp() was not properly interpolating the translation if
rotation was the same on both sides
- Improved @cpp TextureTools::distanceField() @ce to work better on shader
compilers that have problems compiling nested loops (WebGL implementations,
some ES2 devices)
- @ref SceneGraph::AbstractObject::addFeature() and
@ref SceneGraph::Object::addChild() were not properly forwarding reference
arguments
@subsection changelog-2018-10-docs Documentation
- New @ref custom-buildsystems page listing the most important things to keep
in mind when using Magnum with custom buildsystems. See also
[mosra/magnum#268](https://github.com/mosra/magnum/pull/268).
- Compiled code snippets for @ref Audio and @ref SceneGraph libraries, fixing
cases where outdated or plain wrong API constructs were mentioned
- Extended documentation for @ref Math::Matrix3::rotation(),
@ref Math::Matrix4::rotation() and related accessors, explaining use cases
and caveats
- Reworked documentation of @ref Math::Algorithms, adding math equations and
usage examples to all functions
- Improved documentation of @ref Math::Constants, showing useful identities
for each
- The @ref scenegraph documentation was proofread and extended with a section
covering basics with visual diagrams.
- Explicitly mentioning copy/move constructibility for all classes with
non-trivial construction
- Improved Vcpkg build instructions (see
[mosra/magnum#271](https://github.com/mosra/magnum/pull/271),
[mosra/magnum#273](https://github.com/mosra/magnum/pull/273))
- Website styling got out of sync with generated Doxygen documentation,
causing search icon to either disappear on some browsers or be extremely
oversized on others (see
[mosra/magnum#260](https://github.com/mosra/magnum/issues/260),
[mosra/magnum#261](https://github.com/mosra/magnum/issues/261))
- Documentation of @ref Primitives and @ref Shaders namespaces now has proper
sRGB and HiDPi renderings of all primitives and shaders
- Various other fixes and updates (see
[mosra/magnum#281](https://github.com/mosra/magnum/pull/281))
@subsection changelog-2018-10-deprecated Deprecated APIs
- The `Shapes` library is a failed design experiment and is scheduled for
removal in a future release, together with `DebugTools::ShapeRenderer`.
Related geometry algorithms were moved to @ref Math::Distance and
@ref Math::Intersection; if you need a full-fledged physics library, please
have look at [Bullet](https://bulletphysics.org), which has Magnum
integration in @ref BulletIntegration, or at [Box2D](https://box2d.org/),
which has a @ref examples-box2d "Magnum example" as well.
- `Platform::GlutApplication` is based on an outdated toolkit and thus
scheduled for removal in a future release. Please consider switching to
@ref Platform::Sdl2Application or @ref Platform::GlfwApplication as soon as
possible.
- `Platform::*Application::viewportEvent(const Vector2i&)` is deprecated
because it doesn't provide all information needed for DPI-aware rendering.
Override the @ref Platform::Sdl2Application::viewportEvent(ViewportEvent&) "viewportEvent(ViewportEvent&)"
function instead.
- `Platform::Sdl2Application::Configuration::WindowFlags::AllowHighDpi` is
deprecated and has no effect as it is now passed implicitly on platforms
that need it
- `Math::Geometry`, `Math::Geometry::Distance` and
`Math::Geometry::Intersection` namespaces are deprecated for being too
deeply nested, use @ref Math::Distance and @ref Math::Intersection instead
- `Math::Geometry::Intersection::boxFrustum()` is deprecated, use
@ref Math::Intersection::rangeFrustum() instead
- @ref Math::Intersection::planeLine() taking a separate plane normal and
position is deprecated, use @ref Math::planeEquation() and the overload
taking a plane equation as @ref Math::Vector4 instead
- @cpp Audio::PlayableGroup::setClean() @ce is deprecated in favor of
@ref Audio::Listener::update(), as that one is a feature superset with
clearer naming
- @ref MeshTools::compile() taking a @ref GL::BufferUsage and returning a
tuple was deprecated, use the simpler version taking just
@cpp Trade::MeshData2D @ce / @cpp Trade::MeshData3D @ce and directly
returning a @ref GL::Mesh instead
- `Shaders::VertexColor::Color` is deprecated, use the direct
@ref Shaders::VertexColor::Color3 or @ref Shaders::VertexColor::Color4
alternatives instead
- @ref Trade::AbstractMaterialData constructor taking just two parameters
and @ref Trade::PhongMaterialData constructor taking three parameters are
deprecated, use @ref Trade::AbstractMaterialData::AbstractMaterialData(MaterialType, Flags, MaterialAlphaMode, Float, const void*)
and @ref Trade::PhongMaterialData::PhongMaterialData(Flags, MaterialAlphaMode, Float, Float, const void*)
instead
- @ref Trade::CameraData constructor not taking an explicit type enum is
deprecated, use @ref Trade::CameraData::CameraData(CameraType, Rad, Float, Float, Float, const void*)
instead
- @cpp GL::*Texture::setSRGBDecode() @ce,
@cpp GL::Renderer::Feature::FramebufferSRGB @ce,
@cpp Platform::*Application::GLConfiguration::setSRGBCapable() @ce and
@cpp Platform::*Application::GLConfiguration::isSRGBCapable() @ce is
deprecated, use
@ref GL::Texture::setSrgbDecode() "GL::*Texture::setSrgbDecode()",
@ref GL::Renderer::Feature::FramebufferSrgb,
@ref Platform::Sdl2Application::GLConfiguration::setSrgbCapable() "Platform::*Application::GLConfiguration::setSrgbCapable()" and
@ref Platform::Sdl2Application::GLConfiguration::isSrgbCapable() "Platform::*Application::GLConfiguration::isSrgbCapable()" instead as it
has consistent naming with @ref Math::Color3 "Math::Color" APIs
@subsection changelog-2018-10-compatibility Potential compatibility breakages, removed APIs
- The `Shapes` library is not built by default anymore due to its deprecated
status
- @ref Audio::Playable is now by default omnidirectional instead of having
source in direction of negative Z axis (the direction has effect only when
setting inner and outer cone properties of @ref Audio::Source).
- @ref Math::Matrix3::rotation() const and @ref Math::Matrix4::rotation() const
now allow non-uniform scaling, but expect the roation/scaling part to be
orthogonal after normalization (before it required uniform scaling but not
orthogonal axes) --- this might cause imprecise data that were previously
working to fail with an assertion. See the new
@ref Math::Matrix3::rotationShear() and @ref Math::Matrix4::rotationShear()
accessors for a possible solution.
- Since one-dimensional @ref Math::Range is now used on many new places such
as the @ref Animation library, its underlying type is just @cpp T @ce
instead of @ref Math::Vector "Math::Vector<1, T>" to make it easier to use.
This may break rare existing code that was using one-dimensional ranges or
generic code that's always expecting a vector type. See
@ref Math-Range-generic for possible solutions.
- @ref SceneGraph::Camera::setViewport() and @ref SceneGraph::Camera::draw()
are no longer @cpp virtual @ce functions. If you need to override their
functionality, simply call the subclass implementation directly instead of
calling it through a @ref SceneGraph::Camera.
- @ref Shaders::Flat::bindTexture(), @ref Shaders::Phong::bindAmbientTexture(),
@ref Shaders::Phong::bindDiffuseTexture(),
@ref Shaders::Phong::bindSpecularTexture() and
@ref Shaders::Phong::bindTextures() now assert that the shader was created
with the corresponding flag enabled to prevent accidental "black screen of
death" errors. This might cause your application to abort if it was calling
these functions when not needed.
- Ambient color in untextured @ref Shaders::Phong now defaults to
@cpp 0x00000000_rgbaf @ce in order to support alpha-masked drawing out of
the box. This may break code that assumed the alpha channel being opaque by
default.
- @ref Trade::PhongMaterialData::ambientColor(),
@ref Trade::PhongMaterialData::diffuseColor() "diffuseColor()" and
@ref Trade::PhongMaterialData::specularColor() "specularColor()" now return
@ref Color4 instead of @ref Color3
- Applications now expose GL context forward compatibility as an
enabled-by-default context flag. Calling
@ref Platform::Sdl2Application::GLConfiguration::setFlags() "Platform::*Application::GLConfiguration::setFlags()"
(and similarly on windowless apps) will reset that flag, use
@ref Platform::Sdl2Application::GLConfiguration::addFlags() "Platform::*Application::GLConfiguration::addFlags()" (And similarly on
windowless apps) to preserve the enabled-by-default flags.
@section changelog-2018-04 2018.04
Released 2018-05-01, tagged as
[v2018.04](https://github.com/mosra/magnum/releases/tag/v2018.04).
@subsection changelog-2018-04-dependencies Dependency changes
- Building for Android now requires CMake 3.7 with builtin Android
crosscompilation support, the old toolchains were removed. Only the Clang
and libc++ toolchain is now supported, support for GCC and libstdc++ was
dropped, as it was still missing some important C++11 functionality. See
@ref building-cross-android for more information.
@subsection changelog-2018-04-new New features
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- New @ref PixelFormat / @ref CompressedPixelFormat enums containing generic
API-independent pixel formats, together with @ref pixelSize(),
@ref pixelFormatWrap() / @ref pixelFormatUnwrap(),
@ref compressedPixelFormatWrap() / @ref compressedPixelFormatUnwrap() and @ref isPixelFormatImplementationSpecific() /
@ref isCompressedPixelFormatImplementationSpecific() utilities now used by
@ref Image / @ref CompressedImage and @ref ImageView /
@ref CompressedImageView instead of the GL-specific formats
- New @ref MeshPrimitive and @ref MeshIndexType enums containing generic
API-independent mesh primitive types and index types, together with
@ref meshIndexTypeSize() utilities
- New @ref SamplerFilter, @ref SamplerMipmap and @ref SamplerWrapping enums
containing generic API-independent texture sampler modes
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
@subsubsection changelog-2018-04-new-math Math library
- Added @ref Math::isInf(), @ref Math::isNan()
@subsubsection changelog-2018-04-new-gl GL library
- A new library that now contains wrappers for the OpenGL family of graphics
APIs, separated from the core Magnum library (see
[mosra/magnum#233](https://github.com/mosra/magnum/pull/233))
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- New @ref GL::hasPixelFormat(), @ref GL::pixelFormat(), @ref GL::pixelType(),
@ref GL::hasCompressedPixelFormat(), @ref compressedPixelFormat() utilities
for converting generic @ref PixelFormat / @ref CompressedPixelFormat to
GL-specific @ref GL::PixelFormat, @ref GL::PixelType and
@ref GL::CompressedPixelFormat values. The @ref GL::BufferImage and
@ref GL::CompressedBufferImage classes now have overloads accepting both
types.
- New @ref GL::meshPrimitive() and @ref GL::meshIndexType() utilities for
converting generic @ref MeshPrimitive and @ref MeshIndexType to GL-specific
@ref GL::MeshPrimitive and @ref GL::MeshIndexType values. The @ref GL::Mesh
class now has overloads accepting both types.
- New @ref GL::Mesh::indexType() and @ref GL::MeshView::mesh() getters
- New @ref GL::samplerFilter(), @ref GL::samplerMipmap() and
@ref GL::samplerWrapping() utilities for converting generic
@ref SamplerFilter, @ref SamplerMipmap and @ref SamplerWrapping to G
L-specific @ref GL::SamplerFilter, @ref GL::SamplerMipmap and
@ref GL::SamplerWrapping values. All texture classes now have overloads
accepting both types.
- Initial support for OpenGL ES 3.2 and OpenGL 4.6 (see
[mosra/magnum#224](https://github.com/mosra/magnum/issues/224),
[mosra/magnum#231](https://github.com/mosra/magnum/pull/231))
- New OpenGL extension support:
- @gl_extension{ARB,texture_filter_anisotropic}
- @gl_extension{OES,texture_float}, @gl_extension2{OES,texture_half_float,OES_texture_float}
- @gl_extension{EXT,color_buffer_float},
@gl_extension2{EXT,color_buffer_half_float,EXT_color_buffer_half_float}
8 years ago
and
their WebGL counterparts @webgl_extension{EXT,color_buffer_half_float},
@webgl_extension{WEBGL,color_buffer_float},
@webgl_extension{EXT,color_buffer_float}
- Ported @ref GL::OpenGLTester to WebGL
@subsubsection changelog-2018-04-new-platform Platform libraries
- Ability to create @ref Platform::Sdl2Application and
@ref Platform::GlfwApplication classes without implicitly created OpenGL
context by passing @ref Platform::Sdl2Application::Configuration::WindowFlag::Contextless "Configuration::WindowFlag::Contextless"
to them. These two can be now also built completely without the GL library.
- Added @ref Platform::AndroidApplication::windowSize()
- Added @ref Platform::AndroidApplication::nativeActivity() to access
underlying `ANativeActivity` structure for calling various Android APIs
@subsubsection changelog-2018-04-new-primitives Primitives library
- New @ref Primitives::circle3DSolid(), @ref Primitives::circle3DWireframe(),
@ref Primitives::coneSolid(), @ref Primitives::coneWireframe(),
@ref Primitives::grid3DSolid() and @ref Primitives::grid3DWireframe()
primitives
@subsubsection changelog-2018-04-new-trade Trade library
- Debug output operator for @ref Trade::PhongMaterialData::Flag and
@ref Trade::PhongMaterialData::Flags
@subsection changelog-2018-04-changes Changes and improvements
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- The @ref CompressedPixelStorage class and related APIs are now available
on all targets including OpenGL ES and WebGL, however at the moment, until
a compatibility code path is implemented, the @ref GL library expects that
all parameters are at their defaults.
@subsubsection changelog-2018-04-changes-debugtools DebugTools library
- @ref DebugTools::textureSubImage() now accepts both GL-specific
@ref GL::PixelFormat / @ref GL::PixelType combination and the generic
@ref PixelFormat enum
- @ref DebugTools::CompareImage now accepts generic @ref PixelFormat on input
instead of GL-specific @ref GL::PixelFormat / @ref GL::PixelType
@subsubsection changelog-2018-04-changes-gl GL library
- The @ref GL::Mesh::indexTypeSize() and @ref GL::MeshView::setIndexRange()
now expect that the mesh is indexed (instead of silently not doing
anything)
@subsubsection changelog-2018-04-changes-text Text library
- The @ref Text::GlyphCache now unconditionally uses
@ref GL::TextureFormat::Luminance on ES2 and WebGL 1, instead of trying
@ref GL::TextureFormat::Red there first. That's done for consistency with
@ref GL::pixelFormat(), which unconditionally returns
@ref GL::PixelFormat::Luminance for @ref PixelFormat::R8Unorm.
@subsubsection changelog-2018-04-changes-platform Platform libraries
- Separated @ref Platform::Sdl2Application::Configuration "Platform::*Application::Configuration"
into @ref Platform::Sdl2Application::Configuration "Configuration" and
@ref Platform::Sdl2Application::GLConfiguration "GLConfiguration" to allow
creation of non-GL application instances in the future
@subsubsection changelog-2018-04-changes-plugins Plugins
- @ref Trade::TgaImporter "TgaImporter" and
@ref Trade::TgaImageConverter "TgaImageConverter" plugins now operate on
the generic @ref PixelFormat instead of GL-specific @ref GL::PixelFormat /
@ref GL::PixelType
- @ref Trade::AnySceneImporter "AnySceneImporter" now uses `GlbImporter` for
loading binary glTF files instead of proxying them to `GltfImporter`
plugins
@subsection changelog-2018-04-buildsystem Build system
- The core @ref Magnum library is not depending on OpenGL anymore, all
GL-related APIs are now part of a new @ref GL library
- @ref Primitives and @ref Trade libraries do not depend on OpenGL anymore
- @ref DebugTools, @ref MeshTools and @ref TextureTools have only an optional
dependency on the @ref GL library, controlled with `TARGET_GL` CMake option
- All plugin interfaces now implement
@ref Corrade::PluginManager::AbstractPlugin::pluginSearchPaths() "pluginSearchPaths()"
for plugin directory autodetection --- you no longer need to specify the
plugin directory explicitly when loading plugins. See @ref plugins-loading
for more information. See also [mosra/magnum#235](https://github.com/mosra/magnum/issues/235).
- Plugins now provide an automatic means of static plugin import via CMake
targets, no need to call @ref CORRADE_PLUGIN_IMPORT() implicitly anymore.
For this to work, you just need to update local copies of all Find modules.
See @ref plugins-static for more information.
- The @ref Audio::AnyImporter "AnyAudioImporter", @ref Trade::AnyImageConverter "AnyImageConverter",
@ref Trade::AnyImageImporter "AnyImageImporter" and @ref Trade::AnySceneImporter "AnySceneImporter"
plugins were moved from the plugins repository to the core Magnum
repository. If you are using them statically via CMake, you need to update
your copies of `FindMagnum.cmake` and `FindMagnumPlugins.cmake` modules.
See @ref building and @ref cmake for more information.
- The @ref Trade namespace is now a separate library, allowing to use core
Magnum functionality without @ref Corrade::PluginManager
- Suppressed a MSVC warning in @ref MeshTools::interleave() (see
[mosra/magnum#238](https://github.com/mosra/magnum/issues/238))
- Fixed Vcpkg packages to properly copy all plugin and their dependencies
8 years ago
along the executable (see [mosra/magnum#235](https://github.com/mosra/magnum/issues/235),
[mosra/magnum-examples#41](https://github.com/mosra/magnum-examples/issues/41))
- Stable version of Magnum is now available as a binary package in the
ArchLinux `[community]` repo
- Homebrew macOS packages were updated to install the stable version by
default
- Fixed the Debian package after introducing `SOVERSION` to all libraries
(see [mosra/magnum#237](https://github.com/mosra/magnum/issues/237))
- Fixed the Debian package to not include a revision. While just a warning on
Ubuntu, it's a hard error on Debian. (See [mosra/corrade#44](https://github.com/mosra/corrade/issues/44).)
@subsection changelog-2018-04-bugfixes Bug fixes
- Engine startup info was not properly printed to Android log since
introducing the `--magnum-log` option in version 2018.02
- Dropped Google Closure Compiler from Emscripten toolchains, it was bringing
more harm than good (see [mosra/magnum#211](https://github.com/mosra/magnum/issues/211))
- Working around Emscripten issue where `-s USE_PTHREADS=1` would cause all
shader sources containing Unicode characters to be truncated to empty
strings. See the @cpp "emscripten-pthreads-broken-unicode-shader-sources" @ce
workaround description and [mosra/magnum#239](https://github.com/mosra/magnum/issues/239)
for details.
- @cpp GL::Attribute::DataType::HalfFloat @ce was not available on WebGL 2 by
mistake
- A wrong code path for @ref GL::Framebuffer::checkStatus() was selected on
WebGL 1 by mistake
- Fixed `MAGNUM_PLUGINS_DIR` variables to contain proper absolute location by
default again.
@subsection changelog-2018-04-deprecated Deprecated APIs
- All GL-related headers and APIs from the root `Magnum/` directory and
@ref Magnum namespace were moved to the `Magnum/GL/` directory and
@ref Magnum::GL namespace. See their documentation for information about
particular files, classes, enums, typedefs, values and functions.
- The `MAGNUM_ASSERT_VERSION_SUPPORTED()`, `MAGNUM_ASSERT_EXTENSION_SUPPORTED()`
and `MAGNUM_VERIFY_NO_ERROR()` macros are deprecated, use
@ref MAGNUM_ASSERT_GL_VERSION_SUPPORTED(),
@ref MAGNUM_ASSERT_GL_EXTENSION_SUPPORTED() and
@ref MAGNUM_VERIFY_NO_GL_ERROR() instead
- The `Platform::Context` class is deprecated, use @ref Platform::GLContext
instead
- `Platform::*Application::createContext()` and
`Platform::*Application::tryCreateContext()` functions are deprecated for
being too GL-specific, use @ref Platform::Sdl2Application::create() "create()"
and @ref Platform::Sdl2Application::tryCreate() "tryCreate()" instead
- The `Extensions::GL` namespace is deprecated, use @ref GL::Extensions
instead
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- The @ref PixelFormat and @ref CompressedPixelFormat enum now contains
generic API-independent values. The GL-specific formats are present there,
but marked as deprecated. Use either the generic values or
@ref GL::PixelFormat (together with @ref GL::PixelType) and
@ref GL::CompressedPixelFormat instead.
- `PixelStorage::pixelSize()` was deprecated, use @ref GL::pixelSize() or
@ref Magnum::pixelSize() instead
- `PixelStorage::dataProperties(GL::PixelFormat, GL::PixelSize, const Vector3i&)`
was deprecated for being too GL-specific, use
@ref PixelStorage::dataProperties(std::size_t, const Vector3i&) const
together with @ref GL::pixelSize() instead
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- `Image*::type()` functions are deprecated as these are too GL-specific. The
second format specifier is now available through @ref Image::formatExtra(),
@ref ImageView::formatExtra() and @ref Trade::ImageData::formatExtra()
- `Audio::Buffer::Format` is deprecated, use @ref Audio::BufferFormat instead
- `setData()` functions in the @ref Image and @ref CompressedImage classes
are deprecated because they don't offer anything extra over simple
move-assignment of a new instance.
- The @ref MeshPrimitive enum now contains generic API-independent values.
The additional GL-specific types are present there, but marked as
deprecated. Use the GL-specific @ref GL::MeshPrimitive enum instead.
- THe `GL::Mesh::IndexType` enum and the `Mesh::indexSize(MeshIndexType)`
function is deprecated, use @ref Magnum::MeshIndexType /
@ref GL::MeshIndexType and @ref meshIndexTypeSize() instead
- The `GL::Mesh::indexSize()` function is deprecated, use
@ref GL::Mesh::indexTypeSize() instead
- The `Sampler` class and the `Sampler::Filter`, `Sampler::Mipmap`,
`Sampler::Wrapping`, `Sampler::CompareMode`, `Sampler::CompareFunction` and
`Sampler::DepthStencilMode` enums are 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 and
@ref GL::SamplerDepthStencilMode instead
- Class @cpp Primitives::Capsule2D @ce and @cpp Primitives::Capsule3D @ce is
deprecated, use @ref Primitives::capsule2DWireframe(),
@ref Primitives::capsule3DSolid() and @ref Primitives::capsule3DWireframe()
free functions instead
- Class @cpp Primitives::Circle @ce is deprecated, use
@ref Primitives::circle2DSolid() and @ref Primitives::circle2DWireframe()
instead
- Class @cpp Primitives::Crosshair2D @ce and @cpp Primitives::Crosshair3D @ce
is deprecated, use @ref Primitives::crosshair2D() and
@ref Primitives::crosshair3D() free function instead
- Class @cpp Primitives::Cube @ce is deprecated, use @ref Primitives::cubeSolid(),
@ref Primitives::cubeSolidStrip() and @ref Primitives::cubeWireframe() free
functions instead
- Class @cpp Primitives::Cylinder @ce is deprecated, use
@ref Primitives::cylinderSolid(), @ref Primitives::cylinderWireframe() free
functions instead
- Class @cpp Primitives::Icosphere @ce is deprecated, use the
@ref Primitives::icosphereSolid() free function instead
- Class @cpp Primitives::Line @ce is deprecated, use the
@ref Primitives::line2D() and @ref Primitives::line3D() free functions
instead
- Class @cpp Primitives::Plane @ce is deprecated, use
@ref Primitives::planeSolid() and @ref Primitives::planeWireframe() free
functions instead
- Class @cpp Primitives::Square @ce is deprecated, use
@ref Primitives::squareSolid() and @ref Primitives::squareWireframe() free
functions instead
- Class @cpp Primitives::UVSphere @ce is deprecated, use
@ref Primitives::uvSphereSolid() and @ref Primitives::uvSphereWireframe()
free functions instead
- @cpp Shaders::*Vector::setVectorTexture() @ce, @cpp Shaders::Flat::setTexture() @ce,
@cpp Shaders::Phong::setAmbientTexture() @ce, @cpp Shaders::Phong::setDiffuseTexture() @ce,
@cpp Shaders::Phong::setSpecularTexture() @ce and @cpp Shaders::Phong::setTextures() @ce
are deprecated because texture binding (a global state) is confused there
with uniform setup (a shader-local state). That can lead to accidental
state mismatches where a texture is forgotten to be rebound. Use
@ref Shaders::AbstractVector::bindVectorTexture() "Shaders::*Vector::bindVectorTexture()",
@ref Shaders::Flat::bindTexture(), @ref Shaders::Phong::bindAmbientTexture(),
@ref Shaders::Phong::bindDiffuseTexture(), @ref Shaders::Phong::bindSpecularTexture()
and @ref Shaders::Phong::bindTextures() instead.
@subsection changelog-2018-04-compatibility Potential compatibility breakages, removed APIs
- Code that was previously linking just to the core @ref Magnum library may
now need to explicitly link to the @ref Magnum::Trade and @ref Magnum::GL
libraries as well. If using CMake, these dependencies might get linked in
transitively from other libraries, but that doesn't handle all cases. Due
to the complexity of this change, no backwards compatibility is provided.
- The `magnum-info` utility was renamed to @ref magnum-gl-info. No backwards
compatibility symlinks or aliases are provided.
- The `Magnum::Context` target alias was renamed to `Magnum::GLContext`. No
backwards compatibility aliases are provided.
- @ref PixelStorage::dataProperties(), @ref Image::dataProperties(),
@ref ImageView::dataProperties(), @ref Trade::ImageData::dataProperties(), and @ref GL::BufferImage::dataProperties() now return just a pair of two
values, as the third value is now accessible directly through
@ref Image::pixelSize() "*Image::pixelSize()" and no longer calculated
on-demand
- @ref CompressedPixelStorage::dataProperties(),
@ref CompressedImage::dataProperties(),
@ref CompressedImageView::dataProperties() and
@ref GL::CompressedBufferImage::dataProperties() now return just a pair
of two values, as the third value is accessible directly through
@ref CompressedPixelStorage::compressedBlockDataSize()
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- @ref ImageView and @ref CompressedImageView methods are no longer
@cpp constexpr @ce. It might be possible to have them @cpp constexpr @ce in
C++14, but the resulting increase in maintenance costs and compile times is
not worth it.
- `PixelFormat` has been moved verbatim to @ref GL::PixelFormat and there's a
new @ref Magnum::PixelFormat enum for generic pixel formats. It contains
(deprecated) @ref GL::PixelFormat values for covering most of backwards
compatibility, but code that relies on these two types being the same may
break. In particular, @ref GL::BufferImage::format() now returns
@ref GL::PixelFormat instead of @ref Magnum::PixelFormat, code depending on
the return type being implicitly convertible to @ref Magnum::PixelFormat
may break. In all other cases, @ref Image::format() "Image*::format()"
returns @ref Magnum::PixelFormat.
- `CompressedPixelFormat` has been moved verbatim to
@ref GL::CompressedPixelFormat and there's a new
@ref Magnum::CompressedPixelFormat enum for generic pixel formats. It
contains (deprecated) @ref GL::CompressedPixelFormat values for covering
most of backwards compatibility, but code that relies on these two types
being the same may break. In particular,
@ref GL::CompressedBufferImage::format() now returns
@ref GL::CompressedPixelFormat instead of @ref Magnum::CompressedPixelFormat,
code depending on the return type being implicitly convertible to
@ref Magnum::CompressedPixelFormat may break. In all other cases,
@ref CompressedImage::format() "CompressedImage*::format()"
returns @ref Magnum::CompressedPixelFormat.
- `MeshPrimitive` has been moved verbatim to @ref GL::MeshPrimitive and
there's a new @ref Magnum::MeshPrimitive enum for generic primitive types.
It contains (deprecated) additional @ref GL::MeshPrimitive values for
covering most of backwards compatibility, but code that relies on these
two types being the same (or have values that match GL enums) may break.
In particular, @ref GL::Mesh::primitive() now returns
@ref GL::MeshPrimitive instead of @ref Magnum::MeshPrimitive, code
depending on the return type being implicitly convertible to
@ref Magnum::MeshPrimitive may break. In all other cases,
`Trade::MeshData*D::primitive()` etc. returns @ref Magnum::MeshPrimitive.
- Configuration value reader/writers are now for only
@ref Magnum::MeshPrimitive and @ref Magnum::MeshIndexType, not for
@ref GL::MeshPrimitive or @ref GL::MeshIndexType
- @ref DebugTools::CompareImage no longer accepts GL-specific pixel formats,
only the non-deprecated values from the generic @ref PixelFormat enum
- The @ref Trade::TgaImageConverter "TgaImageConverter" plugin no longer
accepts GL-specific pixel formats, only the non-deprecated values from the
generic @ref PixelFormat enum
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
- The @ref Image::pixelSize(), @ref ImageView::pixelSize(),
@ref Trade::ImageData::pixelSize() and @ref GL::BufferImage::pixelSize()
Split the OpenGL layer out, pt 9: generic pixel formats. This is quite big, so: * There are new Magnum::PixelFormat and Magnum::CompressedPixelFormat enums, which contain generic API-independent formats. In particular, PixelFormat replaces GL::PixelFormat and GL::PixelType with a single value. * There's GL::pixelFormat(), GL::pixelType(), GL::compressedPixelFormat() to convert the generic enums to GL-specific. The mapping is only in one direction, done with a lookup table (generic enums are indices to that table). * GL classes taking the formats directly (such as GL::BufferImage) have overloads that take both the GL-specific and generic format. * The generic Image, CompressedImage, ImageView, CompressedImageView, and Trade::ImageData classes now accept the generic formats first-class. However, it's also possible to store an implementation-specific value to cover cases where a generic format enum doesn't have support for a particular format. This is done by wrapping the value using pixelFormatWrap() or compressedPixelFormatWrap(). Particular GPU APIs then assume it's their implementation-specific value and extract the value back using pixelFormatUnwrap() or compressedPixelFormatUnwrap(). There's also an isPixelFormatImplementationSpecific() and isCompressedPixelFormatImplementationSpecific() that distinguishes these values. * Many operations need pixel size and in order to have it even for implementation-specific formats, a corresponding pixelSize() overload is found via ADL on construction and the calculated size stored along the format. Previously the pixel size was only calculated on demand, but that's not possible now. In case such overload is not available, it's possible to pass pixel size manually as well. * In order to support the GL format+type pair, Image, ImageView and Trade::ImageData, there's now an additional untyped formatExtra() field that holds the second value. * The CompressedPixelStorage class is now unconditionally available on all targets, including OpenGL ES and WebGL. However, on OpenGL ES the GL APIs expect that it's all at default values. I attempted to preserve backwards compatibility as much as possible: * The PixelFormat and CompressedPixelFormat enum now contains generic API-independent values. The GL-specific formats are present there, but marked as deprecated. Use either the generic values or GL::PixelFormat (togehter with GL::PixelType) and GL::CompressedPixelFormat instead. There's a lot of ugliness caused by this, but seems to work well. * *Image::type() functions are deprecated as they were too GL-specific. Use formatExtra() and cast it to GL::PixelType instead. * Image constructors take templated format or format+extra arguments, so passing GL-specific values to them should still work.
8 years ago
functions now return @ref UnsignedInt instead of @cpp std::size_t @ce.
- Removed `PixelStorage::setSwapBytes()`, as every Magnum API dealing with
images basically only asserted that it's not set. Use
@ref Corrade::Utility::Endianness instead.
- 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 `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
- Removed the @cpp SceneGraph::TransformationType @ce enum that was
deprecated in 2015.05, use separate `<transform>()` and `<transform>Local()`
variants instead
- Removed @cpp SceneGraph::AbstractObject::hasFeatures() @ce, @cpp firstFeature() @ce,
@cpp lastFeature() @ce, @cpp SceneGraph::Object::hasChildren() @ce,
@cpp firstChild() @ce and @cpp lastChild() @ce that were deprecated in
2015.05, use methods on linked list returned by
@ref SceneGraph::AbstractObject::features() and
@ref SceneGraph::Object::children() instead
- Removed @cpp Platform::ScreenedApplication::frontScreen() @ce and
@cpp Platform::ScreenedApplication::backScreen() @ce that were deprecated
in 2015.05, use methods on linked list returned by
@ref Platform::BasicScreenedApplication::screens() "Platform::ScreenedApplication::screens()"
instead
- Removed @ref Framebuffer::read() "*Framebuffer::read()" functions taking two
vectors that was deprecated in 2015.05, use overload taking @ref Range2Di
instead
- Removed the @cpp Mesh::maxVertexAttributes() @ce function that was
deprecated in 2015.05, use @ref GL::AbstractShaderProgram::maxVertexAttributes()
instead
- Removed @cpp Math::Vector::dot() @ce, @cpp Math::Complex::dot() @ce,
@cpp Math::Quaternion::dot() @ce, @cpp Math::Vector::angle() @ce,
@cpp Math::Complex::angle() @ce, @cpp Math::Quaternion::angle() @ce,
@cpp Math::Quaternion::lerp() @ce, @cpp Math::Quaternion::slerp() @ce,
@cpp Math::Vector2::cross() @ce and @cpp Math::Vector3::cross() @ce that
were deprecated in 2015.05, use @ref Math::dot(), @ref Math::angle(),
@ref Math::lerp(), @ref Math::slerp() and @ref Math::cross() instead
- Removed @cpp *Framebuffer::bind(FramebufferTarget) @ce function that was
deprecated in 2%15.05, use parameter-less @ref GL::Framebuffer::bind() "*Framebuffer::bind()"
instead
- Removed @cpp FramebufferTarget::ReadDraw @ce enum value that was deprecated
in 2015.05, use separate @cpp FramebufferTarget::Read @ce and
@cpp FramebufferTarget::Draw @ce values instead
- Removed @ref GL::CubeMapTexture::imageSize() with explicit face parameter
that was deprecated in 2015.05, use overload that returns one value for all
faces instead
- Removed the `Magnum/DebugMessage.h` header that was deprecated in 2015.05,
use @ref Magnum/GL/DebugOutput.h instead
- Removed the @cpp DebugMessage::Severity @ce enum that was deprecated in
2015.05, use @ref GL::DebugOutput::Severity instead
- Removed @cpp DebugMessage::Callback @ce typedef, @cpp DebugMessage::setCallback() @ce
and @cpp DebugMessage::setDefaultCallback() @ce function that were
deprecated in 2015.05, use @ref GL::DebugOutput::Callback,
@ref GL::DebugOutput::setCallback() and
@ref GL::DebugOutput::setDefaultCallback() instead
- Removed @cpp DebugMessage::maxLoggedMessages() @ce and
@cpp DebugMessage::maxMessageLength() @ce functions that were deprecated in
2015.05, use @ref GL::DebugOutput::maxLoggedMessages() and
@ref GL::DebugOutput::maxMessageLength() instead
- Removed @cpp DebugMessage::setEnabled() @ce function and related values
from @cpp DebugMessage::Source @ce enum that were deprecated in 2015.05,
use @ref GL::DebugOutput::setEnabled() along with @ref GL::DebugOutput::Source,
@ref GL::DebugOutput::Type and @ref GL::DebugOutput::Severity instead
- Removed parameter-less @cpp *Query @ce constructor and parametrized
@cpp *Query::begin() @ce function that were deprecated in 2015.05, use
constructor with parameter and parameter-less
@ref GL::SampleQuery::begin() "GL::*Query::begin()" instead
- Removed `Timeline::setMinimalFrameTime()` that was deprecated since June
2015, use @ref Platform::Sdl2Application::setSwapInterval() "Platform::*Application::setSwapInterval()"
and/or @ref Platform::Sdl2Application::setMinimalLoopPeriod() "Platform::*Application::setMinimalLoopPeriod()"
instead
- Removed `SceneGraph::Camera2D::setProjection()`,
`SceneGraph::Camera3D::setOrthographic()` and
`SceneGraph::Camera3D::setPerspective()` that were deprecated since June
2015, use @ref SceneGraph::Camera::setProjectionMatrix() in combination
with @ref Matrix3::projection(), @ref Matrix4::orthographicProjection() and
@ref Matrix4::perspectiveProjection() instead
- Removed `SceneGraph::AbstractCamera`, `SceneGraph::AbstractBasicCamera2D`,
`SceneGraph::AbstractBasicCamera3D`, `SceneGraph::AbstractCamera2D` and
`SceneGraph::AbstractCamera3D` that were deprecated since June 2015, use
@ref SceneGraph::Camera, @ref SceneGraph::BasicCamera2D,
@ref SceneGraph::BasicCamera3D, @ref SceneGraph::Camera2D and
@ref SceneGraph::Camera3D instead
- Removed `Math::Matrix::IdentityType`, `Math::Matrix::ZeroType`,
`Math::Matrix::Identity` and `Math::Matrix::Zero` that were deprecated
since June 2015, use the @ref Math::IdentityInit and @ref Math::ZeroInit
tags instead
- Removed `Magnum/ImageReference.h` header and `ImageReference` type that
were deprecated since July 2015, use @ref Magnum/ImageView.h and
@ref ImageView instead
- Removed `Magnum/Color.h` header and `BasicColor3` and `BasiColor4` types
that were deprecated since August 2015, use @ref Magnum/Math/Color.h,
@ref Math::Color3 and @ref Math::Color4 instead
- Removed `Magnum/ColorFormat.h` header and `ColorFormat` and `ColorType`
enums that were deprecated since August 2015, use
@ref Magnum/GL/PixelFormat.h, @ref GL::PixelFormat and @ref GL::PixelType
instead
- Removed @ref Image, @ref ImageView, @ref Trade::ImageData constructors,
`Image::setData()` and `ImageView::setData()` taking `void*` that were
deprecated since August 2015, use constructors and functions taking
@ref Corrade::Containers::Array / @ref Corrade::Containers::ArrayView
instead
@subsection changelog-2018-04-docs Documentation
- A new @ref developers page containing step-by-step checklists for
maintainers and core developers
- A new set of @ref platforms "platform-specific guides" containing extended
information that was previously scattered across @ref Platform application
class docs and elsewhere
- Completely reworked @ref platforms-android "Android building"
documentation, now using Gradle CMake integration instead of the outdated
and no longer supported Apache Ant workflow.
- The @ref Primitives namespace now has contains images visualizing how
each primitive looks
- Compiling majority of code snippets to ensure they don't get out of sync
with the code
@section changelog-2018-02 2018.02
Released 2018-02-15, tagged as
[v2018.02](https://github.com/mosra/magnum/releases/tag/v2018.02). See the
8 years ago
[release announcement](https://blog.magnum.graphics/announcements/2018.02/) for
a high-level overview.
@subsection changelog-2018-02-dependencies Dependency changes
- Completely removed NaCl support (see https://blog.chromium.org/2017/05/goodbye-pnacl-hello-webassembly.html,
[mosra/magnum#198](https://github.com/mosra/magnum/issues/198))
- Dropped support for the old MinGW32 (only MinGW-w64 is supported now) (see
[mosra/magnum#46](https://github.com/mosra/magnum/issues/46)
- Bumped minimal CMake version to 2.8.12
- Removed support for macOS 10.8 and older
- Dropped the `compatibility` branch and all support for MSVC 2013 and GCC <
4.7
@subsection changelog-2018-02-new New features
- MSVC 2015 and MSVC 2017 support in `master` branch (see
[mosra/magnum#96](https://github.com/mosra/magnum/issues/96),
[mosra/magnum#209](https://github.com/mosra/magnum/pull/209))
- ANGLE ES2/ES3 support, ability to create desktop GLES contexts on Windows
- Windows Phone/Store support via ANGLE
- iOS support (see [mosra/magnum#82](https://github.com/mosra/magnum/issues/82))
- WebAssembly support when building for Emscripten (see also
[mosra/magnum-bootstrap#11](https://github.com/mosra/magnum-bootstrap/issues/11))
- WebGL 2.0 support
- New OpenGL extension support:
- @gl_extension{EXT,draw_buffers} ES2 extension
- @gl_extension{EXT,sRGB_write_control} ES extension
- @gl_extension{NV,polygon_mode} ES extension
- @gl_extension{KHR,blend_equation_advanced},
@gl_extension2{KHR,blend_equation_advanced_coherent,KHR_blend_equation_advanced}
desktop and ES extensions
- @gl_extension{ANDROID,extension_pack_es31a} ES3 extension, which
includes:
- @gl_extension{OES,texture_storage_multisample_2d_array}
- @gl_extension{OES,texture_stencil8}
- @gl_extension{EXT,texture_border_clamp}
- @gl_extension{EXT,texture_cube_map_array}
- @gl_extension{EXT,texture_buffer}
- @gl_extension{EXT,geometry_shader}
- @gl_extension{EXT,tessellation_shader}
- @gl_extension{NV,shader_noperspective_interpolation} ES3 extension
- @gl_extension{EXT,texture_compression_s3tc} desktop and ES extension,
@webgl_extension{WEBGL,compressed_texture_s3tc} WebGL extension
- @gl_extension2{KHR,texture_compression_astc_ldr,KHR_texture_compression_astc_hdr},
@gl_extension{KHR,texture_compression_astc_hdr} desktop and ES
extension
- @gl_extension{EXT,unpack_subimage} and @gl_extension{NV,pack_subimage}
ES2 extensions
- @gl_extension{ARB,uniform_buffer_object} and its ES3/WebGL2
counterpart, except for data layout queries
- @gl_extension{ARB,texture_barrier}
- @gl_extension{ARB,shader_storage_buffer_object} and its ES3.1
counterpart
- @gl_extension{ARB,compute_shader} and its ES3.1 counterpart
- @gl_extension{ARB,shader_image_load_store} and its ES3.1 counterpart
- @gl_extension{KHR,no_error} desktop and ES extension
- @gl_extension{EXT,shader_framebuffer_fetch}, @gl_extension{ARM,shader_framebuffer_fetch}
and @gl_extension{ARM,shader_framebuffer_fetch_depth_stencil} (partial
support)
- @gl_extension{ARB,transform_feedback2},
@gl_extension{ARB,transform_feedback3},
@gl_extension{AMD,transform_feedback3_lines_triangles},
@gl_extension{ARB,transform_feedback_overflow_query} desktop extension
and their ES3 counterparts, if applicable
(see [mosra/magnum#53](https://github.com/mosra/magnum/issues/53))
- Compressed image support:
- Added @ref CompressedPixelFormat enum, @ref CompressedImage,
@ref CompressedImageView and
@ref GL::CompressedBufferImage "CompressedBufferImage" classes
- Added @ref GL::Texture::setCompressedImage() "*Texture::setCompressedImage()",
@ref GL::Texture::setCompressedSubImage() "*Texture::setCompressedSubImage()"
and @ref GL::Texture::compressedImage() "Texture::compressedImage()"
functions
- Added @ref GL::Renderer::Hint::TextureCompression "Renderer::Hint::TextureCompression"
enum value
- Ability to pass arguments to engine startup via
@ref GL::Context "command-line and environment variables":
- The engine now prints what driver workarounds are enabled and gives the
user an ability to disable them via `--magnum-disable-workarounds`
- It's possible to disable OpenGL extensions to work around driver bugs
using `--magnum-disable-extensions`
- It's possible to control amount of log output on engine startup via
`--magnum-log`
- Published OpenGL test setup code to a new @ref GL::OpenGLTester "OpenGLTester"
library and added GPU time benchmarking to it
- Added @ref PixelStorage class, tracking OpenGL pixel storage state and
applying it prior to read and upload of image data (see
[mosra/magnum#104](https://github.com/mosra/magnum/issues/104))
- Added @ref NoCreate tag to control initialization of GL object classes
- Added templated version of @ref GL::Buffer::map() "Buffer::map*()"
functions
- New `BUILD_MULTITHREADED` @ref cmake "CMake option" and a corresponding
@cpp MAGNUM_BUILD_MULTITHREADED @ce CMake variable and preprocessor define
- Added @ref GL::Framebuffer::detach() "Framebuffer::detach()" as a
conunterpart to all the @ref GL::Framebuffer::attachTexture() "attach*()"
functions
- Added @ref GL::Framebuffer::attachLayeredTexture() "Framebuffer::attachLayeredTexture()"
for layered texture attachments
- Added @ref GL::AbstractFramebuffer::clearDepth() "AbstractFramebuffer::clearDepth()",
@ref GL::AbstractFramebuffer::clearStencil() "AbstractFramebuffer::clearStencil()",
@ref GL::AbstractFramebuffer::clearDepthStencil() "AbstractFramebuffer::clearStencil()",
@ref GL::DefaultFramebuffer::clearColor() "DefaultFramebuffer::clearColor()",
@ref GL::Framebuffer::clearColor() "Framebuffer::clearColor()"
- Added @ref GL::BufferImage::release() "{Compressed,}BufferImage::release()"
and an ability to create @ref GL::BufferImage "{Compressed,}BufferImage"
from an existing @ref GL::Buffer "Buffer"
- New @ref GL::Buffer::mapRead() "Buffer::mapRead()" convenience alternatives
to @ref GL::Buffer::map() "Buffer::map()" that return @cpp const @ce
pointer and implicitly map as read-only
- Implemented @ref GL::Renderer::setMemoryBarrier() "Renderer::setMemoryBarrier()"
and @ref GL::Renderer::setMemoryBarrierByRegion() "Renderer::setMemoryBarrierByRegion()"
- Added @ref GL::isVersionES() "isVersionES()" utility
- Added @ref GL::Context::isCoreProfile() "Context::isCoreProfile()"
- Added @ref GL::TransformFeedback::maxVertexStreams() "TransformFeedback::maxVertexStreams()"
limit query
@subsubsection changelog-2018-02-new-audio Audio library
- Ported to Emscripten (see [mosra/magnum#216](https://github.com/mosra/magnum/pull/216)
- Added @ref Audio::Source::position(), @ref Audio::Source::velocity(),
@ref Audio::Source::isRelative(), @ref Audio::Source::gain(),
@ref Audio::Source::minGain(), @ref Audio::Source::maxGain(),
@ref Audio::Source::referenceDistance(), @ref Audio::Source::rolloffFactor(),
@ref Audio::Source::maxDistance(), @ref Audio::Source::direction(),
@ref Audio::Source::innerConeAngle(), @ref Audio::Source::outerConeAngle(),
@ref Audio::Source::outerConeGain(), @ref Audio::Source::pitch() getters
(see [mosra/magnum#107](https://github.com/mosra/magnum/pull/107))
- Added @ref Audio::Renderer::listenerPosition(), @ref Audio::Renderer::listenerOrientation(),
@ref Audio::Renderer::listenerVelocity(), @ref Audio::Renderer::listenerGain(),
@ref Audio::Renderer::dopplerFactor(), @ref Audio::Renderer::speedOfSound(),
@ref Audio::Renderer::distanceModel() getters (see
[mosra/magnum#107](https://github.com/mosra/magnum/pull/107))
- Added debug operator for @ref Audio::Renderer::DistanceModel
- Added @ref Audio::Playable, @ref Audio::Listener scene graph features and
@ref Audio::PlayableGroup feature group (see
[mosra/magnum#110](https://github.com/mosra/magnum/pull/110),
[mosra/magnum#116](https://github.com/mosra/magnum/pull/116))
- New namespace @ref Audio::Extensions for OpenAL extensions, similar to
@ref GL::Extensions "Extensions" for OpenGL (see
[mosra/magnum#111](https://github.com/mosra/magnum/pull/111))
- HRTF support through @ref Audio::Context::Configuration::setHrtf(),
@ref Audio::Context::isHrtfEnabled(), @ref Audio::Context::hrtfStatus()
(see [mosra/magnum#121](https://github.com/mosra/magnum/pull/121))
- Floating-point audio support in @ref Audio::Buffer
- @ref Audio::WavImporter "WavAudioImporter" plugin now supports more
formats, is more flexible and gives better errors (see
[mosra/magnum#174](https://github.com/mosra/magnum/issues/174),
[mosra/magnum#175](https://github.com/mosra/magnum/pull/175),
[mosra/magnum#176](https://github.com/mosra/magnum/pull/176),
[mosra/magnum#177](https://github.com/mosra/magnum/pull/177),
[mosra/magnum#179](https://github.com/mosra/magnum/pull/179))
- New @ref magnum-al-info "magnum-al-info" utility, available for all desktop
platforms and Emscripten
@subsubsection changelog-2018-02-new-debugtools DebugTools library
- Added @ref DebugTools::bufferData(), @ref DebugTools::bufferSubData()
and @ref DebugTools::textureSubImage() debugging helpers to emulate missing
functionality on OpenGL ES
- New @ref DebugTools::CompareImage class for fuzzy image comparison in
@ref Corrade::TestSuite
@subsubsection changelog-2018-02-new-math Math library
- New @ref Math::Bezier class for handling N-dimensional M-order Bézier
curves (see [mosra/magnum#165](https://github.com/mosra/magnum/pull/165))
- New @ref Math::Frustum class and @ref Math::Geometry::Intersection::pointFrustum(),
`Math::Geometry::Intersection::boxFrustum()` functions (see
[mosra/magnum#185](https://github.com/mosra/magnum/pull/185)
- New @ref Math::Half class, @link Math::Literals::operator""_h @endlink
literal and @ref Math::packHalf() and @ref Math::unpackHalf() functions
- New @ref Math::Color3::fromSrgb(), @ref Math::Color3::toSrgb(),
@ref Math::Color4::fromSrgbAlpha(), @ref Math::Color4::toSrgbAlpha()
- 8-bit and float RGB, RGBA, sRGB and sRGBA literals in @ref Math::Literals
namespace
- Added @ref Math::Color3::fromXyz() "Math::Color*::fromXyz()",
@ref Math::Color3::toXyz() "Math::Color*::toXyz()", @ref Math::xyYToXyz()
and @ref Math::xyzToXyY()
- New @ref Math::pack() and @ref Math::unpack() functions for (un)packing
floats to an integral range with given number of bits
- Implemented @ref Math::sclerp() for dual quaternions (see
[mosra/magnum#114](https://github.com/mosra/magnum/pull/114),
[mosra/magnum#117](https://github.com/mosra/magnum/issues/117),
[mosra/magnum#118](https://github.com/mosra/magnum/pull/118),
[mosra/magnum#122](https://github.com/mosra/magnum/pull/122)
- Added @ref Math::sincos() for real and @ref Math::Dual numbers
- Added @ref Math::clamp() taking three vectors
- Added @ref Math::min() / @ref Math::max() taking a vector and a scalar
- Added @ref Math::min(), @ref Math::max() and @ref Math::minmax() for value
ranges (see [mosra/magnum#193](https://github.com/mosra/magnum/pull/193))
- Added @ref Math::pow(), @ref Math::log() and @ref Math::exp()
- Added @ref Math::Algorithms::qr(), @ref Math::Algorithms::gaussJordanInverted(),
@ref Math::Algorithms::kahanSum()
- Added `Math::Geometry::Distance::pointPlane()`,
`Math::Geometry::Distance::pointPlaneScaled()`,
`Math::Geometry::Distance::pointPlaneNormalized()` functions
- Added @ref Math::Range::contains() and @ref Math::join() to join two ranges
- Ability to convert @ref Math::Complex, @ref Math::DualComplex,
@ref Math::Quaternion, @ref Math::DualQuaternion, @ref Math::Color3,
@ref Math::Color4 and @ref Math::Range classes from/to external
representation
- Ability to construct @ref Math::Dual, @ref Math::Complex and
@ref Math::Quaternion from a different underlying type
- Added @ref Math::ZeroInit, @ref Math::NoInit, @ref Math::IdentityInit tags
to control initialization of all math classes
- Added @ref Math::lerp(const Vector<size, T>&, const Vector<size, T>&, const BoolVector<size>&)
- Added @ref Math::Vector::flipped(), @ref Math::RectangularMatrix::flippedCols(),
@ref Math::RectangularMatrix::flippedRows()
- Added @ref Math::TypeTraits::name() and @ref Math::TypeTraits::equalsZero()
- Added @ref Math::RectangularMatrix::setRow()
- Ability to multiply and divide @ref Math::Dual with a real number
- Ability to access @ref Math::Dual members via reference
- Ability to construct @ref Math::DualQuaternion from dual vector and scalar
- Ability to save and restore @ref Deg and @ref Rad from
@ref Corrade::Utility::Configuration
- Explicit bool conversion for @ref Math::BoolVector (see
[mosra/magnum#182](https://github.com/mosra/magnum/issues/182))
- Component-wise comparison for @ref Math::RectangularMatrix
- Ability to construct @ref Math::RectangularMatrix and derived classes
with one value for all components
@subsubsection changelog-2018-02-new-platform Platform libraries
- New @ref Platform::GlfwApplication class (see
[mosra/magnum#141](https://github.com/mosra/magnum/pull/141),
[mosra/magnum#160](https://github.com/mosra/magnum/pull/160),
[mosra/magnum-bootstrap#6](https://github.com/mosra/magnum-bootstrap/pull/6))
- Text input support in @ref Platform::Sdl2Application and
@ref Platform::GlfwApplication (see [mosra/magnum#129](https://github.com/mosra/magnum/issues/129))
- Added @ref Platform::WindowlessWindowsEglApplication and
@ref Platform::WindowlessIosApplication for ANGLE and iOS
- New @ref Platform::WindowlessEglApplication that works on headless NVidia,
Mesa drivers and Emscripten (see [mosra/magnum#133](https://github.com/mosra/magnum/pull/133))
- New @ref Platform::WindowlessGlxContext "Platform::Windowless*Context"
classes that manage OpenGL context to make threaded context creation
possible
- Ported @ref magnum-gl-info "magnum-info" to Emscripten
- First-class support for scroll events in
@ref Platform::Sdl2Application::MouseScrollEvent (see
[mosra/magnum#157](https://github.com/mosra/magnum/pull/157))
- Added @ref Platform::Sdl2Application::MouseEvent::clickCount()
- Added @ref Platform::Sdl2Application::multiGestureEvent()
- Exposing key repeat in
@ref Platform::Sdl2Application::KeyEvent::isRepeated() "Platform::*Application::KeyEvent::isRepeated()"
(see [mosra/magnum#161](https://github.com/mosra/magnum/issues/161),
[mosra/magnum#162](https://github.com/mosra/magnum/pull/162))
- Added @ref Platform::Sdl2Application::setMinimalLoopPeriod(), which, along
with @ref Platform::Sdl2Application::setSwapInterval() replaces
@cpp Timeline::setMinimalFrameTime() @ce
- Added @ref Platform::Sdl2Application::window() and
@ref Platform::GlfwApplication::window() to access the underlying window
handle
- Added @ref Platform::Sdl2Application::tickEvent()
- Added @ref Platform::GLContext::tryCreate() "Platform::Context::tryCreate()",
which allows the context to be destructed and created again in case the
version is not what the application wants (as opposed to just aborting the
application) (see [mosra/magnum#105](https://github.com/mosra/magnum/issues/105))
- Added @cpp Platform::Sdl2Application::Configuration::setSRGBCapable() @ce
- Added @ref Platform::Sdl2Application::Configuration::WindowFlag::Borderless
and `Platform::Sdl2Application::Configuration::WindowFlag::AllowHighDpi`
for iOS and macOS
- Added @ref Platform::WindowlessGlxApplication::Configuration::setFlags() "Platform::Windowless*Application::Configuration::setFlags()" with
@ref Platform::WindowlessGlxApplication::Configuration::Flag::Debug "Flag::Debug"
- @ref magnum-gl-info "magnum-info" now accepts `--short` and
`--extension-strings` options
- Added @ref Platform::Sdl2Application::windowSize(),
@ref Platform::GlfwApplication::windowSize()
- Extended @ref Platform::Sdl2Application::KeyEvent::Key to be consistent
with @ref Platform::GlfwApplication
- Added modifier keys to
@ref Platform::Sdl2Application::KeyEvent::Key "Platform::*Application::KeyEvent::Key"
- Added @ref Platform::Sdl2Application::InputEvent::Modifier::Super to be
consistent with @ref Platform::GlfwApplication (see
[mosra/magnum#159](https://github.com/mosra/magnum/pull/159))
- Added @ref Platform::Sdl2Application::KeyEvent::keyName() "Platform::*Application::KeyEvent::keyName()"
- It's now possible to iterate main loop manually using
@ref Platform::Sdl2Application::mainLoopIteration()
- Ability to pass command-line arguments to Emscripten browser apps, see
@ref Platform::Sdl2Application and @ref Platform::WindowlessEglApplication
for more information
@subsubsection changelog-2018-02-new-primitives Primitives library
- New @ref Primitives::axis2D() and @ref Primitives::axis3D() primitives
@subsubsection changelog-2018-02-new-shaders Shaders library
- Ability to construct all @ref Shaders classes without an OpenGL context
present using @ref NoCreate
@subsubsection changelog-2018-02-new-text Text library
- New @ref Text::AbstractFont::ascent() and @ref Text::AbstractFont::descent()
font properties
@subsubsection changelog-2018-02-new-trade Trade library
- New @ref magnum-imageconverter "magnum-imageconverter" utility
- Initial implementation of @ref Trade::CameraData and @ref Trade::LightData
- Vertex color support in @cpp Trade::MeshData2D @ce and
@cpp Trade::MeshData3D @ce
- @ref Trade::AbstractImageConverter member functions were changed to
non-@cpp const @ce to make implementation of complex converter plugins possible
- New @ref Trade::AbstractImageConverter::exportToCompressedImage() plugin
interface and @ref Trade::AbstractImageConverter::exportToData(),
@ref Trade::AbstractImageConverter::exportToFile() taking
@ref CompressedImageView as a parameter
- Providing access to plugin manager in @ref Trade::AbstractImporter,
@ref Trade::AbstractImageConverter and @ref Audio::AbstractImporter plugin
APIs now have access to the plugin manager in order to be able to load
other plugins
- @ref Trade::ImageData now handles both compressed and uncompressed
images, @ref Trade::AbstractImageConverter is able to take it and then
delegate to proper function based on whether the image is commpressed or
not
- @ref Trade::AbstractImporter and all `Trade::*Data` classes now provide
member `importerState()` functions allowing the user to access
importer-specific state
- Added @ref Trade::AbstractImporter::openState() (see
8 years ago
[mosra/magnum#225](https://github.com/mosra/magnum/pull/225))
- @ref magnum-distancefieldconverter "magnum-distancefieldconverter" now uses
@ref Trade::AnyImageConverter "AnyImageConverter" by default
- @ref Trade::TgaImporter "TgaImporter" sets proper @ref PixelStorage
alignment if rows are not four-byte aligned
- @ref Trade::TgaImageConverter "TgaImageConverter" now properly handles
@ref PixelStorage parameters
@subsection changelog-2018-02-changes Changes and improvements
- Functionality that is not available on WebGL (like debug output etc.) is
not present in WebGL builds to reduce compiled code size
- The @ref GL::Mesh "Mesh" class now stores a copy of @ref GL::Buffer "Buffer"
instance instead of reference, meaning that you can move your buffers
freely after assigning them to a mesh
- @ref GL::Texture::setStorage() "*Texture::setStorage()" fallback
implementation on OpenGL ES 2.0 and WebGL 1.0 now properly translates sized
texture formats to what the drivers expect (see
[mosra/magnum#214](https://github.com/mosra/magnum/issues/214))
- @ref Trade::TgaImporter "TgaImporter" and @ref Trade::TgaImageConverter "TgaImageConverter"
now consistently use RGB(A) on all platforms and don't require BGR(A) on
desktop
8 years ago
- Ignoring @cpp "No errors." @ce message produced by GLSL compiler/linker on
Intel Windows drivers.
- @ref GL::Texture::image() "*Texture::image()" and
@ref GL::Framebuffer::read() "*Framebuffer::read()"
now reallocate image data only if needed, for both @ref Image and
@ref GL::BufferImage "BufferImage" types
- R-value @ref Image "Image*" no longer restricts conversion to
@ref ImageView as it is a valid use case (for example passing output from
@ref GL::Framebuffer::read() "Framebuffer::read()" directly to
@ref Trade::AbstractImageConverter::exportToFile())
- It's no longer possible to call @ref Image::data() "Image*::data()" on
r-value instances as that would cause accessing freed data. Use
@ref Image::release() instead.
- @ref GL::Buffer::map() "Buffer::map()" now returns
@ref Corrade::Containers::ArrayView instead of a plain pointer for better
security
- Improved @ref GL::Context::resetState() "Context::resetState()" to better
handle corner cases with VAOs
- Graceful handling of broken GL contexts
- Behavior of @ref GL::Version::GLES200 "Version::GLES200" and upwards on
desktop OpenGL is changed to request an ES dialect of GLSL when used in
@ref GL::Shader "Shader" (instead of a particular desktop GL version that
supports given ES version), looks for @gl_extension{ARB,ES2_compatibility} and
others (instead of checking for a particular desktop GL version that
supports given ES version)
- Binding some default VAO in case the engine is running on core profile with
@gl_extension{ARB,vertex_array_object} disabled
- It's now possible to create @ref ImageView with @cpp nullptr @ce data (for
example for old-style texture allocation using
@ref GL::Texture::setImage() "Texture::setImage()")
- Various workarounds to make the engine working better on SVGA3D drivers
(VMWare guest)
- Various updates and code modernization (see
[mosra/magnum#200](https://github.com/mosra/magnum/pull/200))
@subsubsection changelog-2018-02-changes-math Math library
- @ref Double types are no longer restricted to just desktop GL builds, all
related types also work on ES and WebGL builds
- Default-constructed @ref Color4 has zero alpha now instead of fully opaque
black
- Proper implementation of @ref Math::Vector::isZero() for integers
- @ref Math::Matrix4::transformPoint() now properly uses the perspective
divide from projection matrices
- Updated @ref Math::TypeTraits fuzzy comparison epsilon values for
@cpp long double @ce and @cpp double @ce
- @ref Math::Matrix4::perspectiveProjection() now supports infinite far plane
- @ref Math::pow() now works for both vectors and scalars
- @ref Math::Vector::minmax() now works on arbitrary vectors instead of just
@ref Math::Vector2
@subsubsection changelog-2018-02-changes-platform Platform library
- Requesting core OpenGL context by default in @ref Platform::WindowlessGlxApplication
and @ref Platform::Sdl2Application. On binary NVidia, AMD and Windows Intel
drivers this causes the context to be stuck on OpenGL 3.1, in which case
the context is destroyed and old-style forward-compatible context is
requested instead.
- @ref Platform::Sdl2Application now leaves windows positioning on the system
instead of forcing the window to be centered
- @ref Platform::Sdl2Application now shows the window only once the GL
context is fully created to avoid flickering
@subsubsection changelog-2018-02-changes-shaders Shaders library
- @ref Shaders::Flat now sets default color to white only in textured version
- @ref Shaders::Phong gained the ability to have both color and texture
- @ref Shaders::Phong is now able to do alpha-masking (see
[mosra/magnum#112](https://github.com/mosra/magnum/issues/112),
[mosra/magnum-examples#29](https://github.com/mosra/magnum-examples/issues/29))
@subsection changelog-2018-02-buildsystem Build system
- Continuous testing for Linux, macOS, Windows MSVC, Windows MinGW, Windows RT,
iOS, Android and Emscripten on [Travis CI](https://travis-ci.org/mosra/magnum)
and [AppVeyor CI](https://ci.appveyor.com/project/mosra/magnum), with code
coverage on [codecov.io](https://codecov.io/gh/mosra/magnum); replacing the
unmaintained and outdated Jenkins configuration (see
[mosra/magnum#99](https://github.com/mosra/magnum/issues/99),
[mosra/magnum#120](https://github.com/mosra/magnum/pull/120),
[mosra/magnum#142](https://github.com/mosra/magnum/pull/142),
[mosra/magnum#203](https://github.com/mosra/magnum/pull/203))
- Support for CMake subprojects. You can now clone Magnum into a subdirectory
in your project and add it using @cmake add_subdirectory() @ce. The
@cmake find_package() @ce command will then use the CMake subproject
instead of looking for it in system-wide locations. See
[mosra/magnum#49](https://github.com/mosra/magnum/issues/49).
[mosra/magnum#140](https://github.com/mosra/magnum/issues/140).
- Reworked CMake buildsystem to use the new imported target workflow, see
@ref cmake for more information (see
[mosra/magnum#103](https://github.com/mosra/magnum/issues/103))
- CMake targets are now organized in folders for better development
experience in IDEs such as Visual Studio or Xcode
- Added @ref building-packages-brew "Homebrew package"
- Improvements and dependency updates to the
@ref building-packages-deb "Debian package" (see
[mosra/magnum#119](https://github.com/mosra/magnum/issues/119))
- Ability to build OpenGL tests also on Windows and macOS (see `BUILD_GL_TESTS`
@ref building-features "CMake option")
- Ability to override the implicit plugin directory using a
`MAGNUM_PLUGINS_DIR` CMake cache variable
- Ability to override deploy directory (used for example by Emscripten) using
a `MAGNUM_DEPLOY_PREFIX` CMake cache variable
- Better handling of compiled-in resources in static build. You don't need to
manually register resources when using Shaders library in static builds
(see [mosra/magnum-examples#9](https://github.com/mosra/magnum-examples/issues/9))
- `MACOSX_RPATH` is now enabled by default on CMake 3.0+ (see
[mosra/magnum#126](https://github.com/mosra/magnum/pull/126)
- Enabling only C++ in CMake @cmake project() @ce call, if possible, to speed
up initial CMake run
- Windowless application libraries now make use of the `BUILD_STATIC_PIC`
@ref cmake "CMake option"
- Fixed `FindSDL2.cmake` module to work out-of-the-box on Windows and macOS
(see [mosra/magnum#166](https://github.com/mosra/magnum/pull/166))
- Fixed `FindSDL2.cmake` to link to EGL when targeting GLES (see
[mosra/magnum-examples#9](https://github.com/mosra/magnum-examples/issues/9))
- Bundling a patched version of `FindOpenAL.cmake` to make it working on
Emscripten
- Fixed `EMSCRIPTEN` environment variable handling in Emscripten toolchains
(see [mosra/toolchains#2](https://github.com/mosra/toolchains/pull/2),
[mosra/toolchains#3](https://github.com/mosra/toolchains/issues/3))
@subsection changelog-2018-02-bugfixes Bug fixes
- Wrapping mode for @ref GL::CubeMapTexture "CubeMapTexture" is now correctly
two-dimensional instead of three-dimensional, wrapping mode for
@ref GL::Texture2DArray "TextureNDArray" is now correctly N-dimensional
instead of N+1
- Fixed WebGL context creation on Internet Explorer, it claims to have
version 0.94
- Fixed random browser-specific issues by avoiding the use of XHTML in
Emscripten builds
- @ref Trade::ObjImporter "ObjImporter" plugin now opens the files as binary
to avoid line ending issues
- Various compatibility updates to the @ref Shaders library
- Updates to OpenGL tests to work better on non-NVidia cards
- Various fixes for OpenGL object label queries on AMD drivers
- Fixed @cpp TextureTools::distanceField() @ce on 3.0 &lt;= GL < 3.2
- Fixed driver crash on AMD with @cpp TextureTools::distanceField() @ce
- @ref GL::Framebuffer::attachCubeMapTexture() "Framebuffer::attachCubeMapTexture()"
incorrectly behaved as a layered attachment (see
[mosra/magnum#123](https://github.com/mosra/magnum/issues/123))
- Fixed object label queries using the @gl_extension{EXT,debug_label}
extension
- @gl_extension{EXT,direct_state_access} function was accidentally used in
@gl_extension{ARB,direct_state_access} code path, causing crashes on Mesa
- Properly export @ref GL::Framebuffer::DrawAttachment "Framebuffer::DrawAttachment"
to avoid linker failures on Windows
- Fixed @ref GL::Framebuffer "Framebuffer" attachments on GLES2 drivers w/o
separate read/draw bindings (see
[mosra/magnum#204](https://github.com/mosra/magnum/issues/204))
- Fixed @ref GL::Framebuffer "Framebuffer" binding on WebGL (see
[mosra/magnum#134](https://github.com/mosra/magnum/pull/134))
- On Emscripten, @ref Platform::Sdl2Application was by default rendering a
800x600 canvas to an area of 640x480 pixels, causing severe aliasing.
Canvas is now by default sized to 640x480 to match the default CSS style.
- @ref Platform::WindowlessWglApplication is fixed to allow the GL context to
be created and destroyed multiple times during application run
- @ref SceneGraph::Camera now works properly with @ref Double underlying type
- It's now possible to delete a running @ref SceneGraph::Animable
- @ref Text::AbstractLayouter has now a virtual destructor to avoid leaking
its subclasses
- Fixed @ref Trade::ObjImporter on Android
- Fixed assertion when using @ref DebugTools::ObjectRenderer
- Fixed appearance of `Primitives::Cylinder::solid()` and
`Primitives::Circle::solid()` (see [mosra/magnum#197](https://github.com/mosra/magnum/pull/197),
[mosra/magnum#220](https://github.com/mosra/magnum/pull/220))
- Fixed a possible OOB access when reading @ref Math::Vector /
@ref Math::RectangularMatrix from @ref Corrade::Utility::Configuration
- Fixed unfortunate interaction of VAOs and index buffers on platforms
without direct state access
- Fixed resetting a bit in @ref Math::BoolVector::set() (see
[mosra/magnum#208](https://github.com/mosra/magnum/issues/208),
[mosra/magnum#
- @ref Audio::Context::hrtfSpecifierString() was crashing on systems
supporting only @alc_extension{SOFTX,HRTF} and not @alc_extension{SOFT,HRTF}
- Fixed bad interaction of builtin OpenGL headers and Qt on macOS (see
[mosra/magnum#212](https://github.com/mosra/magnum/issues/212))
- Fixed building for Android with standard build systems (see
[mosra/magnum#131](https://github.com/mosra/magnum/issues/131))
- Fixed building of WGL context library (see
[mosra/magnum#137](https://github.com/mosra/magnum/pull/137))
- Various compilation warning/error fixes on various compilers (see
[mosra/magnum#100](https://github.com/mosra/magnum/issues/100),
[mosra/magnum#109](https://github.com/mosra/magnum/issues/109),
[mosra/magnum#138](https://github.com/mosra/magnum/pull/138),
[mosra/magnum#189](https://github.com/mosra/magnum/issues/189),
[mosra/magnum#190](https://github.com/mosra/magnum/pull/190))
@subsection changelog-2018-02-deprecated Deprecated APIs
- `Timeline::setMinimalFrameTime()` is deprecated, use
@ref Platform::Sdl2Application::setSwapInterval() "Platform::*Application::setSwapInterval()"
and/or @ref Platform::Sdl2Application::setMinimalLoopPeriod() "Platform::*Application::setMinimalLoopPeriod()"
instead
- `SceneGraph::Camera2D::setProjection()`,
`SceneGraph::Camera3D::setOrthographic()` and
`SceneGraph::Camera3D::setPerspective()` are deprecated, use
@ref SceneGraph::Camera::setProjectionMatrix() in combination with
@ref Matrix3::projection(), @ref Matrix4::orthographicProjection() and
@ref Matrix4::perspectiveProjection() instead
- `SceneGraph::AbstractCamera`, `SceneGraph::AbstractBasicCamera2D`,
`SceneGraph::AbstractBasicCamera3D`, `SceneGraph::AbstractCamera2D` and
`SceneGraph::AbstractCamera3D` are deprecated, use @ref SceneGraph::Camera,
@ref SceneGraph::BasicCamera2D, @ref SceneGraph::BasicCamera3D, @ref SceneGraph::Camera2D and @ref SceneGraph::Camera3D instead
- `Math::Matrix::IdentityType`, `Math::Matrix::ZeroType`,
`Math::Matrix::Identity` and `Math::Matrix::Zero` are deprecated, use the
new @ref Math::IdentityInit and @ref Math::ZeroInit tags instead
- `AbstractShaderProgram::setUniform(Int, UnsignedInt, const T*)` is
deprecated, use @ref GL::AbstractShaderProgram::setUniform(Int, Containers::ArrayView<const Float>) "AbstractShaderProgram::setUniform(Int, Containers::ArrayView<const T>)"
instead
- `Magnum/ImageReference.h` header and `ImageReference` type is deprecated,
use @ref Magnum/ImageView.h and @ref ImageView instead
- `Magnum/Color.h` header and `BasicColor3` and `BasiColor4` types are
deprecated, use @ref Magnum/Math/Color.h, @ref Math::Color3 and
@ref Math::Color4 instead
- `Magnum/ColorFormat.h` header and `ColorFormat` and `ColorType` enums are
deprecated, use @ref Magnum/GL/PixelFormat.h "Magnum/PixelFormat.h",
@ref GL::PixelFormat "PixelFormat" and @ref GL::PixelType "PixelType"
instead
- @ref Image, @ref ImageView, @ref Trade::ImageData constructors,
`Image::setData()` and `ImageView::setData()` taking `void*` are
deprecated, use constructors and functions taking
@ref Corrade::Containers::Array / @ref Corrade::Containers::ArrayView
instead
- Templated @ref GL::Buffer::data() "Buffer:.data()",
@ref GL::Buffer::subData() "Buffer::subData()" and
@ref GL::Buffer::map() "Buffer::map()" are deprecated, use the
non-templated versions in combination with @ref Corrade::Containers::arrayCast()
instead (see [mosra/magnum#213](https://github.com/mosra/magnum/issues/213))
- `CubeMapTexture::Coordinate` enum is deprecated, use
@ref GL::CubeMapCoordinate "CubeMapCoordinate" instead
- @ref GL::Context::current() "Context::current()" and
@ref Audio::Context::current() returning a pointer is deprecated, it's
returning a reference now and asserts that a context exists. Use
@ref GL::Context::hasCurrent() "Context::hasCurrent()" and
@ref Audio::Context::hasCurrent() to check for context presence.
- Angle literals available directly in the @ref Magnum namespace are
deprecated, import the @ref Math::Literals namespace instead
- `Platform::Sdl2Application::MouseEvent::Button::WheelUp`,
`Platform::Sdl2Application::MouseEvent::Button::WheelDown`,
`Platform::GlfwApplication::MouseEvent::Button::WheelUp` and
`Platform::GlfwApplication::MouseEvent::Button::WheelDown` mouse events are
deprecated, use @ref Platform::Sdl2Application::mouseScrollEvent() /
@ref Platform::GlfwApplication::mouseScrollEvent() and
@ref Platform::Sdl2Application::MouseScrollEvent /
@ref Platform::GlfwApplication::MouseScrollEvent instead
- @ref Platform::Sdl2Application::Sdl2Application() "Platform::*Application::*Application()"
and @ref Platform::WindowlessGlxApplication::WindowlessGlxApplication() "Platform::Windowless*Application::Windowless*Application()"
constructors taking @cpp nullptr @ce are deprecated, use constructors
taking @ref NoCreateT instead to create an application without creating
OpenGL context
- `Math::Color*::fromHSV()` and `Math::Color*::toHSV()` are deprecated, use
@ref Math::Color3::fromHsv() "Math::Color*::fromHsv()" and
@ref Math::Color3::toHsv() "Math::Color*::toHsv()" instead
- `Math::normalize()` and `Math::denormalize()` had confusing naming and thus
are deprecated, use @ref Math::pack() and @ref Math::unpack() from the
@ref Magnum/Math/Packing.h header instead
- @cpp Trade::MeshData2D @ce and @cpp Trade::MeshData3D @ce constructors
without the `colors` parameter are deprecated, use the full ones instead
- @cpp Shaders::Generic::Color @ce vertex attribute implicit constructor is
deprecated, use a constructor with explicit component count instead
- The bundled @ref std::optional implementation was causing serious conflicts
8 years ago
with C++17 and it's now deprecated in favor of
@ref Corrade::Containers::Optional. (Deprecated) aliases and conversion
operators are provided for backwards compatibility.
- `Audio::Context::hrtfSpecifier()` is deprecated, use
@ref Audio::Context::hrtfSpecifierString() instead
@subsection changelog-2018-02-compatibility Potential compatibility breakages, removed APIs
- The `Math::Geometry::Distance` and `Math::Geometry::Intersection` classes
are now a namespace (might break `using` declarations, but otherwise it's
fully source-compatible)
- Removed `Context::majorVersion()` and `Context::minorVersion()` functions,
use @ref Context::version() instead
- Removed deprecated `Magnum/DebugMarker.h` header, use
`Magnum/DebugOutput.h` and @ref GL::DebugMessage "DebugMessage" class
instead
- Removed deprecated `*Buffer` values from
@ref GL::FramebufferBlit "FramebufferBlit", use values without the `Buffer`
suffix
- Removed deprecated list-argument functions taking pointers from @ref Audio
and @ref SceneGraph libraries, use lists of references instead
- Removed deprecated texture unit enums from @ref Shaders library, use
dedicated texture setters instead
- Removed deprecated `*Texture::maxLayers()` functions, use
@ref GL::Shader::maxCombinedTextureImageUnits() "Shader::maxCombinedTextureImageUnits()"
instead
- Removed deprecated @cpp MeshTools::combineIndexedArrays() @ce,
@ref MeshTools::compressIndices(), @ref MeshTools::interleave() and
@cpp MeshTools::removeDuplicates() @ce overloads, use the general ones
instead
- Removed deprecated `Mesh*::set*{Range,Count}()` functions, use
@ref GL::Mesh::setCount() "Mesh*::setCount()" and
@ref GL::MeshView::setIndexRange() "MeshView::setIndexRange()" instead
- Removed deprecated parameterless @cpp GL::Mesh::draw() @ce overload, use
the one with explicit shader parameter instead
- Removed deprecated `Context::Flag::Robustness` enum value, use
@ref GL::Context::Flag::RobustAccess "Context::Flag::RobustAccess" instead
- Removed deprecated `Texture::Target` enum, use dedicated
@ref GL::Texture "Texture", @ref GL::TextureArray "TextureArray",
@ref GL::RectangleTexture "RectangleTexture" and
@ref GL::MultisampleTexture "MultisampleTexture" classes instead
- Removed deprecated @ref Resource conversion operator, use explicit
conversion instead
- Removed deprecated `Framebuffer::attachTexture*D()` overloads, use one of
@ref GL::Framebuffer::attachTexture() "Framebuffer::attachTexture()" or
@ref GL::Framebuffer::attachTextureLayer() "Framebuffer::attachTextureLayer()"
overloads instead.
- Removed `SceneGraph::Camera3D::near()` and `SceneGraph::Camera3D::far()`
getters, because they can't be provided anymore with current more general
implementation. THe user is advised to cache the values on application side
if they are really needed.
- Removed `AbstractImage` class and `Magnum/AbstractImage.h` header, its
functionality is present in the @ref Image "Image*" classes directly
- Removed `Image::dataSize()` function as it has ambiguous meaning in regards
to recently added features, use @ref Image::dataProperties() "Image::dataProperties()"
instead
- The `FindGLFW.cmake` now prefers absolute includes (i.e. `GLFW/glfw3.h`
instead of just `glfw3.h`). The @ref Platform::GlfwApplication now depends
on this, so be sure to update your copy to avoid build issues.
@subsection changelog-2018-02-performance Performance improvements
- Reduced size of and number of allocations in @ref GL::Mesh "Mesh" class.
@subsection changelog-2018-02-docs Documentation
- New documentation theme powered by [m.css](http://mcss.mosra.cz) and
related massive updates of *everything* (see
[mosra/magnum#113](https://github.com/mosra/magnum/issues/113))
- Explicit list of extensions that are available in WebGL builds
- New page explaining @ref opengl-wrapping "OpenGL wrapper layer"
- Documented extra CMake modules in @ref cmake-modules
- The @ref building documentation now prefers package installation instead of
manual build
- Clarified behavior of @ref Math::Matrix4::lookAt() (see
[mosra/magnum#127](https://github.com/mosra/magnum/issues/127))
- Documented how to use Vcpkg packages
- Updated links to OpenGL API documentation (see
[mosra/magnum#196](https://github.com/mosra/magnum/pull/196)
- Various other documentation updates (see
[mosra/magnum#94](https://github.com/mosra/magnum/pull/94),
[mosra/magnum#135](https://github.com/mosra/magnum/pull/135),
[mosra/magnum#170](https://github.com/mosra/magnum/issues/170),
[mosra/magnum-plugins#17](https://github.com/mosra/magnum-plugins/issues/17),
[mosra/magnum-bootstrap#8](https://github.com/mosra/magnum-bootstrap/issues/8))
Changelogs for previous versions are available in @ref changelog-old.
*/
}