TORCS  1.3.9
The Open Racing Car Simulator
susp.h
Go to the documentation of this file.
1 /***************************************************************************
2 
3  file : susp.h
4  created : Sun Mar 19 00:08:53 CET 2000
5  copyright : (C) 2000-2016 by Eric Espie, Bernhard Wymann
6  email : torcs@free.fr
7  version : $Id$
8 
9  ***************************************************************************/
10 
11 /***************************************************************************
12  * *
13  * This program is free software; you can redistribute it and/or modify *
14  * it under the terms of the GNU General Public License as published by *
15  * the Free Software Foundation; either version 2 of the License, or *
16  * (at your option) any later version. *
17  * *
18  ***************************************************************************/
19 
20 #ifndef _SUSP_H__
21 #define _SUSP_H__
22 
23 
24 typedef struct
25 {
26  tdble C1, v1; /* coefs for slow */
27  tdble C2, b2; /* coefs for fast */
28 } tDamperDef;
29 
30 typedef struct
31 {
34 } tDamper;
35 
36 typedef struct
37 {
38  tdble K; /* spring coef */
39  tdble F0; /* initial force */
40  tdble x0; /* initial suspension travel */
41  tdble xMax; /* maxi suspension travel */
42  tdble bellcrank; /* ratio of movement between wheel and suspension */
43  tdble packers; /* packer size (min susp. travel) */
44 } tSpring;
45 
46 
47 typedef struct Suspension
48 {
51 
52  tdble x; /* suspension travel */
53  tdble v; /* suspension travel speed */
54 
55  tdble force; /* generated force */
56  int state; /* indicate the state of the suspension */
57 #define SIM_SUSP_COMP 1 /* the suspension is fully compressed */
58 #define SIM_SUSP_EXT 2 /* the suspension is fully extended */
59 } tSuspension;
60 
61 
62 #endif /* _SUSP_H__ */
63 
64 
65 
tdble C2
Definition: susp.h:27
tdble K
Definition: susp.h:38
tdble xMax
Definition: susp.h:41
tdble packers
Definition: susp.h:43
tdble F0
Definition: susp.h:39
tdble force
Definition: susp.h:55
tdble x0
Definition: susp.h:40
tdble x
Definition: susp.h:52
struct Suspension tSuspension
Definition: susp.h:36
tSpring spring
Definition: susp.h:49
tdble bellcrank
Definition: susp.h:42
float tdble
Floating point type used in TORCS.
Definition: tgf.h:48
Definition: susp.h:30
tdble v1
Definition: susp.h:26
int state
Definition: susp.h:56
tdble v
Definition: susp.h:53
tDamperDef bump
Definition: susp.h:32
tDamperDef rebound
Definition: susp.h:33
tDamper damper
Definition: susp.h:50