Blender  V2.59
Classes | Defines | Typedefs | Functions | Variables
ntl_vector3dim.h File Reference
#include <iostream>
#include <map>
#include <vector>
#include <string>
#include <sstream>
#include <math.h>
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
#include <float.h>

Go to the source code of this file.

Classes

class  ntlVector3Dim< Scalar >

Defines

#define __FLT_MAX__   3.402823466e+38f
#define __DBL_MAX__   1.7976931348623158e+308
#define M_PI   3.1415926536
#define M_E   2.7182818284
#define GFX_PRECISION   1
#define GFX_REAL_MAX   __FLT_MAX__
#define VECTOR_EPSILON   (1e-5f)
#define HAVE_GFXTYPES
#define VECTOR_TYPE   ntlVector3Dim<Scalar>

Typedefs

typedef ntlVector3Dim< double > ntlVec3d
typedef ntlVector3Dim< float > ntlVec3f
typedef ntlVector3Dim< int > ntlVec3i
typedef ntlVec3f ntlColor
typedef float gfxReal
typedef double gfxDouble
typedef ntlVector3Dim< gfxRealntlVec3Gfx

Functions

template<class Scalar >
std::ostream & operator<< (std::ostream &os, const ntlVector3Dim< Scalar > &i)
template<class Scalar >
std::istream & operator>> (std::istream &is, ntlVector3Dim< Scalar > &i)
template<class Scalar >
Scalar dot (const ntlVector3Dim< Scalar > &t, const ntlVector3Dim< Scalar > &v)
template<class Scalar >
ntlVector3Dim< Scalar > cross (const ntlVector3Dim< Scalar > &t, const ntlVector3Dim< Scalar > &v)
template<class T >
ntlVec3d vec2D (T v)
template<class T >
ntlVec3f vec2F (T v)
template<class T >
ntlColor vec2Col (T v)
template<class T >
ntlVec3Gfx vec2G (T v)
gfxReal getVecEpsilon ()
template<class Scalar >
Scalar norm (const VECTOR_TYPE &v)
template<class Scalar >
Scalar normNoSqrt (const VECTOR_TYPE &v)
template<class Scalar >
VECTOR_TYPE getNormalized (const VECTOR_TYPE &v)
template<class Scalar >
Scalar normalize (VECTOR_TYPE &v)
template<class Scalar >
VECTOR_TYPE reflectVector (const VECTOR_TYPE &t, const VECTOR_TYPE &n)
template<class Scalar >
VECTOR_TYPE refractVector (const VECTOR_TYPE &t, const VECTOR_TYPE &normal, Scalar nt, Scalar nair, int &refRefl)
template<class Scalar >
bool equal (const VECTOR_TYPE &v, const VECTOR_TYPE &c)
template<class Scalar >
void rgbToHsv (VECTOR_TYPE &V)
template<class Scalar >
void hsvToRgb (VECTOR_TYPE &V)

Variables

const char * globVecFormatStr
 global string for formatting vector output in utilities.cpp

Detailed Description

Definition in file ntl_vector3dim.h.


Define Documentation

#define __DBL_MAX__   1.7976931348623158e+308

Definition at line 93 of file ntl_vector3dim.h.

#define __FLT_MAX__   3.402823466e+38f

Definition at line 86 of file ntl_vector3dim.h.

#define GFX_PRECISION   1

Definition at line 827 of file ntl_vector3dim.h.

#define GFX_REAL_MAX   __FLT_MAX__
#define HAVE_GFXTYPES

Definition at line 862 of file ntl_vector3dim.h.

#define M_E   2.7182818284

Definition at line 99 of file ntl_vector3dim.h.

#define M_PI   3.1415926536

Definition at line 98 of file ntl_vector3dim.h.

#define VECTOR_EPSILON   (1e-5f)
#define VECTOR_TYPE   ntlVector3Dim<Scalar>

Definition at line 871 of file ntl_vector3dim.h.

Referenced by getNormalized(), and reflectVector().


Typedef Documentation

typedef double gfxDouble

Definition at line 851 of file ntl_vector3dim.h.

typedef float gfxReal

Definition at line 833 of file ntl_vector3dim.h.

