Lines Matching defs:mat
303 Vector2 Transform(const Vector2& vec, const Matrix3& mat)
306 retVal.x_ = vec.x_ * mat.mat_[0][0] + vec.y_ * mat.mat_[1][0] + mat.mat_[2][0]; // 2: row2
307 retVal.y_ = vec.x_ * mat.mat_[0][1] + vec.y_ * mat.mat_[1][1] + mat.mat_[2][1]; // 2: row2
312 Vector3 Transform(const Vector3& vec, const Matrix4& mat)
315 retVal.x_ = vec.x_ * mat.mat_[0][0] + vec.y_ * mat.mat_[1][0] +
316 vec.z_ * mat.mat_[2][0] + mat.mat_[3][0]; // 2: row2, 3: row3
317 retVal.y_ = vec.x_ * mat.mat_[0][1] + vec.y_ * mat.mat_[1][1] +
318 vec.z_ * mat.mat_[2][1] + mat.mat_[3][1]; // 2: row2, 3: row3
319 retVal.z_ = vec.x_ * mat.mat_[0][2] + vec.y_ * mat.mat_[1][2] + // 2: row2
320 vec.z_ * mat.mat_[2][2] + mat.mat_[3][2]; // 2: row2, 3: row3
325 Vector3 TransformWithPerspDiv(const Vector3& vec, const Matrix4& mat, float w)
328 retVal.x_ = vec.x_ * mat.mat_[0][0] + vec.y_ * mat.mat_[1][0] +
329 vec.z_ * mat.mat_[2][0] + w * mat.mat_[3][0]; // 2: row2, 3: row3
330 retVal.y_ = vec.x_ * mat.mat_[0][1] + vec.y_ * mat.mat_[1][1] +
331 vec.z_ * mat.mat_[2][1] + w * mat.mat_[3][1]; // 2: row2, 3: row3
332 retVal.z_ = vec.x_ * mat.mat_[0][2] + vec.y_ * mat.mat_[1][2] +
333 vec.z_ * mat.mat_[2][2] + w * mat.mat_[3][2]; // 2: row2, 3: row3
334 float transformedW = vec.x_ * mat.mat_[0][3] + vec.y_ * mat.mat_[1][3] +
335 vec.z_ * mat.mat_[2][3] + w * mat.mat_[3][3]; // 2: row2, 3: row3
345 Vector2 GetOriginScreenPoint(const Vector2& p, const Matrix4& mat)
347 Matrix4 invertMat = mat;