/* * Copyright 2014 Google Inc. All rights reserved. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. * You may obtain a copy of the License at * * http://www.apache.org/licenses/LICENSE-2.0 * * Unless required by applicable law or agreed to in writing, software * distributed under the License is distributed on an "AS IS" BASIS, * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. * See the License for the specific language governing permissions and * limitations under the License. */ #ifndef MATHFU_CONSTANTS_H #define MATHFU_CONSTANTS_H #include "mathfu/matrix.h" #include "mathfu/quaternion.h" #include "mathfu/vector.h" namespace mathfu { /// @file mathfu/constants.h /// @brief Vector constants for specific dimensions. /// @addtogroup mathfu_constants /// /// It is preferable to use these constants rather than constructing them /// when they're required. Construction most-likely slower than loading them /// from memory. ///
/// For example, the following:
///
/// lookat = mat4::LookAt(target, position, mathfu::kAxisY3f);
///
///
is preferable to:
///
/// lookat = mat4::LookAt(target, position,
/// mathfu::Vector
///
in terms of efficiency and in addition to resulting in more concise
/// code.
///
float
Vector of zeros.
static const Vectorfloat
Vector of ones.
static const Vectorfloat
unit Vector pointing along the X axis.
static const Vectorfloat
unit Vector pointing along the Y axis.
static const Vectorfloat
Vector of zeros.
static const Vectorfloat
Vector of ones.
static const Vectorfloat
unit Vector pointing along the X axis.
static const Vectorfloat
unit Vector pointing along the Y axis.
static const Vectorfloat
unit Vector pointing along the Z axis.
static const Vectorfloat
Vector of zeros.
static const Vectorfloat
Vector of ones.
static const Vectorfloat
unit Vector pointing along the X axis.
static const Vectorfloat
unit Vector pointing along the Y axis.
static const Vectorfloat
unit Vector pointing along the Z axis.
static const Vectorfloat
unit Vector pointing along the W axis.
static const Vectordouble
Vector of zeros.
static const Vectordouble
Vector of ones.
static const Vectordouble
unit Vector pointing along the X axis.
static const Vectordouble
unit Vector pointing along the Y axis.
static const Vectordouble
Vector of zeros.
static const Vectordouble
Vector of ones.
static const Vectordouble
unit Vector pointing along the X axis.
static const Vectordouble
unit Vector pointing along the Y axis.
static const Vectordouble
unit Vector pointing along the Z axis.
static const Vectordouble
Vector of zeros.
static const Vectordouble
Vector of ones.
static const Vectordouble
unit Vector pointing along the X axis.
static const Vectordouble
unit Vector pointing along the Y axis.
static const Vectordouble
unit Vector pointing along the Z axis.
static const Vectordouble
unit Vector pointing along the W axis.
static const Vectorint
Vector of zeros.
static const Vectorint
Vector of ones.
static const Vectorint
unit Vector pointing along the X axis.
static const Vectorint
unit Vector pointing along the Y axis.
static const Vectorint
Vector of zeros.
static const Vectorint
Vector of ones.
static const Vectorint
unit Vector pointing along the X axis.
static const Vectorint
unit Vector pointing along the Y axis.
static const Vectorint
unit Vector pointing along the Z axis.
static const Vectorint
Vector of zeros.
static const Vectorint
Vector of ones.
static const Vectorint
unit Vector pointing along the X axis.
static const Vectorint
unit Vector pointing along the Z axis.
static const Vectorint
unit Vector pointing along the Y axis.
static const Vectorint
unit Vector pointing along the W axis.
static const Vector