| 177 |
|
#undef y |
| 178 |
|
#undef z |
| 179 |
|
|
| 180 |
< |
void matrix3x3::SetColumn(int col, const vector3 &v) throw(OBError) |
| 180 |
> |
void matrix3x3::SetColumn(int col, const vector3 &v) |
| 181 |
|
{ |
| 182 |
|
if (col > 2) |
| 183 |
|
{ |
| 184 |
< |
OBError er("matrix3x3::SetColumn(int col, const vector3 &v)", |
| 185 |
< |
"The method was called with col > 2.", |
| 186 |
< |
"This is a programming error in your application."); |
| 187 |
< |
throw er; |
| 184 |
> |
obErrorLog.ThrowError(__func__, |
| 185 |
> |
"The method was called with col > 2.", obError); |
| 186 |
|
} |
| 187 |
|
|
| 188 |
|
ele[0][col] = v.x(); |
| 190 |
|
ele[2][col] = v.z(); |
| 191 |
|
} |
| 192 |
|
|
| 193 |
< |
void matrix3x3::SetRow(int row, const vector3 &v) throw(OBError) |
| 193 |
> |
void matrix3x3::SetRow(int row, const vector3 &v) |
| 194 |
|
{ |
| 195 |
|
if (row > 2) |
| 196 |
|
{ |
| 197 |
< |
OBError er("matrix3x3::SetRow(int row, const vector3 &v)", |
| 198 |
< |
"The method was called with row > 2.", |
| 201 |
< |
"This is a programming error in your application."); |
| 202 |
< |
throw er; |
| 197 |
> |
obErrorLog.ThrowError(__func__, |
| 198 |
> |
"The method was called with row > 2.", obError); |
| 199 |
|
} |
| 200 |
|
|
| 201 |
|
ele[row][0] = v.x(); |
| 203 |
|
ele[row][2] = v.z(); |
| 204 |
|
} |
| 205 |
|
|
| 206 |
< |
vector3 matrix3x3::GetColumn(unsigned int col) const throw(OBError) |
| 206 |
> |
vector3 matrix3x3::GetColumn(unsigned int col) |
| 207 |
|
{ |
| 208 |
|
if (col > 2) |
| 209 |
|
{ |
| 210 |
< |
OBError er("matrix3x3::GetColumn(unsigned int col) const", |
| 211 |
< |
"The method was called with col > 2.", |
| 216 |
< |
"This is a programming error in your application."); |
| 217 |
< |
throw er; |
| 210 |
> |
obErrorLog.ThrowError(__func__, |
| 211 |
> |
"The method was called with col > 2.", obError); |
| 212 |
|
} |
| 213 |
|
|
| 214 |
|
return vector3(ele[0][col], ele[1][col], ele[2][col]); |
| 215 |
|
} |
| 216 |
|
|
| 217 |
< |
vector3 matrix3x3::GetRow(unsigned int row) const throw(OBError) |
| 217 |
> |
vector3 matrix3x3::GetRow(unsigned int row) |
| 218 |
|
{ |
| 219 |
|
if (row > 2) |
| 220 |
|
{ |
| 221 |
< |
OBError er("matrix3x3::GetRow(unsigned int row) const", |
| 222 |
< |
"The method was called with row > 2.", |
| 229 |
< |
"This is a programming error in your application."); |
| 230 |
< |
throw er; |
| 221 |
> |
obErrorLog.ThrowError(__func__, |
| 222 |
> |
"The method was called with row > 2.", obError); |
| 223 |
|
} |
| 224 |
|
|
| 225 |
|
return vector3(ele[row][0], ele[row][1], ele[row][2]); |
| 286 |
|
discouraged, unless you are certain that the determinant is in a |
| 287 |
|
reasonable range, away from 0.0 (Stefan Kebekus) |
| 288 |
|
*/ |
| 289 |
< |
matrix3x3 matrix3x3::inverse(void) const throw(OBError) |
| 289 |
> |
matrix3x3 matrix3x3::inverse(void) |
| 290 |
|
{ |
| 291 |
|
double det = determinant(); |
| 292 |
|
if (fabs(det) <= 1e-6) |
| 293 |
|
{ |
| 294 |
< |
OBError er("matrix3x3::invert(void)", |
| 295 |
< |
"The method was called on a matrix with |determinant| <= 1e-6.", |
| 304 |
< |
"This is a runtime or a programming error in your application."); |
| 305 |
< |
throw er; |
| 294 |
> |
obErrorLog.ThrowError(__func__, |
| 295 |
> |
"The method was called on a matrix with |determinant| <= 1e-6.", obError); |
| 296 |
|
} |
| 297 |
|
|
| 298 |
|
matrix3x3 inverse; |
| 425 |
|
\endcode |
| 426 |
|
|
| 427 |
|
*/ |
| 428 |
< |
matrix3x3 matrix3x3::findEigenvectorsIfSymmetric(vector3 &eigenvals) const throw(OBError) |
| 428 |
> |
matrix3x3 matrix3x3::findEigenvectorsIfSymmetric(vector3 &eigenvals) |
| 429 |
|
{ |
| 430 |
|
matrix3x3 result; |
| 431 |
|
|
| 432 |
|
if (!isSymmetric()) |
| 433 |
|
{ |
| 434 |
< |
OBError er("matrix3x3::findEigenvectorsIfSymmetric(vector3 &eigenvals) const throw(OBError)", |
| 435 |
< |
"The method was called on a matrix that was not symmetric, i.e. where isSymetric() == false.", |
| 446 |
< |
"This is a runtime or a programming error in your application."); |
| 447 |
< |
throw er; |
| 434 |
> |
obErrorLog.ThrowError(__func__, |
| 435 |
> |
"The method was called on a matrix that was not symmetric, i.e. where isSymetric() == false.", obError); |
| 436 |
|
} |
| 437 |
|
|
| 438 |
|
double d[3]; |