C++ SDK Reference  12.5
 All Classes Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
diguyInteractionMachine.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 #ifndef __diguyInteractionMachine_H
29 #define __diguyInteractionMachine_H
30 
31 
32 #ifdef SWIG
34 #else
35 #define CPLUSPLUS_ONLY
36 #endif
37 
38 #ifdef CPLUSPLUS_ONLY
39 class bdiScenarioInteractionMachine;
40 class diguyCharacter;
41 #endif
42 
43 
44 #include <declspec_diguy.h>
45 
46 /*********************************************************************/
105 class BDI_DECLSPEC_diguy diguyInteractionMachine
106 {
107 
108 public:
109 
110 /*****************************************************************************
111  **
112  *2 General Functions
113  **
114  */
115 
116  /*l
117  *b Description:
118  **
119  ** Returns the name of the object. This pointer will
120  ** never be NULL.
121  **
122  *b Returns:
123  **
124  ** name of the object
125  **
126  *b Callable From:
127  **
128  *- - C++
129  *- - Script
130  */
131  const char* get_name();
132 
133  /*l
134  *b Description:
135  **
136  ** This function begins the interaction.
137  **
138  ** The interaction UI will appear in DI-Guy Scenario.
139  **
140  ** The interaction can be ended by calling end_interaction(), or by
141  ** the current state being changed to "end" through an input
142  ** selection or a call to set_current_state().
143  **
144  *b Arguments:
145  **
146  *a initial_state - initial state that interaction will
147  *a be in
148  *a initial_input - initial input that will be returned
149  *a by get_last_selected_input() in the
150  *a first state
151  **
152  ** By default, initial state will be "begin".
153  ** By default, initial input will be "begin".
154  **
155  *b Returns:
156  **
157  ** 0 on success, -1 on failure
158  **
159  *b Callable From:
160  **
161  *- - C++
162  *- - Script
163  */
164  int begin_interaction(const char* initial_state = NULL,
165  const char* initial_input = NULL);
166 
167  /*l
168  *b Description:
169  **
170  ** This function ends the interaction.
171  **
172  ** The interaction UI will be hidden in DI-Guy Scenario.
173  **
174  ** Note that this call does not run the entry script of the "end"
175  ** state. Call set_current_state("end") to end the interaction
176  ** and run the entry script of the "end" state when doing so.
177  **
178  *b Returns:
179  **
180  ** 0 on success, -1 on failure
181  **
182  *b Callable From:
183  **
184  *- - C++
185  *- - Script
186  */
187  int end_interaction();
188 
189  /*l
190  *b Returns:
191  **
192  ** 1 if interaction is active and visible, 0 if not
193  **
194  *b Callable From:
195  **
196  *- - C++
197  *- - Script
198  */
199  int get_interaction_is_active();
200 
201  /*l
202  *b Description:
203  **
204  ** This function sets whether the scenario is paused while the
205  ** interaction is active.
206  **
207  ** If the scenario is to be paused, the current playback mode
208  ** will be saved when the interaction begins, the playback
209  ** mode will be changed to DIGUY_SCENARIO_PLAYBACK_MODE_STOP,
210  ** and the original playback mode will be restored when the
211  ** interaction ends.
212  **
213  ** If the scenario is not to be paused, beginning and ending
214  ** the interaction will have no effect on the playback mode.
215  **
216  ** The default is to not pause the scenario.
217  **
218  *b Arguments:
219  **
220  *a pause_while_active - pass 1 to pause scenario when interaction
221  *a is active, 0 to not change playback mode
222  **
223  *b Callable From:
224  **
225  *- - C++
226  *- - Script
227  */
228  void set_pause_scenario_while_active(int pause_while_active);
229 
230  /*l
231  *b Returns:
232  **
233  ** 1 if playback mode will be paused, 0 if not
234  **
235  *b Callable From:
236  **
237  *- - C++
238  *- - Script
239  */
240  int get_pause_scenario_while_active();
241 
242  /*l
243  *b Description:
244  **
245  ** This function resets the interaction to a clean state.
246  ** It will:
247  **
248  *- - set the initial heading to ""
249  *- - set the initial info text to ""
250  *- - remove all inputs
251  *- - reset ui appearances
252  *- - set all other parameters to default values
253  *-
254  *- It will also do an implicit reset() call.
255  **
256  *b Callable From:
257  **
258  *- - C++
259  *- - Script
260  */
261  void reinitialize();
262 
263  /*l
264  *b Description:
265  **
266  ** This function resets the interaction to a reset state.
267  ** It will:
268  **
269  *- - set the UI appearance text to initial_ui_appearance
270  *- - set the heading to be initial_heading
271  *- - set the info text to initial_info
272  *- - set the current state to "begin"
273  **
274  *b Callable From:
275  **
276  *- - C++
277  *- - Script
278  */
279  void reset();
280 
281  /*l
282  *b Description:
283  **
284  ** This function stores a pointer to the passed character
285  ** in the interaction machine. Access to the character is
286  ** then possible in state scripts by calling
287  ** get_interaction_subject().
288  **
289  *b Arguments:
290  **
291  *a interaction_subject - pointer to character that is to
292  *a by the interaction's primary subject
293  **
294  *b Callable From:
295  **
296  *- - C++
297  *- - Script
298  */
299  void set_interaction_subject(diguyCharacter* interaction_subject);
300 
301  /*l
302  *b Returns:
303  **
304  ** value set by set_interaction_subject()
305  **
306  *b Callable From:
307  **
308  *- - C++
309  *- - Script
310  */
311  diguyCharacter* get_interaction_subject();
312 
313 
314 /*****************************************************************************
315  **
316  *2 UI Functions
317  **
318  */
319 
320  /*l
321  *b Description:
322  **
323  ** This function updates the visible interaction UI in
324  ** DI-Guy Scenario. May calls that change visible settings of
325  ** the UI will not take effect until this function is called.
326  **
327  *b Callable From:
328  **
329  *- - C++
330  *- - Script
331  */
332  int update_ui();
333 
334  /*l
335  *b Description:
336  **
337  ** This enumeration lists the indices used for
338  ** various UI appearance calls. These indices should
339  ** be used when calling:
340  **
341  *- - set_initial_ui_appearance()
342  *- - set_ui_appearance()
343  *- - set_heading_color_bg()
344  *- - set_heading_color_fg()
345  *- - set_heading_font()
346  **
347  ** and equivalent functions for info and inputs.
348  **
349  ** Each UI appearance can have different colors and font
350  ** settings, potentially giving the scenario user a
351  ** visual cue that the interaction is showing a conversation,
352  ** showing generation information, or providing an important
353  ** notification,
354  **
355  *b Callable From:
356  **
357  *- - C++
358  *- - Script
359  */
360  enum {
361  UI_APPEARANCE_CONVERSATION = 0,
362  UI_APPEARANCE_INFO,
363  UI_APPEARANCE_NOTIFICATION,
364  UI_APPEARANCE_3,
365  UI_APPEARANCE_4,
366 
367  UI_APPEARANCE_COUNT
368  };
369 
370  /*l
371  *b Description:
372  **
373  ** This function sets the UI appearance that will be used
374  ** after a begin_interaction() or reset() call.
375  **
376  ** The default is UI_APPEARANCE_CONVERSATION.
377  **
378  *b Arguments:
379  **
380  *a initial_ui_appearance - initial UI appearance
381  **
382  *b Callable From:
383  **
384  *- - C++
385  *- - Script
386  */
387  int set_initial_ui_appearance(int initial_ui_appearance);
388 
389  /*l
390  *b Returns:
391  **
392  ** initial UI appearance as set by set_initial_ui_appearance()
393  **
394  *b Callable From:
395  **
396  *- - C++
397  *- - Script
398  */
399  int get_initial_ui_appearance();
400 
401  /*l
402  *b Description:
403  **
404  ** This function sets the current UI appearance that should be
405  ** used for the interaction.
406  **
407  ** The new setting will not take effect until the next call
408  ** to update_ui().
409  **
410  ** Call update_ui() for new setting to take effect.
411  **
412  *b Arguments:
413  **
414  *a ui_appearance - new current UI appearance
415  **
416  *b Callable From:
417  **
418  *- - C++
419  *- - Script
420  */
421  int set_ui_appearance(int ui_appearance);
422 
423  /*l
424  *b Returns:
425  **
426  ** current UI appearance; default is value returned by
427  ** get_initial_ui_appearance()
428  **
429  *b Callable From:
430  **
431  *- - C++
432  *- - Script
433  */
434  int get_ui_appearance();
435 
436 
437 /*****************************************************************************/
443  /*l
444  *b Description:
445  **
446  ** This function sets the heading text that will be shown after
447  ** after a begin_interaction() or reset() call.
448  **
449  ** The default is "", or show nothing.
450  **
451  *b Arguments:
452  **
453  *a initial_heading - initial heading text
454  **
455  *b Callable From:
456  **
457  *- - C++
458  *- - Script
459  */
460  void set_initial_heading(const char* initial_heading);
461 
462  /*l
463  *b Returns:
464  **
465  ** initial heading text as set by set_initial_heading()
466  **
467  *b Callable From:
468  **
469  *- - C++
470  *- - Script
471  */
472  const char* get_initial_heading();
473 
474  /*l
475  *b Description:
476  **
477  ** This function sets the current heading text that will be
478  ** shown.
479  **
480  ** Call update_ui() for new setting to take effect.
481  **
482  *b Arguments:
483  **
484  *a heading - heading text to be shown
485  **
486  *b Callable From:
487  **
488  *- - C++
489  *- - Script
490  */
491  void set_heading(const char* heading);
492 
493  /*l
494  *b Returns:
495  **
496  ** current heading text as set by set_heading()
497  **
498  *b Callable From:
499  **
500  *- - C++
501  *- - Script
502  */
503  const char* get_heading();
504 
505  /*l
506  *b Description:
507  **
508  ** This function sets whether the heading will be visible.
509  **
510  ** Call update_ui() for new setting to take effect.
511  **
512  *b Arguments:
513  **
514  *a heading_visible - 1 for visible, 0 for invisible
515  **
516  *b Callable From:
517  **
518  *- - C++
519  *- - Script
520  */
521  void set_heading_visible(int heading_visible);
522 
523  /*l
524  *b Returns:
525  **
526  ** whether heading is visible
527  **
528  *b Callable From:
529  **
530  *- - C++
531  *- - Script
532  */
533  int get_heading_visible();
534 
535  /*l
536  *b Description:
537  **
538  ** This function sets the background color of the heading.
539  **
540  ** Call update_ui() for new setting to take effect.
541  **
542  *b Arguments:
543  **
544  *a ui_appearance - which UI appearance this changes
545  *a r, g, b, a - RGBA colors, from 0.0 to 1.0
546  **
547  *b Callable From:
548  **
549  *- - C++
550  *- - Script
551  */
552  void set_heading_color_bg(int ui_appearance,
553  float r,
554  float g,
555  float b,
556  float a = 1.0f);
557 
558  /*l
559  *b Description:
560  **
561  ** This function sets the foreground/font color of the heading.
562  **
563  ** Call update_ui() for new setting to take effect.
564  **
565  *b Arguments:
566  **
567  *a ui_appearance - which UI appearance this changes
568  *a r, g, b, a - RGBA colors, from 0.0 to 1.0
569  **
570  *b Callable From:
571  **
572  *- - C++
573  *- - Script
574  */
575  void set_heading_color_fg(int ui_appearance,
576  float r,
577  float g,
578  float b,
579  float a = 1.0f);
580 
581  /*l
582  *b Description:
583  **
584  ** This function sets the font characteristics of the heading.
585  **
586  ** Call update_ui() for new setting to take effect.
587  **
588  *b Arguments:
589  **
590  *a ui_appearance - which UI appearance this changes
591  *a font_family - font family
592  *a font_point_size - point size of font
593  *a font_is_bold - pass 1 for bold, 0 for normal
594  *a font_is_italic - pass 1 for italic, 0 for normal
595  **
596  ** On Windows, the default font family is ""MS Shell Dlg",
597  ** and the default point size is 10.
598  **
599  *b Callable From:
600  **
601  *- - C++
602  *- - Script
603  */
604  void set_heading_font(int ui_appearance,
605  const char* font_family,
606  int font_point_size,
607  int font_is_bold = 0,
608  int font_is_italic = 0);
609 
610 
611 /*****************************************************************************/
617  /*l
618  *b Description:
619  **
620  ** Similar to set_initial_heading(), but for info instead.
621  **
622  ** Note that the info text can use simple HTML-style tags. For
623  ** example:
624  *>
625  *- - for a paragraph break: <p>
626  *- - for bold text: <b>bold</b>
627  *- - for underlined text: <u>bold</u>
628  *- - for italicized text: <i>bold</i>
629  *<
630  **
631  ** The default is "", or show nothing.
632  */
633  void set_initial_info(const char* initial_info);
634 
635  /*l
636  *b Description:
637  **
638  ** Similar to get_initial_heading(), but for info instead.
639  */
640  const char* get_initial_info();
641 
642  /*l
643  *b Description:
644  **
645  ** Similar to set_heading(), but for info instead.
646  */
647  void set_info(const char* info);
648 
649  /*l
650  *b Description:
651  **
652  ** Similar to get_heading(), but for info instead.
653  */
654  const char* get_info();
655 
656  /*l
657  *b Description:
658  **
659  ** Similar to set_heading_visible(), but for info instead.
660  */
661  void set_info_visible(int info_visible);
662 
663  /*l
664  *b Description:
665  **
666  ** Similar to get_heading_visible(), but for info instead.
667  */
668  int get_info_visible();
669 
670  /*l
671  *b Description:
672  **
673  ** Similar to get_heading_visible(), but for info instead.
674  */
675  void set_info_color_bg(int ui_appearance,
676  float r,
677  float g,
678  float b,
679  float a = 1.0f);
680 
681  /*l
682  *b Description:
683  **
684  ** Similar to set_heading_color_fg(), but for info instead.
685  */
686  void set_info_color_fg(int ui_appearance,
687  float r,
688  float g,
689  float b,
690  float a = 1.0f);
691 
692  /*l
693  *b Description:
694  **
695  ** Similar to set_heading_font(), but for info instead.
696  */
697  void set_info_font(int ui_appearance,
698  const char* font_family,
699  int font_point_size,
700  int font_is_bold = 0,
701  int font_is_italic = 0);
702 
703 
704 /*****************************************************************************/
718  /*l
719  *b Returns:
720  **
721  ** number of states in the interaction machine
722  **
723  *b Callable From:
724  **
725  *- - C++
726  *- - Script
727  */
728  int get_num_states();
729 
730  /*l
731  *b Returns:
732  **
733  ** string id of state with given index; the returned pointer will
734  ** never be NULL
735  **
736  *b Callable From:
737  **
738  *- - C++
739  *- - Script
740  */
741  const char* get_state_id_at_index(int index);
742 
743  /*l
744  *b Description:
745  **
746  ** This function removes all existing states from the interaction
747  ** machine.
748  **
749  ** Default new states named "begin" and "end" are then automatically
750  ** added. These default states do not have an entry script, but one
751  ** can be added later with the set_state_entry_script() or
752  ** set_begin_state_entry_script() functions.
753  **
754  ** More new states can be added using the add_state() function.
755  **
756  *b Callable From:
757  **
758  *- - C++
759  *- - Script
760  */
761  void clear_states();
762 
763  /*l
764  *b Description:
765  **
766  ** This function adds a new state to the interaction machine. Each
767  ** state must have a unique state_id (name of the state).
768  **
769  *b Arguments:
770  **
771  *a state_id - name of the new state
772  *a entry_script - script text that will be run every time this
773  *a new state is entered
774  **
775  *b Returns:
776  **
777  ** 0 on success, -1 on failure
778  **
779  *b Callable From:
780  **
781  *- - C++
782  *- - Script
783  */
784  int add_state(const char* state_id,
785  const char* entry_script);
786 
787  /*l
788  *b Description:
789  **
790  ** This function removes the specified state from the interaction
791  ** machine.
792  **
793  ** The required "begin" and "end" states cannot be removed.
794  **
795  *b Arguments:
796  **
797  *a state_id - name of state to remove
798  **
799  *b Returns:
800  **
801  ** 0 on success, -1 on failure
802  **
803  *b Callable From:
804  **
805  *- - C++
806  *- - Script
807  */
808  int remove_state(const char* state_id);
809 
810  /*l
811  *b Description:
812  **
813  ** This function renames the specified state. Each state must
814  ** have a unique state_id (name of the state).
815  **
816  ** The required "begin" and "end" states cannot be renamed.
817  **
818  *b Arguments:
819  **
820  *a old_state_id - name of state to rename
821  *a new_state_id - new name of state
822  **
823  *b Returns:
824  **
825  ** 0 on success, -1 on failure
826  **
827  *b Callable From:
828  **
829  *- - C++
830  *- - Script
831  */
832  int rename_state(const char* old_state_id, const char* new_state_id);
833 
834  /*l
835  *b Description:
836  **
837  ** This function sets the entry script of this state. Each time
838  ** the specified state is entered, the entry script will be run.
839  **
840  *b Arguments:
841  **
842  *a state_id - name of state to modify
843  *a entry_script - new entry script
844  **
845  *b Returns:
846  **
847  ** 0 on success, -1 on failure
848  **
849  *b Callable From:
850  **
851  *- - C++
852  *- - Script
853  */
854  int set_state_entry_script(const char* state_id,
855  const char* entry_script);
856 
857  /*l
858  *b Description:
859  **
860  ** This function sets the entry script of the required "begin"
861  ** state.
862  **
863  *b Arguments:
864  **
865  *a entry_script - new entry script
866  **
867  *b Returns:
868  **
869  ** 0 on success, -1 on failure
870  **
871  *b Callable From:
872  **
873  *- - C++
874  *- - Script
875  */
876  int set_begin_state_entry_script(const char* entry_script);
877 
878  /*l
879  *b Description:
880  **
881  ** This function returns the current state the interaction machine
882  ** is in.
883  **
884  *b Returns:
885  **
886  ** name of current state; the returned should never be NULL
887  **
888  *b Callable From:
889  **
890  *- - C++
891  *- - Script
892  */
893  const char* get_current_state();
894 
895  /*l
896  *b Description:
897  **
898  ** This function sets the current state of the interaction machine.
899  ** The entry script of the new state will be run by default, but
900  ** can optionally be skipped.
901  **
902  ** If the new state is "end", the interaction will end, as
903  ** if the end_interaction() call is made, once the entry script of
904  ** the "end" state entry script is run.
905  **
906  *b Arguments:
907  **
908  *a new_current_state - new current state
909  *a run_entry_script - pass 1 to run the new state's entry script,
910  *a 0 to not
911  **
912  *b Returns:
913  **
914  ** 0 on success, -1 on failure
915  **
916  *b Callable From:
917  **
918  *- - C++
919  *- - Script
920  */
921  void set_current_state(const char* new_current_state,
922  int run_entry_script = 1);
923 
924 
925 /*****************************************************************************/
931  /*l
932  *b Description:
933  **
934  ** This function removes all inputs from the interaction machine.
935  ** New inputs can be added by calling add_input().
936  **
937  *b Callable From:
938  **
939  *- - C++
940  *- - Script
941  */
942  void clear_inputs();
943 
944  /*l
945  *b Description:
946  **
947  ** This function adds a new input to the interaction machine. Each
948  ** input must have a unique input_id (name of the input).
949  **
950  ** If the resulting state is "end", the interaction will end, as
951  ** if the end_interaction() call is made, once the entry script of
952  ** the "end" state entry script is run.
953  **
954  *b Arguments:
955  **
956  *a input_id - name of the new input
957  *a input_string - text that will be shown in the UI
958  *a resulting_state - state id of the state the interaction machine
959  *a will change to if this new input is selected
960  *a int_param_0 - an optional integer parameter that can be
961  *a interpreted in the new state's entry script
962  **
963  *b Returns:
964  **
965  ** 0 on success, -1 on failure
966  **
967  *b Callable From:
968  **
969  *- - C++
970  *- - Script
971  */
972  int add_input(const char* input_id,
973  const char* input_string,
974  const char* resulting_state = "",
975  int int_param_0 = 0);
976 
977  /*l
978  *b Description:
979  **
980  ** This function removes the specified input.
981  **
982  *b Arguments:
983  **
984  *a input_id - name of input to rename
985  **
986  *b Returns:
987  **
988  ** 0 on success, -1 on failure
989  **
990  *b Callable From:
991  **
992  *- - C++
993  *- - Script
994  */
995  int remove_input(const char* input_id);
996 
997  /*l
998  *b Returns:
999  **
1000  ** how many inputs there are
1001  **
1002  *b Callable From:
1003  **
1004  *- - C++
1005  *- - Script
1006  */
1007  int get_num_inputs();
1008 
1009  /*l
1010  *b Returns:
1011  **
1012  ** input id of the input at the specified index; see
1013  ** add_input()
1014  **
1015  *b Callable From:
1016  **
1017  *- - C++
1018  *- - Script
1019  */
1020  const char* get_input_id(int index);
1021 
1022  /*l
1023  *b Returns:
1024  **
1025  ** input string of the specified input; see add_input()
1026  **
1027  *b Callable From:
1028  **
1029  *- - C++
1030  *- - Script
1031  */
1032  const char* get_input_string(const char* input_id);
1033 
1034  /*l
1035  *b Returns:
1036  **
1037  ** resulting state of the specified input; see add_input()
1038  **
1039  *b Callable From:
1040  **
1041  *- - C++
1042  *- - Script
1043  */
1044  const char* get_input_resulting_state(const char* input_id);
1045 
1046  /*l
1047  *b Returns:
1048  **
1049  ** integer parameter 0 of the specified input; see add_input()
1050  **
1051  *b Callable From:
1052  **
1053  *- - C++
1054  *- - Script
1055  */
1056  int get_input_int_param_0(const char* input_id);
1057 
1058  /*l
1059  *b Description:
1060  **
1061  ** This function "manually" selects the specified input. Most of
1062  ** the time inputs are selected via the UI.
1063  **
1064  ** A side effect of selecting an input is almost always that the
1065  ** interaction machine will be put into a new state.
1066  **
1067  *b Arguments:
1068  **
1069  *a input_id - input id of input that should be selected
1070  **
1071  ** The passed input id must be a current available input of the
1072  ** interaction machine.
1073  **
1074  *b Returns:
1075  **
1076  ** 0 on success, -1 on failure
1077  **
1078  *b Callable From:
1079  **
1080  *- - C++
1081  *- - Script
1082  */
1083  int select_input(const char* input_id);
1084 
1085  /*l
1086  *b Returns:
1087  **
1088  ** input id of the last selected input; state entry scripts can
1089  ** use this information to make decisions based on how the state
1090  ** was entered
1091  **
1092  *b Callable From:
1093  **
1094  *- - C++
1095  *- - Script
1096  */
1097  const char* get_last_selected_input();
1098 
1099  /*l
1100  *b Description:
1101  **
1102  ** This function sets the name of the scenario-level variable in
1103  ** which the name of the last selected input will be recorded.
1104  ** State entry scripts can then read determine which input
1105  ** caused the interaction machine to entry the state.
1106  **
1107  *b Arguments:
1108  **
1109  *a last_input_variable - name of scenario-level variable
1110  **
1111  *b Returns:
1112  **
1113  ** 0 on success, -1 on failure
1114  **
1115  *b Callable From:
1116  **
1117  *- - C++
1118  *- - Script
1119  */
1120  void set_last_input_variable(const char* last_input_variable);
1121 
1122  /*l
1123  *b Returns:
1124  **
1125  ** name of last input variable; empty string ("") if there is
1126  ** none
1127  **
1128  *b Callable From:
1129  **
1130  *- - C++
1131  *- - Script
1132  */
1133  const char* get_last_input_variable();
1134 
1135  /*l
1136  *b Description:
1137  **
1138  ** This function sets whether the inputs section of the UI will
1139  ** be visible. The inputs will be visible by default.
1140  **
1141  *b Arguments:
1142  **
1143  *a visible - pass 1 to make inputs visible; 0 to not
1144  **
1145  *b Callable From:
1146  **
1147  *- - C++
1148  *- - Script
1149  */
1150  void set_inputs_visible(int visible);
1151 
1152  /*l
1153  *b Returns:
1154  **
1155  ** whether the inputs section of the UI will be visible
1156  **
1157  *b Callable From:
1158  **
1159  *- - C++
1160  *- - Script
1161  */
1162  int get_inputs_visible();
1163 
1164  /*l
1165  *b Description:
1166  **
1167  ** This function sets whether a "shortcut" for each input will be
1168  ** visible in the UI, before the input text.
1169  **
1170  ** Currently the shortcuts are limited to numbers; the first input
1171  ** will be prefixed by "1.", the second by "2.", etc.
1172  **
1173  ** Input shortcuts are visible by default.
1174  **
1175  *b Arguments:
1176  **
1177  *a visible - pass 1 to make shortcuts visible; 0 to not
1178  **
1179  *b Callable From:
1180  **
1181  *- - C++
1182  *- - Script
1183  */
1184  void set_input_shortcuts_visible(int visible);
1185 
1186  /*l
1187  *b Returns:
1188  **
1189  ** whether the input shortcuts will be visible in the UI
1190  **
1191  *b Callable From:
1192  **
1193  *- - C++
1194  *- - Script
1195  */
1196  int get_input_shortcuts_visible();
1197 
1198  /*l
1199  *b Description:
1200  **
1201  ** Similar to set_heading_font(), but for inputs instead.
1202  */
1203  void set_inputs_font(int ui_appearance,
1204  const char* font_family,
1205  int font_point_size,
1206  int font_is_bold = 0,
1207  int font_is_italic = 0);
1208 
1209  /*l
1210  *b Description:
1211  **
1212  ** Similar to set_heading_color_bg(), but for inputs instead.
1213  */
1214  void set_inputs_color_bg(int ui_appearance,
1215  float r,
1216  float g,
1217  float b,
1218  float a = 1.0f);
1219 
1220  /*l
1221  *b Description:
1222  **
1223  ** Similar to set_heading_color_fg(), but for inputs instead.
1224  */
1225  void set_inputs_color_fg(int ui_appearance,
1226  float r,
1227  float g,
1228  float b,
1229  float a = 1.0f);
1230 
1231 
1232 /****************************************************************************/
1233 /****************************************************************************/
1234 /****************************************************************************/
1243 /****************************************************************************/
1244 /****************************************************************************/
1245 /****************************************************************************/
1246 
1247  // use set_ui_appearance() instead
1248  int set_current_settings_index(int current_settings_index);
1249 
1250  // set set_begin_state_entry_script() instead
1251  void set_input_response_script(const char* script);
1252 
1257 #ifdef CPLUSPLUS_ONLY
1258 
1259  bdiScenarioInteractionMachine* get_scripted_object() {return m_scripted_object;}
1260 
1261 private:
1262 
1263  /*l
1264  ** A private constructor.
1265  */
1266  diguyInteractionMachine(bdiScenarioInteractionMachine* scripted_object);
1267 
1268  /*l
1269  ** A private destructor.
1270  */
1271  virtual ~diguyInteractionMachine();
1272 
1273  /*l
1274  ** A pointer to internal data.
1275  */
1276  bdiScenarioInteractionMachine* m_scripted_object;
1277 
1278  friend class bdiScenarioInteractionMachine;
1279 
1280 #endif
1281 
1282 };
1283 
1284 
1285 #endif /* __diguyInteractionMachine_H */
1286 
1287 
1288 /*
1289  * Copyright (C) 1992-2013 Boston Dynamics
1290  * ALL RIGHTS RESERVED.
1291  *
1292  * These coded instructions, statements, and computer programs
1293  * contain unpublished proprietary information of Boston Dynamics
1294  * and are protected by Copyright Laws of the United States.
1295  * They may not be used, duplicated, or disclosed in any form, in
1296  * whole or in part, without the prior written consent from Boston
1297  * Dynamics.
1298  *
1299  * RESTRICTED RIGHTS LEGEND
1300  * Use, duplication, or disclosure by the government is subject
1301  * to restrictions as set forth in FAR 52.227.19(c)(2) or
1302  * subparagraph (c)(1)(ii) of the Rights in Technical Data and
1303  * Computer Software clause at DFARS 252.227-7013 and/or in
1304  * similar or successor clauses in the FAR, or the DOD or NASA
1305  * FAR Supplement, or to subparagraphs (c)(1) and (c)(2) of the
1306  * Commercial Computer Software--Restricted Rights at 48 CFR
1307  * 52.227-19, as applicable. Unpublished-rights reserved under
1308  * the Copyright Laws of the United States.
1309  * Contractor/Manufacturer is:
1310  * Boston Dynamics/78 Fourth Avenue/Waltham MA 02451.
1311  */
1312