C++ SDK Reference  12.5
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
diguyVehicleController.h
Go to the documentation of this file.
1 
2 /*
3  * Copyright (C) 1992-2013 Boston Dynamics
4  * ALL RIGHTS RESERVED.
5  *
6  * These coded instructions, statements, and computer programs
7  * contain unpublished proprietary information of Boston Dynamics
8  * and are protected by Copyright Laws of the United States.
9  * They may not be used, duplicated, or disclosed in any form, in
10  * whole or in part, without the prior written consent from Boston
11  * Dynamics.
12  *
13  * RESTRICTED RIGHTS LEGEND
14  * Use, duplication, or disclosure by the government is subject
15  * to restrictions as set forth in FAR 52.227.19(c)(2) or
16  * subparagraph (c)(1)(ii) of the Rights in Technical Data and
17  * Computer Software clause at DFARS 252.227-7013 and/or in
18  * similar or successor clauses in the FAR, or the DOD or NASA
19  * FAR Supplement, or to subparagraphs (c)(1) and (c)(2) of the
20  * Commercial Computer Software--Restricted Rights at 48 CFR
21  * 52.227-19, as applicable. Unpublished-rights reserved under
22  * the Copyright Laws of the United States.
23  * Contractor/Manufacturer is:
24  * Boston Dynamics/78 Fourth Avenue/Waltham MA 02451.
25  */
26 
27 /*********************************************************************
28  **
29  *t diguyVehicleController
30  **
31  */
32 
33 #ifndef __diguyVehicleController_H
34 #define __diguyVehicleController_H
35 
36 #ifdef SWIG
38 #else
39 #define CPLUSPLUS_ONLY
40 #endif
41 
42 #ifdef CPLUSPLUS_ONLY
43 
44 #include <declspec_diguy.h>
45 #include <diguy_constants.h>
46 
47 class diguyCharacter;
48 class bdiScenarioVehicleController;
49 
50 #endif
51 
52 
53 /****************************************************************************/
54 class BDI_DECLSPEC_diguy diguyVehicleController
55 {
56 
57 public:
58 
59 /*****************************************************************************
60  **
61  *2 Character Functions
62  **
63  */
64  diguyCharacter* get_vehicle_character();
65 
66 
67 /*****************************************************************************
68  **
69  *2 Speed Functions
70  **
71  ** These functions should only be used in free action mode.
72  **
73  */
74 
75  /*l
76  *b Description:
77  **
78  ** This function sets the vehicle's speed. The speed becomes
79  ** effective immediately; no acceleration or deceleration is applied.
80  **
81  *b Arguments:
82  **
83  *a speed - new speed of vehicle
84  *a units - units of speed
85  **
86  *b Callable From:
87  **
88  *- - C++
89  *- - Script
90  */
91  void set_speed(float speed,
93 
94  /*
95  * Documentation Pending
96  */
98 
99  /*
100  * Documentation Pending
101  */
102  void set_desired_speed_with_acceleration(float desired_speed,
103  float acceleration,
105 
106  /*
107  * Documentation Pending
108  *
109  * Reach desired speed over the acceleration_time. Actual
110  * acceleration is derived from change in speeds and the alloted
111  * time.
112  */
113  void set_desired_speed_with_acceleration_time(float desired_speed,
114  float acceleration_time, // seconds
116 
117  /*
118  * Documentation Pending
119  */
120  float get_desired_speed(diguySpeedUnits units = DIGUY_SPEED_UNITS_METERS_PER_SECOND);
121 
122  /*
123  * Documentation Pending
124  */
125  void set_default_acceleration(float acceleration,
127  float get_default_acceleration(diguySpeedUnits units = DIGUY_SPEED_UNITS_METERS_PER_SECOND);
128 
129  void set_default_deceleration(float deceleration,
131  float get_default_deceleration(diguySpeedUnits units = DIGUY_SPEED_UNITS_METERS_PER_SECOND);
132 
133 
134 /*****************************************************************************
135  **
136  *2 Steering Functions
137  **
138  ** These functions should only be used in free action mode.
139  **
140  */
141 
142  /*
143  * Documentation Pending
144  */
145  void set_vehicle_simulation_mode(diguyVehicleSimulationMode vsim_mode);
146 
147  /*
148  * Documentation Pending
149  */
150  diguyVehicleSimulationMode get_vehicle_simulation_mode();
151 
152  /*
153  * Documentation Pending
154  */
155  void set_front_wheels_steer_angle(float angle);
156 
157  /*
158  * Documentation Pending
159  */
160  float get_front_wheels_steer_angle();
161 
162  /*
163  * Documentation Pending
164  */
165  void set_desired_front_wheels_steer_angle(float desired_angle,
166  float angle_change_rate = DIGUY_DEFAULT_FLOAT);
167 
168  /*
169  * Documentation Pending
170  */
171  float get_desired_front_wheels_steer_angle();
172 
173 
178 #ifdef CPLUSPLUS_ONLY
179 
180  bdiScenarioVehicleController* get_scripted_object() {return m_scripted_object;}
181 
182 private:
183 
184  /*l
185  ** A private constructor.
186  */
187  diguyVehicleController(bdiScenarioVehicleController* vehicle_controller);
188 
189  /*l
190  ** A pointer to internal data.
191  */
192  bdiScenarioVehicleController* m_scripted_object;
193 
194  friend class bdiScenarioVehicleController;
195 
196 #endif
197 
198 };
200 #endif /* __diguyVehicleController_H */
202