Sign in to follow this  

matrix multiplication

This topic is 4533 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, This is from the nvidia matrix class : matrix4 & mult_right( const matrix4 & b ) { matrix4 mt(*this); set_value(real(0)); for(int i=0; i < 4; i++) for(int j=0; j < 4; j++) for(int c=0; c < 4; c++) element(i,j) += mt(i,c) * b(c,j); return *this; } matrix4 & operator *= ( const matrix4 & mat ) { mult_right( mat ); return *this; } And it's used like this : matrix4f m_matrix = P * M; It's not a standard matrix * matrix operation, what are they doing here ? thanks, Bruno

Share this post


Link to post
Share on other sites
This is an ordinary matrix multiplication operation; the three loops are just a slick way to multiply everything.

Share this post


Link to post
Share on other sites

This topic is 4533 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this