- Cal3D 0.11 API Reference -

physique.h

00001 //****************************************************************************//
00002 // physique.h                                                                 //
00003 // Copyright (C) 2001, 2002 Bruno 'Beosil' Heidelberger                       //
00004 //****************************************************************************//
00005 // This library is free software; you can redistribute it and/or modify it    //
00006 // under the terms of the GNU Lesser General Public License as published by   //
00007 // the Free Software Foundation; either version 2.1 of the License, or (at    //
00008 // your option) any later version.                                            //
00009 //****************************************************************************//
00010 
00011 #ifndef CAL_PHYSIQUE_H
00012 #define CAL_PHYSIQUE_H
00013 
00014 #include "cal3d/global.h"
00015 
00016 
00017 class CalModel;
00018 class CalSubmesh;
00019 class CalVector;
00020 
00021 
00022 class CAL3D_API CalPhysique
00023 {
00024 public:
00025   CalPhysique(CalModel* pModel);
00026   ~CalPhysique() { }
00027 
00028   int calculateTangentSpaces(CalSubmesh *pSubmesh, int mapId, float *pTangentSpaceBuffer, int stride=0);
00029   int calculateNormals(CalSubmesh *pSubmesh, float *pNormalBuffer, int stride=0);
00030   int calculateVertices(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0);
00031   CalVector calculateVertex(CalSubmesh *pSubmesh, int vertexId);
00032   int calculateVerticesAndNormals(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0);
00033   int calculateVerticesNormalsAndTexCoords(CalSubmesh *pSubmesh, float *pVertexBuffer,int NumTexCoords=1);  
00034   void update();
00035   void setNormalization(bool normalize);
00036   void setAxisFactorX(float factor);
00037   void setAxisFactorY(float factor);
00038   void setAxisFactorZ(float factor);
00039 
00040 private:
00041   CalModel *m_pModel;
00042   bool m_Normalize;
00043   float m_axisFactorX;
00044   float m_axisFactorY;
00045   float m_axisFactorZ;
00046 };
00047 
00048 #endif
00049 
00050 //****************************************************************************//

Generated at Thu Jun 29 19:03:59 2006 by The Cal3D Team with Doxygen 1.4.6