bool MatrixTransform::equals(const MatrixTransform & other) const { if (this == &other) return true; if (getImpl()->dir_ != other.getImpl()->dir_) { return false; } return *getImpl() == *(other.getImpl()); }
bool MatrixTransform::equals(const MatrixTransform & other) const { const float abserror = 1e-9f; for(int i=0; i<16; ++i) { if(!equalWithAbsError(getImpl()->matrix_[i], other.getImpl()->matrix_[i], abserror)) { return false; } } for(int i=0; i<4; ++i) { if(!equalWithAbsError(getImpl()->offset_[i], other.getImpl()->offset_[i], abserror)) { return false; } } return true; }