Issue found with PVS-Studio:

A lot of instances where some function args are not actually modified in any way, meaning that it is better for performance to convert them into const references. This prevents an additional copy, which can help performance.
This commit is contained in:
Areloch 2015-07-16 22:02:18 -05:00
parent ec63398042
commit 11398bb04e
40 changed files with 59 additions and 59 deletions

View file

@ -1103,8 +1103,8 @@ protected:
virtual void shakeCamera( U32 imageSlot );
virtual void updateDamageLevel();
virtual void updateDamageState();
virtual void onImpact(SceneObject* obj, VectorF vec);
virtual void onImpact(VectorF vec);
virtual void onImpact(SceneObject* obj, const VectorF& vec);
virtual void onImpact(const VectorF& vec);
/// @}
/// The inner prep render function that does the
@ -1587,7 +1587,7 @@ public:
virtual void getEyeCameraTransform( IDisplayDevice *display, U32 eyeId, MatrixF *outMat );
/// Calculates a delta camera angle and view position based on inPose
virtual DisplayPose calcCameraDeltaPose(GameConnection *con, DisplayPose inPose);
virtual DisplayPose calcCameraDeltaPose(GameConnection *con, const DisplayPose& inPose);
/// Gets the index of a node inside a mounted image given the name
/// @param imageSlot Image slot