Human/CreateVRML.h

Go to the documentation of this file.
00001 /* Copyright (C) INRIA 1999-2005
00002 ** 
00003 ** This program is free software; you can redistribute it and/or modify it
00004 ** under the terms of the GNU General Public License version 2 as published
00005 ** by the Free Software Foundation.
00006 ** 
00007 ** This program is distributed in the hope that it will be useful, but
00008 ** WITHOUT ANY WARRANTY; without even the implied warranty of
00009 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
00010 ** Public License for more details.
00011 ** 
00012 ** You should have received a copy of the GNU General Public License along
00013 ** with this program; if not, write to the Free Software Foundation, Inc.,
00014 ** 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00015 ** 
00016 */
00029 #ifndef CREATE_VRML_H
00030 #define CREATE_VRML_H
00031 
00032 #ifdef WINDOWS
00033 #define extern __declspec (dllexport)
00034 #endif
00035 
00036 // Standard includes
00037 #include <stdio.h>
00038 #include <stdlib.h>
00039 
00040 #define TRUE 1
00041 #define FALSE 0
00042 
00043 
00047 struct VRMLFeatures {
00048         int useJava;           
00051         int nbSamples;         
00052         double dt;             
00053         int nbJoints;          
00054         double *jointsRot;     
00057         double *jointsPos;     
00060         char **jointsNames;    
00061         char *geomFilename;    
00063         char *outputFilename;  
00065         int nbPhysVec;         
00067         char **physVecNames;   
00069         double *physVecRGB;    
00072         double *physVecRot;    
00075         double *physVecPos;    
00078         double *physVecScale;  
00082 };
00083 
00084 struct MatList {
00085   char name[64];
00086   struct MatList *next;
00087 
00088 };
00089         
00090 
00091 // Enum types
00092 
00093 enum InterpType {
00094   POSITION,
00095   ORIENTATION,
00096   COLOR,
00097   SCALE
00098 };
00099 
00100 void InitVRMLFeatures();
00101 
00102 void ResetVRMLFeatures();
00103 
00104 int SetUpVRMLFile(char *outputFilename, int useJava);
00105 
00106 int SetUpVRMLInterpolation( int nbS,
00107                                                                 double dt);
00108 
00109 int SetUpVRMLCharacter( char *geomFilename,
00110                                                 int nb,
00111                                                 char **names,
00112                                                 double *rot,
00113                                                 double *pos);
00114 
00115 int SetUpVRMLPhysVec(int nb,
00116                                          char **names,
00117                                          double *rot,
00118                                          double *pos,
00119                                          double *scale,
00120                                          double *RGB);
00121                                         
00122 
00130 int WriteVRMLPhysVec(FILE *f,
00131                                          int index,
00132                                          char *name,
00133                                          double *data);
00134 
00146 int WriteVRMLInterpolator(FILE *f,
00147                                           enum InterpType type,
00148                                           int index,
00149                                           char *name,
00150                                           int nbItems,
00151                                                   int nbSamples,
00152                                           double *data);
00153 
00154 
00155                                                 
00156 
00157 
00164 int CreateVRML( );
00165                                 
00173 extern void 
00174 HAnimPosition(double *Pos, double*q);
00175 
00183 extern void 
00184 HAnimOrientations(double *Or, double *q);
00185 
00196 extern void 
00197 HAnimVPos(double *VPOS, double *Lambda, double *q);
00198 
00208 extern void 
00209 HAnimVScale(double *VScale, double *Lambda, double *q);
00210 
00220 extern void 
00221 HAnimVRot(double *VRot, double *Lambda, double *q);
00222 
00223 #endif // CREATE_VRML_H

HuMAnS

humans-users@inrialpes.fr


Generated on Tue Mar 6 14:12:04 2007 for HuMAnS by doxygen 1.4.7