Convert channel counts to size_t.
IIRC, this was originally requested by ajm during review of the other size_t conversions I did over the past year, and I agreed it made sense, but wanted to do it separately since those changes were already gargantuan. BUG=chromium:81439 TEST=none R=henrik.lundin@webrtc.org, henrika@webrtc.org, kjellander@webrtc.org, minyue@webrtc.org, perkj@webrtc.org, solenberg@webrtc.org, stefan@webrtc.org, tina.legrand@webrtc.org Review URL: https://codereview.webrtc.org/1316523002 . Cr-Commit-Position: refs/heads/master@{#11229}
This commit is contained in:
@ -27,10 +27,10 @@ class ComplexMatrix : public Matrix<complex<T> > {
|
||||
public:
|
||||
ComplexMatrix() : Matrix<complex<T> >() {}
|
||||
|
||||
ComplexMatrix(int num_rows, int num_columns)
|
||||
ComplexMatrix(size_t num_rows, size_t num_columns)
|
||||
: Matrix<complex<T> >(num_rows, num_columns) {}
|
||||
|
||||
ComplexMatrix(const complex<T>* data, int num_rows, int num_columns)
|
||||
ComplexMatrix(const complex<T>* data, size_t num_rows, size_t num_columns)
|
||||
: Matrix<complex<T> >(data, num_rows, num_columns) {}
|
||||
|
||||
// Complex Matrix operations.
|
||||
@ -51,7 +51,7 @@ class ComplexMatrix : public Matrix<complex<T> > {
|
||||
|
||||
ComplexMatrix& ConjugateTranspose() {
|
||||
this->CopyDataToScratch();
|
||||
int num_rows = this->num_rows();
|
||||
size_t num_rows = this->num_rows();
|
||||
this->SetNumRows(this->num_columns());
|
||||
this->SetNumColumns(num_rows);
|
||||
this->Resize();
|
||||
@ -82,8 +82,8 @@ class ComplexMatrix : public Matrix<complex<T> > {
|
||||
private:
|
||||
ComplexMatrix& ConjugateTranspose(const complex<T>* const* src) {
|
||||
complex<T>* const* elements = this->elements();
|
||||
for (int i = 0; i < this->num_rows(); ++i) {
|
||||
for (int j = 0; j < this->num_columns(); ++j) {
|
||||
for (size_t i = 0; i < this->num_rows(); ++i) {
|
||||
for (size_t j = 0; j < this->num_columns(); ++j) {
|
||||
elements[i][j] = conj(src[j][i]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user