From a18ec9b6d8933f9700a2e71f0ccc8faef790d84e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 25 Jan 2019 19:58:08 +0100 Subject: [PATCH] Doc++ --- doc/platform.dox | 4 ++-- src/Magnum/GL/Buffer.h | 32 +++++++++++++++-------------- src/Magnum/Trade/AbstractImporter.h | 8 ++++---- 3 files changed, 23 insertions(+), 21 deletions(-) diff --git a/doc/platform.dox b/doc/platform.dox index cf21efb09..8272e71e9 100644 --- a/doc/platform.dox +++ b/doc/platform.dox @@ -144,8 +144,8 @@ this: @snippet MagnumPlatform.cpp configuration However, sometimes you would need to configure the application based on some -configuration file or system introspection. In that case you can pass `nullptr` -instead of @ref Platform::Sdl2Application::Configuration "Configuration" +configuration file or system introspection. In that case you can pass +@ref NoCreate instead of @ref Platform::Sdl2Application::Configuration "Configuration" instance and then specify it later with @ref Platform::Sdl2Application::create() "create()": @snippet MagnumPlatform.cpp createcontext diff --git a/src/Magnum/GL/Buffer.h b/src/Magnum/GL/Buffer.h index 75396aa57..11786486a 100644 --- a/src/Magnum/GL/Buffer.h +++ b/src/Magnum/GL/Buffer.h @@ -656,14 +656,15 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject { * @brief Bind ranges of buffers to given range of indexed targets * * Binds first buffer in the list to @p firstIndex, second to - * `firstIndex + 1` etc. Second parameter is offset, third is size. If - * any buffer is `nullptr`, given indexed target is unbound. The range - * of indices must respect limits for given @p target. The offsets must - * respect alignment, which is 4 bytes for @ref Target::AtomicCounter - * and implementation-defined for other targets. All the buffers must - * have allocated data store. If @gl_extension{ARB,multi_bind} (part of - * OpenGL 4.4) is not available, the feature is emulated with sequence - * of @ref bind(Target, UnsignedInt, GLintptr, GLsizeiptr) / + * @cpp firstIndex + 1 @ce etc. Second parameter is offset, third is + * size. If any buffer is @cpp nullptr @ce, given indexed target is + * unbound. The range of indices must respect limits for given + * @p target. The offsets must respect alignment, which is 4 bytes for + * @ref Target::AtomicCounter and implementation-defined for other + * targets. All the buffers must have allocated data store. If + * @gl_extension{ARB,multi_bind} (part of OpenGL 4.4) is not available, + * the feature is emulated with sequence of + * @ref bind(Target, UnsignedInt, GLintptr, GLsizeiptr) / * @ref unbind(Target, UnsignedInt) calls. * @note This function is meant to be used only internally from * @ref AbstractShaderProgram subclasses. See its documentation @@ -690,12 +691,13 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject { * @brief Bind buffers to given range of indexed targets * * Binds first buffer in the list to @p firstIndex, second to - * `firstIndex + 1` etc. If any buffer is `nullptr`, given indexed - * target is unbound. The range of indices must respect limits for - * given @p target. All the buffers must have allocated data store. If - * @gl_extension{ARB,multi_bind} (part of OpenGL 4.4) is not available, - * the feature is emulated with sequence of @ref bind(Target, UnsignedInt) - * / @ref unbind(Target, UnsignedInt) calls. + * @cpp firstIndex + 1 @ce etc. If any buffer is @cpp nullptr @ce, + * given indexed target is unbound. The range of indices must respect + * limits for given @p target. All the buffers must have allocated data + * store. If @gl_extension{ARB,multi_bind} (part of OpenGL 4.4) is not + * available, the feature is emulated with sequence of + * @ref bind(Target, UnsignedInt) / @ref unbind(Target, UnsignedInt) + * calls. * @note This function is meant to be used only internally from * @ref AbstractShaderProgram subclasses. See its documentation * for more information. @@ -1134,7 +1136,7 @@ class MAGNUM_GL_EXPORT Buffer: public AbstractObject { * @param length Length of the mapped memory in bytes * @param flags Flags. At least @ref MapFlag::Read or * @ref MapFlag::Write must be specified. - * @return Sized view to buffer data or `nullptr` on error + * @return Sized view to buffer data or @cpp nullptr @ce on error * * If neither @gl_extension{ARB,direct_state_access} (part of OpenGL 4.5) * nor @gl_extension{EXT,direct_state_access} desktop extension is diff --git a/src/Magnum/Trade/AbstractImporter.h b/src/Magnum/Trade/AbstractImporter.h index c2d257fe0..9d8d769e7 100644 --- a/src/Magnum/Trade/AbstractImporter.h +++ b/src/Magnum/Trade/AbstractImporter.h @@ -584,7 +584,7 @@ class MAGNUM_TRADE_EXPORT AbstractImporter: public PluginManager::AbstractManagi * @brief Two-dimensional object * @param id Object ID, from range [0, @ref object2DCount()). * - * Returns given object or `nullptr` if importing failed. + * Returns given object or @cpp nullptr @ce if importing failed. */ std::unique_ptr object2D(UnsignedInt id); @@ -611,7 +611,7 @@ class MAGNUM_TRADE_EXPORT AbstractImporter: public PluginManager::AbstractManagi * @brief Three-dimensional object * @param id Object ID, from range [0, @ref object3DCount()). * - * Returns given object or `nullptr` if importing failed. + * Returns given object or @cpp nullptr @ce if importing failed. */ std::unique_ptr object3D(UnsignedInt id); @@ -692,7 +692,7 @@ class MAGNUM_TRADE_EXPORT AbstractImporter: public PluginManager::AbstractManagi * @brief Material * @param id Material ID, from range [0, @ref materialCount()). * - * Returns given material or `nullptr` if importing failed. + * Returns given material or @cpp nullptr @ce if importing failed. */ std::unique_ptr material(UnsignedInt id); @@ -812,7 +812,7 @@ class MAGNUM_TRADE_EXPORT AbstractImporter: public PluginManager::AbstractManagi * The importer might provide access to its internal data structures * for currently opened document through this function. See * documentation of a particular plugin for more information about - * returned type and contents. Returns `nullptr` by default. + * returned type and contents. Returns @cpp nullptr @ce by default. * @see @ref AbstractMaterialData::importerState(), * @ref AnimationData::importerState(), @ref CameraData::importerState(), * @ref ImageData::importerState(), @ref LightData::importerState(),