#include "chrome/browser/vr/elements/viewport_aware_root.h"
#include <cmath>
#include <memory>
#include "base/memory/raw_ptr.h"
#include "base/numerics/ranges.h"
#include "base/time/time.h"
#include "chrome/browser/vr/elements/draw_phase.h"
#include "chrome/browser/vr/test/animation_utils.h"
#include "chrome/browser/vr/test/constants.h"
#include "chrome/browser/vr/ui_scene.h"
#include "testing/gtest/include/gtest/gtest.h"
#include "ui/gfx/geometry/insets_f.h"
#include "ui/gfx/geometry/quaternion.h"
#include "ui/gfx/geometry/transform.h"
namespace vr {
namespace {
const float kThreshold = …;
const int kFramesPerSecond = …;
bool Point3FAreNearlyEqual(const gfx::Point3F& lhs, const gfx::Point3F& rhs) { … }
bool MatricesAreNearlyEqual(const gfx::Transform& lhs,
const gfx::Transform& rhs) { … }
void RotateAboutYAxis(float degrees, gfx::Vector3dF* out) { … }
class ViewportAwareRootForTesting : public ViewportAwareRoot { … };
}
class ViewportAwareRootTest : public testing::Test { … };
TEST_F(ViewportAwareRootTest, TestAdjustRotationForHeadPose) { … }
TEST_F(ViewportAwareRootTest, ChildElementsRepositioned) { … }
TEST_F(ViewportAwareRootTest, ChildElementsHasOpacityAnimation) { … }
TEST_F(ViewportAwareRootTest, ResetPositionWhenReshow) { … }
TEST_F(ViewportAwareRootTest, IsChildrenVisible) { … }
}