kfbxdualquaternion.h

Go to the documentation of this file.
00001 
00004 #ifndef FBXFILESDK_KFBXMATH_KFBXDUALQUATERNION_H
00005 #define FBXFILESDK_KFBXMATH_KFBXDUALQUATERNION_H
00006 
00007 /**************************************************************************************
00008 
00009  Copyright (C) 2010 Autodesk, Inc. and/or its licensors.
00010  All Rights Reserved.
00011 
00012  The coded instructions, statements, computer programs, and/or related material 
00013  (collectively the "Data") in these files contain unpublished information 
00014  proprietary to Autodesk, Inc. and/or its licensors, which is protected by 
00015  Canada and United States of America federal copyright law and by international 
00016  treaties. 
00017  
00018  The Data may not be disclosed or distributed to third parties, in whole or in
00019  part, without the prior written consent of Autodesk, Inc. ("Autodesk").
00020 
00021  THE DATA IS PROVIDED "AS IS" AND WITHOUT WARRANTY.
00022  ALL WARRANTIES ARE EXPRESSLY EXCLUDED AND DISCLAIMED. AUTODESK MAKES NO
00023  WARRANTY OF ANY KIND WITH RESPECT TO THE DATA, EXPRESS, IMPLIED OR ARISING
00024  BY CUSTOM OR TRADE USAGE, AND DISCLAIMS ANY IMPLIED WARRANTIES OF TITLE, 
00025  NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE OR USE. 
00026  WITHOUT LIMITING THE FOREGOING, AUTODESK DOES NOT WARRANT THAT THE OPERATION
00027  OF THE DATA WILL BE UNINTERRUPTED OR ERROR FREE. 
00028  
00029  IN NO EVENT SHALL AUTODESK, ITS AFFILIATES, PARENT COMPANIES, LICENSORS
00030  OR SUPPLIERS ("AUTODESK GROUP") BE LIABLE FOR ANY LOSSES, DAMAGES OR EXPENSES
00031  OF ANY KIND (INCLUDING WITHOUT LIMITATION PUNITIVE OR MULTIPLE DAMAGES OR OTHER
00032  SPECIAL, DIRECT, INDIRECT, EXEMPLARY, INCIDENTAL, LOSS OF PROFITS, REVENUE
00033  OR DATA, COST OF COVER OR CONSEQUENTIAL LOSSES OR DAMAGES OF ANY KIND),
00034  HOWEVER CAUSED, AND REGARDLESS OF THE THEORY OF LIABILITY, WHETHER DERIVED
00035  FROM CONTRACT, TORT (INCLUDING, BUT NOT LIMITED TO, NEGLIGENCE), OR OTHERWISE,
00036  ARISING OUT OF OR RELATING TO THE DATA OR ITS USE OR ANY OTHER PERFORMANCE,
00037  WHETHER OR NOT AUTODESK HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH LOSS
00038  OR DAMAGE. 
00039 
00040 **************************************************************************************/
00041 #include <fbxfilesdk/fbxfilesdk_def.h>
00042 
00043 #include <fbxfilesdk/kfbxmath/kfbxvector4.h>
00044 #include <fbxfilesdk/kfbxmath/kfbxquaternion.h>
00045 
00046 #include <fbxfilesdk/fbxfilesdk_nsbegin.h>
00047 
00053 class KFBX_DLL KFbxDualQuaternion
00054     {
00055 
00056     public:
00057 
00062 
00064         KFbxDualQuaternion();
00065 
00070         KFbxDualQuaternion(const KFbxQuaternion& pV1, const KFbxQuaternion& pV2);
00071 
00075         KFbxDualQuaternion(const KFbxDualQuaternion& pV);
00076 
00081         KFbxDualQuaternion(const KFbxQuaternion& pRotation, const KFbxVector4& pTranslation);
00082 
00093         KFbxDualQuaternion(double pX1, double pY1, double pZ1, double pW1, double pX2, double pY2, double pZ2, double pW2);
00094         
00096         ~KFbxDualQuaternion();
00097 
00099 
00104 
00108         KFbxDualQuaternion& operator=(const KFbxDualQuaternion& pDualQuaternion);
00109 
00120         void Set(double pX1, double pY1, double pZ1, double pW1, double pX2, double pY2, double pZ2, double pW2);
00121 
00125         KFbxQuaternion& GetFirstQuaternion();
00126 
00130         KFbxQuaternion& GetSecondQuaternion();
00131 
00135         const KFbxQuaternion& GetFirstQuaternion() const;
00136 
00140         const KFbxQuaternion& GetSecondQuaternion() const;
00141 
00145         KFbxQuaternion GetRotation() const;
00146 
00152         KFbxVector4 GetTranslation() const;
00153         
00155 
00160         
00166         KFbxDualQuaternion operator+(double pValue) const;
00167 
00173         KFbxDualQuaternion operator-(double pValue) const;
00174 
00180         KFbxDualQuaternion operator*(double pValue) const;
00181 
00187         KFbxDualQuaternion operator/(double pValue) const;
00188 
00194         KFbxDualQuaternion& operator+=(double pValue);
00195 
00201         KFbxDualQuaternion& operator-=(double pValue);
00202 
00208         KFbxDualQuaternion& operator*=(double pValue);
00209 
00215         KFbxDualQuaternion& operator/=(double pValue);
00216         
00218 
00223 
00227         KFbxDualQuaternion operator-() const;
00228         
00234         KFbxDualQuaternion operator+(const KFbxDualQuaternion& pDualQuaternion) const;
00235 
00241         KFbxDualQuaternion operator-(const KFbxDualQuaternion& pDualQuaternion) const;
00242 
00248         KFbxDualQuaternion operator*(const KFbxDualQuaternion& pDualQuaternion) const;
00249 
00255         KFbxDualQuaternion operator/(const KFbxDualQuaternion& pDualQuaternion) const;
00256 
00262         KFbxDualQuaternion& operator+=(const KFbxDualQuaternion& pDualQuaternion);
00263 
00269         KFbxDualQuaternion& operator-=(const KFbxDualQuaternion& pDualQuaternion);
00270 
00276         KFbxDualQuaternion& operator*=(const KFbxDualQuaternion& pDualQuaternion);
00277         
00283         KFbxDualQuaternion& operator/=(const KFbxDualQuaternion& pDualQuaternion);
00284 
00290         KFbxDualQuaternion operator*(const KFbxVector4 pVector) const;
00291 
00296         KFbxDualQuaternion Product(const KFbxDualQuaternion& pDualQuaternion) const;
00297 
00300         void           Normalize();
00301 
00305         void           Inverse();
00306 
00310         KFbxVector4    Deform(KFbxVector4& pPoint);
00311 
00313 
00319 
00322         void           Conjugate();
00323 
00326         void           Dual();
00327 
00330         void           DualConjugate();
00331 
00333 
00338 
00343         bool operator==(const KFbxDualQuaternion & pV) const;
00344         
00349         bool operator!=(const KFbxDualQuaternion & pV) const;
00350         
00352 
00353 
00355     //
00356     //  WARNING!
00357     //
00358     //  Anything beyond these lines may not be documented accurately and is 
00359     //  subject to change without notice.
00360     //
00362 
00363 
00364 #ifndef DOXYGEN_SHOULD_SKIP_THIS    
00365         private:
00370 
00373             KFbxQuaternion mQ1;
00374 
00377             KFbxQuaternion mQ2;
00378 
00380 #endif //doxygen
00381 
00382     };
00383 
00384     //inline EFbxType FbxTypeOf( KFbxDualQuaternion const &pItem )  { return eDOUBLE8; }
00385 
00386 #include <fbxfilesdk/fbxfilesdk_nsend.h>
00387 
00388 #endif // FBXFILESDK_KFBXMATH_KFBXDUALQUATERNION_H
00389