chromium/third_party/angle/src/common/matrix_utils_unittest.cpp

//
// Copyright 2015 The ANGLE Project Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
//
// matrix_utils_unittests:
//   Unit tests for the matrix utils.
//

#include "matrix_utils.h"

#include <gtest/gtest.h>

usingnamespaceangle;

namespace
{

struct RotateArgs
{};

struct TranslateArgs
{};

struct ScaleArgs
{};

struct FrustumArgs
{};

void CheckMat4ExactlyEq(const Mat4 &a, const Mat4 &b)
{}

// TODO(lfy): Spec out requirements for matrix precision
void CheckMatrixCloseToGolden(float *golden, const Mat4 &m)
{}

void CheckMatrixCloseToGolden(const std::vector<float> &golden, const Mat4 &m)
{}
}  // namespace

namespace
{

const unsigned int minDimensions =;
const unsigned int maxDimensions =;

TEST(MatrixUtilsTest, MatrixConstructorTest)
{}

TEST(MatrixUtilsTest, MatrixCompMultTest)
{}

TEST(MatrixUtilsTest, MatrixOuterProductTest)
{}

TEST(MatrixUtilsTest, MatrixTransposeTest)
{}

TEST(MatrixUtilsTest, MatrixDeterminantTest)
{}

TEST(MatrixUtilsTest, 2x2MatrixInverseTest)
{}

TEST(MatrixUtilsTest, 3x3MatrixInverseTest)
{}

TEST(MatrixUtilsTest, 4x4MatrixInverseTest)
{}

// Tests constructors for mat4; using raw float*, std::vector<float>,
// and Matrix<float>.
TEST(MatrixUtilsTest, Mat4Construction)
{}

// Tests rotation matrices.
TEST(MatrixUtilsTest, Mat4Rotate)
{}

// Tests mat4 translation.
TEST(MatrixUtilsTest, Mat4Translate)
{}

// Tests scale for mat4.
TEST(MatrixUtilsTest, Mat4Scale)
{}

// Tests frustum matrices.
TEST(MatrixUtilsTest, Mat4Frustum)
{}

// Tests orthographic projection matrices.
TEST(MatrixUtilsTest, Mat4Ortho)
{}

// Tests for inverse transpose of mat4, which is a frequent operation done to
// the modelview matrix, for things such as transformation of normals.
TEST(MatrixUtilsTest, Mat4InvTr)
{}

// Tests mat4 matrix/matrix multiplication by multiplying two translation matrices.
TEST(MatrixUtilsTest, Mat4Mult)
{}

// Tests exact equality.
TEST(MatrixUtilsTest, ExactEquality)
{}

// Tests near equality.
TEST(MatrixUtilsTest, NearEquality)
{}

}  // namespace