#include <glsl_math.h>
Inheritance diagram for gslib::glsl_math::matrix_mixin< SubClass, FriendVector, RowSize, ColumnSize >:


Public Types | |
| typedef tuple_mixin< SubClass, RowSize *ColumnSize > | TupleMixin |
Public Member Functions | |
| SubClass & | operator *= (value_type v) |
| SubClass | operator * (value_type v) const |
| SubClass & | operator/= (value_type v) |
| SubClass | operator/ (value_type v) const |
| FriendVector & | operator[] (size_type nthColumn) |
| get nthColumn column vector's reference | |
| const FriendVector & | operator[] (size_type nthColumn) const |
| get nthColumn column vector's const reference | |
| SubClass | operator * (const SubClass &other) const |
| SubClass & | operator *= (const SubClass &other) |
| FriendVector | operator * (const FriendVector &v) |
| multiply with column vector ( Right Hand System, OpenGL ) | |
Static Public Member Functions | |
| size_type | columnSize () |
| size_type | rowSize () |
Friends | |
| FriendVector | operator * (const FriendVector &v, const SubClass &other) |
| multiply with column vector ( Left Hand Syste, DirectX ) | |
Definition at line 437 of file glsl_math.h.
|
|||||
|
Definition at line 438 of file glsl_math.h. |
|
|||||||||
|
Definition at line 501 of file glsl_math.h.
00501 {
00502 return ColumnSize;
00503 }
|
|
||||||||||
|
multiply with column vector ( Right Hand System, OpenGL )
Definition at line 483 of file glsl_math.h.
00483 {
00484 FriendVector result( 0 );
00485 for ( size_type i = 0; i < FriendVector::size(); ++i ) {
00486 for ( size_type j = 0; j < FriendVector::size(); ++j ) {
00487 result[ i ] += v[ j ] * operator [] ( j )[ i ];
00488 }
00489 }
00490 return result;
00491 }
|
|
||||||||||
|
Definition at line 462 of file glsl_math.h.
00462 {
00463 #define AT( i, j ) operator [] ( i )[ j ]
00464
00465 SubClass result( 0 );
00466 for ( size_type i = 0; i < ColumnSize; ++i ) {
00467 for ( size_type j = 0; j < RowSize; ++j ) {
00468 for ( size_type k = 0; k < ColumnSize; ++k ) {
00469 result[ i ][ j ] += AT( j, k ) * other[ k ][ i ];
00470 }
00471 }
00472 }
00473
00474 #undef AT
00475
00476 return result;
00477 }
|
|
||||||||||
|
Reimplemented from gslib::glsl_math::tuple_mixin< SubClass, RowSize *ColumnSize >. Definition at line 442 of file glsl_math.h.
00442 {
00443 return TupleMixin::operator * ( v );
00444 }
|
|
||||||||||
|
Definition at line 478 of file glsl_math.h.
00478 {
00479 *this = ( *this ) * other;
00480 return *this;
00481 }
|
|
||||||||||
|
Reimplemented from gslib::glsl_math::tuple_mixin< SubClass, RowSize *ColumnSize >. Definition at line 439 of file glsl_math.h.
00439 {
00440 return TupleMixin::operator *= ( v );
00441 }
|
|
||||||||||
|
Reimplemented from gslib::glsl_math::tuple_mixin< SubClass, RowSize *ColumnSize >. Definition at line 448 of file glsl_math.h.
00448 {
00449 return TupleMixin::operator / ( v );
00450 }
|
|
||||||||||
|
Reimplemented from gslib::glsl_math::tuple_mixin< SubClass, RowSize *ColumnSize >. Definition at line 445 of file glsl_math.h.
00445 {
00446 return TupleMixin::operator /= ( v );
00447 }
|
|
||||||||||
|
get nthColumn column vector's const reference
Reimplemented from gslib::glsl_math::tuple< Size >. Definition at line 458 of file glsl_math.h.
00458 {
00459 BOOST_ASSERT( nthColumn < ColumnSize );
00460 return *( reinterpret_cast< const FriendVector* >( begin() ) + nthColumn );
00461 }
|
|
||||||||||
|
get nthColumn column vector's reference
Reimplemented from gslib::glsl_math::tuple< Size >. Definition at line 453 of file glsl_math.h. Referenced by gslib::glsl_math::matrix_mixin< mat2, vec2, 2, 2 >::operator *().
00453 {
00454 BOOST_ASSERT( nthColumn < ColumnSize );
00455 return *( reinterpret_cast< FriendVector* >( begin() ) + nthColumn );
00456 }
|
|
|||||||||
|
Definition at line 504 of file glsl_math.h.
00504 {
00505 return RowSize;
00506 }
|
|
||||||||||||||||
|
multiply with column vector ( Left Hand Syste, DirectX )
Definition at line 493 of file glsl_math.h.
|
1.3.6