From 1c4135fc09a926f9f682b56ea558260242198465 Mon Sep 17 00:00:00 2001 From: Lynix Date: Tue, 1 Mar 2016 15:37:05 +0100 Subject: [PATCH] Improve documentation Former-commit-id: 08d70f6a53a7f12d2748d145d1fe139595a1b39e --- include/Nazara/Core/AbstractLogger.docx | 1 + include/Nazara/Core/Algorithm.inl | 33 ++++++++++++++----------- include/Nazara/Core/Bitset.inl | 15 +++++------ include/Nazara/Core/CallOnExit.inl | 1 + include/Nazara/Core/Color.inl | 1 + include/Nazara/Core/Config.hpp | 5 ++++ include/Nazara/Core/Endianness.inl | 2 ++ include/Nazara/Core/Functor.inl | 27 ++++++++++++-------- include/Nazara/Core/Initializer.inl | 9 ++----- include/Nazara/Core/MemoryHelper.inl | 4 +-- include/Nazara/Core/MemoryPool.inl | 1 + include/Nazara/Core/MemoryStream.inl | 6 ++--- include/Nazara/Core/Mutex.inl | 1 + include/Nazara/Core/ObjectLibrary.inl | 8 ++---- include/Nazara/Core/ObjectRef.inl | 23 +++-------------- include/Nazara/Core/Primitive.inl | 27 +------------------- include/Nazara/Core/ResourceLoader.inl | 9 ++----- include/Nazara/Core/ResourceManager.inl | 12 ++------- include/Nazara/Core/Signal.inl | 17 +++++++------ include/Nazara/Core/SparsePtr.inl | 13 +++++----- include/Nazara/Core/Stream.inl | 1 + include/Nazara/Core/String.inl | 1 + include/Nazara/Core/TaskScheduler.inl | 1 + include/Nazara/Core/Thread.inl | 7 +++--- include/Nazara/Math/Algorithm.inl | 29 ++++++++++++++++++++++ include/Nazara/Math/BoundingVolume.inl | 19 +++++++------- include/Nazara/Math/Box.inl | 17 +++++++------ include/Nazara/Math/Config.hpp | 5 ++++ include/Nazara/Math/EulerAngles.inl | 11 +++++---- include/Nazara/Math/Frustum.inl | 5 ++-- include/Nazara/Math/Matrix4.inl | 11 +++++---- include/Nazara/Math/OrientedBox.inl | 13 +++++----- include/Nazara/Math/Plane.inl | 15 +++++------ include/Nazara/Math/Quaternion.inl | 13 +++++----- include/Nazara/Math/Ray.inl | 15 +++++------ include/Nazara/Math/Rect.inl | 17 +++++++------ include/Nazara/Math/Sphere.inl | 11 +++++---- include/Nazara/Math/Vector2.inl | 17 +++++++------ include/Nazara/Math/Vector3.inl | 19 +++++++------- include/Nazara/Math/Vector4.inl | 23 ++++++++--------- src/Nazara/Core/AbstractHash.cpp | 3 ++- src/Nazara/Core/AbstractLogger.cpp | 3 ++- src/Nazara/Core/ByteArray.cpp | 1 + src/Nazara/Core/ByteStream.cpp | 1 + src/Nazara/Core/Clock.cpp | 9 +------ src/Nazara/Core/ConditionVariable.cpp | 1 + src/Nazara/Core/Core.cpp | 3 ++- src/Nazara/Core/Directory.cpp | 1 + src/Nazara/Core/DynLib.cpp | 1 + src/Nazara/Core/Error.cpp | 1 + src/Nazara/Core/ErrorFlags.cpp | 1 + src/Nazara/Core/File.cpp | 1 + src/Nazara/Core/FileLogger.cpp | 1 + src/Nazara/Core/GuillotineBinPack.cpp | 1 + src/Nazara/Core/HardwareInfo.cpp | 1 + src/Nazara/Core/LockGuard.cpp | 1 + src/Nazara/Core/Log.cpp | 1 + src/Nazara/Core/MemoryManager.cpp | 1 + src/Nazara/Core/MemoryStream.cpp | 1 + src/Nazara/Core/MemoryView.cpp | 3 ++- src/Nazara/Core/Mutex.cpp | 1 + src/Nazara/Core/ParameterList.cpp | 1 + src/Nazara/Core/PluginManager.cpp | 1 + src/Nazara/Core/PrimitiveList.cpp | 1 + src/Nazara/Core/RefCounted.cpp | 1 + src/Nazara/Core/Resource.cpp | 1 + src/Nazara/Core/Semaphore.cpp | 1 + src/Nazara/Core/StdLogger.cpp | 1 + src/Nazara/Core/Stream.cpp | 1 + src/Nazara/Core/String.cpp | 1 + src/Nazara/Core/StringStream.cpp | 1 + src/Nazara/Core/TaskScheduler.cpp | 3 ++- src/Nazara/Core/Thread.cpp | 3 ++- src/Nazara/Core/Unicode.cpp | 1 + 74 files changed, 277 insertions(+), 242 deletions(-) diff --git a/include/Nazara/Core/AbstractLogger.docx b/include/Nazara/Core/AbstractLogger.docx index cdc37f3f8..6ac06b95c 100644 --- a/include/Nazara/Core/AbstractLogger.docx +++ b/include/Nazara/Core/AbstractLogger.docx @@ -3,6 +3,7 @@ // For conditions of distribution and use, see copyright notice in Config.hpp /*! +* \ingroup core * \class Nz::AbstractLogger * \brief Logger interface */ diff --git a/include/Nazara/Core/Algorithm.inl b/include/Nazara/Core/Algorithm.inl index a9855c62c..c45147d79 100644 --- a/include/Nazara/Core/Algorithm.inl +++ b/include/Nazara/Core/Algorithm.inl @@ -31,7 +31,8 @@ namespace Nz } /*! - * \brief Applies the tuple to the function + * \ingroup core + * \brief Applies the tuple to the function (e.g. calls the function using the tuple content as arguments) * \return The result of the function * * \param fn Function @@ -39,7 +40,6 @@ namespace Nz * * \see Apply */ - template auto Apply(F&& fn, Tuple&& t) { @@ -49,7 +49,8 @@ namespace Nz } /*! - * \brief Applies the tuple to the member function on an object + * \ingroup core + * \brief Applies the tuple to the member function on an object (e.g. calls the member function using the tuple content as arguments) * \return The result of the member function called * * \param object Object of a class @@ -58,7 +59,6 @@ namespace Nz * * \see Apply */ - template auto Apply(O& object, F&& fn, Tuple&& t) { @@ -68,15 +68,17 @@ namespace Nz } /*! + * \ingroup core * \brief Computes the hash of a hashable object * \return A bytearray which represents the hash * * \param hash Enumeration of type HashType - * \param v Object to hash, must be convertible to "Nz::String" + * \param v Object to hash * + * \remark a HashAppend specialization for type T is required + * * \see ComputeHash */ - template ByteArray ComputeHash(HashType hash, const T& v) { @@ -84,17 +86,18 @@ namespace Nz } /*! + * \ingroup core * \brief Computes the hash of a hashable object * \return A bytearray which represents the hash * * \param hash Pointer to abstract hash - * \param v Object to hash, must be convertible to "Nz::String" + * \param v Object to hash * * \remark Produce a NazaraAssert if pointer to Abstracthash is invalid + * \remark a HashAppend specialization for type T is required * * \see ComputeHash */ - template ByteArray ComputeHash(AbstractHash* hash, const T& v) { @@ -108,6 +111,7 @@ namespace Nz } /*! + * \ingroup core * \brief Returns the number of elements in a C-array * \return The number of elements * @@ -115,7 +119,6 @@ namespace Nz * * \see CountOf */ - template constexpr std::size_t CountOf(T(&name)[N]) noexcept { @@ -123,6 +126,7 @@ namespace Nz } /*! + * \ingroup core * \brief Returns the number of elements in a container * \return The number of elements * @@ -130,7 +134,6 @@ namespace Nz * * \see CountOf */ - template std::size_t CountOf(const T& c) { @@ -138,12 +141,12 @@ namespace Nz } /*! + * \ingroup core * \brief Combines two hash in one * * \param seed First value that will be modified (expected to be 64bits) * \param v Second value to hash */ - // Algorithm from CityHash by Google // http://stackoverflow.com/questions/8513911/how-to-create-a-good-hash-combine-with-64-bit-output-inspired-by-boosthash-co template @@ -167,6 +170,7 @@ namespace Nz template struct PointedType {typedef T type;}; /*! + * \ingroup core * \brief Serializes a boolean * \return true if serialization succedeed * @@ -175,7 +179,6 @@ namespace Nz * * \see Serialize, Unserialize */ - inline bool Serialize(SerializationContext& context, bool value) { if (context.currentBitPos == 8) @@ -194,6 +197,7 @@ namespace Nz } /*! + * \ingroup core * \brief Serializes an arithmetic type * \return true if serialization succedeed * @@ -202,7 +206,6 @@ namespace Nz * * \see Serialize, Unserialize */ - template std::enable_if_t::value, bool> Serialize(SerializationContext& context, T value) { @@ -222,6 +225,7 @@ namespace Nz } /*! + * \ingroup core * \brief Unserializes a boolean * \return true if unserialization succedeed * @@ -230,7 +234,6 @@ namespace Nz * * \see Serialize, Unserialize */ - inline bool Unserialize(SerializationContext& context, bool* value) { if (context.currentBitPos == 8) @@ -250,6 +253,7 @@ namespace Nz } /*! + * \ingroup core * \brief Unserializes an arithmetic type * \return true if unserialization succedeed * @@ -260,7 +264,6 @@ namespace Nz * * \see Serialize, Unserialize */ - template std::enable_if_t::value, bool> Unserialize(SerializationContext& context, T* value) { diff --git a/include/Nazara/Core/Bitset.inl b/include/Nazara/Core/Bitset.inl index 330d174bc..70c1158eb 100644 --- a/include/Nazara/Core/Bitset.inl +++ b/include/Nazara/Core/Bitset.inl @@ -17,14 +17,15 @@ namespace Nz { /*! - * \class Nz::Bitset + * \ingroup core + * \class Nz::Bitset * \brief Core class that represents a set of bits * * This class meets the requirements of Container, AllocatorAwareContainer, SequenceContainer */ /*! - * \brief Constructs a Bitset object by default + * \brief Constructs a Bitset object by default */ template @@ -34,7 +35,7 @@ namespace Nz } /*! - * \brief Constructs a Bitset object of bitCount bits to value val + * \brief Constructs a Bitset object of bitCount bits to value val * * \param bitCount Number of bits * \param val Value of those bits, by default false @@ -48,7 +49,7 @@ namespace Nz } /*! - * \brief Constructs a Bitset object from the contents initialized with a copy of the null-terminated character string pointed to by bits + * \brief Constructs a Bitset object from the contents initialized with a copy of the null-terminated character string pointed to by bits * * \param bits Null-terminated character string containing only '0' and '1' * @@ -62,7 +63,7 @@ namespace Nz } /*! - * \brief Constructs a Bitset object from the contents initialized with a copy of the character string pointed to by bits takings the bitCount first characters + * \brief Constructs a Bitset object from the contents initialized with a copy of the character string pointed to by bits takings the bitCount first characters * * \param bits Character string containing only '0' and '1' * \param bitCount Number of characters to take into consideration @@ -96,7 +97,7 @@ namespace Nz } /*! - * \brief Constructs a Bitset object from a Nz::String + * \brief Constructs a Bitset object from a Nz::String * * \param bits String containing only '0' and '1' */ @@ -912,7 +913,7 @@ namespace Nz template template - void* Bitset::Bit::operator&() const + void* Bitset::Bit::operator&() const { // The template is necessary to make it fail only when used static_assert(!BadCall, "It is impossible to take the address of a bit in a bitset"); diff --git a/include/Nazara/Core/CallOnExit.inl b/include/Nazara/Core/CallOnExit.inl index 987da852e..0318752cc 100644 --- a/include/Nazara/Core/CallOnExit.inl +++ b/include/Nazara/Core/CallOnExit.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::CallOnExit * \brief Core class that represents a function to call at the end of the scope */ diff --git a/include/Nazara/Core/Color.inl b/include/Nazara/Core/Color.inl index 7dcfc7d75..c3359cd0f 100644 --- a/include/Nazara/Core/Color.inl +++ b/include/Nazara/Core/Color.inl @@ -12,6 +12,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Color * \brief Core class that represents a color */ diff --git a/include/Nazara/Core/Config.hpp b/include/Nazara/Core/Config.hpp index bd67daec6..955b98c75 100644 --- a/include/Nazara/Core/Config.hpp +++ b/include/Nazara/Core/Config.hpp @@ -27,6 +27,11 @@ #ifndef NAZARA_CONFIG_CORE_HPP #define NAZARA_CONFIG_CORE_HPP +/*! +* \defgroup core (NazaraCore) Core module +* Core/System module including classes to handle threading, time, hardware info, memory management, etc... +*/ + /// Each modification of a parameter needs a recompilation of the module // Precision of reals when transformed into string (Max. numbers after the coma) diff --git a/include/Nazara/Core/Endianness.inl b/include/Nazara/Core/Endianness.inl index 72cb9fc43..400224920 100644 --- a/include/Nazara/Core/Endianness.inl +++ b/include/Nazara/Core/Endianness.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \brief Gets the platform endianness * \return Type of the endianness */ @@ -22,6 +23,7 @@ namespace Nz } /*! + * \ingroup core * \brief Swaps the byte for endianness operations * * \param buffer Raw memory diff --git a/include/Nazara/Core/Functor.inl b/include/Nazara/Core/Functor.inl index 96c22b175..d5cefe434 100644 --- a/include/Nazara/Core/Functor.inl +++ b/include/Nazara/Core/Functor.inl @@ -7,8 +7,9 @@ namespace Nz { /*! - * \class Nz::StdLogger - * \brief Core class that represents a functor + * \ingroup core + * \class Nz::FunctorWithoutArgs + * \brief Core class that represents a functor using a function without argument */ /*! @@ -16,7 +17,6 @@ namespace Nz * * \param func Function to execute */ - template FunctorWithoutArgs::FunctorWithoutArgs(F func) : m_func(func) @@ -26,7 +26,6 @@ namespace Nz /*! * \brief Runs the function */ - template void FunctorWithoutArgs::Run() { @@ -34,12 +33,17 @@ namespace Nz } /*! - * \brief Constructs a FunctorWithoutArgs object with a function and its arguments + * \ingroup core + * \class Nz::FunctorWithArgs + * \brief Core class that represents a functor using a function with arguments + */ + + /*! + * \brief Constructs a FunctorWithArgs object with a function and its arguments * * \param func Function to execute * \param args Arguments for the function */ - template FunctorWithArgs::FunctorWithArgs(F func, Args&&... args) : m_func(func), @@ -50,7 +54,6 @@ namespace Nz /*! * \brief Runs the function */ - template void FunctorWithArgs::Run() { @@ -58,12 +61,17 @@ namespace Nz } /*! - * \brief Constructs a FunctorWithoutArgs object with a member function and an object + * \ingroup core + * \class Nz::MemberWithoutArgs + * \brief Core class that represents a functor using a member function + */ + + /*! + * \brief Constructs a MemberWithoutArgs object with a member function and an object * * \param func Member function to execute * \param object Object to execute on */ - template MemberWithoutArgs::MemberWithoutArgs(void (C::*func)(), C* object) : m_func(func), @@ -74,7 +82,6 @@ namespace Nz /*! * \brief Runs the function */ - template void MemberWithoutArgs::Run() { diff --git a/include/Nazara/Core/Initializer.inl b/include/Nazara/Core/Initializer.inl index cbf613699..23cc7b2de 100644 --- a/include/Nazara/Core/Initializer.inl +++ b/include/Nazara/Core/Initializer.inl @@ -48,7 +48,8 @@ namespace Nz } /*! - * \class Nz::Initializer + * \ingroup core + * \class Nz::Initializer * \brief Core class that represents a module initializer */ @@ -57,7 +58,6 @@ namespace Nz * * \param initialize Initialize the module */ - template Initializer::Initializer(bool initialize) : m_initialized(false) @@ -71,7 +71,6 @@ namespace Nz * * \see Uninitialize */ - template Initializer::~Initializer() { @@ -83,7 +82,6 @@ namespace Nz * * \see Uninitialize */ - template bool Initializer::Initialize() { @@ -97,7 +95,6 @@ namespace Nz * \brief Checks whether the module is initialized * \return true if initialized */ - template bool Initializer::IsInitialized() const { @@ -109,7 +106,6 @@ namespace Nz * * \see Initialize */ - template void Initializer::Uninitialize() { @@ -121,7 +117,6 @@ namespace Nz * \brief Converts the initializer to boolean * \return true if initialized */ - template Initializer::operator bool() const { diff --git a/include/Nazara/Core/MemoryHelper.inl b/include/Nazara/Core/MemoryHelper.inl index 507f57bab..7f77dd041 100644 --- a/include/Nazara/Core/MemoryHelper.inl +++ b/include/Nazara/Core/MemoryHelper.inl @@ -17,6 +17,7 @@ namespace Nz { /*! + * \ingroup core * \fn Nz::MemoryHelper * \brief Core functions that helps the handle of memory in the engine */ @@ -26,7 +27,6 @@ namespace Nz * * \remark Uses MemoryManager with NAZARA_CORE_MANAGE_MEMORY defined else operator delete */ - inline void OperatorDelete(void* ptr) { #if NAZARA_CORE_MANAGE_MEMORY @@ -41,7 +41,6 @@ namespace Nz * * \remark Uses MemoryManager with NAZARA_CORE_MANAGE_MEMORY defined else operator new */ - inline void* OperatorNew(std::size_t size) { #if NAZARA_CORE_MANAGE_MEMORY @@ -58,7 +57,6 @@ namespace Nz * \param ptr Pointer to raw memory allocated * \param args Arguments for the constructor */ - template T* PlacementNew(void* ptr, Args&&... args) { diff --git a/include/Nazara/Core/MemoryPool.inl b/include/Nazara/Core/MemoryPool.inl index bd5bc8882..14c3868dd 100644 --- a/include/Nazara/Core/MemoryPool.inl +++ b/include/Nazara/Core/MemoryPool.inl @@ -10,6 +10,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::MemoryPool * \brief Core class that represents a memory pool */ diff --git a/include/Nazara/Core/MemoryStream.inl b/include/Nazara/Core/MemoryStream.inl index 839f2564c..79a19f467 100644 --- a/include/Nazara/Core/MemoryStream.inl +++ b/include/Nazara/Core/MemoryStream.inl @@ -8,9 +8,10 @@ namespace Nz { /*! + * \ingroup core + * \class Nz::MemoryStream * \brief Constructs a MemoryStream object by default */ - inline MemoryStream::MemoryStream() : Stream(StreamOption_None, OpenMode_ReadWrite), m_pos(0) @@ -23,7 +24,6 @@ namespace Nz * \param byteArray Bytes to stream * \param openMode Reading/writing mode for the stream */ - inline MemoryStream::MemoryStream(ByteArray* byteArray, UInt32 openMode) : MemoryStream() { @@ -36,7 +36,6 @@ namespace Nz * * \remark Produces a NazaraAssert if buffer is invalid */ - inline ByteArray& MemoryStream::GetBuffer() { NazaraAssert(m_buffer, "Invalid buffer"); @@ -50,7 +49,6 @@ namespace Nz * * \remark Produces a NazaraAssert if buffer is invalid */ - inline const ByteArray& MemoryStream::GetBuffer() const { NazaraAssert(m_buffer, "Invalid buffer"); diff --git a/include/Nazara/Core/Mutex.inl b/include/Nazara/Core/Mutex.inl index 7d0618071..fe4a77577 100644 --- a/include/Nazara/Core/Mutex.inl +++ b/include/Nazara/Core/Mutex.inl @@ -9,6 +9,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Mutex */ diff --git a/include/Nazara/Core/ObjectLibrary.inl b/include/Nazara/Core/ObjectLibrary.inl index 41497a808..e656a820e 100644 --- a/include/Nazara/Core/ObjectLibrary.inl +++ b/include/Nazara/Core/ObjectLibrary.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ObjectRef * \brief Core class that represents a reference to an object */ @@ -20,7 +21,6 @@ namespace Nz * * \remark Produces a NazaraError if object not found */ - template ObjectRef ObjectLibrary::Get(const String& name) { @@ -35,7 +35,6 @@ namespace Nz * \brief Checks whether the library has the object with that name * \return true if it the case */ - template bool ObjectLibrary::Has(const String& name) { @@ -48,7 +47,6 @@ namespace Nz * \param name Name of the object * \param object Object to stock */ - template void ObjectLibrary::Register(const String& name, ObjectRef object) { @@ -61,7 +59,6 @@ namespace Nz * * \param name Name of the object */ - template ObjectRef ObjectLibrary::Query(const String& name) { @@ -77,7 +74,6 @@ namespace Nz * * \param name Name of the object */ - template void ObjectLibrary::Unregister(const String& name) { @@ -87,7 +83,7 @@ namespace Nz template bool ObjectLibrary::Initialize() { - return true; // Que faire + return true; // Nothing to do } template diff --git a/include/Nazara/Core/ObjectRef.inl b/include/Nazara/Core/ObjectRef.inl index 7799b6cbd..ad74b4f2e 100644 --- a/include/Nazara/Core/ObjectRef.inl +++ b/include/Nazara/Core/ObjectRef.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ObjectRef * \brief Core class that represents a reference to an object */ @@ -15,7 +16,6 @@ namespace Nz /*! * \brief Constructs a ObjectRef object by default */ - template ObjectRef::ObjectRef() : m_object(nullptr) @@ -27,7 +27,6 @@ namespace Nz * * \param object Pointer to handle like a reference (can be nullptr) */ - template ObjectRef::ObjectRef(T* object) : m_object(object) @@ -41,7 +40,6 @@ namespace Nz * * \param ref ObjectRef to assign into this */ - template ObjectRef::ObjectRef(const ObjectRef& ref) : m_object(ref.m_object) @@ -55,7 +53,6 @@ namespace Nz * * \param ref ObjectRef of type U to convert to type T */ - template template ObjectRef::ObjectRef(const ObjectRef& ref) : @@ -68,7 +65,6 @@ namespace Nz * * \param ref ObjectRef to move into this */ - template ObjectRef::ObjectRef(ObjectRef&& ref) noexcept : m_object(ref.m_object) @@ -79,7 +75,6 @@ namespace Nz /*! * \brief Destructs the object (remove a reference to the object when shared) */ - template ObjectRef::~ObjectRef() { @@ -91,7 +86,6 @@ namespace Nz * \brief Gets the underlying pointer * \return Underlying pointer */ - template T* ObjectRef::Get() const { @@ -102,7 +96,6 @@ namespace Nz * \brief Checks whether the reference is valid * \return true if reference is not nullptr */ - template bool ObjectRef::IsValid() const { @@ -113,7 +106,6 @@ namespace Nz * \brief Releases the handle of the pointer * \return Underlying pointer */ - template T* ObjectRef::Release() { @@ -130,7 +122,6 @@ namespace Nz * \brief Resets the content of the ObjectRef with another pointer * \return true if old handle is destroyed */ - template bool ObjectRef::Reset(T* object) { @@ -154,7 +145,6 @@ namespace Nz * * \param ref ObjectRef to swap */ - template ObjectRef& ObjectRef::Swap(ObjectRef& ref) { @@ -169,7 +159,6 @@ namespace Nz * * \see IsValid */ - template ObjectRef::operator bool() const { @@ -180,7 +169,6 @@ namespace Nz * \brief Dereferences the ObjectRef * \return Underlying pointer */ - template ObjectRef::operator T*() const { @@ -191,20 +179,18 @@ namespace Nz * \brief Dereferences the ObjectRef * \return Underlying pointer */ - template T* ObjectRef::operator->() const { return m_object; } - + /*! * \brief Assigns the object into this * \return A reference to this * * \param object Pointer to handle like a reference (can be nullptr) */ - template ObjectRef& ObjectRef::operator=(T* object) { @@ -219,7 +205,6 @@ namespace Nz * * \param ref The other ObjectRef */ - template ObjectRef& ObjectRef::operator=(const ObjectRef& ref) { @@ -234,7 +219,6 @@ namespace Nz * * \param ref ObjectRef of type U to convert */ - template template ObjectRef& ObjectRef::operator=(const ObjectRef& ref) @@ -252,7 +236,6 @@ namespace Nz * * \param ref ObjectRef to move in this */ - template ObjectRef& ObjectRef::operator=(ObjectRef&& ref) noexcept { @@ -267,12 +250,12 @@ namespace Nz namespace std { /*! + * \ingroup core * \brief Gives a hash representation of the object, specialisation of std * \return Hash of the ObjectRef * * \param object Object to hash */ - template struct hash> { diff --git a/include/Nazara/Core/Primitive.inl b/include/Nazara/Core/Primitive.inl index 8aeecc5b6..8124a7ed9 100644 --- a/include/Nazara/Core/Primitive.inl +++ b/include/Nazara/Core/Primitive.inl @@ -7,6 +7,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::PrimitiveList * \brief Core class that represents a geometric primitive */ @@ -19,7 +20,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeBox(const Vector3f& lengths, const Vector3ui& subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -38,7 +38,6 @@ namespace Nz * \param rotation Rotation of the box * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeBox(const Vector3f& lengths, const Vector3ui& subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakeBox(lengths, subdivision, Matrix4f::Transform(position, rotation), uvCoords); @@ -53,7 +52,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeCone(float length, float radius, unsigned int subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -74,7 +72,6 @@ namespace Nz * \param rotation Rotation of the cone * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeCone(float length, float radius, unsigned int subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakeCone(length, radius, subdivision, Matrix4f::Transform(position, rotation), uvCoords); @@ -88,7 +85,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeCubicSphere(float size, unsigned int subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -108,7 +104,6 @@ namespace Nz * \param rotation Rotation of the cubic sphere * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeCubicSphere(float size, unsigned int subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakeCubicSphere(size, subdivision, Matrix4f::Transform(position, rotation), uvCoords); @@ -122,7 +117,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeIcoSphere(float size, unsigned int recursionLevel, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -142,7 +136,6 @@ namespace Nz * \param rotation Rotation of the icosphere * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeIcoSphere(float size, unsigned int recursionLevel, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakeIcoSphere(size, recursionLevel, Matrix4f::Transform(position, rotation), uvCoords); @@ -156,7 +149,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakePlane(const Vector2f& size, const Vector2ui& subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -174,7 +166,6 @@ namespace Nz * \param planeInfo Information for the plane * \param uvCoords Coordinates for texture */ - inline void Primitive::MakePlane(const Vector2f& size, const Vector2ui& subdivision, const Planef& planeInfo, const Rectf& uvCoords) { MakePlane(size, subdivision, Matrix4f::Transform(planeInfo.distance * planeInfo.normal, Quaternionf::RotationBetween(Vector3f::Up(), planeInfo.normal)), uvCoords); @@ -189,7 +180,6 @@ namespace Nz * \param rotation Rotation of the plane * \param uvCoords Coordinates for texture */ - inline void Primitive::MakePlane(const Vector2f& size, const Vector2ui& subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakePlane(size, subdivision, Matrix4f::Transform(position, rotation), uvCoords); @@ -204,7 +194,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeUVSphere(float size, unsigned int sliceCount, unsigned int stackCount, const Matrix4f& transformMatrix, const Rectf& uvCoords) { matrix = transformMatrix; @@ -226,7 +215,6 @@ namespace Nz * \param rotation Rotation of the box * \param uvCoords Coordinates for texture */ - inline void Primitive::MakeUVSphere(float size, unsigned int sliceCount, unsigned int stackCount, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { MakeUVSphere(size, sliceCount, stackCount, Matrix4f::Transform(position, rotation), uvCoords); @@ -241,7 +229,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Box(const Vector3f& lengths, const Vector3ui& subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -260,7 +247,6 @@ namespace Nz * \param rotation Rotation of the box * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Box(const Vector3f& lengths, const Vector3ui& subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; @@ -279,7 +265,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Cone(float length, float radius, unsigned int subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -299,7 +284,6 @@ namespace Nz * \param rotation Rotation of the cone * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Cone(float length, float radius, unsigned int subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; @@ -317,7 +301,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::CubicSphere(float size, unsigned int subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -336,7 +319,6 @@ namespace Nz * \param rotation Rotation of the cubic sphere * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::CubicSphere(float size, unsigned int subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; @@ -354,7 +336,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::IcoSphere(float size, unsigned int recursionLevel, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -373,7 +354,6 @@ namespace Nz * \param rotation Rotation of the icosphere * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::IcoSphere(float size, unsigned int recursionLevel, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; @@ -391,7 +371,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Plane(const Vector2f& size, const Vector2ui& subdivision, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -409,7 +388,6 @@ namespace Nz * \param planeInfo Information for the plane * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Plane(const Vector2f& size, const Vector2ui& subdivision, const Planef& plane, const Rectf& uvCoords) { Primitive primitive; @@ -428,7 +406,6 @@ namespace Nz * \param rotation Rotation of the plane * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::Plane(const Vector2f& size, const Vector2ui& subdivision, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; @@ -447,7 +424,6 @@ namespace Nz * \param transformMatrix Matrix to apply * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::UVSphere(float size, unsigned int sliceCount, unsigned int stackCount, const Matrix4f& transformMatrix, const Rectf& uvCoords) { Primitive primitive; @@ -467,7 +443,6 @@ namespace Nz * \param rotation Rotation of the box * \param uvCoords Coordinates for texture */ - inline Primitive Primitive::UVSphere(float size, unsigned int sliceCount, unsigned int stackCount, const Vector3f& position, const Quaternionf& rotation, const Rectf& uvCoords) { Primitive primitive; diff --git a/include/Nazara/Core/ResourceLoader.inl b/include/Nazara/Core/ResourceLoader.inl index e58ec1b33..f16ab6d6e 100644 --- a/include/Nazara/Core/ResourceLoader.inl +++ b/include/Nazara/Core/ResourceLoader.inl @@ -12,7 +12,8 @@ namespace Nz { /*! - * \class Nz::ResourceLoader + * \ingroup core + * \class Nz::ResourceLoader * \brief Core class that represents a loader of resources */ @@ -22,7 +23,6 @@ namespace Nz * * \param extension Extension of the file */ - template bool ResourceLoader::IsExtensionSupported(const String& extension) { @@ -52,7 +52,6 @@ namespace Nz * \remark Produces a NazaraWarning if loader failed * \remark Produces a NazaraError if all loaders failed or no loader was found */ - template bool ResourceLoader::LoadFromFile(Type* resource, const String& filePath, const Parameters& parameters) { @@ -171,7 +170,6 @@ namespace Nz * \remark Produces a NazaraWarning if loader failed * \remark Produces a NazaraError if all loaders failed or no loader was found */ - template bool ResourceLoader::LoadFromMemory(Type* resource, const void* data, unsigned int size, const Parameters& parameters) { @@ -268,7 +266,6 @@ namespace Nz * \remark Produces a NazaraWarning if loader failed * \remark Produces a NazaraError if all loaders failed or no loader was found */ - template bool ResourceLoader::LoadFromStream(Type* resource, Stream& stream, const Parameters& parameters) { @@ -336,7 +333,6 @@ namespace Nz * \param fileLoader Optional function to load the data from a file in the resource * \param memoryLoader Optional function to load the data from a raw memory in the resource */ - template void ResourceLoader::RegisterLoader(ExtensionGetter extensionGetter, StreamChecker checkFunc, StreamLoader streamLoader, FileLoader fileLoader, MemoryLoader memoryLoader) { @@ -368,7 +364,6 @@ namespace Nz * \param fileLoader Optional function to load the data from a file in the resource * \param memoryLoader Optional function to load the data from a raw memory in the resource */ - template void ResourceLoader::UnregisterLoader(ExtensionGetter extensionGetter, StreamChecker checkFunc, StreamLoader streamLoader, FileLoader fileLoader, MemoryLoader memoryLoader) { diff --git a/include/Nazara/Core/ResourceManager.inl b/include/Nazara/Core/ResourceManager.inl index 9c8dc903b..edc85068b 100644 --- a/include/Nazara/Core/ResourceManager.inl +++ b/include/Nazara/Core/ResourceManager.inl @@ -10,14 +10,14 @@ namespace Nz { /*! - * \class Nz::ResourceManager + * \ingroup core + * \class Nz::ResourceManager * \brief Core class that represents a resource manager */ /*! * \brief Clears the content of the manager */ - template void ResourceManager::Clear() { @@ -30,7 +30,6 @@ namespace Nz * * \param filePath Path to the asset that will be loaded */ - template ObjectRef ResourceManager::Get(const String& filePath) { @@ -63,7 +62,6 @@ namespace Nz * \brief Gets the defaults parameters for the load * \return Default parameters for loading from file */ - template const Parameters& ResourceManager::GetDefaultParameters() { @@ -73,7 +71,6 @@ namespace Nz /*! * \brief Purges the resource manager from every asset whose it is the only owner */ - template void ResourceManager::Purge() { @@ -97,7 +94,6 @@ namespace Nz * \param filePath Path for the resource * \param resource Object to associate with */ - template void ResourceManager::Register(const String& filePath, ObjectRef resource) { @@ -111,7 +107,6 @@ namespace Nz * * \param params Default parameters for loading from file */ - template void ResourceManager::SetDefaultParameters(const Parameters& params) { @@ -123,7 +118,6 @@ namespace Nz * * \param filePath Path for the resource */ - template void ResourceManager::Unregister(const String& filePath) { @@ -136,7 +130,6 @@ namespace Nz * \brief Initializes the resource manager * \return true */ - template bool ResourceManager::Initialize() { @@ -146,7 +139,6 @@ namespace Nz /*! * \brief Uninitialize the resource manager */ - template void ResourceManager::Uninitialize() { diff --git a/include/Nazara/Core/Signal.inl b/include/Nazara/Core/Signal.inl index de1609d78..466d87537 100644 --- a/include/Nazara/Core/Signal.inl +++ b/include/Nazara/Core/Signal.inl @@ -9,12 +9,13 @@ namespace Nz { /*! - * \class Nz::Signal + * \ingroup core + * \class Nz::Signal * \brief Core class that represents a signal, a list of objects waiting for its message */ /*! - * \brief Constructs a Signal object by default + * \brief Constructs a Signal object by default */ template @@ -24,7 +25,7 @@ namespace Nz } /*! - * \brief Constructs a Signal object by move semantic + * \brief Constructs a Signal object by move semantic * * \param signal Signal to move in this */ @@ -240,12 +241,12 @@ namespace Nz } /*! - * \class Nz::Signal::Connection + * \class Nz::Signal::Connection * \brief Core class that represents a connection attached to a signal */ /*! - * \brief Constructs a Signal::Connection object with a slot + * \brief Constructs a Signal::Connection object with a slot * * \param slot Slot of the listener */ @@ -293,12 +294,12 @@ namespace Nz } /*! - * \class Nz::Signal::ConnectionGuard + * \class Nz::Signal::ConnectionGuard * \brief Core class that represents a RAII for a connection attached to a signal */ /*! - * \brief Constructs a Signal::ConnectionGuard object with a connection + * \brief Constructs a Signal::ConnectionGuard object with a connection * * \param connection Connection for the scope */ @@ -310,7 +311,7 @@ namespace Nz } /*! - * \brief Constructs a Signal::ConnectionGuard object with a connection by move semantic + * \brief Constructs a Signal::ConnectionGuard object with a connection by move semantic * * \param connection Connection for the scope */ diff --git a/include/Nazara/Core/SparsePtr.inl b/include/Nazara/Core/SparsePtr.inl index 31e83addd..d81c1eac3 100644 --- a/include/Nazara/Core/SparsePtr.inl +++ b/include/Nazara/Core/SparsePtr.inl @@ -8,12 +8,13 @@ namespace Nz { /*! - * \class Nz::SparsePtr + * \ingroup core + * \class Nz::SparsePtr * \brief Core class that represents a pointer and the step between two elements */ /*! - * \brief Constructs a SparsePtr object by default + * \brief Constructs a SparsePtr object by default */ template @@ -23,7 +24,7 @@ namespace Nz } /*! - * \brief Constructs a SparsePtr object with a pointer + * \brief Constructs a SparsePtr object with a pointer * * \param ptr Pointer to data */ @@ -35,7 +36,7 @@ namespace Nz } /*! - * \brief Constructs a SparsePtr object with a pointer and a step + * \brief Constructs a SparsePtr object with a pointer and a step * * \param ptr Pointer to data * \param stride Step between two elements @@ -48,7 +49,7 @@ namespace Nz } /*! - * \brief Constructs a SparsePtr object from another type of SparsePtr + * \brief Constructs a SparsePtr object from another type of SparsePtr * * \param ptr Pointer to data of type U to convert to type T */ @@ -214,7 +215,7 @@ namespace Nz */ template - T* SparsePtr::operator->() const + T* SparsePtr::operator->() const { return reinterpret_cast(m_ptr); } diff --git a/include/Nazara/Core/Stream.inl b/include/Nazara/Core/Stream.inl index fa90682b0..aae7fe155 100644 --- a/include/Nazara/Core/Stream.inl +++ b/include/Nazara/Core/Stream.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \brief Constructs a Stream object with options * * \param streamOptions Options for the stream diff --git a/include/Nazara/Core/String.inl b/include/Nazara/Core/String.inl index 40c08d315..aa4343371 100644 --- a/include/Nazara/Core/String.inl +++ b/include/Nazara/Core/String.inl @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \brief Constructs a String object with a shared string by move semantic * * \param sharedString Shared string to move into this diff --git a/include/Nazara/Core/TaskScheduler.inl b/include/Nazara/Core/TaskScheduler.inl index ba64cfb1a..96e240081 100644 --- a/include/Nazara/Core/TaskScheduler.inl +++ b/include/Nazara/Core/TaskScheduler.inl @@ -7,6 +7,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::TaskScheduler * \brief Core class that represents a thread pool */ diff --git a/include/Nazara/Core/Thread.inl b/include/Nazara/Core/Thread.inl index f3de4ae24..f372c803f 100644 --- a/include/Nazara/Core/Thread.inl +++ b/include/Nazara/Core/Thread.inl @@ -8,12 +8,13 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Thread * \brief Core class that represents a thread */ /*! - * \brief Constructs a Thread object with a function + * \brief Constructs a Thread object with a function * * \param function Task the thread will execute in parallel */ @@ -25,7 +26,7 @@ namespace Nz } /*! - * \brief Constructs a Thread object with a function and its parameters + * \brief Constructs a Thread object with a function and its parameters * * \param function Task the thread will execute in parallel * \param args Arguments of the function @@ -38,7 +39,7 @@ namespace Nz } /*! - * \brief Constructs a Thread object with a member function and its object + * \brief Constructs a Thread object with a member function and its object * * \param function Task the thread will execute in parallel * \param object Object on which the method will be called diff --git a/include/Nazara/Math/Algorithm.inl b/include/Nazara/Math/Algorithm.inl index f18ee119e..e7e205e45 100644 --- a/include/Nazara/Math/Algorithm.inl +++ b/include/Nazara/Math/Algorithm.inl @@ -99,6 +99,7 @@ namespace Nz } /*! + * \ingroup math * \brief Approaches the objective, beginning with value and with increment * \return The nearest value of the objective you can get with the value and the increment for one step * @@ -120,6 +121,7 @@ namespace Nz } /*! + * \ingroup math * \brief Clamps value between min and max and returns the expected value * \return If value is not in the interval of min..max, value obtained is the nearest limit of this interval * @@ -135,6 +137,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets number of bits set in the number * \return The number of bits set to 1 * @@ -157,6 +160,7 @@ namespace Nz } /*! + * \ingroup math * \brief Converts degree to radian * \return The representation in radian of the angle in degree (0..2*pi) * @@ -170,6 +174,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the unit from degree and convert it according to NAZARA_MATH_ANGLE_RADIAN * \return Express the degrees * @@ -187,6 +192,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the unit from radian and convert it according to NAZARA_MATH_ANGLE_RADIAN * \return Express the radians * @@ -204,6 +210,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the nearest power of two for the number * \return First power of two containing the number * @@ -222,6 +229,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -249,6 +257,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -270,6 +279,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -285,6 +295,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -301,6 +312,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -316,6 +328,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits * @@ -332,6 +345,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits + 1 for the dot * @@ -346,6 +360,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits + 1 for the dot * @@ -360,6 +375,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the number of digits to represent the number in base 10 * \return Number of digits + 1 for the dot * @@ -374,6 +390,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the log in base 2 of integral number * \return Log of the number (floor) * @@ -391,6 +408,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the log in base 2 of integral number, only works for power of two ! * \return Log of the number * @@ -408,6 +426,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the power of integrals * \return base^exponent for integral * @@ -426,6 +445,7 @@ namespace Nz } /*! + * \ingroup math * \brief Interpolates the value to other one with a factor of interpolation * \return A new value which is the interpolation of two values * @@ -446,6 +466,7 @@ namespace Nz } /*! + * \ingroup math * \brief Multiplies X and Y, then add Z * \return The result of X * Y + Z * @@ -487,6 +508,7 @@ namespace Nz #endif /*! + * \ingroup math * \brief Normalizes the angle * \return Normalized value between 0..2*(pi if radian or 180 if degrees) * @@ -512,6 +534,7 @@ namespace Nz } /*! + * \ingroup math * \brief Checks whether two numbers are equal * \return true if they are equal within a certain epsilon * @@ -527,6 +550,7 @@ namespace Nz } /*! + * \ingroup math * \brief Checks whether two numbers are equal * \return true if they are equal within the max difference * @@ -547,6 +571,7 @@ namespace Nz } /*! + * \ingroup math * \brief Converts the number to String * \return String representation of the number * @@ -598,6 +623,7 @@ namespace Nz } /*! + * \ingroup math * \brief Converts radian to degree * \return The representation in degree of the angle in radian (0..360) * @@ -611,6 +637,7 @@ namespace Nz } /*! + * \ingroup math * \brief Converts the string to number * \return Number which is represented by the string * @@ -672,6 +699,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the degree from unit and convert it according to NAZARA_MATH_ANGLE_RADIAN * \return Express in degrees * @@ -689,6 +717,7 @@ namespace Nz } /*! + * \ingroup math * \brief Gets the radian from unit and convert it according to NAZARA_MATH_ANGLE_RADIAN * \return Express in radians * diff --git a/include/Nazara/Math/BoundingVolume.inl b/include/Nazara/Math/BoundingVolume.inl index 4cde59731..4047769dc 100644 --- a/include/Nazara/Math/BoundingVolume.inl +++ b/include/Nazara/Math/BoundingVolume.inl @@ -15,14 +15,15 @@ namespace Nz { /*! - * \class Nz::BoundingVolume + * \ingroup math + * \class Nz::BoundingVolume * \brief Math class that represents a bounding volume, a combination of a box and an oriented box * * \remark You need to call Update not to have undefined behaviour */ /*! - * \brief Constructs a BoundingVolume object by default + * \brief Constructs a BoundingVolume object by default * * \remark extend is set to Extend_Null, aabb and obb are uninitialized */ @@ -34,7 +35,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from Extend + * \brief Constructs a BoundingVolume object from Extend * \param Extend Extend of the volume part of enumeration Extend * * \remark Aabb and obb are uninitialized @@ -47,7 +48,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from its position and sizes + * \brief Constructs a BoundingVolume object from its position and sizes * * \param X X component of position * \param Y Y component of position @@ -66,7 +67,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from a box + * \brief Constructs a BoundingVolume object from a box * * \param box Box object * @@ -80,7 +81,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from an oriented box + * \brief Constructs a BoundingVolume object from an oriented box * * \param orientedBox OrientedBox object * @@ -94,7 +95,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from two vectors representing point of the space + * \brief Constructs a BoundingVolume object from two vectors representing point of the space * (X, Y, Z) will be the components minimum of the two vectors and the (width, height, depth) will be the components maximum - minimum * * \param vec1 First point @@ -110,7 +111,7 @@ namespace Nz } /*! - * \brief Constructs a BoundingVolume object from another type of BoundingVolume + * \brief Constructs a BoundingVolume object from another type of BoundingVolume * * \param volume BoundingVolume of type U to convert to type T */ @@ -272,7 +273,7 @@ namespace Nz } /*! - * \brief Sets a BoundingVolume object from two vectors representing point of the space + * \brief Sets a BoundingVolume object from two vectors representing point of the space * (X, Y, Z) will be the components minimum of the two vectors and the (width, height, depth) will be the components maximum - minimum * * \param vec1 First point diff --git a/include/Nazara/Math/Box.inl b/include/Nazara/Math/Box.inl index a377b7d8f..8c8d655ef 100644 --- a/include/Nazara/Math/Box.inl +++ b/include/Nazara/Math/Box.inl @@ -13,12 +13,13 @@ namespace Nz { /*! - * \class Nz::Box + * \ingroup math + * \class Nz::Box * \brief Math class that represents a three dimensional box */ /*! - * \brief Constructs a Box object from its width, height and depth + * \brief Constructs a Box object from its width, height and depth * * \param Width Width of the box (following X) * \param Height Height of the box (following Y) @@ -51,7 +52,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from an array of six elements + * \brief Constructs a Box object from an array of six elements * * \param vec[6] vec[0] is X position, vec[1] is Y position, vec[2] is Z position, vec[3] is width, vec[4] is height and vec[5] is depth */ @@ -63,7 +64,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from a Rect + * \brief Constructs a Box object from a Rect * * \param rect Rectangle which describes (X, Y) position and (width, height) lenghts * @@ -77,7 +78,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from a vector representing width, height and depth + * \brief Constructs a Box object from a vector representing width, height and depth * * \param lengths (Width, Height, Depth) of the box * @@ -91,7 +92,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from two vectors representing point of the space + * \brief Constructs a Box object from two vectors representing point of the space * (X, Y, Z) will be the components minimum of the two vectors and the (width, height, depth) will be the components maximum - minimum * * \param vec1 First point @@ -105,7 +106,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from another type of Box + * \brief Constructs a Box object from another type of Box * * \param box Box of type U to convert to type T */ @@ -540,7 +541,7 @@ namespace Nz } /*! - * \brief Constructs a Box object from its position and sizes + * \brief Constructs a Box object from its position and sizes * * \param X X component of position * \param Y Y component of position diff --git a/include/Nazara/Math/Config.hpp b/include/Nazara/Math/Config.hpp index 3d27848af..a4891a18a 100644 --- a/include/Nazara/Math/Config.hpp +++ b/include/Nazara/Math/Config.hpp @@ -28,6 +28,11 @@ #ifndef NAZARA_CONFIG_MATH_HPP #define NAZARA_CONFIG_MATH_HPP +/*! +* \defgroup math (NazaraMath) Mathematics module +* 2D/3D mathematics module including matrix, vector, box, sphere, quaternion, ... +*/ + /// Each modification of a paramater of the module needs a recompilation of the unit // Define the radian as unit for angles diff --git a/include/Nazara/Math/EulerAngles.inl b/include/Nazara/Math/EulerAngles.inl index 3e4eabc6a..5c442f6c9 100644 --- a/include/Nazara/Math/EulerAngles.inl +++ b/include/Nazara/Math/EulerAngles.inl @@ -16,14 +16,15 @@ namespace Nz { /*! - * \class Nz::Vector4 + * \ingroup math + * \class Nz::EulerAngles * \brief Math class that represents an Euler angle. Those describe a rotation transformation by rotating an object on its various axes in specified amounts per axis, and a specified axis order * * \remark Rotation are "left-handed", it means that you take your left hand, put your thumb finger in the direction you want and you other fingers represent the way of rotating */ /*! - * \brief Constructs a EulerAngles object from its components + * \brief Constructs a EulerAngles object from its components * * \param P Pitch component = X axis * \param Y Yaw component = Y axis @@ -37,7 +38,7 @@ namespace Nz } /*! - * \brief Constructs a EulerAngles object from an array of three elements + * \brief Constructs a EulerAngles object from an array of three elements * * \param angles[3] angles[0] is pitch component, angles[1] is yaw component and angles[2] is roll component */ @@ -49,7 +50,7 @@ namespace Nz } /*! - * \brief Constructs a EulerAngles object from a quaternion + * \brief Constructs a EulerAngles object from a quaternion * * \param quat Quaternion representing a rotation of space */ @@ -61,7 +62,7 @@ namespace Nz } /*! - * \brief Constructs a EulerAngles object from another type of EulerAngles + * \brief Constructs a EulerAngles object from another type of EulerAngles * * \param angles EulerAngles of type U to convert to type T */ diff --git a/include/Nazara/Math/Frustum.inl b/include/Nazara/Math/Frustum.inl index 35e63ca98..4ff2b8f1b 100644 --- a/include/Nazara/Math/Frustum.inl +++ b/include/Nazara/Math/Frustum.inl @@ -17,14 +17,15 @@ namespace Nz { /*! - * \class Nz::Frustum + * \ingroup math + * \class Nz::Frustum * \brief Math class that represents a frustum in the three dimensional vector space * * Frustums are used to determine what is inside the camera's field of view. They help speed up the rendering process */ /*! - * \brief Constructs a Frustum object from another type of Frustum + * \brief Constructs a Frustum object from another type of Frustum * * \param frustum Frustum of type U to convert to type T */ diff --git a/include/Nazara/Math/Matrix4.inl b/include/Nazara/Math/Matrix4.inl index a5b4fb631..935387eba 100644 --- a/include/Nazara/Math/Matrix4.inl +++ b/include/Nazara/Math/Matrix4.inl @@ -22,14 +22,15 @@ namespace Nz { /*! - * \class Nz::Matrix4 + * \ingroup math + * \class Nz::Matrix4 * \brief Math class that represents a transformation of the four dimensional vector space with the notion of projectivity * * \remark Matrix4 is said to be "row-major" and affine if last column is made of (0, 0, 0, 1) */ /*! - * \brief Constructs a Matrix4 object from its components + * \brief Constructs a Matrix4 object from its components * * \param rIJ Matrix components at index(I, J) */ @@ -47,7 +48,7 @@ namespace Nz } /*! - * \brief Constructs a Matrix4 object from an array of sixteen elements + * \brief Constructs a Matrix4 object from an array of sixteen elements * * \param matrix[16] Matrix components */ @@ -59,7 +60,7 @@ namespace Nz } /*! - * \brief Constructs a Matrix4 object from another type of Matrix4 + * \brief Constructs a Matrix4 object from another type of Matrix4 * * \param matrix Matrix4 of type U to convert to type T */ @@ -1785,7 +1786,7 @@ std::ostream& operator<<(std::ostream& out, const Nz::Matrix4& matrix) */ template -Nz::Matrix4 operator*(T scale, const Nz::Matrix4& matrix) +Nz::Matrix4 operator*(T scale, const Nz::Matrix4& matrix) { return matrix * scale; } diff --git a/include/Nazara/Math/OrientedBox.inl b/include/Nazara/Math/OrientedBox.inl index c1668118c..188b6d8fc 100644 --- a/include/Nazara/Math/OrientedBox.inl +++ b/include/Nazara/Math/OrientedBox.inl @@ -14,14 +14,15 @@ namespace Nz { /*! - * \class Nz::OrientedBox + * \ingroup math + * \class Nz::OrientedBox * \brief Math class that represents an oriented three dimensional box * * \remark You need to call Update not to have undefined behaviour */ /*! - * \brief Constructs a OrientedBox object from its position and sizes + * \brief Constructs a OrientedBox object from its position and sizes * * \param X X component of position * \param Y Y component of position @@ -38,7 +39,7 @@ namespace Nz } /*! - * \brief Constructs a OrientedBox object from a box + * \brief Constructs a OrientedBox object from a box * * \param box Box object */ @@ -50,7 +51,7 @@ namespace Nz } /*! - * \brief Constructs a OrientedBox object from two vectors representing point of the space + * \brief Constructs a OrientedBox object from two vectors representing point of the space * (X, Y, Z) will be the components minimum of the two vectors and the (width, height, depth) will be the components maximum - minimum * * \param vec1 First point @@ -64,7 +65,7 @@ namespace Nz } /*! - * \brief Constructs a OrientedBox object from another type of OrientedBox + * \brief Constructs a OrientedBox object from another type of OrientedBox * * \param orientedBox OrientedBox of type U to convert to type T */ @@ -178,7 +179,7 @@ namespace Nz } /*! - * \brief Sets a OrientedBox object from two vectors representing point of the space + * \brief Sets a OrientedBox object from two vectors representing point of the space * (X, Y, Z) will be the components minimum of the two vectors and the (width, height, depth) will be the components maximum - minimum * * \param vec1 First point diff --git a/include/Nazara/Math/Plane.inl b/include/Nazara/Math/Plane.inl index 9b29ab48a..29bd829b2 100644 --- a/include/Nazara/Math/Plane.inl +++ b/include/Nazara/Math/Plane.inl @@ -12,14 +12,15 @@ namespace Nz { /*! - * \class Nz::Vector4 + * \ingroup math + * \class Nz::Plane * \brief Math class that represents a plane in 3D * * \remark The convention used in this class is: If you ask for plane with normal (0, 1, 0) and distance 1, you will get 0 * X + 1 * Y + 0 * Z - 1 = 0 or Y = 1. Notice the sign minus before the distance on the left side of the equation */ /*! - * \brief Constructs a Plane object from its components + * \brief Constructs a Plane object from its components * * \param normalX X component of the normal * \param normalY Y component of the normal @@ -34,7 +35,7 @@ namespace Nz } /*! - * \brief Constructs a Plane object from an array of four elements + * \brief Constructs a Plane object from an array of four elements * * \param plane[4] plane[0] is X component, plane[1] is Y component, plane[2] is Z component and plane[3] is D */ @@ -46,7 +47,7 @@ namespace Nz } /*! - * \brief Constructs a Plane object from a normal and a distance + * \brief Constructs a Plane object from a normal and a distance * * \param Normal normal of the vector * \param D Distance to origin @@ -59,7 +60,7 @@ namespace Nz } /*! - * \brief Constructs a Plane object from a normal and a point + * \brief Constructs a Plane object from a normal and a point * * \param Normal Normal of the plane * \param point Point which verifies the equation of the plane @@ -72,7 +73,7 @@ namespace Nz } /*! - * \brief Constructs a Plane object from three points + * \brief Constructs a Plane object from three points * * \param point1 First point * \param point2 Second point @@ -88,7 +89,7 @@ namespace Nz } /*! - * \brief Constructs a Plane object from another type of Plane + * \brief Constructs a Plane object from another type of Plane * * \param plane Plane of type U to convert to type T */ diff --git a/include/Nazara/Math/Quaternion.inl b/include/Nazara/Math/Quaternion.inl index ea1ce4d3e..75e3966d3 100644 --- a/include/Nazara/Math/Quaternion.inl +++ b/include/Nazara/Math/Quaternion.inl @@ -16,14 +16,15 @@ namespace Nz { /*! - * \class Nz::Quaternion + * \ingroup math + * \class Nz::Quaternion * \brief Math class that represents an element of the quaternions * * \remark The quaternion is meant to be 'unit' to represent rotations in a three dimensional space */ /*! - * \brief Constructs a Quaternion object from its components + * \brief Constructs a Quaternion object from its components * * \param W W component * \param X X component @@ -38,7 +39,7 @@ namespace Nz } /*! - * \brief Constructs a Quaternion object from a EulerAngles + * \brief Constructs a Quaternion object from a EulerAngles * * \param angles Easier representation of rotation of space * @@ -52,7 +53,7 @@ namespace Nz } /*! - * \brief Constructs a Quaternion object from an angle and a direction + * \brief Constructs a Quaternion object from an angle and a direction * * \param angle Unit depends of NAZARA_MATH_ANGLE_RADIAN * \param axis Vector3 which represents a direction, no need to be normalized @@ -65,7 +66,7 @@ namespace Nz } /*! - * \brief Constructs a Quaternion object from an array of four elements + * \brief Constructs a Quaternion object from an array of four elements * * \param quat[4] quat[0] is W component, quat[1] is X component, quat[2] is Y component and quat[3] is Z component */ @@ -85,7 +86,7 @@ namespace Nz */ /*! - * \brief Constructs a Quaternion object from another type of Quaternion + * \brief Constructs a Quaternion object from another type of Quaternion * * \param quat Quaternion of type U to convert to type T */ diff --git a/include/Nazara/Math/Ray.inl b/include/Nazara/Math/Ray.inl index de2b2d726..e83c39488 100644 --- a/include/Nazara/Math/Ray.inl +++ b/include/Nazara/Math/Ray.inl @@ -11,14 +11,15 @@ namespace Nz { /*! - * \class Nz::Ray + * \ingroup math + * \class Nz::Ray * \brief Math class that represents a ray or a straight line in 3D space * * This ray is meant to be understood like origin + lambda * direction, where lambda is a real positive parameter */ /*! - * \brief Constructs a Ray object from its position and direction + * \brief Constructs a Ray object from its position and direction * * \param X X position * \param Y Y position @@ -35,7 +36,7 @@ namespace Nz } /*! - * \brief Constructs a Ray object from two Vector3 + * \brief Constructs a Ray object from two Vector3 * * \param Origin Vector which represents the origin of the ray * \param Direction Vector which represents the direction of the ray @@ -48,7 +49,7 @@ namespace Nz } /*! - * \brief Constructs a Ray object from two arrays of three elements + * \brief Constructs a Ray object from two arrays of three elements * * \param Origin[3] Origin[0] is X position, Origin[1] is Y position and Origin[2] is Z position * \param Direction[3] Direction[0] is X direction, Direction[1] is Y direction and Direction[2] is Z direction @@ -61,7 +62,7 @@ namespace Nz } /*! - * \brief Constructs a Ray object from the intersection of two planes + * \brief Constructs a Ray object from the intersection of two planes * * \param planeOne First plane * \param planeTwo Second secant plane @@ -77,7 +78,7 @@ namespace Nz } /*! - * \brief Constructs a Ray object from another type of Ray + * \brief Constructs a Ray object from another type of Ray * * \param ray Ray of type U to convert to type T */ @@ -90,7 +91,7 @@ namespace Nz } /*! - * \brief Constructs a Ray object from two Vector3 from another type of Ray + * \brief Constructs a Ray object from two Vector3 from another type of Ray * * \param Origin Origin of type U to convert to type T * \param Direction Direction of type U to convert to type T diff --git a/include/Nazara/Math/Rect.inl b/include/Nazara/Math/Rect.inl index 82c9e9f3f..9a2737a02 100644 --- a/include/Nazara/Math/Rect.inl +++ b/include/Nazara/Math/Rect.inl @@ -13,14 +13,15 @@ namespace Nz { /*! - * \class Nz::Rect + * \ingroup math + * \class Nz::Rect * \brief Math class that represents an axis-aligned rectangle in two dimensions * * \remark The basis is said to be "left-hand". It means that with your left hand, the thumb is X positive, the index finger Y positive pointing to the bottom */ /*! - * \brief Constructs a Rect object from its width and height + * \brief Constructs a Rect object from its width and height * * \param Width Width of the rectangle (following X) * \param Height Height of the rectangle (following Y) @@ -35,7 +36,7 @@ namespace Nz } /*! - * \brief Constructs a Rect object from its position, width and height + * \brief Constructs a Rect object from its position, width and height * * \param X X position * \param Y Y position @@ -50,7 +51,7 @@ namespace Nz } /*! - * \brief Constructs a Rect object from an array of four elements + * \brief Constructs a Rect object from an array of four elements * * \param vec[4] vec[0] is X position, vec[1] is Y position, vec[2] is width and vec[3] is height */ @@ -62,7 +63,7 @@ namespace Nz } /*! - * \brief Constructs a Rect object from a vector representing width and height + * \brief Constructs a Rect object from a vector representing width and height * * \param lengths (Width, Height) of the rectangle * @@ -76,7 +77,7 @@ namespace Nz } /*! - * \brief Constructs a Rect object from two vectors representing point of the space + * \brief Constructs a Rect object from two vectors representing point of the space * (X, Y) will be the components minimum of the two vectors and the width and height will be the components maximum - minimum * * \param vec1 First point @@ -90,7 +91,7 @@ namespace Nz } /*! - * \brief Constructs a Rect object from another type of Rect + * \brief Constructs a Rect object from another type of Rect * * \param rect Rect of type U to convert to type T */ @@ -504,7 +505,7 @@ namespace Nz } /*! - * \brief Sets a Rect object from two vectors representing point of the space + * \brief Sets a Rect object from two vectors representing point of the space * (X, Y) will be the components minimum of the two vectors and the width and height will be the components maximum - minimum * \return A reference to this rectangle * diff --git a/include/Nazara/Math/Sphere.inl b/include/Nazara/Math/Sphere.inl index 062a7b271..eac46d76c 100644 --- a/include/Nazara/Math/Sphere.inl +++ b/include/Nazara/Math/Sphere.inl @@ -14,12 +14,13 @@ namespace Nz { /*! - * \class Nz::Sphere + * \ingroup math + * \class Nz::Sphere * \brief Math class that represents a sphere "S2" in a three dimensional euclidean space */ /*! - * \brief Constructs a Sphere object from its center position and radius + * \brief Constructs a Sphere object from its center position and radius * * \param X X position * \param Y Y position @@ -41,7 +42,7 @@ namespace Nz */ /*! - * \brief Constructs a Sphere object from its position and radius + * \brief Constructs a Sphere object from its position and radius * * \param center Center of the sphere * \param Radius Half of the diameter @@ -54,7 +55,7 @@ namespace Nz } /*! - * \brief Constructs a Sphere object from an array of four elements + * \brief Constructs a Sphere object from an array of four elements * * \param sphere[4] sphere[0] is X component, sphere[1] is Y component, sphere[2] is Z component and sphere[3] is radius */ @@ -66,7 +67,7 @@ namespace Nz } /*! - * \brief Constructs a Sphere object from another type of Sphere + * \brief Constructs a Sphere object from another type of Sphere * * \param sphere Sphere of type U to convert to type T */ diff --git a/include/Nazara/Math/Vector2.inl b/include/Nazara/Math/Vector2.inl index 1876087f5..45e8d8f5d 100644 --- a/include/Nazara/Math/Vector2.inl +++ b/include/Nazara/Math/Vector2.inl @@ -14,12 +14,13 @@ namespace Nz { /*! - * \class Nz::Vector2 + * \ingroup math + * \class Nz::Vector2 * \brief Math class that represents an element of the two dimensional vector space */ /*! - * \brief Constructs a Vector2 object from its coordinates + * \brief Constructs a Vector2 object from its coordinates * * \param X X component * \param Y Y component @@ -32,7 +33,7 @@ namespace Nz } /*! - * \brief Constructs explicitely a Vector2 object from its "scale" + * \brief Constructs explicitely a Vector2 object from its "scale" * * \param scale X component = Y component */ @@ -44,7 +45,7 @@ namespace Nz } /*! - * \brief Constructs a Vector2 object from an array of two elements + * \brief Constructs a Vector2 object from an array of two elements * * \param vec[2] vec[0] is X component and vec[1] is Y component */ @@ -56,7 +57,7 @@ namespace Nz } /*! - * \brief Constructs a Vector2 object from another type of Vector2 + * \brief Constructs a Vector2 object from another type of Vector2 * * \param vec Vector of type U to convert to type T */ @@ -69,7 +70,7 @@ namespace Nz } /*! - * \brief Constructs a Vector2 object from a Vector3 + * \brief Constructs a Vector2 object from a Vector3 * * \param vec Vector3 where only the first two components are taken */ @@ -81,7 +82,7 @@ namespace Nz } /*! - * \brief Constructs a Vector2 object from a Vector4 + * \brief Constructs a Vector2 object from a Vector4 * * \param vec Vector4 where only the first two components are taken */ @@ -988,7 +989,7 @@ std::ostream& operator<<(std::ostream& out, const Nz::Vector2& vec) */ template -Nz::Vector2 operator*(T scale, const Nz::Vector2& vec) +Nz::Vector2 operator*(T scale, const Nz::Vector2& vec) { return Nz::Vector2(scale * vec.x, scale * vec.y); } diff --git a/include/Nazara/Math/Vector3.inl b/include/Nazara/Math/Vector3.inl index a1807c902..f25fc5ba4 100644 --- a/include/Nazara/Math/Vector3.inl +++ b/include/Nazara/Math/Vector3.inl @@ -14,14 +14,15 @@ namespace Nz { /*! - * \class Nz::Vector2 + * \ingroup math + * \class Nz::Vector3 * \brief Math class that represents an element of the three dimensional vector space * * \remark The basis is said to be "right-hand". It means that with your right hand, the thumb is X positive, the index finger Y positive and the middle finger (pointing to you) Z positive */ /*! - * \brief Constructs a Vector3 object from its coordinates + * \brief Constructs a Vector3 object from its coordinates * * \param X X component * \param Y Y component @@ -35,7 +36,7 @@ namespace Nz } /*! - * \brief Constructs a Vector3 object from a component and a Vector2 + * \brief Constructs a Vector3 object from a component and a Vector2 * * \param X X component * \param vec vec.X = Y component and vec.y = Z component @@ -48,7 +49,7 @@ namespace Nz } /*! - * \brief Constructs explicitely a Vector3 object from its "scale" + * \brief Constructs explicitely a Vector3 object from its "scale" * * \param scale X component = Y component = Z component */ @@ -60,7 +61,7 @@ namespace Nz } /*! - * \brief Constructs a Vector3 object from an array of three elements + * \brief Constructs a Vector3 object from an array of three elements * * \param vec[3] vec[0] is X component, vec[1] is Y component and vec[2] is Z component */ @@ -72,7 +73,7 @@ namespace Nz } /*! - * \brief Constructs a Vector3 object from a Vector2 and a component + * \brief Constructs a Vector3 object from a Vector2 and a component * * \param vec vec.X = X component and vec.y = Y component * \param Z Z component @@ -85,7 +86,7 @@ namespace Nz } /*! - * \brief Constructs a Vector3 object from another type of Vector3 + * \brief Constructs a Vector3 object from another type of Vector3 * * \param vec Vector of type U to convert to type T */ @@ -98,7 +99,7 @@ namespace Nz } /*! - * \brief Constructs a Vector3 object from a Vector4 + * \brief Constructs a Vector3 object from a Vector4 * * \param vec Vector4 where only the first three components are taken */ @@ -1299,7 +1300,7 @@ std::ostream& operator<<(std::ostream& out, const Nz::Vector3& vec) */ template -Nz::Vector3 operator*(T scale, const Nz::Vector3& vec) +Nz::Vector3 operator*(T scale, const Nz::Vector3& vec) { return Nz::Vector3(scale * vec.x, scale * vec.y, scale * vec.z); } diff --git a/include/Nazara/Math/Vector4.inl b/include/Nazara/Math/Vector4.inl index c5127b34e..bdf2bd64f 100644 --- a/include/Nazara/Math/Vector4.inl +++ b/include/Nazara/Math/Vector4.inl @@ -16,12 +16,13 @@ namespace Nz { /*! - * \class Nz::Vector4 + * \ingroup math + * \class Nz::Vector4 * \brief Math class that represents an element of the three dimensional vector space with the notion of projectivity. When the fourth component is 1, it describes an 'usual' point and when it is 0, it represents the point at infinity */ /*! - * \brief Constructs a Vector4 object from its coordinates + * \brief Constructs a Vector4 object from its coordinates * * \param X X component * \param Y Y component @@ -36,7 +37,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from two components and a Vector2 + * \brief Constructs a Vector4 object from two components and a Vector2 * * \param X X component * \param Y Y component @@ -50,7 +51,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from one component, a Vector2 and one component + * \brief Constructs a Vector4 object from one component, a Vector2 and one component * * \param X X component * \param vec vec.X = Y component and vec.y = Z component @@ -64,7 +65,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from one component and a Vector3 + * \brief Constructs a Vector4 object from one component and a Vector3 * * \param X X component * \param vec vec.X = Y component, vec.y = Z component and vec.z = W component @@ -77,7 +78,7 @@ namespace Nz } /*! - * \brief Constructs explicitely a Vector4 object from its "scale" + * \brief Constructs explicitely a Vector4 object from its "scale" * * \param scale X component = Y component = Z component = W component */ @@ -89,7 +90,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from an array of four elements + * \brief Constructs a Vector4 object from an array of four elements * * \param vec[4] vec[0] is X component, vec[1] is Y component, vec[2] is Z component and vec[3] is W component */ @@ -101,7 +102,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from a Vector2 and two components + * \brief Constructs a Vector4 object from a Vector2 and two components * * \param vec vec.X = X component and vec.y = Y component * \param Z Z component @@ -115,7 +116,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from one component and a Vector3 + * \brief Constructs a Vector4 object from one component and a Vector3 * * \param vec vec.X = X component, vec.y = Y component and vec.z = Z component * \param W W component @@ -128,7 +129,7 @@ namespace Nz } /*! - * \brief Constructs a Vector4 object from another type of Vector4 + * \brief Constructs a Vector4 object from another type of Vector4 * * \param vec Vector of type U to convert to type T */ @@ -1037,7 +1038,7 @@ std::ostream& operator<<(std::ostream& out, const Nz::Vector4& vec) template -Nz::Vector4 operator*(T scale, const Nz::Vector4& vec) +Nz::Vector4 operator*(T scale, const Nz::Vector4& vec) { return Nz::Vector4(scale * vec.x, scale * vec.y, scale * vec.z, scale * vec.w); } diff --git a/src/Nazara/Core/AbstractHash.cpp b/src/Nazara/Core/AbstractHash.cpp index 60f2f42cb..419ba74e9 100644 --- a/src/Nazara/Core/AbstractHash.cpp +++ b/src/Nazara/Core/AbstractHash.cpp @@ -18,7 +18,8 @@ namespace Nz { /*! - * \class Nz::AbstractHash + * \ingroup core + * \class Nz::AbstractHash * \brief Core class that represents the behaviour of the hash classes * * \remark This class is abstract diff --git a/src/Nazara/Core/AbstractLogger.cpp b/src/Nazara/Core/AbstractLogger.cpp index 06695a928..ceac9eff8 100644 --- a/src/Nazara/Core/AbstractLogger.cpp +++ b/src/Nazara/Core/AbstractLogger.cpp @@ -21,7 +21,8 @@ namespace Nz } /*! - * \class Nz::AbstractLogger + * \ingroup core + * \class Nz::AbstractLogger * \brief Core class that represents the behaviour of the log classes * * \remark This class is abstract diff --git a/src/Nazara/Core/ByteArray.cpp b/src/Nazara/Core/ByteArray.cpp index 9763e6336..e505f13f2 100644 --- a/src/Nazara/Core/ByteArray.cpp +++ b/src/Nazara/Core/ByteArray.cpp @@ -10,6 +10,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ByteArray * \brief Core class that represents an array of bytes */ diff --git a/src/Nazara/Core/ByteStream.cpp b/src/Nazara/Core/ByteStream.cpp index 1b0fc853e..cf5a045a9 100644 --- a/src/Nazara/Core/ByteStream.cpp +++ b/src/Nazara/Core/ByteStream.cpp @@ -12,6 +12,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ByteStream * \brief Core class that represents a stream of bytes */ diff --git a/src/Nazara/Core/Clock.cpp b/src/Nazara/Core/Clock.cpp index ef4689d50..60482b18e 100644 --- a/src/Nazara/Core/Clock.cpp +++ b/src/Nazara/Core/Clock.cpp @@ -42,6 +42,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::Clock * \brief Utility class that measure the elapsed time */ @@ -52,7 +53,6 @@ namespace Nz * \param startingValue The starting time value, in microseconds * \param paused The clock pause state */ - Clock::Clock(UInt64 startingValue, bool paused) : m_elapsedTime(startingValue), m_refTime(GetElapsedMicroseconds()), @@ -66,7 +66,6 @@ namespace Nz * * \see GetMicroseconds, GetMilliseconds */ - float Clock::GetSeconds() const { return GetMicroseconds()/1000000.f; @@ -78,7 +77,6 @@ namespace Nz * * \see GetMilliseconds, GetSeconds */ - UInt64 Clock::GetMicroseconds() const { NazaraLock(m_mutex); @@ -96,7 +94,6 @@ namespace Nz * * \see GetMicroseconds, GetSeconds */ - UInt64 Clock::GetMilliseconds() const { return GetMicroseconds()/1000; @@ -108,7 +105,6 @@ namespace Nz * * \see Pause, Unpause */ - bool Clock::IsPaused() const { NazaraLock(m_mutex); @@ -124,7 +120,6 @@ namespace Nz * * \see IsPaused, Unpause */ - void Clock::Pause() { NazaraLock(m_mutex); @@ -140,7 +135,6 @@ namespace Nz * \brief Restart the clock * Restarts the clock, putting it's time counter back to zero (as if the clock got constructed). */ - void Clock::Restart() { NazaraLock(m_mutex); @@ -158,7 +152,6 @@ namespace Nz * * \see IsPaused, Unpause */ - void Clock::Unpause() { NazaraLock(m_mutex); diff --git a/src/Nazara/Core/ConditionVariable.cpp b/src/Nazara/Core/ConditionVariable.cpp index c01b47722..0730ea829 100644 --- a/src/Nazara/Core/ConditionVariable.cpp +++ b/src/Nazara/Core/ConditionVariable.cpp @@ -19,6 +19,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ConditionVariable * \brief Core class that represents a condition variable * diff --git a/src/Nazara/Core/Core.cpp b/src/Nazara/Core/Core.cpp index 26a451512..1ccb35212 100644 --- a/src/Nazara/Core/Core.cpp +++ b/src/Nazara/Core/Core.cpp @@ -14,7 +14,8 @@ namespace Nz { /*! - * \class Nz::CoreCore + * \ingroup core + * \class Nz::Core * \brief Core class that represents the module initializer of Core */ diff --git a/src/Nazara/Core/Directory.cpp b/src/Nazara/Core/Directory.cpp index b076b38d7..b48930419 100644 --- a/src/Nazara/Core/Directory.cpp +++ b/src/Nazara/Core/Directory.cpp @@ -35,6 +35,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::Directory * \brief Core class that represents a directory */ diff --git a/src/Nazara/Core/DynLib.cpp b/src/Nazara/Core/DynLib.cpp index 3261f0959..515f437b4 100644 --- a/src/Nazara/Core/DynLib.cpp +++ b/src/Nazara/Core/DynLib.cpp @@ -26,6 +26,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::DynLib * \brief Core class that represents a dynamic library loader */ diff --git a/src/Nazara/Core/Error.cpp b/src/Nazara/Core/Error.cpp index 59a8b72fb..ae6f0cc09 100644 --- a/src/Nazara/Core/Error.cpp +++ b/src/Nazara/Core/Error.cpp @@ -19,6 +19,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Error * \brief Core class that represents an error */ diff --git a/src/Nazara/Core/ErrorFlags.cpp b/src/Nazara/Core/ErrorFlags.cpp index d29efbc5a..003e37a23 100644 --- a/src/Nazara/Core/ErrorFlags.cpp +++ b/src/Nazara/Core/ErrorFlags.cpp @@ -9,6 +9,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ErrorFlags * \brief Core class that represents flags for error */ diff --git a/src/Nazara/Core/File.cpp b/src/Nazara/Core/File.cpp index 55587c9e0..c03fb7b7f 100644 --- a/src/Nazara/Core/File.cpp +++ b/src/Nazara/Core/File.cpp @@ -31,6 +31,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::File * \brief Core class that represents a file */ diff --git a/src/Nazara/Core/FileLogger.cpp b/src/Nazara/Core/FileLogger.cpp index 6a94787bd..bac0cb099 100644 --- a/src/Nazara/Core/FileLogger.cpp +++ b/src/Nazara/Core/FileLogger.cpp @@ -13,6 +13,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::FileLogger * \brief Core class that represents a file logger */ diff --git a/src/Nazara/Core/GuillotineBinPack.cpp b/src/Nazara/Core/GuillotineBinPack.cpp index 69e3a1333..e43e07572 100644 --- a/src/Nazara/Core/GuillotineBinPack.cpp +++ b/src/Nazara/Core/GuillotineBinPack.cpp @@ -17,6 +17,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::GuillotineBinPack * \brief Core class that represents the "Guillotine problem", combination of the "Bin packing problem" and the "cutting stock" */ diff --git a/src/Nazara/Core/HardwareInfo.cpp b/src/Nazara/Core/HardwareInfo.cpp index af7f47e5d..1fbd1a04a 100644 --- a/src/Nazara/Core/HardwareInfo.cpp +++ b/src/Nazara/Core/HardwareInfo.cpp @@ -83,6 +83,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::HardwareInfo * \brief Core class that represents the info we can get from hardware */ diff --git a/src/Nazara/Core/LockGuard.cpp b/src/Nazara/Core/LockGuard.cpp index 31c1fe559..e714f05f7 100644 --- a/src/Nazara/Core/LockGuard.cpp +++ b/src/Nazara/Core/LockGuard.cpp @@ -9,6 +9,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::LockGuard * \brief Core class that represents a mutex wrapper that provides a convenient RAII-style mechanism */ diff --git a/src/Nazara/Core/Log.cpp b/src/Nazara/Core/Log.cpp index 1a658c97e..9e6b13353 100644 --- a/src/Nazara/Core/Log.cpp +++ b/src/Nazara/Core/Log.cpp @@ -16,6 +16,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::Log * \brief Core class that represents a logger */ diff --git a/src/Nazara/Core/MemoryManager.cpp b/src/Nazara/Core/MemoryManager.cpp index 20dc17fa8..5ee1755d7 100644 --- a/src/Nazara/Core/MemoryManager.cpp +++ b/src/Nazara/Core/MemoryManager.cpp @@ -67,6 +67,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::MemoryManager * \brief Core class that represents a manager for the memory */ diff --git a/src/Nazara/Core/MemoryStream.cpp b/src/Nazara/Core/MemoryStream.cpp index 7940fee8a..bb77f35f8 100644 --- a/src/Nazara/Core/MemoryStream.cpp +++ b/src/Nazara/Core/MemoryStream.cpp @@ -11,6 +11,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::MemoryStream * \brief Core class that represents a stream of memory */ diff --git a/src/Nazara/Core/MemoryView.cpp b/src/Nazara/Core/MemoryView.cpp index a636eb9a8..02c8b26c2 100644 --- a/src/Nazara/Core/MemoryView.cpp +++ b/src/Nazara/Core/MemoryView.cpp @@ -10,6 +10,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::MemoryView * \brief Core class that represents a view of the memory behaving like a stream */ @@ -134,7 +135,7 @@ namespace Nz { std::size_t endPos = static_cast(m_pos + size); if (endPos > m_size) - size = m_size - m_pos; + size = static_cast(m_size - m_pos); NazaraAssert(buffer, "Invalid buffer"); diff --git a/src/Nazara/Core/Mutex.cpp b/src/Nazara/Core/Mutex.cpp index 2d17276f1..68c94a8cf 100644 --- a/src/Nazara/Core/Mutex.cpp +++ b/src/Nazara/Core/Mutex.cpp @@ -18,6 +18,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Mutex * \brief Core class that represents a binary semaphore, a mutex * diff --git a/src/Nazara/Core/ParameterList.cpp b/src/Nazara/Core/ParameterList.cpp index 1244b8b2c..405ebd1cd 100644 --- a/src/Nazara/Core/ParameterList.cpp +++ b/src/Nazara/Core/ParameterList.cpp @@ -13,6 +13,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::ParameterList * \brief Core class that represents a list of parameters */ diff --git a/src/Nazara/Core/PluginManager.cpp b/src/Nazara/Core/PluginManager.cpp index 04fcafac7..24fbafcfb 100644 --- a/src/Nazara/Core/PluginManager.cpp +++ b/src/Nazara/Core/PluginManager.cpp @@ -25,6 +25,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::PluginManager * \brief Core class that represents a manager for plugin */ diff --git a/src/Nazara/Core/PrimitiveList.cpp b/src/Nazara/Core/PrimitiveList.cpp index 644f46e66..a8d406b94 100644 --- a/src/Nazara/Core/PrimitiveList.cpp +++ b/src/Nazara/Core/PrimitiveList.cpp @@ -9,6 +9,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::PrimitiveList * \brief Core class that represents a list of geometric primitives */ diff --git a/src/Nazara/Core/RefCounted.cpp b/src/Nazara/Core/RefCounted.cpp index f2ef2b926..31e749515 100644 --- a/src/Nazara/Core/RefCounted.cpp +++ b/src/Nazara/Core/RefCounted.cpp @@ -17,6 +17,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::RefCounted * \brief Core class that represents a reference with a counter */ diff --git a/src/Nazara/Core/Resource.cpp b/src/Nazara/Core/Resource.cpp index 23fa6ea22..82ef768d1 100644 --- a/src/Nazara/Core/Resource.cpp +++ b/src/Nazara/Core/Resource.cpp @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Resource * \brief Core class that represents a resource */ diff --git a/src/Nazara/Core/Semaphore.cpp b/src/Nazara/Core/Semaphore.cpp index c5d9cc5b7..1b2194095 100644 --- a/src/Nazara/Core/Semaphore.cpp +++ b/src/Nazara/Core/Semaphore.cpp @@ -17,6 +17,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Semaphore * \brief Core class that represents a counting semaphore */ diff --git a/src/Nazara/Core/StdLogger.cpp b/src/Nazara/Core/StdLogger.cpp index 783957ef1..e38daa077 100644 --- a/src/Nazara/Core/StdLogger.cpp +++ b/src/Nazara/Core/StdLogger.cpp @@ -21,6 +21,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::StdLogger * \brief Core class that represents a logger writing to standard output (stdout, stderr) */ diff --git a/src/Nazara/Core/Stream.cpp b/src/Nazara/Core/Stream.cpp index 3ddcb9fc7..b36b67d85 100644 --- a/src/Nazara/Core/Stream.cpp +++ b/src/Nazara/Core/Stream.cpp @@ -12,6 +12,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::Stream * \brief Core class that represents a stream */ diff --git a/src/Nazara/Core/String.cpp b/src/Nazara/Core/String.cpp index 74c2afe80..8abeb2d02 100644 --- a/src/Nazara/Core/String.cpp +++ b/src/Nazara/Core/String.cpp @@ -77,6 +77,7 @@ namespace Nz } /*! + * \ingroup core * \class Nz::String * \brief Core class that represents a string */ diff --git a/src/Nazara/Core/StringStream.cpp b/src/Nazara/Core/StringStream.cpp index a76dc9d86..ebd509c65 100644 --- a/src/Nazara/Core/StringStream.cpp +++ b/src/Nazara/Core/StringStream.cpp @@ -8,6 +8,7 @@ namespace Nz { /*! + * \ingroup core * \class Nz::StringStream * \brief Core class that represents a stream of strings */ diff --git a/src/Nazara/Core/TaskScheduler.cpp b/src/Nazara/Core/TaskScheduler.cpp index 108e120b1..a29436407 100644 --- a/src/Nazara/Core/TaskScheduler.cpp +++ b/src/Nazara/Core/TaskScheduler.cpp @@ -25,7 +25,8 @@ namespace Nz } /*! - * \class Nz::TaskScheduler + * \ingroup core + * \class Nz::TaskScheduler * \brief Core class that represents a pool of threads * * \remark Initialized should be called first diff --git a/src/Nazara/Core/Thread.cpp b/src/Nazara/Core/Thread.cpp index da01025d3..0c4cd8008 100644 --- a/src/Nazara/Core/Thread.cpp +++ b/src/Nazara/Core/Thread.cpp @@ -22,7 +22,8 @@ namespace Nz { /*! - * \class Nz::Thread + * \ingroup core + * \class Nz::Thread * \brief Core class that represents a thread */ diff --git a/src/Nazara/Core/Unicode.cpp b/src/Nazara/Core/Unicode.cpp index 9168e855e..0f6dd8452 100644 --- a/src/Nazara/Core/Unicode.cpp +++ b/src/Nazara/Core/Unicode.cpp @@ -26,6 +26,7 @@ namespace Nz namespace Nz { /*! + * \ingroup core * \class Nz::Unicode * \brief Core class that represents a Unicode character */