From 23f93cd65eaeb8340334bc6f4718e5004ea64b90 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Fri, 7 Sep 2012 15:50:12 +0200 Subject: [PATCH] Mention @fn_gl and @def_gl in Coding Style manual. --- doc/coding-style.dox | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/doc/coding-style.dox b/doc/coding-style.dox index 09fbdcb80..ad4b75de4 100644 --- a/doc/coding-style.dox +++ b/doc/coding-style.dox @@ -49,6 +49,21 @@ the operator is implemented (not of class in which the operator is implemented), thus efficiently connecting the two classes together in the documentation. +@subsubsection documentation-commands-ref_gl Links to related OpenGL functions and definitions + +If an function touches OpenGL, related OpenGL functions should be documented +in @c \@see block with @c \@fn_gl command. If only specific definition is used +in the function, document it with @c \@def_gl command. Example usage: +@code +// @see @fn_gl{Enable}/@fn_gl{Disable} with @def_gl{TEXTURE_CUBE_MAP_SEAMLESS} +inline static void setSeamless(bool enabled) { + enabled ? glEnable(GL_TEXTURE_CUBE_MAP_SEAMLESS) : glDisable(GL_TEXTURE_CUBE_MAP_SEAMLESS); +} +@endcode + +It produces link to the online manual, in this case @fn_gl{Enable}/@fn_gl{Disable} +with @def_gl{TEXTURE_CUBE_MAP_SEAMLESS}. + @subsubsection documentation-commands-extension Links to OpenGL extensions If an OpenGL extension is referenced in the documentation, it should be done