- Cal3D 0.11 API Reference -

physique.h
1//****************************************************************************//
2// physique.h //
3// Copyright (C) 2001, 2002 Bruno 'Beosil' Heidelberger //
4//****************************************************************************//
5// This library is free software; you can redistribute it and/or modify it //
6// under the terms of the GNU Lesser General Public License as published by //
7// the Free Software Foundation; either version 2.1 of the License, or (at //
8// your option) any later version. //
9//****************************************************************************//
10
11#ifndef CAL_PHYSIQUE_H
12#define CAL_PHYSIQUE_H
13
14#include "cal3d/global.h"
15
16
17 class CalModel;
18 class CalSubmesh;
19 class CalVector;
20
21
22 class CAL3D_API CalPhysique
23{
24 public:
25 CalPhysique(CalModel* pModel);
26 ~CalPhysique() { }
27
28 int calculateTangentSpaces(CalSubmesh *pSubmesh, int mapId, float *pTangentSpaceBuffer, int stride=0);
29 int calculateNormals(CalSubmesh *pSubmesh, float *pNormalBuffer, int stride=0);
30 int calculateVertices(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0);
31 CalVector calculateVertex(CalSubmesh *pSubmesh, int vertexId);
32 int calculateVerticesAndNormals(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0);
33 int calculateVerticesNormalsAndTexCoords(CalSubmesh *pSubmesh, float *pVertexBuffer,int NumTexCoords=1);
34 void update();
35 void setNormalization(bool normalize);
36 void setAxisFactorX(float factor);
37 void setAxisFactorY(float factor);
38 void setAxisFactorZ(float factor);
39
40 private:
41 CalModel *m_pModel;
42 bool m_Normalize;
43 float m_axisFactorX;
44 float m_axisFactorY;
45 float m_axisFactorZ;
46};
47
48#endif
49
50//****************************************************************************//
CalModel
Definition model.h:31
CalPhysique::calculateNormals
int calculateNormals(CalSubmesh *pSubmesh, float *pNormalBuffer, int stride=0)
Calculates the transformed normal data.
Definition physique.cpp:428
CalPhysique::update
void update()
Updates all the internally handled attached meshes.
Definition physique.cpp:965
CalPhysique::calculateVertex
CalVector calculateVertex(CalSubmesh *pSubmesh, int vertexId)
Calculates one transformed vertex.
Definition physique.cpp:200
CalPhysique::setNormalization
void setNormalization(bool normalize)
Sets the normalization flag to true or false.
Definition physique.cpp:1015
CalPhysique::CalPhysique
CalPhysique(CalModel *pModel)
Constructs the physique instance.
Definition physique.cpp:36
CalPhysique::calculateVertices
int calculateVertices(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0)
Calculates the transformed vertex data.
Definition physique.cpp:61
CalPhysique::calculateTangentSpaces
int calculateTangentSpaces(CalSubmesh *pSubmesh, int mapId, float *pTangentSpaceBuffer, int stride=0)
Calculates the transformed tangent space data.
Definition physique.cpp:326
CalPhysique::calculateVerticesAndNormals
int calculateVerticesAndNormals(CalSubmesh *pSubmesh, float *pVertexBuffer, int stride=0)
Calculates the transformed vertex data.
Definition physique.cpp:565
CalPhysique::calculateVerticesNormalsAndTexCoords
int calculateVerticesNormalsAndTexCoords(CalSubmesh *pSubmesh, float *pVertexBuffer, int NumTexCoords=1)
Calculates the transformed vertex data.
Definition physique.cpp:759
CalSubmesh
Definition submesh.h:23
CalVector
The vector class.
Definition vector.h:37

Generated by The Cal3D Team with Doxygen 1.15.0