Warning fix by maxim, and add multiplication order in docs
git-svn-id: svn://svn.code.sf.net/p/irrlicht/code/trunk@3245 dfc29bdd-3216-0410-991c-e03cc46cb475master
parent
9d1cc03094
commit
b3ab720d03
|
@ -22,7 +22,6 @@
|
||||||
//#define USE_MATRIX_TEST_DEBUG
|
//#define USE_MATRIX_TEST_DEBUG
|
||||||
|
|
||||||
#if defined( USE_MATRIX_TEST_DEBUG )
|
#if defined( USE_MATRIX_TEST_DEBUG )
|
||||||
#include <windows.h>
|
|
||||||
|
|
||||||
struct MatrixTest
|
struct MatrixTest
|
||||||
{
|
{
|
||||||
|
@ -125,17 +124,20 @@ namespace core
|
||||||
CMatrix4<T>& operator-=(const CMatrix4<T>& other);
|
CMatrix4<T>& operator-=(const CMatrix4<T>& other);
|
||||||
|
|
||||||
//! set this matrix to the product of two matrices
|
//! set this matrix to the product of two matrices
|
||||||
|
/** Calculate b*a */
|
||||||
inline CMatrix4<T>& setbyproduct(const CMatrix4<T>& other_a,const CMatrix4<T>& other_b );
|
inline CMatrix4<T>& setbyproduct(const CMatrix4<T>& other_a,const CMatrix4<T>& other_b );
|
||||||
|
|
||||||
//! Set this matrix to the product of two matrices
|
//! Set this matrix to the product of two matrices
|
||||||
/** no optimization used,
|
/** Calculate b*a, no optimization used,
|
||||||
use it if you know you never have a identity matrix */
|
use it if you know you never have a identity matrix */
|
||||||
CMatrix4<T>& setbyproduct_nocheck(const CMatrix4<T>& other_a,const CMatrix4<T>& other_b );
|
CMatrix4<T>& setbyproduct_nocheck(const CMatrix4<T>& other_a,const CMatrix4<T>& other_b );
|
||||||
|
|
||||||
//! Multiply by another matrix.
|
//! Multiply by another matrix.
|
||||||
|
/** Calculate other*this */
|
||||||
CMatrix4<T> operator*(const CMatrix4<T>& other) const;
|
CMatrix4<T> operator*(const CMatrix4<T>& other) const;
|
||||||
|
|
||||||
//! Multiply by another matrix.
|
//! Multiply by another matrix.
|
||||||
|
/** Calculate and return other*this */
|
||||||
CMatrix4<T>& operator*=(const CMatrix4<T>& other);
|
CMatrix4<T>& operator*=(const CMatrix4<T>& other);
|
||||||
|
|
||||||
//! Multiply by scalar.
|
//! Multiply by scalar.
|
||||||
|
@ -1416,7 +1418,7 @@ namespace core
|
||||||
{
|
{
|
||||||
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
||||||
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
||||||
const T w = h / aspectRatio;
|
const T w = static_cast<T>(h / aspectRatio);
|
||||||
|
|
||||||
_IRR_DEBUG_BREAK_IF(zNear==zFar); //divide by zero
|
_IRR_DEBUG_BREAK_IF(zNear==zFar); //divide by zero
|
||||||
M[0] = w;
|
M[0] = w;
|
||||||
|
@ -1455,7 +1457,7 @@ namespace core
|
||||||
{
|
{
|
||||||
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
||||||
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
||||||
const T w = (T)(h / aspectRatio);
|
const T w = static_cast<T>(h / aspectRatio);
|
||||||
|
|
||||||
_IRR_DEBUG_BREAK_IF(zNear==zFar); //divide by zero
|
_IRR_DEBUG_BREAK_IF(zNear==zFar); //divide by zero
|
||||||
M[0] = w;
|
M[0] = w;
|
||||||
|
@ -1492,7 +1494,7 @@ namespace core
|
||||||
{
|
{
|
||||||
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
const f64 h = reciprocal(tan(fieldOfViewRadians*0.5));
|
||||||
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
_IRR_DEBUG_BREAK_IF(aspectRatio==0.f); //divide by zero
|
||||||
const T w = (T)(h / aspectRatio);
|
const T w = static_cast<T>(h / aspectRatio);
|
||||||
|
|
||||||
M[0] = w;
|
M[0] = w;
|
||||||
M[1] = 0;
|
M[1] = 0;
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
Tests finished. 52 tests of 52 passed.
|
Tests finished. 54 tests of 54 passed.
|
||||||
Compiled as DEBUG
|
Compiled as DEBUG
|
||||||
Test suite pass at GMT Thu Feb 18 11:54:08 2010
|
Test suite pass at GMT Thu Mar 11 23:23:09 2010
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue