1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Minor tidying-up.

This commit is contained in:
jules 2012-09-04 11:38:16 +01:00
parent 4ccba42fa8
commit 842d30fbfa
28 changed files with 113 additions and 117 deletions

View file

@ -33,8 +33,8 @@
class ItemPreviewComponent : public Component
{
public:
ItemPreviewComponent (const File& file_)
: file (file_)
ItemPreviewComponent (const File& f)
: file (f)
{
setOpaque (true);
tryToLoadImage();

View file

@ -54,8 +54,8 @@ namespace FileHelpers
class FileModificationDetector
{
public:
FileModificationDetector (const File& file_)
: file (file_)
FileModificationDetector (const File& f)
: file (f)
{
}

View file

@ -100,7 +100,7 @@ public:
class Int8
{
public:
inline Int8 (void* data_) noexcept : data (static_cast <int8*> (data_)) {}
inline Int8 (void* d) noexcept : data (static_cast <int8*> (d)) {}
inline void advance() noexcept { ++data; }
inline void skip (int numSamples) noexcept { data += numSamples; }
@ -125,7 +125,7 @@ public:
class UInt8
{
public:
inline UInt8 (void* data_) noexcept : data (static_cast <uint8*> (data_)) {}
inline UInt8 (void* d) noexcept : data (static_cast <uint8*> (d)) {}
inline void advance() noexcept { ++data; }
inline void skip (int numSamples) noexcept { data += numSamples; }
@ -150,7 +150,7 @@ public:
class Int16
{
public:
inline Int16 (void* data_) noexcept : data (static_cast <uint16*> (data_)) {}
inline Int16 (void* d) noexcept : data (static_cast <uint16*> (d)) {}
inline void advance() noexcept { ++data; }
inline void skip (int numSamples) noexcept { data += numSamples; }
@ -175,7 +175,7 @@ public:
class Int24
{
public:
inline Int24 (void* data_) noexcept : data (static_cast <char*> (data_)) {}
inline Int24 (void* d) noexcept : data (static_cast <char*> (d)) {}
inline void advance() noexcept { data += 3; }
inline void skip (int numSamples) noexcept { data += 3 * numSamples; }
@ -200,7 +200,7 @@ public:
class Int32
{
public:
inline Int32 (void* data_) noexcept : data (static_cast <uint32*> (data_)) {}
inline Int32 (void* d) noexcept : data (static_cast <uint32*> (d)) {}
inline void advance() noexcept { ++data; }
inline void skip (int numSamples) noexcept { data += numSamples; }
@ -225,7 +225,7 @@ public:
class Float32
{
public:
inline Float32 (void* data_) noexcept : data (static_cast <float*> (data_)) {}
inline Float32 (void* d) noexcept : data (static_cast <float*> (d)) {}
inline void advance() noexcept { ++data; }
inline void skip (int numSamples) noexcept { data += numSamples; }
@ -275,7 +275,7 @@ public:
public:
inline Interleaved() noexcept : numInterleavedChannels (1) {}
inline Interleaved (const Interleaved& other) noexcept : numInterleavedChannels (other.numInterleavedChannels) {}
inline Interleaved (const int numInterleavedChannels_) noexcept : numInterleavedChannels (numInterleavedChannels_) {}
inline Interleaved (const int numInterleavedChans) noexcept : numInterleavedChannels (numInterleavedChans) {}
inline void copyFrom (const Interleaved& other) noexcept { numInterleavedChannels = other.numInterleavedChannels; }
template <class SampleFormatType> inline void advanceData (SampleFormatType& s) noexcept { s.skip (numInterleavedChannels); }
template <class SampleFormatType> inline void advanceDataBy (SampleFormatType& s, int numSamples) noexcept { s.skip (numInterleavedChannels * numSamples); }

View file

@ -336,8 +336,8 @@ private:
class HashEntry
{
public:
HashEntry (KeyTypeParameter key_, ValueTypeParameter value_, HashEntry* const nextEntry_)
: key (key_), value (value_), nextEntry (nextEntry_)
HashEntry (KeyTypeParameter k, ValueTypeParameter val, HashEntry* const next)
: key (k), value (val), nextEntry (next)
{}
const KeyType key;

View file

@ -248,9 +248,9 @@ public:
{
const ScopedLockType lock (getLock());
ObjectClass** e = data.elements.getData();
ObjectClass** const end_ = e + numUsed;
ObjectClass** const endPointer = e + numUsed;
while (e != end_)
while (e != endPointer)
{
if (objectToLookFor == *e)
return static_cast <int> (e - data.elements.getData());
@ -270,9 +270,9 @@ public:
{
const ScopedLockType lock (getLock());
ObjectClass** e = data.elements.getData();
ObjectClass** const end_ = e + numUsed;
ObjectClass** const endPointer = e + numUsed;
while (e != end_)
while (e != endPointer)
{
if (objectToLookFor == *e)
return true;
@ -616,13 +616,13 @@ public:
{
const ScopedLockType lock (getLock());
const int start = jlimit (0, numUsed, startIndex);
const int end_ = jlimit (0, numUsed, startIndex + numberToRemove);
const int start = jlimit (0, numUsed, startIndex);
const int endIndex = jlimit (0, numUsed, startIndex + numberToRemove);
if (end_ > start)
if (endIndex > start)
{
int i;
for (i = start; i < end_; ++i)
for (i = start; i < endIndex; ++i)
{
if (data.elements[i] != nullptr)
{
@ -631,9 +631,9 @@ public:
}
}
const int rangeSize = end_ - start;
const int rangeSize = endIndex - start;
ObjectClass** e = data.elements + start;
i = numUsed - end_;
i = numUsed - endIndex;
numUsed -= rangeSize;
while (--i >= 0)

View file

@ -95,8 +95,7 @@ struct Expression::Helpers
class EvaluationError : public std::exception
{
public:
EvaluationError (const String& description_)
: description (description_)
EvaluationError (const String& desc) : description (desc)
{
DBG ("Expression::EvaluationError: " + description);
}
@ -108,8 +107,8 @@ struct Expression::Helpers
class Constant : public Term
{
public:
Constant (const double value_, const bool isResolutionTarget_)
: value (value_), isResolutionTarget (isResolutionTarget_) {}
Constant (const double val, const bool resolutionTarget)
: value (val), isResolutionTarget (resolutionTarget) {}
Type getType() const noexcept { return constantType; }
Term* clone() const { return new Constant (value, isResolutionTarget); }
@ -199,7 +198,7 @@ struct Expression::Helpers
class SymbolTerm : public Term
{
public:
explicit SymbolTerm (const String& symbol_) : symbol (symbol_) {}
explicit SymbolTerm (const String& sym) : symbol (sym) {}
TermPtr resolve (const Scope& scope, int recursionDepth)
{
@ -232,10 +231,10 @@ struct Expression::Helpers
class Function : public Term
{
public:
explicit Function (const String& functionName_) : functionName (functionName_) {}
explicit Function (const String& name) : functionName (name) {}
Function (const String& functionName_, const Array<Expression>& parameters_)
: functionName (functionName_), parameters (parameters_)
Function (const String& name, const Array<Expression>& params)
: functionName (name), parameters (params)
{}
Type getType() const noexcept { return functionType; }
@ -351,8 +350,8 @@ struct Expression::Helpers
class EvaluationVisitor : public Scope::Visitor
{
public:
EvaluationVisitor (const TermPtr& input_, const int recursionCount_)
: input (input_), output (input_), recursionCount (recursionCount_) {}
EvaluationVisitor (const TermPtr& term, const int recursion)
: input (term), output (term), recursionCount (recursion) {}
void visit (const Scope& scope) { output = input->resolve (scope, recursionCount); }
@ -367,8 +366,8 @@ struct Expression::Helpers
class SymbolVisitingVisitor : public Scope::Visitor
{
public:
SymbolVisitingVisitor (const TermPtr& input_, SymbolVisitor& visitor_, const int recursionCount_)
: input (input_), visitor (visitor_), recursionCount (recursionCount_) {}
SymbolVisitingVisitor (const TermPtr& term, SymbolVisitor& v, const int recursion)
: input (term), visitor (v), recursionCount (recursion) {}
void visit (const Scope& scope) { input->visitAllSymbols (visitor, scope, recursionCount); }
@ -383,8 +382,8 @@ struct Expression::Helpers
class SymbolRenamingVisitor : public Scope::Visitor
{
public:
SymbolRenamingVisitor (const TermPtr& input_, const Expression::Symbol& symbol_, const String& newName_, const int recursionCount_)
: input (input_), symbol (symbol_), newName (newName_), recursionCount (recursionCount_) {}
SymbolRenamingVisitor (const TermPtr& term, const Expression::Symbol& symbol_, const String& newName_, const int recursionCount_)
: input (term), symbol (symbol_), newName (newName_), recursionCount (recursionCount_) {}
void visit (const Scope& scope) { input->renameSymbol (symbol, newName, scope, recursionCount); }
@ -406,9 +405,9 @@ struct Expression::Helpers
class Negate : public Term
{
public:
explicit Negate (const TermPtr& input_) : input (input_)
explicit Negate (const TermPtr& term) : input (term)
{
jassert (input_ != nullptr);
jassert (term != nullptr);
}
Type getType() const noexcept { return operatorType; }
@ -425,10 +424,10 @@ struct Expression::Helpers
String getName() const { return "-"; }
TermPtr negated() { return input; }
TermPtr createTermToEvaluateInput (const Scope& scope, const Term* input_, double overallTarget, Term* topLevelTerm) const
TermPtr createTermToEvaluateInput (const Scope& scope, const Term* term, double overallTarget, Term* topLevelTerm) const
{
(void) input_;
jassert (input_ == input);
(void) term;
jassert (term == input);
const Term* const dest = findDestinationFor (topLevelTerm, this);

View file

@ -46,8 +46,8 @@ public:
}
/** Constructs a range with given start and end values. */
Range (const ValueType start_, const ValueType end_) noexcept
: start (start_), end (jmax (start_, end_))
Range (const ValueType startValue, const ValueType endValue) noexcept
: start (startValue), end (jmax (startValue, endValue))
{
}

View file

@ -133,7 +133,7 @@ public:
class SharedPointer : public ReferenceCountingType
{
public:
explicit SharedPointer (ObjectType* const owner_) noexcept : owner (owner_) {}
explicit SharedPointer (ObjectType* const obj) noexcept : owner (obj) {}
inline ObjectType* get() const noexcept { return owner; }
void clearPointer() noexcept { owner = nullptr; }

View file

@ -38,7 +38,7 @@ class GlobalRef
{
public:
inline GlobalRef() noexcept : obj (0) {}
inline explicit GlobalRef (jobject obj_) : obj (retain (obj_)) {}
inline explicit GlobalRef (jobject o) : obj (retain (o)) {}
inline GlobalRef (const GlobalRef& other) : obj (retain (other.obj)) {}
~GlobalRef() { clear(); }
@ -97,9 +97,9 @@ private:
//==============================================================================
jobject obj;
static inline jobject retain (jobject obj_)
static inline jobject retain (jobject obj)
{
return obj_ == 0 ? 0 : getEnv()->NewGlobalRef (obj_);
return obj == 0 ? 0 : getEnv()->NewGlobalRef (obj);
}
};
@ -108,7 +108,7 @@ template <typename JavaType>
class LocalRef
{
public:
explicit inline LocalRef (JavaType obj_) noexcept : obj (obj_) {}
explicit inline LocalRef (JavaType o) noexcept : obj (o) {}
inline LocalRef (const LocalRef& other) noexcept : obj (retain (other.obj)) {}
~LocalRef() { clear(); }
@ -132,9 +132,9 @@ public:
private:
JavaType obj;
static JavaType retain (JavaType obj_)
static JavaType retain (JavaType obj)
{
return obj_ == 0 ? 0 : (JavaType) getEnv()->NewLocalRef (obj_);
return obj == 0 ? 0 : (JavaType) getEnv()->NewLocalRef (obj);
}
};
@ -172,7 +172,7 @@ namespace
class JNIClassBase
{
public:
explicit JNIClassBase (const char* classPath_);
explicit JNIClassBase (const char* classPath);
virtual ~JNIClassBase();
inline operator jclass() const noexcept { return classRef; }

View file

@ -67,9 +67,9 @@ void CriticalSection::exit() const noexcept
class WaitableEventImpl
{
public:
WaitableEventImpl (const bool manualReset_)
WaitableEventImpl (const bool useManualReset)
: triggered (false),
manualReset (manualReset_)
manualReset (useManualReset)
{
pthread_cond_init (&condition, 0);
@ -773,8 +773,7 @@ public:
int handle, refCount;
};
InterProcessLock::InterProcessLock (const String& name_)
: name (name_)
InterProcessLock::InterProcessLock (const String& nm) : name (nm)
{
}

View file

@ -34,10 +34,10 @@ template <class ComClass>
class ComSmartPtr
{
public:
ComSmartPtr() throw() : p (0) {}
ComSmartPtr (ComClass* const p_) : p (p_) { if (p_ != 0) p_->AddRef(); }
ComSmartPtr (const ComSmartPtr<ComClass>& p_) : p (p_.p) { if (p != 0) p ->AddRef(); }
~ComSmartPtr() { release(); }
ComSmartPtr() throw() : p (0) {}
ComSmartPtr (ComClass* const obj) : p (obj) { if (p) p->AddRef(); }
ComSmartPtr (const ComSmartPtr<ComClass>& other) : p (other.p) { if (p) p->AddRef(); }
~ComSmartPtr() { release(); }
operator ComClass*() const throw() { return p; }
ComClass& operator*() const throw() { return *p; }

View file

@ -174,8 +174,8 @@ private:
#if JUCE_NO_COMPILER_THREAD_LOCAL
struct ObjectHolder
{
ObjectHolder (const Thread::ThreadID& threadId_)
: threadId (threadId_), object()
ObjectHolder (const Thread::ThreadID& tid)
: threadId (tid), object()
{}
Thread::ThreadID threadId;

View file

@ -505,7 +505,7 @@ private:
template <typename ElementComparator>
struct ComparatorAdapter
{
ComparatorAdapter (ElementComparator& comparator_) noexcept : comparator (comparator_) {}
ComparatorAdapter (ElementComparator& comp) noexcept : comparator (comp) {}
int compareElements (const ValueTree* const first, const ValueTree* const second)
{

View file

@ -281,8 +281,8 @@ public:
{
public:
//==============================================================================
Iterator (const ListType& list_) noexcept
: list (list_), index (list_.size())
Iterator (const ListType& listToIterate) noexcept
: list (listToIterate), index (listToIterate.size())
{}
~Iterator() noexcept {}

View file

@ -165,8 +165,8 @@ private:
{
ColourPoint() noexcept {}
ColourPoint (const double position_, const Colour& colour_) noexcept
: position (position_), colour (colour_)
ColourPoint (const double pos, const Colour& col) noexcept
: position (pos), colour (col)
{}
bool operator== (const ColourPoint& other) const noexcept;

View file

@ -53,8 +53,8 @@ public:
/** Creates a pixel from a 32-bit argb value.
*/
PixelARGB (const uint32 argb_) noexcept
: argb (argb_)
PixelARGB (const uint32 argbValue) noexcept
: argb (argbValue)
{
}
@ -427,11 +427,11 @@ public:
forcedinline void multiplyAlpha (float) noexcept {}
/** Sets the pixel's colour from individual components. */
void setARGB (const uint8, const uint8 r_, const uint8 g_, const uint8 b_) noexcept
void setARGB (const uint8, const uint8 red, const uint8 green, const uint8 blue) noexcept
{
r = r_;
g = g_;
b = b_;
r = red;
g = green;
b = blue;
}
/** Premultiplies the pixel's RGB values by its alpha. */

View file

@ -35,10 +35,10 @@ AffineTransform::AffineTransform (const AffineTransform& other) noexcept
{
}
AffineTransform::AffineTransform (const float mat00_, const float mat01_, const float mat02_,
const float mat10_, const float mat11_, const float mat12_) noexcept
: mat00 (mat00_), mat01 (mat01_), mat02 (mat02_),
mat10 (mat10_), mat11 (mat11_), mat12 (mat12_)
AffineTransform::AffineTransform (const float m00, const float m01, const float m02,
const float m10, const float m11, const float m12) noexcept
: mat00 (m00), mat01 (m01), mat02 (m02),
mat10 (m10), mat11 (m11), mat12 (m12)
{
}

View file

@ -30,7 +30,7 @@
class CoreGraphicsContext : public LowLevelGraphicsContext
{
public:
CoreGraphicsContext (CGContextRef context_, const float flipHeight_, const float targetScale_);
CoreGraphicsContext (CGContextRef context, const float flipHeight, const float targetScale);
~CoreGraphicsContext();
//==============================================================================

View file

@ -42,8 +42,8 @@ class JUCE_API Justification
{
public:
//==============================================================================
/** Creates a Justification object using a combination of flags. */
inline Justification (int flags_) noexcept : flags (flags_) {}
/** Creates a Justification object using a combination of flags from the Flags enum. */
inline Justification (int justificationFlags) noexcept : flags (justificationFlags) {}
/** Creates a copy of another Justification object. */
Justification (const Justification& other) noexcept;
@ -103,7 +103,7 @@ public:
//==============================================================================
/** Flag values that can be combined and used in the constructor. */
enum
enum Flags
{
//==============================================================================
/** Indicates that the item should be aligned against the left edge of the available space. */

View file

@ -42,8 +42,8 @@ class JUCE_API RectanglePlacement
{
public:
//==============================================================================
/** Creates a RectanglePlacement object using a combination of flags. */
inline RectanglePlacement (int flags_) noexcept : flags (flags_) {}
/** Creates a RectanglePlacement object using a combination of flags from the Flags enum. */
inline RectanglePlacement (int placementFlags) noexcept : flags (placementFlags) {}
/** Creates a copy of another RectanglePlacement object. */
RectanglePlacement (const RectanglePlacement& other) noexcept;
@ -56,7 +56,7 @@ public:
//==============================================================================
/** Flag values that can be combined and used in the constructor. */
enum
enum Flags
{
//==============================================================================
/** Indicates that the source rectangle's left edge should be aligned with the left edge of the target rectangle. */

View file

@ -282,8 +282,8 @@ private:
public:
typedef void (*FunctionType) (int, ParamType);
FunctionCaller1 (FunctionType& function_, ParamType& param_)
: function (function_), param (param_) {}
FunctionCaller1 (FunctionType& f, ParamType& p1)
: function (f), param (p1) {}
void modalStateFinished (int returnValue) { function (returnValue, param); }
@ -300,8 +300,8 @@ private:
public:
typedef void (*FunctionType) (int, ParamType1, ParamType2);
FunctionCaller2 (FunctionType& function_, ParamType1& param1_, ParamType2& param2_)
: function (function_), param1 (param1_), param2 (param2_) {}
FunctionCaller2 (FunctionType& f, ParamType1& p1, ParamType2& p2)
: function (f), param1 (p1), param2 (p2) {}
void modalStateFinished (int returnValue) { function (returnValue, param1, param2); }
@ -319,8 +319,8 @@ private:
public:
typedef void (*FunctionType) (int, ComponentType*);
ComponentCaller1 (FunctionType& function_, ComponentType* comp_)
: function (function_), comp (comp_) {}
ComponentCaller1 (FunctionType& f, ComponentType* c)
: function (f), comp (c) {}
void modalStateFinished (int returnValue)
{
@ -340,8 +340,8 @@ private:
public:
typedef void (*FunctionType) (int, ComponentType*, ParamType1);
ComponentCaller2 (FunctionType& function_, ComponentType* comp_, ParamType1 param1_)
: function (function_), comp (comp_), param1 (param1_) {}
ComponentCaller2 (FunctionType& f, ComponentType* c, ParamType1 p1)
: function (f), comp (c), param1 (p1) {}
void modalStateFinished (int returnValue)
{

View file

@ -221,9 +221,9 @@ protected:
class Positioner : public RelativeCoordinatePositionerBase
{
public:
Positioner (DrawableType& component_)
: RelativeCoordinatePositionerBase (component_),
owner (component_)
Positioner (DrawableType& c)
: RelativeCoordinatePositionerBase (c),
owner (c)
{}
bool registerCoordinates() { return owner.registerCoordinates (*this); }

View file

@ -25,9 +25,9 @@
WildcardFileFilter::WildcardFileFilter (const String& fileWildcardPatterns,
const String& directoryWildcardPatterns,
const String& description_)
: FileFilter (description_.isEmpty() ? fileWildcardPatterns
: (description_ + " (" + fileWildcardPatterns + ")"))
const String& desc)
: FileFilter (desc.isEmpty() ? fileWildcardPatterns
: (desc + " (" + fileWildcardPatterns + ")"))
{
parse (fileWildcardPatterns, fileWildcards);
parse (directoryWildcardPatterns, directoryWildcards);

View file

@ -40,7 +40,7 @@ class JUCE_API RelativeCoordinatePositionerBase : public Component::Positioner
public MarkerList::Listener
{
public:
RelativeCoordinatePositionerBase (Component& component_);
RelativeCoordinatePositionerBase (Component& component);
~RelativeCoordinatePositionerBase();
void componentMovedOrResized (Component&, bool, bool);
@ -60,7 +60,7 @@ public:
class ComponentScope : public Expression::Scope
{
public:
ComponentScope (Component& component_);
ComponentScope (Component& component);
Expression getSymbolValue (const String& symbol) const;
void visitRelativeScope (const String& scopeName, Visitor& visitor) const;

View file

@ -71,8 +71,8 @@ private:
class ColourSelector::ColourSpaceView : public Component
{
public:
ColourSpaceView (ColourSelector& owner_, float& h_, float& s_, float& v_, const int edgeSize)
: owner (owner_), h (h_), s (s_), v (v_), lastHue (0.0f), edge (edgeSize)
ColourSpaceView (ColourSelector& cs, float& hue, float& sat, float& val, const int edgeSize)
: owner (cs), h (hue), s (sat), v (val), lastHue (0.0f), edge (edgeSize)
{
addAndMakeVisible (&marker);
setMouseCursor (MouseCursor::CrosshairCursor);
@ -194,8 +194,8 @@ private:
class ColourSelector::HueSelectorComp : public Component
{
public:
HueSelectorComp (ColourSelector& owner_, float& h_, float& s_, float& v_, const int edgeSize)
: owner (owner_), h (h_), s (s_), v (v_), edge (edgeSize)
HueSelectorComp (ColourSelector& cs, float& hue, float& sat, float& val, const int edgeSize)
: owner (cs), h (hue), s (sat), v (val), edge (edgeSize)
{
addAndMakeVisible (&marker);
}
@ -248,8 +248,8 @@ private:
class ColourSelector::SwatchComponent : public Component
{
public:
SwatchComponent (ColourSelector& owner_, int index_)
: owner (owner_), index (index_)
SwatchComponent (ColourSelector& cs, int itemIndex)
: owner (cs), index (itemIndex)
{
}
@ -306,15 +306,13 @@ private:
};
//==============================================================================
ColourSelector::ColourSelector (const int flags_,
const int edgeGap_,
const int gapAroundColourSpaceComponent)
ColourSelector::ColourSelector (const int sectionsToShow, const int edge, const int gapAroundColourSpaceComponent)
: colour (Colours::white),
flags (flags_),
edgeGap (edgeGap_)
flags (sectionsToShow),
edgeGap (edge)
{
// not much point having a selector with no components in it!
jassert ((flags_ & (showColourAtTop | showSliders | showColourspace)) != 0);
jassert ((flags & (showColourAtTop | showSliders | showColourspace)) != 0);
updateHSV();

View file

@ -36,10 +36,10 @@ extern jobject createOpenGLView (ComponentPeer*);
class OpenGLContext::NativeContext
{
public:
NativeContext (Component& component_,
NativeContext (Component& comp,
const OpenGLPixelFormat& pixelFormat,
void* /*contextToShareWith*/)
: component (component_),
: component (comp),
isInsideGLCallback (false)
{
{

View file

@ -32,9 +32,9 @@ class OpenGLContext::NativeContext
public:
NativeContext (Component& component,
const OpenGLPixelFormat& pixelFormat,
void* contextToShareWith_)
void* shareContext)
: renderContext (0), embeddedWindow (0), swapFrames (0), bestVisual (0),
contextToShareWith (contextToShareWith_)
contextToShareWith (shareContext)
{
ScopedXLock xlock;
XSync (display, False);

View file

@ -39,7 +39,7 @@ class Quaternion
public:
Quaternion() noexcept : scalar() {}
Quaternion (const Quaternion& other) noexcept : vector (other.vector), scalar (other.scalar) {}
Quaternion (const Vector3D<Type>& vector_, const Type& scalar_) noexcept : vector (vector_), scalar (scalar_) {}
Quaternion (const Vector3D<Type>& vectorPart, const Type& scalarPart) noexcept : vector (vectorPart), scalar (scalarPart) {}
Quaternion (const Type& x, const Type& y, const Type& z, const Type& w) noexcept : vector (x, y, z), scalar (w) {}
/** Creates a quaternion from an angle and an axis. */