typedef ntlVec3f ntlColor

Definition at line 798 of file ntl_vector3dim.h.

typedef ntlVector3Dim<double> ntlVec3d

Definition at line 789 of file ntl_vector3dim.h.

typedef ntlVector3Dim<float> ntlVec3f

Definition at line 792 of file ntl_vector3dim.h.

Definition at line 854 of file ntl_vector3dim.h.

typedef ntlVector3Dim<int> ntlVec3i

Definition at line 795 of file ntl_vector3dim.h.


Function Documentation

template<class Scalar >
ntlVector3Dim<Scalar> cross ( const ntlVector3Dim< Scalar > &  t,
const ntlVector3Dim< Scalar > &  v 
) [inline]
template<class Scalar >
Scalar dot ( const ntlVector3Dim< Scalar > &  t,
const ntlVector3Dim< Scalar > &  v 
) [inline]

Definition at line 678 of file ntl_vector3dim.h.

Referenced by btPerturbedContactResult::addContactPoint(), ATTRIBUTE_ALIGNED16(), btNearestPointInLineSegment(), btTransformAabb(), btPrimitiveTriangle::buildTriPlane(), btTriangleShapeEx::buildTriPlane(), ntlMaterial::calculateFresnel(), ControlParticles::checkPointInside(), TNT::Cholesky_upper_factorization(), btVoronoiSimplexSolver::closestPtPointTetrahedron(), cloth_calc_spring_force(), collision_response(), column_vector_multiplication(), ntlMatrix4x4< Scalar >::decompose(), IsoSurface::diffuseVertexField(), do_material_tex(), dot(), dupli_extrude_cursor(), EdgeSeparation(), AnimationExporter::extract_transform_name(), FindIncidentEdge(), FindMaxSeparation(), frontface(), LbmSolverInterface::geoInitCheckPointInside(), btTriangleMeshShape::getAabb(), btCapsuleShape::getAabb(), btHeightfieldTerrainShape::getAabb(), ntlLightObject::getShadedColor(), btSphereBoxCollisionAlgorithm::getSphereDistance(), btSphereBoxCollisionAlgorithm::getSpherePenetration(), LbmFsgrSolver::handleObstacleParticle(), ntlGeometryObject::initMovingPoints(), LocalSupportVertexCallback::internalProcessTriangleIndex(), ntlRay::intersectTriangle(), ntlRay::intersectTriangleBack(), ntlRay::intersectTriangleFront(), ntlRay::intersectTriangleX(), isect_line_plane_v3(), lasso_inside(), Matrix_mul(), mean_value_half_tan(), MT_multTransposeRight(), KDL::VectorVel::Norm(), normal_projection_project_vertex(), btTransform::operator()(), operator*(), p_vec_angle(), pe_deflect_emitter(), btVoronoiSimplexSolver::pointOutsideOfPlane(), LbmFsgrSolver::prepareVisualization(), SupportVertexCallback::processTriangle(), ntlVector3Dim< Scalar >::projectNormalTo(), btSoftBody::PSolve_SContacts(), reflectVector(), refraction(), refractVector(), rotation_between_quats_to_quat(), seqbase_unique_name_recursive(), set_phong_threshold(), ntlRay::shade(), similar_face_select__internal(), IsoSurface::smoothNormals(), IsoSurface::smoothSurface(), btConeTwistConstraint::solveConstraintObsolete(), btTranslationalLimitMotor::solveLinearAxis(), strand_segment_recursive(), btMatrix3x3::timesTranspose(), GIM_BOX_BOX_TRANSFORM_CACHE::transform(), vec_magnitude_nosqrt(), Vector_angle(), Vector_dot(), Vector_getLength(), Vector_getLengthSquared(), Vector_mul(), Vector_project(), and Vector_setLength().

template<class Scalar >
bool equal ( const VECTOR_TYPE &  v,
const VECTOR_TYPE &  c 
) [inline]
template<class Scalar >
VECTOR_TYPE getNormalized ( const VECTOR_TYPE &  v) [inline]
gfxReal getVecEpsilon ( ) [inline]
template<class Scalar >
void hsvToRgb ( VECTOR_TYPE &  V) [inline]

Definition at line 1051 of file ntl_vector3dim.h.

