Doxygen Source Code Documentation
plug_coorder.c File Reference
#include "afni.h"Go to the source code of this file.
| Defines | |
| #define | NUM_CORD_STRINGS (sizeof(cord_strings)/sizeof(char *)) | 
| Functions | |
| char * | CORD_main (PLUGIN_interface *) | 
| DEFINE_PLUGIN_PROTOTYPE PLUGIN_interface * | PLUGIN_init (int ncall) | 
| Variables | |
| char | helpstring [] | 
| char * | cord_strings [] | 
Define Documentation
| 
 | 
| 
 Definition at line 52 of file plug_coorder.c. Referenced by PLUGIN_init(). | 
Function Documentation
| 
 | 
| 
 Definition at line 125 of file plug_coorder.c. References AFNI_library_type::cord, GLOBAL_argopt, GLOBAL_library, MCW_strncpy, AF_options::orient_code, PLUTO_force_redisplay(), and THD_coorder_fill(). Referenced by PLUGIN_init(). 
 00126 {
00127    char * str ;                 /* strings from user */
00128 
00129    /*--------- go to next input line ---------*/
00130 
00131    PLUTO_next_option(plint) ;
00132 
00133    str = PLUTO_get_string(plint) ;      /* get string item (the method) */
00134 
00135    MCW_strncpy(GLOBAL_argopt.orient_code,str,4) ;
00136    THD_coorder_fill( GLOBAL_argopt.orient_code , &GLOBAL_library.cord ) ;
00137    PLUTO_force_redisplay() ;
00138    return NULL ;
00139 }
 | 
| 
 | 
| 
 Definition at line 74 of file plug_coorder.c. References AFNI_library_type::cord, CORD_main(), cord_strings, GLOBAL_library, helpstring, NUM_CORD_STRINGS, THD_coorder::orcode, PLUTO_add_hint(), PLUTO_set_runlabels(), PLUTO_set_sequence(), and PLUTO_string_index(). 
 00075 {
00076    PLUGIN_interface * plint ;     /* will be the output of this routine */
00077    int meth ;
00078 
00079    if( ncall > 0 ) return NULL ;  /* only one interface */
00080 
00081    /*---------------- set titles and call point ----------------*/
00082 
00083    plint = PLUTO_new_interface( "Coord Order" ,
00084                                 "Coordinate Order Display" ,
00085                                 helpstring ,
00086                                 PLUGIN_CALL_VIA_MENU , CORD_main  ) ;
00087 
00088    PLUTO_add_hint( plint , "Coordinate Order Display" ) ;
00089 
00090    PLUTO_set_sequence( plint , "A:afnicontrol:display" ) ;
00091 
00092    PLUTO_set_runlabels( plint , "Set+Keep" , "Set+Close" ) ;  /* 04 Nov 2003 */
00093 
00094    /*---------- 2nd line: other inputs ----------*/
00095 
00096    PLUTO_add_option( plint ,
00097                      "Input" ,  /* label at left of input line */
00098                      "Input" ,  /* tag to return to plugin */
00099                      TRUE       /* is this mandatory? */
00100                    ) ;
00101 
00102    meth = PLUTO_string_index( GLOBAL_library.cord.orcode ,
00103                               NUM_CORD_STRINGS ,
00104                               cord_strings ) ;
00105    if( meth < 0 || meth >= NUM_CORD_STRINGS ) meth = 0 ;
00106 
00107    PLUTO_add_string( plint ,
00108                      "Order" ,          /* label next to chooser button */
00109                      NUM_CORD_STRINGS , /* number of strings to choose among */
00110                      cord_strings ,     /* list of strings to choose among */
00111                      meth               /* index of default string */
00112                    ) ;
00113 
00114    /*--------- done with interface setup ---------*/
00115 
00116    return plint ;
00117 }
 | 
Variable Documentation
| 
 | 
| Initial value:  {
 "Dicom" , "Flipped" ,
  "RAI" , "RAS" , "RPI" , "RPS" , "RIA" , "RIP" , "RSA" , "RSP" ,
  "LAI" , "LAS" , "LPI" , "LPS" , "LIA" , "LIP" , "LSA" , "LSP" ,
  "AIR" , "ASR" , "PIR" , "PSR" , "IAR" , "IPR" , "SAR" , "SPR" ,
  "AIL" , "ASL" , "PIL" , "PSL" , "IAL" , "IPL" , "SAL" , "SPL" ,
  "IRA" , "SRA" , "IRP" , "SRP" , "ARI" , "PRI" , "ARS" , "PRS" ,
  "ILA" , "SLA" , "ILP" , "SLP" , "ALI" , "PLI" , "ALS" , "PLS"
}Definition at line 42 of file plug_coorder.c. Referenced by PLUGIN_init(). | 
| 
 | 
| Initial value: "Purpose: control the AFNI display of coordinates.\n" "\n" "The input 'Order' specifies which anatomical directions are to\n" "be displayed in the AFNI control window as the -x, -y, and -z\n" "axes, respectively.\n" "\n" "For example, the 'Dicom' order is equivalent to 'RAI', which\n" "means that\n" " -x = Right [and so +x = Left ]\n" " -y = Anterior [ so +y = Posterior]\n" " -z = Inferior [ so +z = Superior ]\n" "\n" "The 'flipped' order is 'LPI', which is used in many journals.\n" "See the output of 'afni -help' for more information.\n" "\n" "After you make your choice, you must press one of the\n" "'Set' buttons for the plugin to send its data to AFNI.\n" "Author -- RW Cox" Definition at line 19 of file plug_coorder.c. Referenced by PLUGIN_init(). | 
 
                             
                             
                             
                             
                             
                             
                             
                             
                             
                             
                             
                             
 
 
 
 
       
	   
	   
	   
	  