References g, and p.

template<class Scalar >
Scalar norm ( const VECTOR_TYPE &  v) [inline]

Definition at line 879 of file ntl_vector3dim.h.

References fabs(), sqrt(), and VECTOR_EPSILON.

Referenced by LbmFsgrSolver::adaptTimestep(), LbmFsgrSolver::advanceParticles(), axisProjection(), BLI_edgefill(), btShapeHull::buildHull(), ntlScene::buildScene(), C_Matrix_OrthoProjection(), C_Matrix_Scale(), btMinkowskiPenetrationDepthSolver::calcPenDepth(), ntlGeometryObjModel::calcTriangleDivs(), ntlGeometryObject::calcTriangleDivs(), Parametrizer::calculateAllMissingValues(), btConeTwistConstraint::computeConeLimitInfo(), IsoSurface::computeNormals(), MeanValueMeshCoords::computeWeights(), AUD_ButterworthFactory::createReader(), AUD_LowpassFactory::createReader(), AUD_HighpassFactory::createReader(), ntlMatrix4x4< Scalar >::decompose(), eff_calc_visibility(), Eigenhqr2(), LbmFsgrSolver::fineAdvance(), GetNormal(), btConeTwistConstraint::GetPointForAngle(), KDL::Rotation::GetXZRot(), ControlParticles::initFromMVCMesh(), LbmFsgrSolver::initGeometryFlags(), LbmFsgrSolver::initializeSolverGrids(), LbmFsgrSolver::initLevelOmegas(), LbmFsgrSolver::LbmFsgrSolver(), LbmFsgrSolver::mainLoop(), normalize(), ntlTriangle::ntlTriangle(), p_abf_compute_gradient(), p_chart_abf_solve(), planeProjection(), ntlWorld::renderScene(), IsoSurface::smoothNormals(), IsoSurface::smoothSurface(), iTaSC::WSDLSSolver::solve(), iTaSC::WDLSSolver::solve(), btSoftColliders::ClusterBase::SolveContact(), traceray(), IsoSurface::triangulate(), iTaSC::Armature::updateJoint(), Vector_normalize(), and view3d_align_axis_to_vector().

template<class Scalar >
Scalar normalize ( VECTOR_TYPE &  v) [inline]
template<class Scalar >
Scalar normNoSqrt ( const VECTOR_TYPE &  v) [inline]
template<class Scalar >
std::ostream& operator<< ( std::ostream &  os,
const ntlVector3Dim< Scalar > &  i 
)

Definition at line 217 of file ntl_vector3dim.h.

References globVecFormatStr, and i.

template<class Scalar >
std::istream& operator>> ( std::istream &  is,
ntlVector3Dim< Scalar > &  i 
)

Definition at line 234 of file ntl_vector3dim.h.

template<class Scalar >
VECTOR_TYPE reflectVector ( const VECTOR_TYPE &  t,
const VECTOR_TYPE &  n 
) [inline]

Definition at line 949 of file ntl_vector3dim.h.

References dot(), and VECTOR_TYPE.

Referenced by ntlRay::shade().

template<class Scalar >
VECTOR_TYPE refractVector ( const VECTOR_TYPE &  t,
const VECTOR_TYPE &  normal,
Scalar  nt,
Scalar  nair,
int &  refRefl 
) [inline]

Definition at line 962 of file ntl_vector3dim.h.

References dot(), and sqrt().

Referenced by ntlRay::shade().

template<class Scalar >
void rgbToHsv ( VECTOR_TYPE &  V) [inline]

Definition at line 1011 of file ntl_vector3dim.h.

template<class T >
ntlColor vec2Col ( v) [inline]

Definition at line 803 of file ntl_vector3dim.h.

template<class T >
ntlVec3d vec2D ( v) [inline]
template<class T >
ntlVec3f vec2F ( v) [inline]

Definition at line 802 of file ntl_vector3dim.h.

template<class T >
ntlVec3Gfx vec2G ( v) [inline]

Variable Documentation

const char* globVecFormatStr

global string for formatting vector output in utilities.cpp

Definition at line 82 of file utilities.cpp.

Referenced by operator<<(), and BasicVector::operator<<().