======================================================================== == These changes start after the release of AFNI 1.99 on 24 July 1996. == == Before that, some stuff was desultorily maintained on paper. == ======================================================================== 25 July 1996: * Added Button 2 click (time_index += 1 or -= 1) to afni_graph.c [N.B.: this change was later removed with the drawing plugin.] 29 July 1996: * Added shadow color changing code to "colormenu" widgets in bbox.c -- this gives a little visual feedback when a color is selected. * Used 'glob' routines from tcsh-6.05 to allow filename globbing on non-POSIX systems without the glob routines (like SGIs). 30 July 1996: * Modified MCW_file_expand routine to properly glob files specified in the form 3D:a:b:c:d:e:fname, where only 'fname' will have the wildcards. To3d help printout now reflects this change. * Used fsync(fileno()) to ensure that writes of .BRIK files are flushed to disk -- in afni_func.c and 3ddata.c. * Don't do shadow color changing in "colormenus" unless the widget is realized, since this causes a BadDrawable error on Linux (Motif 2.0). * Changed most popup widgets to be of class "menu", which means that their background color can now be changed separately. * Changed operation of -R option in afni to limit the levels of recursion. Mostly involved changing the routine THD_get_all_subdirs in 3ddata.c. 31 July 1996: * Changed to3d to prevent creation of 3D+time functional datasets. Modified to3d -help to reflect this, and added 'Nz = %d' to the 3D+time information label in the to3d widget panel. 1 August 1996: * Modified imseq.c and afni.c to allow the user to toggle between periodic montages and "no wrap" montages. Added a toggle button "Wrap" next to the crosshair "Gap" menu. * Modified crosshairs in afni.c so that in "Single" mode with a grapher active, then only the frame showing the graphed voxels is drawn. In "Multi" mode, both the frame and the crosshairs will be shown. 2 August 1996: * Modified FD2.c to show average pixel value over frame as well as time, when "AvIm" is being used. Also added 'b' keypress to toggle common baselines for graphs. * Added SEEK_ constants back to mri_read.c, since C compiler on sparky doesn't have them in stdio.h. * Fixed "afni -im" problem with inversion of top_form during waits -- the program didn't turn the inversion off correctly. This error was due to the "dangling else" problem. The addition of a {} pair fixed it right up. Moral of the story: don't be stupid. 6 August 1996: * Fixed a bug in afni_slice.c about the new NN code. The code now doesn't use the "parallel" fast mode unless both the inner and outer axes are parallel. * Fixed a bug in 3ddata.c, where the taxis wasn't properly set on input of a 3D+t dataset if no slice offset data was input. This would cause a crash when trying to delete a dataset. * Added "-warp_4D" switch to afni to allow output of 3D+t datasets in Talairach coordinate. Consumes huge amounts of disk space and CPU time. * Removed fsync() because of time penalty. 7 August 1996: * Fixed another bug in afni_slice.c about the new NN code. The allocation macro MAKE_IBIG failed to take into account that the array ib[] index would run from 0.."top", and it only allocated "top" entries, whereas it should do at least "top+1". 8 August 1996: * Added "-gfisher" option to 3dmerge.c, for purpose of averaging correlation coefficient bricks. Fixed a bug in this program that took the DSET_BRICK_FACTOR from the input dataset before editing, which is a mistake, since editing might alter this scaling factor. * Changed output format from %14.7g to %13.6g in 3dinfo.c. This tends to suppress the annoying roundoff error in the scaled statistics report. 9 August 1996: * Fixed scaling bug in editvol.c EDIT_one_dataset's clip code. For shorts scaled to floats, clip values were computed as integers, which gave truncation errors in some cases. Now, clip values are computed as floats, then converted to integers, with appropriate min- and max-ing. * Also added -1uclip and -2uclip options to EDIT_. See "3dmerge -help" for information. 13 August 1996: * Altered autoRange and userRange controls (in Define Function control panel) in afni to a) always allow the user to set the range, even for thresholds b) eliminate the inversion to indicate the autoRange is on c) compute the autoRange for thresholds as well as fims These changes also eliminate a bug (feature?) where the user could set "Func=Threshold" (SHOWFUNC_THR), which would formerly disable these controls, then switch to another dataset where they would not properly be re-enabled. * Added function AFNI_rescan_session to afni_func.c, which will close all the datasets in a session, then re-read the session directory to make a new set of datasets. At present, this is actuated from the "hidden" popup menu. Tricky points are catching all pointers to datasets that are in the rescanned session, since they will change, and dealing with the case when the user deletes some dataset files. 28 August 1996: * Fixed routine T3D_fix_dataset_dimen() in to3d.c to clear the data brick pointers of the OLD number of bricks, not the NEW number of bricks. This error caused to3d to crash when going from a dataset type with large nvals to small nvals, since some sub-brick pointers were not being properly cleared. [This error only manifested itself on SGI machines, and was found by Christopher Wiggins.] * Made all routines in mri_write.c return a count of the number of files they successfully wrote out (instead of returning void, as before). [This change was prompted by Doug Ward.] 29 August 1996: * If a session directory has functions but no anatomies, then afni.c now prints out a warning message instead of just skipping it silently. [Prompted by Chris Wiggins.] * If a dataset has parent IDCODEs, then the corresponding parent name will not be set in 3ddata.c. This is to prevent confusion. 1 September 1996: * Moved rescan pushbutton from hidden menu to datamode control panel. * Modified 3dmerge.c to allow merger of thresholds in datasets as well as intensities. Uses a new '-t*' type of flag -- the only one implemented so far is '-tfico', which requires all inputs to be of the fico dataset type. See the '-gfisher' merger mode given earlier. 7 September 1996 * Modified -tfico option in 3dmerge.c to allow some of the datasets to be of the fith type. If all of them are fico, then the output will be fico (with degrees-of-freedom parameters summed), otherwise the output will just be fith. * Added "-q" == "be quiet" option to fim2. 30 September 1996: * After several false starts, finally begin creation of plugin code. This is after conversations with Mike Beauchamp and Jay Kummer. Yesterday and today: - afni_plugin.h has interface structures defined; - afni_plugin.c has interface definition routines and widget creation routines; - machdep.h has new #define's to set the type of dynamic library loading to use. Much more to come. * Modified MCW_widget_geom in xutil.h to properly deal with the case of unrealized widgets -- must use XtQueryGeometry instead of XtGetValues. 06 October 1996: * Fixed use of "==" in assignment statement in 3ddata.h. * afni_plugin.c now has - working widget creation and popup routines - plugin callable routines to extract values from user selected options from the interface 07 October 1996: * Changed 3ddata.c to allow use of AFNI_TS_PATH as an alternate to AFNI_TSPATH. If neither environment variable exists, then the path "./" will be used as a last resort. * Something similar done in afni_plug.c with AFNI_PLUGIN_PATH. * Made the switchview callback in afni.c pop down the strlist chooser. This is because a plugin interface will only be allowed to choose from current view datasets, and if such a view switch is made, the list of choosable datasets must be modified. The simplest way to do this is to make the user start the choice process over. 09 October 1996: * Fixed bug in afni_plugin.c that failed to check certain datasets for inclusion in the dataset choosers. * Modified BHelp to include color and border controls. * Incorporated Doug Ward's changed version of editvol.[hc], which adds various cluster editing and volume filtering options to 3dmerge.c (et al.). 11 October 1996: * Fixed (sort of) sizing problem in afni_plugin.c creation of plugin interface windows. * Wrote routine for plugin to load a new dataset into the current session of a controller window. 12 October 1996: * afni_plugin.c changes: - Modified PLUGIN_prefix_ok in afni_plugin.c to check for duplicate prefixes, as well as for illegal characters in the prefix string. - Routine PLUGIN_force_redisplay will make all im3d units redraw their windows. - Routine PLUGIN_copy_dset will copy a dataset, including the bricks. - Added helpstring to the plugin interface, and a "Help" button to popup a plugin-supplied message. * Modified afni to allow separate control of warp-on-demand for anatomy and functional datasets. When a plugin directly modifies a Talairach dataset brick, for example, then if it is set to warp-on-demand, the display won't be affected, since the program always warps from the +orig brick. Under the old scheme, if the anat were w-o-d, then the func had to be w-o-d as well. In the situation where the anat dataset brick does not exist in Talairach coords, then the effect of the plugin would be invisible if the user couldn't force the function to be view-brick independent of the anatomy. * Fixed an old bug in THD_dset_in_sessionlist (3ddata.c) that returned the wrong session index. 14 October 1996: * Fixed bug in 3ddata.h macro FILECODE_TO_PREFIX so that the last '+' in the filecode is used to find the prefix, rather than the first '+'. This fixes a problem with datasets whose prefix contains a '+' character. 18 October 1996: * Modified mri_read.c so that '# line' comments in pgm files can be read. This lets AFNI programs read pgm files created from programs like "xv". * Changed plugin callable functions/macros in afni_plugin.[ch] to start with PLUTO (PLugin UTility Operation). 20 October 1996: * Fixed bugs in imseq.c: - During "image processing" of complex images, one reference to input image "im" had not been changed to "lim" (the locally processed copy). - If ISQ_make_image fails, the XImage "seq->given_xim" would be NULL. This is now detected, and ISQ_show_image won't try to put this NULL image to the screen (which would cause a Segmentation error). * Minor changes to afni_plugin.c: - Added reminder of current "view" at top of plugin dataset chooser. - Added [c] reminder of current controller in plugin shell widget titlebar and icon label strings. * Minor changes to afni_graph.c: - Changed time increment event from Button2 to Shift or Ctrl with Button1. This is to allow the eventual dedication of Button2 events to plugins. 21 October 1996: * Changed FD_brick_to_timeseries (in 3ddata.c) to scale each element by the brick_fac value appropriate for that time index, rather than by the value for time index = 0. This is done using the new routine mri_mult_to_float (in mri_to_float.c). * Fixed bug in EDIT_dset_items (editvol.h) that used "float" inputs. Default type promotion (there can be no prototype here) turns all float inputs to doubles, so they must be retrieved this way. Also, fixed error when "ADN_nsl" is passed as zero -- no longer requires a "ADN_toff_sl" array in this special case. Also made EDERR macro always print a message, even if not in debug mode. * Added DSET_TIMESTEP macro (and others) to 3ddata.h. * Modified PLUTO_add_dset (afni_plugin.c) to allow for other actions when a dataset is set back to AFNI. * Added "progress meter" PLUTO_ functions to afni_plugin.c; also modified the meter code in xutil.c to check if the percent value has changed before trying to update the meter progress. * Added "units_type" to the 3D+time dataset format. This lets the "time axis" be expressed in milliseconds, seconds, or Hertz. Changes were made to 3ddata.[ch], to3d.c, 3dinfo.c, and editvol.[ch]. * Power spectrum plugin "plug_power.c" was made to work today. 22 October 1996: * Added timeseries chooser to afni_plugin.c. * Added ability to apply a function to graph data (e.g., to take the logarithm of each point). This affected afni.[ch] and afni_graph.[ch]. * Fixed a bug in afni_fimmer.c, where routine AFNI_ts_in_library could return the wrong value if the timeseries being searched for was not actually found. * Modified directory scan in 3ddata.c (for timeseries) and afni_plugin.c (for plugins) to skip directories that have already be scanned. This is to avoid the situation where the PATH variable contains duplicate entries. 23 October 1996: * Added Shift/Ctrl/Alt-Button3 simulation of lower tier button presses to imseq.c. 25 October 1996: * Fixed imseq.c routine that re-places the "dialog" window (for Disp and Mont) on the screen when the image is resized -- somehow the code that fixed the problem of forcing the dialog off the edge of the screen lost an "=", and so nothing happened. * Added "i" button to right edge of imseq.c windows -- allows the user to down/up the fraction of the window that the image takes up. 27 October 1996: * Added PLUTO_popup_image() function to afni_plugin.c. Also used this to provide a "hidden menu" popup of an image of me in afni_func.c. 30 October 1996: * Added ability to apply function to each pixel of a displayed image (cognate to the similar ability in graphs -- see 22 October). This primarily affected imseq.c, but also a few other places. * Added new "fift" dataset type, to deal with F-test sub-bricks. - Incorporated cdflib into mrilib. This is to use the "cdff" to compute the CDF for the F statistic, in mri_stats.c - Changed the precision of the threshold scale (thr_scale) from 0..99 to 0..999, and correspondingly changed the scaling from the scale to func_threshold from 0.01 to 0.001. Also changed the "decim" factor for the scale. 31 October 1996: * Modified EDIT_substitute_brick in editvol.c to allow the input array "fim" to be NULL. In that case, the routine will create it. This is a convenience for the user (say, a plugin author). 1 November 1996: * Added routine PLUTO_4D_to_typed_fim to afni_plugin.c. This takes a user function and a 3D+time dataset, and returns fim dataset, with the user function applied to each voxel timeseries. 2 November 1996: * Fixed a major bug with the multiple controller window ("New" button) extension. The problem is that the information about how to extract images from a dataset is stored in the dataset, in the "wod_daxes" and "vox_warp" sub-structs. This causes difficulties when two controllers view the same dataset at different resolutions (e.g., overlay the same function on two different anatomies). The fix is to put the originals of "wod_daxes", "vox_warp", and "wod_flag" into the controller (im3d) struct itself. When the dataset is going to be used, then this information is copied into the dataset struct. This is a clumsy fix, but breaks the least code in the afni_warp.c routines for extracting slices from a dataset. 3 November 1996: * Moved functional resample arrowval from the "Define Function" control panel to the "Define Datamode" panel, where it will be close to the analogous control from anatomy. * Added 1D and 2D transformation function registries. Made up some sample transformation functions (median filtering, etc.). * Added time units appendage to TR in to3d.c. 4 November 1996: * Added "Lock" menu to Datamode panel. This allows the user to specify that certain controllers have their coordinates locked together, so that jumping around in one dataset can be mirrored by jumps in another. At this time, the AFNI_transform_vector function does not properly transform vectors from +tlrc coordinates to +orig coordinates (say) if the two datasets are not in the parent/child relationship. This can be confusing if two such datasets are locked, and they are not in the same "view". * Made pressing Button1 on the AFNI logo in a grapher window also turn off/on the menubar widgets. This enables a screen dump of a graph without that extraneous stuff being present. 6 November 1996: * Added -unique option to afni.c to allow creation of unique display contexts (MCW_DC's) for each AFNI controller window. (This won't work on 8 bit displays.) afni.c and afni_widg.c were changed appropriately (and afni.h). 10 November 1996: * Wrote "lsqfit" plugin. This allows computation of least squares fits to timeseries graphs. Modified afni_graph.c to allow "Double Plot" to overlay least squares fit graph (or other output of a "Tran 1D") on the data timeseries graph. 12 November 1996: * Fixed bug with multiple displays and the "lock" -- when changing the dataset in an AFNI controller, you don't want the coordinate lock to apply. * Started adding "orts" to AFNI's interactive fimmery. 19 November 1996: * Made afni.c (AFNI_setup_viewing routine) set the FIM-able dataset to the newly activated anatomical, if possible. In the old version, if you switched anatomies, the FIM-able dataset didn't switch with you. This was confusing to the uninitiated masses (that is to say, Mike Beauchamp). 21 November 1996: * Incorporated the f2c (Fortran-to-C) convertor into the AFNI96 distribution, in a separate directory (f2cdir). This allows the use of the old "parser.f" routines to compile and execute user created expressions. * Added macro AVOPT_columnize to bbox.h, which allows the setup of an optmenu in a multicolumn layout. Also setup the "Plugins" button to allow this (when the number of plugins grows past 20). 22 November 1996: * Adapted MCW_choose_strlist (in bbox.c) to allow selection of multiple items from the list. 23 November 1996: * Rearranged Write buttons on Datamode control panel in AFNI. Added a write "Many" button which lets the user pick lots of datasets to write out, so he can go get a cup of coffee. Put all 3 Write buttons in a single row. * Added a Rescan All button to allow rescanning of all sessions. Put both Rescan buttons in a single row. Also added a "*.1D" rescan button to allow for re-reading of timeseries files. * Attached data type descriptors like [fim] and [epan:3D+t] to the listings in the dataset choosers. 10 December 1996: * Fixed small bugs in parser_int.c, in the utility routines where a pointer to a doublereal wasn't dereferenced before comparing it to zero. 01 January 1997: * Added routines to libmri.a to allow reading in a 3D: image file in "delay" mode -- only the filename and offset into it are stored in the image. When access to the image is desired, then it will be read from disk. * Added -delay switch to to3d.c to take advantage of this procedure. This prevents duplicate malloc required for huge 3D: file (once for the 3D: input and once for the dataset brick). People who do all 3D+time input data in one big file have run out of memory otherwise. * Added "++" toggle to allow display of crosshairs in all slices of an AFNI montage. This is specifically for Jeff Binder. * Added RESET_AFNI_QUIT() calls to a bunch of routines in afni.c. 02 January 1997: * Added mcw_glob.c usage to FD2.c, to allow internal expansion of wildcarded filename. This overcomes the SGI limit on the number of arguments on the command line. 03 January 1997: * Got program waver.c to work -- generation of an ideal waveform with tunable parameters. 13 January 1997: * Added -subort option to fim2.c -- subtraction of orts from an image time series. 20 January 1997: * Included "#include " in mcw_glob.h, to prevent complaints from stupid compilers. * Added Makefile.osf1, from a system at U Maryland. * Added gmovie, a script to create a GIF movie from a bunch of PNM files. 21 January 1997: * Made the "fscale" element in a grapher (afni_graph.[hc]) be a float, so that finer control over graph scaling is possible. * Changed "Scale", "Ignore", and "Matrix" controls in graph window to be optmenus. Added a routine to allow optmenus to be refitted. 22 January 1997: * Made the control buttons on the image viewers (imseq.c) a little smaller. 30 January 1997: * Added program 3dcalc.c. * Changed STEP function in parser.f to be 1 only for x > 0. 14 February 1997: * Incorporated GNU malloc into afni.c, which will be enabled with the #define-ition of USE_GNU_MALLOC (e.g., in machdep.h). * #define-ing NO_FRIVOLITIES in machdep.h will no disable the picture and sonnets. 16 February 1997: * Incorporated GNU malloc checking into "dafni". Now checks the status of all malloc-ed blocks on entry and exit to every routine using "ENTRY" and "RETURN" macros. (Nevertheless, this still doesn't find the bug I'm looking for.) * When a grapher window is being destroyed, its corresponding image window needs to redraw the crosshairs. This redraw command could cause a crash (for reasons unknown) when the dataset is being changed (that is, the grapher is being trashed because the new dataset does not support graphs). This is fixed in afni.c and afni_func.c so that when a grapher is destroyed due to underlay switching, then the corresponding image redraw commands will be ignored. 18 February 1997: * Added some logical functions (and, or, mofn) to parser.f, and so to 3dcalc. Also added the -session option, and made the default session = "./". 20 February 1997: * Moved a couple routines in afni_plugin.c outside the "#ifdef ALLOW_PLUGINS ... #endif" code block since they are used in non-plugin-specific parts of AFNI. 23 February 1997: * Wrote plug_imreg.c to do 2D registration on 3D+time datasets. * Modified mri_align.c, imreg.c, and fim2.c to recognize macro ALLOW_DFTIME, if the user wants to compile the ability to do -dftime or -dfspacetime registration. 03 March 1997: * Allow to3d to create 3D+time FIM datasets. Allow afni to display them as functional overlays. * Add -noplugins option to afni, so that it is possible to skip plugins initialization (also can setenv AFNI_NOPLUGINS). * In to3d.c, if any -[xyz]SLAB or -[xyz]FOV options are used, then require that all 3 axes be given if the dataset is to be written out correctly without opening the interactive window. 04 March 1997: * Added a "Read Sess" button to allow input of a new session into afni. Also added a function THD_equiv_files to 3ddata.c to allow for checking if 2 filenames are equivalent (point to the same inode on the same disk). 05 March 1997: * Added a dummy dataset to afni.c, so that if there are none when the user starts, he can read them in with the "Read Sess" button. * Added a "Read 1D" button to allow input of timeseries files. 10 March 1997: * Made the "Selection" box in the new file selectors have the "HOTCOLOR" as the background. This is because of the importance of the contents of this box. ?? March 1997: * Created script files to compile and distribute AFNI binaries on and to various computers. 02 April 1997: * Incorporated the CLAMS library into the internal (MCW only) version of AFNI. 03 April 1997: * Created the "imcalc" program, analogous to 3dcalc, but for 2D images. 21 April 1997: * Started work on "plug_realtime.c", including the "3T_toafni.c" program to extract data from ParaVision and send it into AFNI. 22 April 1997: * Modified registered functions to each have an int flag. The only flag value used now is bit 0 = RETURNS_STRING. This can be used in a 1D function (via PLUTO_register_1D_funcstr) to return an extra string that will be displayed in graph's button 3 popup. * Modified the LSQfit plugin to return the fit parameters in the extra string, so that the user can display them. 17 June 1997: * Lots of changes in the last 2 months to make plug_realtime.c work. * Added a menu item to afni_graph.c to allow user to control graph colors and line thicknesses. The colors can also be initialized from the .Xdefaults file. * Added a menu item to afni_graph.c to allow the graph window to be dumped to an image file. Had to fix xim.c to allow for the XImage format returned by XGetImage on the graph Pixmap. * Modified imseq.c so that if the user types ".pnm" as the end of the "Save:one" filename, the program won't add another ".pnm" to the end. 18 June 1997: * Had to fix the xim.c routine XImage_to_mri to work correctly with 12 bit Visuals. * Added stuff so that .Xdefaults can initialize the line thicknesses as well as the colors. 25 June 1997: * Made afni_plugout.c and plugout_tt.c -- initial implementations of the "plugout" concept: programs that talk to AFNI using IOCHANs to get T-T coordinates, etc. * Modified iochan.c to allow a socket connection to cutoff abruptly when closed. This was needed because I found that a socket connection might hang around a while after close, and this would prevent new connections on the same port #. At present, this capability is only used when afni exits. * The plugout code (afni_plugout.c) is an Xt work process. To prevent it soaking up too much CPU time, if nothing happens, it will sleep for 10 msec. This work process is disabled if the realtime plugin is active. 30 June 1997: * Added routine THD_extract_series and macros PLUTO_extract_series* to get time series from 3D+time datasets. [per Ziad Saad] * Modified 3ddup.c to allow conversion of 3D+time anatomy into 3D+time fim. This will allow the overlay of EPI time series as "function" onto the corresponding anatomy. 02 July 1997: * Modified imstat.c to work with 3D image files, at least partly. 16 July 1997: * Made -orient option (and AFNI_ORIENT environment) work to change the order in which coordinates are displayed in the afni.c crosshair label. 22 July 1997: * -orient (and AFNI_ORIENT) now work with 3dclust.c. * The "jump to" popup in afni.c now works with the orientation code, so that you can paste coordinates out of 3dclust into to jumpto window. 23 July 1997: * Added 6 new functional dataset types, with thresholds being distributed as follows: normal chi-square incomplete-beta binomial gamma Poisson * Gave user ability to change range of threshold slider -- before, range was fixed by threshold functional dataset type. * Found problem on Linux (1.2.13) with "dlopen" loading of plugins and models -- seems to have problems at about the 20th library. Not sure what to do about this. * Added routine PLUTO_report to allow a plugin to report status information at startup. 28 July 1997: * Added new utility program "3drefit.c" to allow user to change the axes stored in a dataset header. This is mostly to fixup errors that may have occured at to3d time. * Added -orient option to to3d.c (not that it is much use). * Fixed bug in 3dinfo.c, for printout of sub-brick scaling factors when no statistics are present in the header. 30 July 1997: * Added ability to include a rotation warp when using 3ddup. * Added ability to include empty markers in 3drefit. * Fixed AFNI_init_warp (in afni.c) where it give the name of the new dataset based on the "adam" dataset, rather than the "parent". This causes problems when transforming a dataset that is itself warp-on-demand from 3ddup -- the names would be based on the ultimate warp parent, not the derived parent from 3ddup. 1 August 1997: * Added a label in the Define Function control panel to show the crosshair pixel value, if all 3 image windows are open (afni.c, afni_func.c, afni_widg.c). * Made Button3+Modifiers work even if CapsLock or NumLock is pressed (imseq.c). * Added random Shakespearean insults. * Added AFNI_SESSTRAIL (3ddata.c) to control session "lastname". 22 August 1997: * Raoqiong Tong modified parser.f to make the vector evaluation routine work again. * Also fixed 3dcalc.c to work with 3D+time datasets. 26 August 1997: * Oops! Had to fix the EXP_0D plugin in plug_lsqfit.c because the parser vector evaluation routine was changed. 03 October 1997: * Oops!! Fixed a bug in mri_align.c, where the fine fit weight image wasn't computed properly. This affected fim2, imreg, and plug_imreg. 22 October 1997: * Oops**2. Fixed a bug in the bug fix above. 27 October 1997: * Changed csfft to csfft_cox in all places to avoid conflict with code by AJ. 30 October 1997: * Fixed DXY_THRESH to PHI_THRESH in one line of mri_align.c * Worked on adding popup "hints" to AFNI. 10 November 1997: * Added popup hints to to3d. * Added "Clinical" disclaimer to startup message. * Remove scale hints (afni.c, imseq.c), since they are particularly obnoxious. 12 November 1997: * Added some SPARKY specific header declarations to fix problems with SunOS compiling system (e.g., strtod). 20 November 1997: * Increased buffer sizes in count.c * Added Makefile.sparc5_2.5 for Suns. 21 November 1997: * Allowed brick dimensions to be specified as "120A" or "A120" in to3d.c. This is to make it consistent with the way scanners print on films. 30 November 1997: * Added the "bucket" types (anat and func) to 3ddata.h, and then modified afni, editvol, etc., to utilize this type of dataset. * Created program 3dbucket.c to put buckets together out of sub-bricks from other datasets. * Modified 3drefit.c to allow changes to bucket sub-brick information. 09 December 1997: * Added a new chooser to let user pick interpolation method for threshold (statistical) sub-bricks. * Fixed CUBIC_CLIP in afni_warp.c -- it was incorrectly placed before the brick_fac scaling, not after. * Removed FIM menu from Define Function control panel. 13 December 1997: * Added new file "3dmaker.c", for routines that make new 3D datasets from other datasets. Moved the guts of the PLUTO_4D_to_typed_* routines into this file. * Also fixed a "float *" inside mallocs to be "float" in a couple of places in these routines. This should be innocuous, since most CPUs satisfy sizeof(float) <= sizeof(float *) 15 December 1997: * Added "Compute FIM+" to FIM menu. This saves the best time series index in a new sub-brick. * Added some macros to editvol.h to make changing sub-brick auxiliary values simpler. 17 December 1997: * Modified AFNI_set_viewpoint to skip graph redraw unless REDISPLAY_ALL or unless a new (x,y,z) location is set. * Added menu to the pbar label to allow modification of the colors and spacings. * Modified display.h to allocate overlay colors from read-write cells. This allows the colors to be redefined. 18 December 1997: * Added -noqual option to AFNI to make it skip quality checks when doing marker transformations. * Added -view option to 3drefit to let it change coordinate systems. 21 December 1997: * Added ability to read in palettes and colors from .afnirc file, and interactively from a user-specified file. Also allow user to reset the top and spacings on the color pbar. * Modified display.[ch] to put all overlay stuff into a shared struct for all MCW_DCs. This means that the -unique option will only generate new grayscale colorcells for each controller, but they will now share overlay colors. This is intended to prevent a problem when users add new colors dynamically from external palette files. This change affected files: afni_func.c afni_graph.c afni_graph.h afni_setup.c xim.c afni_widg.c bbox.c display.c display.h imseq.c pbar.c * Modified pbar.c to keep the input pval's exactly when calling alter_MCW_pbar -- formerly, after resizing the panes, the values might be altered slightly. * Discovered that 17 Dec 97 change to AFNI_set_viewpoint could make graph not be drawn correctly on startup. Added "never_drawn" variable to graphs and imseqs to allow this condition to be detected. 22 December 1997: * Removed auto-change of threshold scale for bucket datasets from afni.c. Also unmanages/remanages this scale when the pbar is being changed, due to horrible visual effects on the SGI machine nimloth (if FIX_SCALE_SIZE_PROBLEM is defined). * Modified pbar.c to store the summed pane heights, and then recompute the value/label only when such a summed height changes. This prevents the modification of the value/label pairs at other panes when resizing only one pane. * Modified AFNI_bucket_label_CB (afni_func.c) to put the sub-brick index at the left of the option menu label. 26 December 1997: * Fixed bug in palette write-out (afni_setup.c). * Added a scrollable text output utility (xutil.c). Made the plugin help use it if the help string has many lines (afni_plugin.c). Added a line counting routine to 3ddata.c 02 January 1998: * Added ability to read compressed .BRIK files to 3ddata.c (gzip -d, bzip2 -d, and uncompress are supported). * Added program "3dnoise" to zero out noise-like regions of nonnegative short datasets. * Modified display of dataset names to include number of points in a 3D+t dataset, and to include a "z" flag to indicate compression of dataset. 05 January 1998: * Added "New Stuff" entry to Misc menu, which just pops up the README.changes file into a readonly text window. * Program "quotize.c" will take a text file and make it into a C array of strings, one line per element. This is used in afni_func.c to popup the README.changes file, which is put into the file "newstuff.hhh" by quotize and in the Makefile.INCLUDE. 07 January 1998: * Added a routine to editvol.c to do local averaging of a dataset faster than -1filter_mean -- it seems to run about 6 times faster. This is implemented as -1filter_aver in 3dmerge, so that the older one is still available. Also modified plug_edit.c to add this option to the Filter menu. 08 January 1998: * Modified scaling for output of 3dmerge.c so that the program detects if all the inputs are integer types (byte or short, unscaled). If they are, and the merger type is consistent with integer type, then the output will be unscaled, otherwise it will be scaled by a float. 09 January 1998: * Modified afni_graph.[ch] to allow choice of a timeseries to be used to define the x-axis graphing. Thus, if x(t) is the x-axis timeseries, and yij(t) are the data timeseries, then each graph ij now shows x(t) vs. yij(t) rather than t vs. yij(t). * Also modified the Button 1 press in the central graph to jump to the time index point whose graph point is closest to the button click. * Also allowed data plots to be shown as points instead of lines. "Points" are drawn using the "_circle" routine ("filled" or "hollow", as the line is "thick" or "thin"). 12 January 1998: * Allow a gap between the sub-graph boxes. This is chosen from the "Colors etc." menu. * Raoqiong Tong fixed a bug in the new parser.f with the AND, OR, and MOFN functions. 14 January 1998: * Modified symbol for current time index in afni_graph.c, so that when data is graphed with points the current point can be distinguished from the graph points. 16 January 1998: * Added "Percent Change" calculation to afni_fimmer.c, and removed the "real-time" update feature from those routines. 01 February 1998: * Modified 3ddata.c to avoid use of "scandir" routine, which caused no end of trouble on Solaris. * Moved the "mcw_glob" routines into libmri.a. These are used to get filenames from the directory now. 02 February 1998: * Fixed a typo in plug_imreg.c to make the "Fine Blur" parameter scale to FWHM properly. * Broke 3ddata.c into "thd_*.c" routines, and incorporated them into libmri.a. Also incorporated 3dmaker.c and iochan.c. Files 3ddata.c, 3dmaker.[ch], and iochan.[ch] are no more! 03 February 1998: * Also put editvol.c into "edt_*.c" routines, and thence into librmi.a * Added an "Autoscale" button to graph Opt menu, and also execute the autoscale code when the graph is 1st drawn. 04 February 1998: * Modified dbtrace.h to enable tracing with usual afni run. This can be turned on/off using the "Misc" menu, or the "-trace" option (if the program is compiled with USE_TRACING). 08 February 1998: * Modified afni_graph.c to display dataset indices in graph window, rather than FD_brick indices. (See the DONT_MANGLE_XYZ location.) * Modified imseq.[ch], afni_graph.[ch], afni.[ch], and the new file afni_receive.c to allow transmission of mouse Button2 data to a calling routine. Work is in progress -- more later. 13 February 1998: * Released drawing plugin to MCW users. Includes open and closed curves, filling, and undo. * Also added .BRIK output compression to thd_compress.[ch], and to thd_writedblk.c. 16 March 1998: * Added internal globbing to 'afni -im'. * Modified function AFNI_follower_dataset (afni_func.c) to copy datablock auxiliary data from the data parent, if available. * Modified 3drefit.c to allow -fbuc and -abuc to work no matter how many sub-bricks are present. * Added program 3dmaskave.c to print out averages from dataset sub-bricks, with ROI selected by a mask. 18 March 1998: * Made "ptr" a byte variable rather than char in XImage_to_mri (xim.c) -- this seems to fix a problem on some machines. 20 March 1998: * Fixed EDIT_add_bricklist -- the brick auxiliary data additions would free data that hadn't been allocated. * Modified stuff so that Dummy dataset is not deleted -- this seems to help. (It only takes up 64K, so the loss is small.) 21 March 1998: * Modified 3dmaskave to allow dumping of all voxels hit by the mask, and to compute the standard deviation also. 24 March 1998: * Modified plug_copy.c to allow creation of a 1 sub-brick zero-filled "copy" -- useful for making mask datasets. * Modified 3dnoise.c for 3D+time datasets, so that a voxel is zeroed only if a majority of time points at that location fall below the cutoff. * Modified plug_drawdset.c to recompute statistics after each edit, no matter what. Also changed the help message a little. * Wrote plug_maskave.c to do pretty much the same thing as 3dmaskave.c. 17 April 1998: * Modified 3dcalc.c to allow input of *.1D time series in place of datasets. 25 April 1998: * Modified thd_*.c to store byte order (for short and int datasets) in the the .HEAD file. Then when the file is read in, it will be byte swapped if necessary (which will force it to be malloc-ed, not mmap-ed). * Also modified 3drefit to allow a byte order to be written to the .HEAD file. Note that this does not affect the .BRIK file. * Added new environment variable AFNI_BYTEORDER to control the byte order of output datasets. This can be "LSB_FIRST" or "MSB_FIRST". If not present, this means to use the native order of the CPU. * Added new enviroment variable "AFNI_NOMMAP" to allow suppression of mmap. If the value is "YES", then all datasets will be malloc-ed. * Modified the "Purge Memory" button to purge ALL datasets from memory. Formerly, it only purged the unused ones. 29 April 1998: * At the behest of Ted DeYoe, modified 3dcalc.c (again!) to allow operations on bucket and other multi-brick datasets that aren't 3D+time. * Also modified 3drefit.c to allow conversion of 3D+time into a bucket. * This also required the ability to erase datablock attributes, since they are persistent -- even if the data in the dataset is voided, the attribute will remain to be written to disk. So a routine THD_erase_one_atr was added. In files thd_writedset.c and thd_writdblk.c, every attribute that DOESN'T get written now gets erased. This will still leave extra attributes (perhaps added by a plugin) being persistent, but avoids the attribute "hangover" problem. 30 April 1998: * Modified 3dcalc.c to purge dataset sub-bricks when finished with them, and to allocate output buffer sub-bricks only when needed. This is to keep memory usage down when using compressed 3D+time datasets. * Also added the -verbose option to 3dcalc.c. 1 May 1998: * Fixed plug_rename.c to work with compressed datasets. Added a routine COMPRESS_add_suffix to thd_compress.c to facilitate this. 4 May 1998: * Added routine THD_purge_one_brick to thd_purgedblk.c, to allow freeing of one sub-brick from a malloc-ed dataset. Also defined macro DSET_unload_one(dset,iv). 3 June 1998: * Modified AFNI_make_descendants to allow descendancy to flow from +acpc datasets, not just from +orig datasets. However, this doesn't work just yet, due to warping issues. 5 June 1998: * Modified 3dnoise.c to have option to set noise level on command line, rather than compute it. 9 June 1998: * Modified edt_clust*.c routines to implement -1clust_order option. * Modified 3drefit.c to have -nowarp option. 13 July 1998: * Incorporated Doug Ward's erosion+dilation routines into the clustering modules. 14 July 1998: * Added option -skip_afnirc to allow .afnirc file to be skipped. * Fixed bug in afni_setup.c that didn't manage the palette chooser menu when starting with 0 palettes and then later reading in some. * Fixed bug in plug_copy.c that put the anat type off by 1. Also made the "Zero [One]" option not make the anat type always be omri. * Fixed bug in parser.f, whereby the vector versions of the boolean functions (or, and, mofn) were evaluated incorrectly. 15 July 1998: * Change afni_pcor.c to remove use of DENEPS test for division in computation of correlation coefficient. 17 July 1998: * Added program imstack.c to stack up a bunch of 2D images into the stupid MGH format. [For Kathleen Marie Donahue.] 21 July 1998: * Added model_convgamma.c to represent a gamma variate convolved with a reference time series. The "k" parameter of Doug Ward's model_gammaver.c was modified to be called "amp" here, since the impulse response is reparameterized to have peak value = "amp", rather than "k * (rb/e)**r", which is clumsy. * Modified Doug Ward's NLfit_model.h to ensure that certain routines needed by model functions can be forced to be loaded. * Modified 3dTSgen.c to make the "-ncnstr" and "-scnstr" options recognized, since there is a typo in the manual. * Modified Makefile.INCLUDE for 3dTSgen and 3dNLfim to use the proper dynamic linking load flags $(PLFLAGS), and also to include the proper dependencies. 22 July 1998: * Added routine THD_timeof_vox to thd_timeof.c. This allows computation of voxel time from voxel index, rather than voxel coordinate. * Removed some redundant code from 3dTSgen.c -- it opened the input dataset twice in a row, and loaded the datablock when there was no need. * Modified 3dTSgen.c, 3dNLfim.c, and plug_nlfit.c to have new "-inTR" option to allow computation of model functions with TR set from the input dataset rather than fixed at TR=1. Note that if the units of the dataset time axis are msec, they will be converted to sec instead (allowing msec to be used as a unit was a mistake). 27 July 1998: * Fixed a bug in routine suck_file in afni_setup.c, which put the terminating NUL character 1 place too far in the output array. * Wrote program uncomment.c, to remove comments from C files. * Added model_convgamma2a.c. * Modified NLfit.c to generate a fixed set of random samples instead of starting over for each voxel. Also fixed the algorithm that keeps the best random samples -- it was not always keeping the best one, just some of them. 01 August 1998: * Added copyright information to some .c and .h files. * Modified mri_to_short.c to allow for special case of scale!=1.0. * Modified plug_realtime.c to allow for 2D image alignment. (Continuation of work from April that was unfinished then.) First cut is to do all registration at end of acquisition. * Turned off "frivolities" during a real-time run. * Added the ability to graph points+lines together in afni_graph.c (also see changes of 09 Jan 1998). 06 August 1998: * Added changes to thd_compress.[ch] made by Craig Stark/Paul Reber of UCSD, to allow them to use their custom decompression program "brikcomp". * Added realtime 2D registration to plug_realtime.c. * Modified 3dmaskave.c and plug_maskave.c to allow user to choose a sub-brick of the mask dataset. plug_maskave.c also now lets the user save the mask average of a 3D+time dataset into the timeseries library (for use as a FIM, for example). Also fixed an overflow bug in both programs when the mask range is too big for a short or byte dataset. 07 August 1998: * Modified display.[ch] to store extra information about the X11 visual. This isn't used yet, but is preparatory to allowing support for using TrueColor visuals and installed colormaps. 17 August 1998: * Adapted old Fortran PLOTPAK to in-memory plotting, with routines to graph to screen and to PostScript. * Used this to implement the "Plot" button in the timeseries chooser, and to do graphing of the realtime 2D motion parameters. 22 August 1998: * Modified display.c to support TrueColor visuals, and xim.c to support arbitrary byte ordering, plus 3 and 4 bytes/pixel. 23 August 1998: * Modified dbtrace.h and most afni_*.c files to allow not only debug tracing of routine entry/exit, but also the printout of other debugging information that was formerly hidden behind "#ifdef AFNI_DEBUG". * A few more changes to make xim.c work properly with depth=24, which can be either 3 or 4 bytes/pixel. 25 August 1998: * Modified afni_pcor.c change of 15 July 1998 to check denominator vs. DENEPS rather than 0.0. 09 September 1998: * Modified thd_sarr.c to add routine to "normalize" a list of files using the C library routine "realpath" and to cast out duplicate files. * Used this in afni.c and thd_get1D.c. * Also added *.1Dv files to list of allowable 1D extensions in thd_get1D.c. * Doug Ward provided me with the new 3dDeconvolve.c program, as well as some changes to 2dImReg and 3dRegAna. 14 September 1998: * Added "-install" option to afni.c to allow installation of a new X11 Colormap. Also affected display.[ch], afni_widg.c, imseq.c, afni_graph.c, xutil.[ch], afni_plugin.c, to3d.c, and plug_drawdset.c. * Added "-2swap" and "-4swap" options to to3d.c, to allow data to be byte-swapped on input. Also added a "Byte Swap" button to do the same thing interactively. 16 September 1998: * Modified 3dmaskave.c to allow selection of dataset sub-brick and dataset value range. 17 September 1998: * Added "-1zscore" option to 3dmerge.c (via edt_onedset.c, etc.). * Also completed the list of "p2t" and "t2p" routines, as well as adding "t2z" routines, in mri_stats.c and thd_statpval.c. 18 September 1998: * Added program cdf.c to provide a command line way to get results from the "t2p", "p2t", and "t2z" routines. * Modified afni_setup.c so that when a .pal file is input, the last newly defined palette becomes the active one in the AFNI controller which read the file in. 22 September 1998: * Added program 3dTcat.c, to catenate multiple 3D+time datasets into one big dataset (and possibly detrend them at the same time). This was adapted from 3dbucket.c 28 September 1998: * Modified edt_onedset.c to correctly deal with clipping a dataset when the clip range is larger than the dataset range, and the datum type is short. 29 September 1998: * Added routine mri_rota_shear() to mri_rota.c to do 2D image rotation using the Paeth shearing method combined with FFTs. 01 October 1998: * Modified mri_rota_shear to double up on FFTs -- speeds it up by about 30%. * Modified mri_align.c and mri_2dalign.c to allow choice of interpolation method at each stage of registration. * Modified imrotate.c, imreg.c, and plug_realtime.c to use the new image alignment methods. 09 October 1998: * Modifed afni.c and thd_fdbrick.c to allow the user to control the image flipping -- that is, to let left be displayed on the left. 16 October 1998: * Released 3dvolreg.c to Tom Ross for beta testing. 21 October 1998: * Added some routines to afni_plugin.c to create/manipulate PLUGIN_strval's [= label + textfield]. 26 October 1998: * Finished plug_tag.c, and added tagset to a 3D dataset. Modified afni.c to allow markers panel to open when there are no markers, so user can control the color of the tags. * Modified mri_max.c to fix the initial values. * Modified 3dvolreg.c and mri_3dalign.c to add a clipping option. 01 November 1998 [about]: * Added realtime 3D registration to plug_realtime.c. * Added quintic interpolation option to thd_rot3d.c and places that use it (3dvolreg.c, mri_3dalign.c, 3drotate.c, and plug_realtime.c). 03 November 1998: * Modified afni.c, afni_widg.c, and afni.h to allow user to lock the time indexes of controllers, as well as the spatial locations. 12 November 1998: * Modified 3dmerge.c to have new -1dindex and -1tindex options. 16 November 1998: * Modified mri_align.c, mri_2dalign.c, and mri_3dalign.c to ensure that the weighting factors are non-negative. * Modified 3dvolreg.c to skip registration on the base volume. * Added plug_volreg.c to do the same job as 3dvolreg.c. * Fixed bug in 3drotate.c that caused -[ab]shift commands without directional suffixes to be converted into zeros. 18 November 1998: * Fixed a bug in plug_power.c in the untangling of FFT coefficients. * Modified afni_slice.c to properly clip short and byte interpolation to avoid overflow. 20 November 1998: * Modified csfft.c to use unrolled routines for FFTs of length 16, 32, and 64. Also added special routines using the fft64 code to do lengths 128 and 256. * Modified mri_3dalign.c and 3dvolreg.c to allow specification of a different interpolation method to be used at the final rotation to the output brick. 23 November 1998: * Fixed a typo in plug_realtime.c and plug_volreg.c that made the choice of "Heptic" use quintic interpolation instead. 27 November 1998: * Fixed some logical errors in 3dmerge.c with interaction of -1dindex, -1doall, and the dataset I/O. 03 December 1998: * Fixed a problem in 3dmerge.c with "-datum float" and the sub-brick scaling factor, when editing one dataset only. 04 December 1998: * Added unrolled fft8() to csfft.c. * Modified thd_rot3d.c to start the FFT size calculation at least at 95% of the actual width rather than 90%. This reduces the likelihood of wraparound effects. 10 December 1998: * Added a timeout for the child process in plug_realtime.c. 13 December 1998: * Fixed a bug in the dataset -> time series routines that didn't scale properly if some of the brick factors were zero and others were not. Files affected: mri_to_float.c, thd_dsetto1D.c, thd_fdto1D.c, and thd_initdblk.c. 16 December 1998: * Removed TESTER code from afni_widg.c, and added some STATUS() printouts to trace progress. 17 December 1998: * Modified xutil.c to use XmChangeColor to change the color of a widget (routine MCW_set_widget_bg). * Added some changes by Doug Ward to speed up linear regression calculations. 22 Dec 1998: * Fixed a bug in plug_volreg.c, where the ax? variables were used before they were defined, resulting in the wrong order of output of the estimated movement parameters in the graphs and dfile. 30 Dec 1998: * Added function Winsor9 to the 2D transformations, in imseq.c. * Added RowGraphs to imseq.c, also affecting plot_ts.c (in coxplot) and afni.c. 31 Dec 1998: * Modified afni.c crosshairs to allow display only along certain axes. 03 Jan 1999: * Added routine MCW_widget_visible to xutil.c, and used it in imseq.c and afni_graph.c. 04 Jan 1999: * Fixed the time lock feature in afni.c so that it would not operate if toggled off. [Oops] * Added AFNI_ALWAYS_LOCK environment feature. 05 Jan 1999: * Modified the way imseq.c places the dialogs (Disp and Mont buttons), so as to reduce the likelihood that some of the dialog will appear offscreen. * Added HorZ ('h') selection to afni_graph.c "Opt->Grid" submenu, which will draw a dashed line at the y=0 level in each sub-graph. 06 Jan 1999: * Modified afni_graph.c to try to avoid crashes when graphing window is closed using "Opt" menu "Done" button. Seems to be caused by Expose events, but what exactly isn't clear -- happens on SGI systems. Using the "Done" button now starts a 50 msec timeout before the "q" key is simulated. Also, the Expose event count is now checked before processing, and only if event->count == 0 is any work done. Why these changes do the job is not obvious. 07 Jan 1999: * Modified afni_graph.c to move placement on screen of the "Opt->Colors Etc." submenu if it ends up placed directly over the "Opt" menu. This could happen on some versions of Motif when the graph window is up against the right edge of the screen. A callback is executed when the submenu is mapped, and if it is in a bad location, its XmNx value is changed. 10 Jan 1999: * Modified edt_coerce.c to make EDIT_coerce_type work with doubles. 11 Jan 1999: * Modified the rest of edt_coerce.c and edt_volamax.c to allow doubles. * Added thd_mastery.c, which allows a dataset to be "mastered" on input, so that its bricks are a selection of bricks from a master dataset. Adds the routine THD_open_dataset(). Modified 3ddata.h and a bunch of other functions. * Modified 3dinfo.c, 3dcalc.c, rtfeedme.c, from3d.c, 3drotate.c, and 3dvolreg.c, to use the new opening routine, to allow for subset selection. 15 Jan 1999: * Fixed the old 3dpc.c to work with the new AFNI data storage, and to use the EISPACK routines instead of LAPACK (with help from Vinai Roopchansingh). * Made swap4 work with float input datasets as well as int. 19 Jan 1999: * Added "-1ddum" argument to 3dpc.c. 20 Jan 1999: * Fixed bug in mri_stats.c, where the "p2t" conversion was done backwards for the F statistic (p should have been q, and vice-versa). 21 Jan 1999: * Added SurfGraph feature to imseq.c. * Added OSfilt9 to imseq.c and the 2D transformations menu (afni.c). * Modified coxplot/plot_topshell.c to store a handle to the form at the top of the graph window hierarchy. * Modified xutil.c to add the "SaveUnder" property to the hints widget. 24 Jan 1999: * Modified coxplot (coxplot.h, plot_motif.c, plot_x11.c) to use the X11 Double Buffer extension, if HAVE_XDBE is defined. This makes the redrawing of graphs look much smoother. 25 Jan 1999: * Created the "AREN" routines (aren.[ch]) for volume rendering, on top of VolPack. Not sure what to do with them yet. 26 Jan 1999: * Fixed bug in initialization and usage of Xdbe library, in coxplot. 27 Jan 1999: * Add "UK Flag" location marker to RowGraphs and SurfGraphs. 29 Jan 1999: * Fixed afni_func.c so that if the user presses "See Function" when there is no function, it turns the toggle button back off. Formerly, it turned off the internal flag, but didn't change the toggle button state, so that the user was fooled. 30 Jan 1999: * Added "Flood->Zero" and "Zero->Value" options to plug_drawdset.c. 05 Feb 1999: * Added plug_render.c, the first version (grayscale only) of the volume rendering code. * Changed name of AREN to MREN and put it in mri_render.[ch]. * Cloned the mcw_graf.[ch] routines out of xv. * Added the coordinate stuff to 3dcalc.c. 07 Feb 1999: * Added new program 3dfractionize.c (per Ziad Saad). 09 Feb 1999: * Changes to imseq.c include putting the colorbar popup menu on ctrl-Button3 if there is only 1 image in the sequence, and changing the sharp-factor arrowval to run from 1-9 instead of 1-99. * Added "MCW_noactext" option to arrowvals (bbox.c), so that the usual actions taken when the user leaves the window are not taken. * Added many features to plug_render.c: automation, cutouts, and accumulation. * Fixed 3drefit.c -view option. 10 Feb 1999: * Added "Expr > 0" cutout to plug_render.c * Added SIND(), COSD(), and TAND() functions to parser.f 11 Feb 1999: * Modified many routines in mri_*.c to deal with MRI_rgb type images, in preparation for modifying imseq.c to deal with such. * Modified display.[ch] to include a "colordef" for conversion between Pixel and RGB triples. * Added routine to xim.c to convert MRI_rgb image to an XImage. * Changed imseq.c to allow MRI_rgb images. * Created program 1dplot.c. 15 February 1999: * Modifed mri_render.c to change the way it deals with color volumes. * Modified plug_render.c to allow for color overlays. * Modified xim.c and display.c to deal with converting a RGB image to an XImage in a more efficient way. 16 February 1999: * Modified bbox.[ch] to allow non-power-of-10 steps in an arrowval, if the av->fstep structure component is modified by the user. * Some minor cosmetic changes to plug_render.c. 18 February 1999: * In plug_render.c: + Replaced 'Remove Isolas' with 'Remove Small Clusters' in plug_render.c; + Added the slant cut planes. * In imseq.c, made it so that closing a rowgraph or surfgraph window turns off the feature. 22 February 1999: * New routine "addto_args" (addto_args.c) used to catenate stdin to the (argc,argv) command line of a program. Testbed is 3dRegAna.c (for D. Emge). * Added "LOCK_ZORDER" command to plug_realtime (for Vinai). * Fixed some bugs in plug_render.c having to do with the "Expr > 0" cutout: + Combination with AND was incorrect (counted ncdone too many times); + Test for evaluation to a pure number was incorrect if there were any leading blanks. 23 February 1999: * Fixed a bug in thd_trusthost.c. 25 Feb 1999: * Added the MEDIAN function to parser.f and 3dcalc.c. 01 Mar 1999: * Added the *_p2t, *_t2p, and *_t2z functions to parser.f, parser_int.c, and 3dcalc.c. * Created ASCII PPM file gmove.ppmap to use in gmovie csh script. * Removed tapering from FFT interpolation in thd_rot3d.c. 03 Mar 1999: * Modified thd_sarr.c to skip the realpath() expansion if the environment variable AFNI_NOREALPATH is set. 06 Mar 1999: * Removed GNU malloc from afni.c and incorporated my own mcw_malloc.[ch] functions/macros. 08 Mar 1999: * More changes to mcw_malloc.[ch]. * Added macro FREE_AV() to bbox.h, because I found out that all the places where I used XtFree() on an arrowval would leave the string values (sval) high and dry. 09 Mar 1999: * In refit_MCW_optmenu (bbox.c), found I had to free the av->sval and ->old_sval values, since they were being abandoned. * Added AFNI_NO_MCW_MALLOC environment variable to mcw_malloc.c, to let user turn off these routines. 10 Mar 1999: * In afni_graph.c, added deletion of XImage after XGetImage is used to save the graph window to a file. 12 Mar 1999: * Fixed 2 bugs in plug_render.c: - opacity_scale changed wasn't checked if number of cutouts == 0 - didn't invalidate overlay when loading new functional dataset 22 Mar 1999: * Added SOLARIS_DIRENT_PATCH code to mcw_glob.c. 23 Mar 1999: * Added call to reload_DC_colordef in imseq.c so that Save:one works properly after palette adjustment. 26 Mar 1999: * Added a FREE_VOLUMES to plug_render.c after a new anatomical sub-brick is selected. 29 Mar 1999: * Modified afni_receive.c and other places to allow for multiple receivers for an IM3D. * Modified plug_render.c to auto-redraw when it receives notice of a crosshair location move. 30 Mar 1999: 31 Mar 1999: * Modified afni_receive.c to allow for new types of transmission: DRAWNOTICE = notification that something was drawn DSETCHANGE = notification that dataset pointers may have changed (needed when rescanning sessions) * afni_receive.c now handles transmission to all the interested viewers using the AFNI_process_* routines within. * Modified plug_drawdset.c to properly recover when rescan is used. * Modified plug_render.c to redraw when DRAWNOTICE is received, and to recover when rescan is used. * Modified 3dcalc.c to scale each output sub-brick to shorts/bytes separately, rather than globally [per request of KMD]. 01 April 1999: [hope this isn't an unlucky date!] * Finally centralized the computation of the "[A]" type labels for AFNI controllers in afni_func.c, in the new routine AFNI_controller_label(im3d). Then modified afni_plugin.c, afni_widg.c, plug_render.c, plug_drawdset.c, and plug_tag.c to use this function. 02 April 1999: * Modified thd_http.c to use directory $TMPDIR if defined, rather than always rely on /tmp. * Also added routines to this file to allow transfer of "ftp://" URLs -- this is done using a shell script running the ftp program. 03 April 1999: * Modified plug_render.c to have the currently active dataset "selected" when the user popups a new dataset chooser. * Removed the non-working rotation feature from 3ddup.c. 05 April 1999: * Modified thd_http.c to allow change of user ident for ftp:// access to files. * Tested AFNI with LessTif v.0.89 -- seems to work. 13 April 1999: * Modified mri_read.c to allow 3D: hglobal to be < -1 as long as hglobal+himage >= 0 [per Gary Strangman of MGH]. * Added mri_cut.c, function to cut out a sub-image. 14 April 1999: * Modified afni.c to fix the pbar_sgn_* initialization, since it incorrectly checked the thresholds against the range 0..1 rather than -1..1 [per Chad Moritz of UW Madison]. 15 April 1999: * Modified mri_read.c to also try ppm from mri_read() function. * Modified mri_write.c to write byte files as pgm. * Modified mri_to_rgb.c to have a 1 rgb image -> 3 byte image function, and fixed a bug in the 3 images -> 1 rgb image function. * Added mri_dup.c, to upsample a 2D image; added program imupsam.c to do this function from the command line. 19 April 1999 * Modified afni.c, afni.h, afni_widg.c to add "Set All" button to Lock menu. 26 April 1999: * Fixed thd_info.c to report dataset axes dimensions correctly (also fixed DAXES_NUM macro in 3ddata.h). * Put code in plug_render.c that allows non-axial datasets to be rendered -- but disabled it for now. * New program 3daxialize.c will rewrite a dataset with BRIKs into the RAI (axial) orientation. 28 April 1999: * In 3daxialize.c, made sure that the slice-wise time offsets are nulled out. 27 May 1999: * Added an X defaults initializer for the graph ggap. 30 May 1999: * Added a variable polort order to afni.c, afni.h, afni_graph.c, and afni_fimmer.c. * Discovered a bug in afni_pcor.c in the % Change calculation, where the last ort wasn't being used in the baseline estimation. 02 June 1999: * Modified plug_render.c to draw partial crosshair sets like the image viewers. * Modified afni.c to send a "process viewpoint" message when the partial crosshair status changes, so that the renderer will get a notice and be able to redraw itself promptly. * Modified plug_realtime.c to use polort. * Added ability to change FIM background threshold percent (FIM_THR) to afni_graph.[ch], afni.c, afni_fimmer.c, and plug_realtime.c 03 June 1999: * Fixed thd_info.c where it refered to brick labels that might not exist -- now it uses the DSET_BRICK_LAB macro, which always works. * Fixed plug_realtime.c to add brick labels to the FIM dataset. 04 June 1999: * Added ***ENVIRONMENT section to .afnirc file processing: changes to afni_setup.c, and to afni.c to have environment variables setup before other things. * Made AFNI_load_defaults() in afni.c look at environment variable AFNI_name if X11 resource AFNI*name doesn't exist. 07 June 1999: * Fixed bug in edt_onedset.c that always applied the zscore transformation if possible! * Created afni_environ.[ch], which now process the ***ENVIRONMENT section of .afnirc. Also, in all programs, switched use of getenv() to my_getenv(), which just makes sure that the .afnirc ***ENVIRONMENT has been processed before using getenv(). In this way, the .afnirc setup will be universal. 08 June 1999: * Added MCW_new_idcode() to 3drotate.c -- was producing datasets with identical idcodes, which is terrible! * Added function THD_check_idcodes() [thd_checkidc.c] to allow AFNI to check the idcodes in all datasets for duplicates. 15 June 1999: * Fixed afni_receive.c to return the proper "key" value from function AFNI_receive_init(). * Modifed plug_render.c to redisplay func dataset statistics after receiving a drawing notice. * Modified afni_plugin.[ch] to crosscheck each plugin's compilation date with AFNI's, and print a warning if they differ. 17 June 1999: * Added program 24swap.c. 07 July 1999: * Added program 3dTsmooth.c. * Modified afni_plugin.c to skip date crosscheck on systems that don't have the C function strptime(). * Added -vnorm option to 3dpc.c. 13 July 1999: * Added "Scripts" option to plug_render.c. 14 July 1999: * Modified "Scripts" in plug_render.c to allow save/restore of grafs. Also modified mcw_graf.[ch]. 19 July 1999: * Fixed a bug in 3dcalc.c, where it tested CALC_type[ids] for > 0, whereas it should have been >= 0. The effect was that 3D+time byte valued datasets were not loaded into the atoz array. 29 July 1999: * Fixed afni_graph.c to drop use of XComposeStatus in call to XLookupString, which was causing trouble on SunOS. * Line 2707 of afni_graph.c also had an "==" for assignment, instead of "=". The effect was a possible failure of the x-axis (xax_tsim) graphing mode. I don't think this failure ever occured in practice. 30 July 1999: * Added program float_scan.c and function thd_floatscan.c to check floating point files and arrays (respectively) for illegal values (e.g., NaN and Infinity). Incorporated thd_floatscan() into thd_loaddblk.c (if AFNI_FLOATSCAN is set). 01 Aug 1999: * Changed "Voxel Coords" and "Show Hints" pushbutton on Misc menu to toggle buttons. Modified afni.h, afni_widg.c, and afni_func.c. * Added a "writeownsize" option to the Misc menu, but then changed my mind and #ifdef-ed it out. 02 Aug 1999: * Added the AFNI splash screen; see afni_splash.[ch]. 06 Aug 1999: * Modified afni_plugin.[ch] to allow plugins to set a sequence code, which determines the order in which the plugins appear on the menu. * Received 4 plugins (plug_hemisub, plug_maskcalc, plug_roiedit, plug_maxima) from the estate of Rick Reynolds. 07 Aug 1999: * Added a "[left is left]" or "[left is right]" label to the winfo text in AFNI coronal and axial images displays. Affected files: imseq.[ch], afni.c. * Removed the non-toggle code leftover from the 01 Aug 1999 changes. 08 Aug 1999: * Added the radix-3 routine to csfft.c. 09 Aug 1999: * Added the radix-5 routine to csfft.c. * Modified edt_blur.c, thd_rot3d.c, and plug_power.c to use new FFT abilities. 19 Aug 1999: * Added -indump option to 3dmaskave.c. * Added "Jump to (ijk)" button to image window popup: afni.[ch], afni_widg.c. 23 Aug 1999: * Added 1/N scaling option to csfft.c. Modifed fftcheck.c accordingly. 29 Aug 1999: * Modified count.c to accept a '-scale' option. * Modified Tom Ross's 3dNotes.c software to be a set of routines (thd_notes.c), for eventual use in a plugin. 30 Aug 1999: * Modified afni_fimmer.c to accept an upper limit on the computable percent change. 31 Aug 1999: * Added a History Note feature to thd_notes.c. * Added a routine to afni_plugin.c to produce a command string summary of the inputs to a plugin. * Modified many programs and plugins to write to the History Note. 01 Sep 1999: * Wrote a Notes viewing/editing plugin. 08 Sep 1999: * Modified the error messages in some of the thd_*.c files to be more verbose (Bharat Biswal couldn't understand one). * Modified afni_fimmer.c (and afni.h, afni_graph.c) to allow computation of "% From Ave" = percent change computed from the average instead of from the baseline [per AJ]. 11 Sep 1999: * Got History changes from Doug Ward. 14 Sep 1999: * Added complexscan function to thd_floatscan.c. * thd_loaddblk.c now scans complex inputs for errors, if requested. * to3d.c now scans float and complex input images for errors. * to3d.c now clips out all but a few of the input image files on the command line for the History Note. 15 Sep 1999: * Added -slices option to 3dmaskave.c. * Added default values for i,j,k to 3dcalc.c. * Added thd_makemask.c. * Added -mask option to 3dpc.c. 16 Sep 1999: * Changed THD_open_one_dataset() to THD_open_dataset() in programs 3dFourier.c, 3dROIstats.c, 3dmaskave.c, 3dnvals.c, 3dproject.c, 3dttest.c. * Modified 3dclust.c to use -1dindex and -1tindex, as in 3dmerge.c * Modified 3dTcat.c to have options -rlt+ and -rlt++. 19 Sep 1999: * If dataset header doesn't have BYTEORDER attribute, thd_info.c now prints "{assumed}" next to the reported byte order. * Added hostname to History Note time stamp, so you can see what on what machine a program was run. 20 Sep 1999 * thd_initdblk.c: print out a warning if byte order is unspecified when creating a dataset. * thd_notes.c: add the username to the History Note stamp. 21 Sep 1999 * added message about 3drefit to thd_initdblk.c. * modified MEDIAN function in parser.f to handle N=3 case separately. 24 Sep 1999 * Fixed wcsuffix bugs in afni_graph.c: - didn't mangle output name correctly! - overwrote the end of the wcsuffix string! 28 Sep 1999 * Added environment variable AFNI_PCOR_DENEPS to afni_pcor.c, so that user can set the DENEPS test for the correlation coefficient calculation. 30 Sep 1999 * Added plug_histog.c (histogram plugin) and a histogram plotting routine to afni_plugin.c. 04 Oct 1999 * Added histogram of correlation coefficient to plug_histog.c. 05 Oct 1999 * Fixed bug in mcw_malloc.c, where it printed out the wrong info when it found an overwrite error in a malloc()-ed block of memory. 06 Oct 1999 * Modified plug_histog.c and afni_plugin.[ch] to plot extra curves in histograms. * Modified coxplot/plot_motif.c to look harder for the HOTCOLOR before it gives up and uses the default. 07 Oct 1999 * Modified thd_makemask.c to include a counting function. * Modified plug_histog.c to use THD_makemask() rather than create its own mask the hard way (I just forgot about that routine). * Added program 1deval.c, to evaluate an expression at a bunch of points and write it to disk - the goal is to simplify creation of sample 1D files. 08 Oct 1999 * Increased buffer size in mri_read.c for ASCII file line length. 09 Oct 1999 * Added AFNI_ENFORCE_ASPECT environment variable, to make imseq.c enforce the image aspect ratio - this is to be used when the window manager doesn't do this properly. 13 Oct 1999 * Added program 3dTstat.c to compute the same stuff that plug_stats.c does, but in a batch program. 14 Oct 1999 * Added option -apar to 3drefit.c, to allow (re)setting of the anat parent. * Added option -warp to 3dfractionize.c, to allow inverse warping from +tlrc coords back to +orig coords during the fractionation process. 18 Oct 1999 * Added history copy to afni_func.c's creation of follower datasets. * Added -preserve option to 3dfractionize.c, to allow the output dataset to keep the input values, rather than create a fractional mask. * Added program 3dmaskdump.c, to dump voxel values out to ASCII. * Added qsort_int() to mri_percents.c. 19 Oct 1999 * Added program 1dtranspose.c. * Added option -noijk to 3dmaskdump.c. * Added option -tim to afni.c - also modified afni.h, afni_graph.[ch], and afni_func.c to make it work. This option is like -im, but interprets the images as being spread thru time rather than space. 20 Oct 1999 * Modified -tim in afni.c to allow for 3D inputs (space-then-time=-zim, or time-then-space=-tim). 21 Oct 1999 * Fixed a couple of small bugs in 1deval.c. 28 Oct 1999 * Removed "experimental" message for TrueColor visuals in display.c. * Added csfft_nextup_one35() function to csfft.c. * Modified various programs to use csfft_nextup_one35() in place of csfft_nextup(), for efficiency. * Moved shifting routines from thd_rot3d.c to thd_shift2.c, so that they can be used in other programs. 29 Oct 1999 * Added thd_1Dtodset.c - provides the inverse of thd_dsetto1D.c (inserts a vector into a dataset time series, rather than extracts it). * Add thd_detrend.c - detrend a timeseries and provide mean, slope. 30 Oct 1999 * Modified thd_detrend.c to have linear and quadratic detrending, and an L2 normalizing function. 31 Oct 1999 * Finished program 3dTshift.c - time shifting. 01 Nov 1999 * Modified 3dclust.c and edt_onedset.c to have a -verbose option, so as to print out progress report info. * Added MCW_hotcolor() to xutil.[ch], to get rid of HOTCOLOR macro usage. * Added function PLUTO_set_butcolor() to afni_plugin.[ch], to let plugin set its menu button color. 02 Nov 1999 * Modified 3dcalc.c to fix problem with using sub-brick selectors of the form "-b3 zork+orig" -- if zork+orig was a 3D+time dataset, and it was used as the template for the output, the output would be marked as 3D+time even though it was not. The solution was to mangle such inputs to the form "zork+orig[3]", which already worked fine. 03 Nov 1999 * Fixed the -help output for 3drefit.c, in the description of "-apar". 09 Nov 1999 * Added function RWC_visibilize_widget() to xutil.[ch] - used to ensure that popup widgets are fully onscreen. Used this function in afni_func.c, afni_graph.c, afni_setup.c, bbox.c. * Added missing "void" to declaration of function setup_tmpdir() in thd_http.c. 16 Nov 1999 * Added more -help to 3dTshift.c, per MSB's comments. * Added cubic detrend routine to thd_detrend.c. * Added mri_read_1D() to mri_read.c. This adds the ability to do sub-vector selection, and does the transpose too. * Added mri_write_1D() to mri_write.c. This just does the transpose before called mri_write_ascii(). * Modified 1dtranspose.c, 3dcalc.c, waver.c, afni_graph.c, and model_convgamma*.c to use mri_read_1D(). * Modified afni_graph.c to use mri_write_1D(). * Added program 3dDetrend.c: remove time series trends. * Added predefined 't' and 'l' to 3dcalc.c. 17 Nov 1999 * Removed some -help from imcalc.c, since 3dcalc -help has the same info. * Added function PARSER_1deval() to parser_int.c. * Added environment variable AFNI_MARKERS_NOQUAL to afni.c. * Fixed bug in 3dDetrend when -expr string had no variable symbols. * Modified thd_iochan.c to use SO_REUSEADDR to help close down sockets quickly. (But later commented this code out.) 18 Nov 1999 * Modified cs_addto_args.c to make the mangling of the arglist more flexible. * Used the previous change in afni.c to add the environment variable AFNI_OPTIONS that will always be added to the command line args. * Incorporated the OSF1 changes from Matthew Belmonte. 22 Nov 1999 * Added -histpar option to 3dcalc.c. * Added differential subscripting to 3dcalc.c. * Modified thd_intlist.c to allow for negative list elements. 23 Nov 1999 * Modified 3dcalc.c differential subscripting to allow abbreviations of the form a+j, a-k, etc. * Added -quiet option to 3dmaskave.c. * Added -normalize option to 3dDetrend.c. * Fixed error in afni_func.c (and adwarp.c) when writing out a dataset that was told to have a byte order different from the native order - it was written in native order and the header wouldn't know about that - the result was the file was read in incorrectly later. * Also fixed same error in 3daxialize.c. * Also fixed thd_writedblk.c and thd_loaddblk.c to handle byte swapping on complex data correctly. 24 Nov 1999 * Added program 1dfft.c - to calculate abs(FFT(timeseries)). * Modified 1deval.c to allow input of time series. * Got some 3dDeconvolve.c changes from Doug Ward. 25 Nov 1999 * Added program 1dcat.c - catenate *.1D files. 28 Nov 1999 * Added function ZTONE to parser.f. 29 Nov 1999 * Added -tocx, -fromcx, and -nodetrend options to 1dfft.c. * Modified quadratic detrending calculation in thd_detrend.c. * Added -use option to 1dplot.c. * Added SHOWOFF macro to afni.c, distmake, and Makefile.INCLUDE. * Got some 3dDeconvolve.c fixes from Doug Ward. 30 Nov 1999 * Modified 3dTshift.c to allow "-tzero 0.0" and "-slice 0" as options (I used <= instead of < in the original code). * Modified plug_render.c to reset func_cmap_set=0 if a render handle is destroyed - the colormap wasn't being properly reloaded when a new underlay dataset was selected. * Modified SHOWOFF handling in afni.c to always show compilation date no matter what. 01 Dec 1999 * Modified afni.c and afni_func.c to turn on XSynchronize if -TRACE option is used (or when DBG_trace gets set to 2). * Fixed bug in afni_func.c AFNI_force_adoption() routine: the PRINT_TRACING output after the dataset scan would crash if no dataset was found. * Modified imseq.[ch] and afni.c to set "sides" strings for an image, so that "left=SIDE" can be displayed correctly in any orientation of the image flipping process. 03 Dec 1999 * Print a warning message in afni_func.c when a forced adoption takes place. * Disable "sides" labels if an environment variable is present. * Incorporate "-quiet" options in 3dclust.c and 3dROIstats.c from Mike Beauchamp. * Incorporate sub-dataset selection for various statistical programs from Doug Ward. 07 Dec 1999 * Added program 3drename.c, to rename dataset .HEAD and .BRIK files at the same time. * Added environment variable to control Winsor21 function in imseq.c. 08 Dec 1999 * Oops. Took out some debugging statements in 3dTstat.c that somehow survived until now. * Modified count of forced adoption potential conflicts in afni_func.c to avoid some warning messages. * Added "NULL" to return in plug_tag.c, where it had been forgotten. * Added program 1dnorm.c. * Added -byslice option to 3dDetrend.c. 09 Dec 1999 * Added -hilbert option to 1dfft.c, and -install option to 1dplot.c * Added 0 definition of DBG_trace to dbtrace.h in the case USE_TRACING is not defined. 13 Dec 1999 * Added mode functions to parser.f, parser.inc, and 3dcalc.c. * Added -force option to adwarp.c; otherwise, program will not now overwrite existing dataset. * Modified function qginv() in mri_stats.c to never return a value greater than 13, no matter how absurd the value the user enters. * Modified edt_dsetitems.c, editvol.h to have a new editing item: ADN_anatpar_idcode - to let a program attach an anat parent idcode to a file (vs. an anat parent dataset). * Modified afni_func.c to NOT print out a forced adoption message when a dataset is set to be its own anatomy parent. * Modified plug_maskave.c to properly initialize sum=sigma=0 for EACH separate sub-brick calculation. 14 Dec 1999 * Modified edt_emptycopy.c, editvol.h, and afni_plugin.c to have newly created datasets get assigned the same anatomy parent as their progenitors. * Modified afni.c so that manually warped datasets become their own anat parents. * Modified 3drefit.c to allow SELF and NULL to be valid arguments to the -apar option. 20 Dec 1999 * Modified parser.f to remove the possibility of divison by zero in the expression evaluation routines. * Modified display.[ch] and plug_render.c to allow 'non-mixing' of colors displayed from rendering results. 21 Dec 1999 * Modified plug_render.c to put the 'non-mixing' stuff into a separate menu on the 'Color' popup. * Took 3dROIstats.c mods from Mike Beauchamp for the -summary option. 03 Jan 2000 * Modified 3ddata.h to increase maximum number of datasets per directory to 512 anats and funcs (each), and max number of directorys to 80. * Modified afni.h, afni_fimmer.c, afni_pcor.c, and afni_graph.c to add "% From Top" option to FIM menus. 04 Jan 2000 * Added gran(m,s) function to parser.f and 3dcalc.c. * Added "Set All" and "Set Defaults" buttons to FIM+ menu in afni_graph.[ch]. * Removed contents of file README.changes. * Abbreviated "Cannot find ..." error messages in thd_reconpar.c. * Added total dataset count report to afni.c input routine. 05 Jan 2000 * Changed default AFNI_SPLASHTIME to 1.0 seconds in afni.c. * Added "static" to mixshade menu strings in plug_render.c. * Added MCHECK to DBG_SIGNALS in dbtrace.h. * Added routine mri_write_raw() to mri_write.c. * Modified from3d.c to have -raw and -float options. 07 Jan 2000 * Modified plug_render.c to allow ShowThru color overlays: by doing two renderings - underlay and overlay separately - and then compositing the two images afterwards. 10 Jan 2000 * Modified plug_render.c to add AFNI_RENDER_SHOWTHRU_FAC variable to control the compositing of ShowThru images. * Added program afni_vcheck.c, to check the AFNI version against the master copy back at the central AFNI web site. 11 Jan 2000 * Replace "New Stuff" button under the Misc menu with "Version Check", which just runs afni_vcheck and puts the output into a popup. * Modified plug_render.c to make Cutout Overlay work properly with ShowThru. 13 Jan 2000 * Added plug_scatplot.c - scatter plotting. Added PLUTO_scatterplot() function to afni_plugin.[ch]. * Fixed error in setup of Range choosers in plug_histog.c - they were initialized to incorrect values. 19 Jan 2000 * Modified to3d.c to count and report number of negative voxels when the input images are shorts - this is to provide a check for the need for byte-swapping. 20 Jan 2000 * Also added a popup error message when floating point errors are detected in inputs to to3d.c * Added "1xN" pattern to 24swap.c to allow for nonswapped data. 24 Jan 2000 * Fixed error in -mask[n] option processing in 3dROIstats.c - that fiend Tom Ross used argv[narg] instead of argv[narg-1] to check for the presence of the "n" option. 27 Jan 2000 * Modified thd_sarr.c and thd_get1D.c to speed up (hopefully) reading of *.1D files. * Modified afni.[ch] to allow use of "-no1D" option to skip reading of *.1D files from the dataset directories. 28 Jan 2000 * Modified coxplot/plot_x11.c to skip use of XDBE if AFNI_NO_XDBE environment variable is set. 01 Feb 2000 * Added file afni_fimfunc.c, which lets the "user" add a function to the FIM+ menu. The Spearman rank correlation is included as a sample. Also included small changes to afni.[ch], afni_graph.[ch], and a large-ish addition to afni_fimmer.c. * Removed useless "break" statements in afni_graph.c that produced some annoying "unreachable code" compilation warnings. Also modified bbox.c bbox and arrowval utility routines to check if the input items are NULL before accessing them. 02 Feb 2000 * Modified 3dvolreg.c to make it not print out the -help stuff when argc==2. * Added uran() function to parser. 03 Feb 2000 * Modified GRAN() random number generator in parser.f to make it be less obviously periodic. 04 Feb 2000 * Added IRAN() integer deviate, ERAN() exponential deviate, and LRAN logistic deviate generators to parser.f * Added THD_extract_many_series() function, and used in to speed up the fimfunc work in afni_fimmer.c. * Fixed error in 3dbuc2fim.c, where stat_aux array was not malloc()-ed large enough for the EDIT_dset_items() routine usage. 06 Feb 2000 * Added mcw_malloc_sizeof() to mcw_malloc.[ch], to return the size of of a malloc()-ed region, if possible. * Added TRUNCATE_IMARR() macro to mrilib.h. 10 Feb 2000 * Added 3A.: image formats to allow input of unstructured ASCII files into AFNI programs. Routines changed in mri_read.c and mcw_glob.c. 14 Feb 2000 * Added -median and -MAD options to 3dTstat.c (but not to plug_stats.c). 29 Feb 2000 * Revived the program 3ddot.c and added masking options. 02 Mar 2000 * Added plug_nudge.c to move dataset origins around. * Added -dxorigin (etc.) option to 3drefit.c. 06 Mar 2000 * Added -sagittal, -coronal switches to 3daxialize.c. 07 Mar 2000 * Modified plug_realtime.c, to reject nzz=1 datasets, print out better error messages, etc. * Modified rtfeedme.c to have -nzfake option, for testing the above. * Modified jp_afni.c to get orientations correct for Signa realtime. 08 Mar 2000 * Added sync() to plug_realtime.c after writing datasets. 15 Mar 2000 * Added AFNI_VIEW_ANAT_BRICK and AFNI_VIEW_FUNC_BRICK environment variables to afni.c to force switching back to "view brick" mode when switching datasets. * Added "{warp}" string to titlebar when "Warp Anat on Demand" mode is engaged. 16 Mar 2000 * Added -cmask option to 3dmaskdump.c (via new file edt_calcmask.c). 04 Apr 2000 * Added thd_base64.c routines for dealing with BASE64 encodings. 07 Apr 2000 * Included 3dWavelets code from Doug Ward. 11 Apr 2000 * Fixed bug in 3drotate.c when input was a master-ed file. Also added -clipit option to 3drotate.c. * Fixed bug in parser_int.c where stdlib.h wasn't included before drand48() was called. * Added AFNI_GRAYSCALE_BOT to display.c. 12 Apr 2000 * Added AFNI_SYSTEM_AFNIRC environment variable, to allow introduction of a system wide .afnirc file. * Added the ability to change datasets in the renderer from script files (using the saved ID code string). Also, made the threshold slider change when the script changes the threshold value (forgot this visual detail before). 14 Apr 2000 * Added options -1Dfile to 3dvolreg.c and plug_volreg.c to save movement parameters to a 1D file for later ortologizing. 16 Apr 2000 * Oops. Added AFNI_SYSTEM_AFNIRC stuff to afni_environ.[ch] as well. 18 Apr 2000 * Rewrote plug_nudge.c to do rotations and shifts. * Added mri_copy.c. 21 April 2000 * Fixed bug in qsort_floatfloat (cs_sort_ff.c). * First version of plug_betafit.c. 28 April 2000 * Modified plug_realtime.c (and afni_plugin.[ch]) to do "Image Only" realtime acquisition - just show the images, don't do anything else. 01 May 2000 * Modified afni_widg.c to disable Datamode->Misc->Version Check if in realtime mode (due to long hang time while master version web page is fetched across the network). * Added program 3dfim+.c from Doug Ward. 09 May 2000 * Added program imcutup.c and function mri_uncat2D.c to break 2D images up into pieces. 10 May 2000 * Modified afni_fimmer.c to print out an error message if nvox is zero. This happens if the FIM Bkg Thresh is too high. Also modified afni.c to allow this value to be initialize to 0 (before, 1% was the minimum). 12 May 2000 * Incorporated NLfim changes from Doug Ward, to include calculation of R**2, per my request. 18 May 2000 * Add plug_second_dataset.c and code in afni_graph.c to use it - a "1D function" that returns the time series from another dataset, for example to plot the -snfit output of 3dNLfim on top of the original dataset. 19 May 2000 * Added changes from Doug Ward for a "-mask" option to 3dNLfim.c. 22 May 2000 * Added AFNI_USE_THD_open_dataset environment variable to allow THD_open_one_dataset (in thd_opendset.c) to call THD_open_dataset instead (in thd_mastery.c), if a "[" is also present in the dataset pathname. !!! This feature must be used with care, since some programs !!! !!! (e.g., 3dbucket) will break if it is used. A program that !!! !!! writes to a pre-existing dataset MUST NOT open that dataset !!! !!! with a sub-brick selector list. !!! 23 May 2000 * Modified thd_idcode.c to use lowercase in dataset IDcodes. 08 Jun 2000 * Added new picture to splash screen (the MCW gang). Also, added AFNI_IMAGE_PGMFILE environment variable to afni_splash.c 15 Jun 2000 * Added option "-nscale" to 3dcalc.c [that damn Tom Ross again]. * Added an SCO Makefile [from Jason Bacon] and a couple of patches to go with it. * Added "Save to PPM" button to color pbar popup menus, to let the user save a representation of the color overlay scheme. * Fixed check_pixmap in pbar.c to be correct in TrueColor. * Added "Tran 0D" to color pbar popup for AFNI controllers (but not for the rendering plugin). 16 Jun 2000 * Added "Tran 2D" to color pbar popup for AFNI controllers. * Fixed "Save to PPM" to save a check pattern for the "none" color. 19 Jun 2000 * Added ability to set initial string in a "user-typein" string field in PLUTO_add_string(). * Created plug_environ.c. 30 Jun 2000 * Moved plug_environ.c into main afni, on the Misc menu. Modified places where environment variables are used to allow this "Edit Environment" feature to work. * Added "|FFT()|" 1D function to afni.c. * Created program Xphace.c. 03 Jul 2000 * Added 2DChain pseudoplugin. 11 Jul 2000 * Added program 3dZeropad.c. 12 Jul 2000 * Added Left-Right mirror option to afni_graph.[ch] and afni.c to make graph pixel layout correspond to images if left-is-left. 17 Jul 2000 * Added new program 3dTagalign.c. * Fixed a bug in the "Write" callback in plug_tag.c. 20 Jul 2000 * Modified 3dTagalign.c to write matrix+vector to a file and to the output dataset header. * Modified 3drotate.c to read matrix+vector of transformation from a file or from a dataset header. 21 Jul 2000 * Added AFNI_ENFORCE_ASPECT to afni_pplug_env.c. * Added AFNI_IMAGE_PGMFILE_[1-9] to afni_splash.c. 08 Aug 2000 * Used thd_floatscan() to check/fix possible float errors from user functions (in the thd_make*.c functions and in afni_fimmer.c). Was prompted by errors produced in Ziad Saad's Hilbert plugin. 09 Aug 2000 * Modified thd_floatscan.c to use finitef() on Linux. * Modified 3dcalc.c to use thd_floatscan() to check results. * Modified 3dmerge.c to have -1fmask option to restrict filtering, and -1filter_expr option to do arbitrary linear filtering. (Also changed editvol.h, edt_checkargv.c, edt_filtervol.c, and edt_onedset.c) 22 Aug 2000 * Added 'To Disk?' option to plug_maskave.c for the 'doall' case. 24 Aug 2000 * Modified most places where SESSTRAIL is used to use SESSTRAIL+1, so that when filenames are shown, they show all the directories that are shown in the "Switch Session" dialog. [Per the suggestion of Florian Hauch, Munich.] * Also modified afni_pplug_env.c to enable AFNI_SESSTRAIL to be controlled interactively, and to have it modify the window titles and session lastnames when AFNI_SESSTRAIL is altered. 01 Sep 2000 * Incorporated changes from Ziad Saad to the Hilbert delay plugin. * Modified plug_nudge.c to output a 3drotate command line to stderr when the feeble user presses the new 'Print' button. * Added call to AFNI_imseq_clearstat() to afni_plugin.c function PLUTO_dset_redisplay(). 04 Sep 2000 * Added -rotcom output to 3dvolreg.c (and hidden -linear option). * Modified -verbose output of mri_3dalign.c. 11 Sep 2000 * Added -dxyz=1 option to edt_*.c, to allow clustering and filtering in 3dmerge.c to use fake values of dx=dy=dz=1. * Added -1filter_winsor to 3dmerge.c and edt_filtervol.c. * Added "IJK lock" to afni.[ch] and afni_widg.c (Lock menu). * Added -twopass option to 3dvolreg.c. 13 Sep 2000 * Finalized -twopass changes to 3dvolreg.c. * Add -duporigin option to 3drefit.c. 14 Sep 2000 * Added check of grid spacings to 3dvolreg.c 15 Sep 2000 * Added -nscale option to 3dmerge.c 21 Sep 2000 * Added 32 to mri_nsize.c. * Added AFNI_SPLASH_XY to afni_splash.c. 22 Sep 2000 * Added isqDR_setifrac and isqDR_setmontage to imseq.c. * Added graDR_setmatrix, graDR_setgrid, and graDR_setpinnum to afni_graph.c. * Added PLUTO_set_topshell() to afni_plugin.c, and made several PLUGIN_CALL_IMMEDIATELY plugins use this to set the toplevel shell for later AFNI manipulation. * Modified afni_graph.[ch] to allow a graph window to be opened for a dataset of length 1. * Added textgraph mode to afni_graph.c, and also changed the baseline pushbutton to a toggle. 25 Sep 2000 * Added -layout option to allow user to control initial window setup. Most changes in afni_splash.c, but also in afni.c, afni_widg.c, afni.h, etc. * Modified imseq.c to detect Expose events that have resized the image display window -- this happens sometimes when using -layout. 27 Sep 2000 * Program xiner.c writes out Xinerama info about the display, if it is available. This can be used to generate an X11 resource AFNI.xinerama. * If AFNI.xinerama is detected, then new routine RWC_xineramize (in xutil.c) can be used to adjust location of a rectangle to be sure it fits on a sub-screen. Older routine RWC_visibilize_widget now uses this. New callback RWC_visibilize_CB can be used to make sure menus pop up entirely on one sub-screen. * Many places now use visibilize to make sure dialogs and menus pop up on 1 sub-screen. See, for example, all uses of the function RWC_visibilize_widget() and the macro VISIBILIZE_WHEN_MAPPED(). 29 Sep 2000 * Modified afni_graph.[ch] to move FIM and Opt menus onto private menubars. (Got rid of grapher->option_mbar everywhere.) * Also put a Form inbetween the afni_graph shell and the drawing area. The option_rowcol that holds all the menu buttons is now a child of the Form, not the drawing area. This makes it possible to popup the menus with Button3 (the Button3 popup on the drawing area interfered with this). 01 Oct 2000 * Wrote program 3dUndump.c (create a dataset from an ASCII list of voxels, like an inverse to 3dmaskdump.c). 04 Oct 2000 * Put most of the work of 3dZeropad.c into function thd_zeropad.c instead. * Added plug_zeropad.c. 09 Oct 2000 * Enabled startup of RT plugin, and control of all options, via environment variables AFNI_REALTIME_Something. * Modified PLUTO_string_index() in afni_plugin.c to ignore blanks and case. 11 Oct 2000 * Replaced XtAppAddWorkProcess in afni.c with PLUTO_register_workproc, since on Mandrake 7.01, dual P-III, XFree86 4.01 system, the realtime plugin workprocess doesn't start properly (some interaction with the startup workprocess, which does not occur on other systems). * Modified afni_splash.c to change controller crosshairs to Single mode if montage spacing is 1. * Modified afni_graph.c to change grid when program alters pin_num (but not when user does directly). * Modifed plug_realtime.c to start work process after a timeout. * Added PLUTO_register_timeout() afni_plugin.[ch], to execute a function after a given number of ms. 12 Oct 2000 * Modified afni_graph.c to redraw with autoscale when matrix or length is changed by an external (isqDR_) command (not by the user directly). * Modified coxplot/plot_motif.c to get initial geometry of graph shell from an environment variable. * Minor changes to plug_realtime.c to make various things nicer. 13 Oct 2000 * Modified plug_realtime.c to insert its own Xt event loop to deal with interface-freeze when the images are being slammed in as fast as possible (function RT_process_xevents). 16 Oct 2000 * Modified fftest.c to allow use of FFTW; do "make fftwest" and run with nvec = -1. 20 Nov 2000 * Fixed bug in -rlt+ option of 3dTcat.c: qmid was 0.5*ns, but should have been 0.5*(ns-1). This makes the baseline wrong in each voxel. 24 Nov 2000 * Modified plug_render.c to eliminate duplicate rendering of datasets when loading a script that changes dataset index. This was caused by the dataset index CB routine calling draw, and then the script controller calling draw again. Now, the routine that loads the widgets from the rendering state sets a variable that stops drawing if it should occur, then unsets this variable after widgets are loaded. * Modified 3drotate.c to have new -points option, to rotate a set of (x,y,z) triples using the same rotation as would be used for a dataset brick. * Modified 3dUndump.c to check (x,y,z) coordinates for validity. 27 Nov 2000 * Modified plug_nudge.c to reload sub-brick statistic after moving it. 28 Nov 2000 * Modified AFNI_plugin_button() in afni_plugin.c to allow user to have plugin buttons sorted alphabetically. * Fixed bug in plug_nudge.c where the interpolation mode was set improperly. 01 Dec 2000 * Included Vinai Roopchansingh's modified plug_copy.c; this version allows the user to change the datum type, when doing a zero fill. * Added the "License Info" button to the Datamode->Misc menu. 05 Dec 2000 * Included Vinai Roopchansingh's modified 3dhistog.c; this version adds the "-mask" option. * Fixed a bug in the PICTURE_ON/OFF macro (afni.h) so that it is only meaningful for dataset viewing (not for the -im case). 06 Dec 2000 * Modified afni_pcor.c routine PCOR_get_perc to zero out the results if the last reference has no range (previously, it only zeroed out the coef[] array, not bline[]). * Added GPL/MCW Copyright notices to many many *.[ch] files. 09 Dec 2000 * Modified 3dNotes.c and thd_notes.c to allow user to replace the History note, rather than just append to it. * Modified 3dvolreg.c to make the -twopass feature more robust for registering SPGR images. Changes included a coarse grid search for an initial shift, and fading out the weights along the edges. ================================================= == All changes from here on were made at the NIH == ================================================= 23 Jan 2001 * Modified afni.c MAIN_workprocess() function to exit properly when the "nodown" variable is set. Before, if a layout was set, then the layout code did the splashdown, and then the MAIN_workprocess() never signaled that it was done. * Modified thd_trusthost.c to use "192.168." as the prefix for Class B subnets, rather than "192.168.0.". * Modified mrilib.h to change my e-mail address macro. 24 Jan 2001 * Modified 3dclust.c to use '-dxyz=1' option. * Modified afni.c so that graphs of anat buckets interact correctly when the anat bucket chooser is changed, or the graph "time index" is set. 25 Jan 2001 * Modified mcw_malloc.c to use a hash table instead of a linear table. This speeds things up a lot. Also added a serial number to each allocation, to help in identifying the order -- the dump is now sorted by serial number. * Incorporated Matthew Belmonte's codes plug_threshold.c and plug_permtest.c into the system. 26 Jan 2001 * Converted dbtrace.h to debugtrace.c and debugtrace.h. This is the start of an effort to incorporate traceback into all AFNI and mrilib functions. As part of this, removed THD_DEBUG stuff from all library functions. 29 Jan 2001 * Added DEBUGTHISFILE macro to debugtrace.h, and used it in thd_shear3d.c. * Modified 3drotate.c so that input of something like -ashift 10R 0 0 won't have the 0s clobber the 10R; 0s with no direction code suffix will now be skipped in the computation of the dataset-coordinate shift. * Added a few words to README.copyright, and added a Q/A about it to the FAQ. * Added new program 3dMean.c. 31 Jan 2001 * Modified thd_zeropad.c to keep the slice-dependent time shifts (toff_sl) when adding/removing slices in the z-direction. 01 Feb 2001 * Modified thd_info.c to print dataset center (in addition to box edges). * Added thd_center.c (dataset center vector) and thd_mismatch.c (check if 2 datasets are matched for voxel-wise comparisons). * Added program 3dAttribute.c, for printing out values of attributes from dataset header files (for use in scripts). 02 Feb 2001 * Added function NIH_volpad (edt_volpad.c) to do zeropadding on 3D arrays - adapted from thd_zeropad.c. * Added THD_rota_setpad to thd_rot3d.c to set zeropadding amount for rotations. 05 Feb 2001 * Added mayo_analyze.h to define the structure of an ANALYZE 7.5 .hdr file, and then added mri_read_analyze75() to mri_read.c. * Modified to3d.c to use image dimensions if they are set from the image file (as is possible with ANALYZE .hdr files, for example). * Modified mri_new.c to set dw=-666 as a flag that the d? variables defaults of 1.0 haven't been changed. * Modified thd_rot3d.c to allow setting of zeropad amount via environment variable AFNI_ROTA_ZPAD. * Modified 3drotate.c and 3dvolreg.c to use new command line option "-zpad n". * Modified to3d.c to use -zpad option to add zero slices in the z-direction. Also added attribute to header (TO3D_ZPAD) to mark this fact. When such a dataset is used with -geomparent, then it's zero padding will be subtracted off when setting the new dataset's origin. * Modified 3dAttribute.c to have '-all' and '-name' options. 06 Feb 2001 * Modified vecmat.h to have separate types and macros for float and double vectors/matrices. Modified all places that used the old "FLOAT_TYPE double" method to use the new types/macros (mostly the 3D rotation codes). * Modified 3dvolreg.c to write rotation parameters, matrices, etc. to the header of the output dataset. 07 Feb 2001 * Modified 3dZeropad.c to have '-z' option to add slices (evenly) in the dataset z-axis (slice) direction. * Modified 3drotate.c to deal with -rotparent and -gridparent options. 08 Feb 2001 * Debugged several stupid errors in 3drotate.c changes of yesterday. * Implemented program cat_matvec.c to catenate matrix+vector transformations. * File thd_read_matvec.c reads a matrix+vector (THD_dvecmat; cf. vecmat.h) from a file, or from a dataset attribute. 12 Feb 2001 * Modified edt_volpad.c to allow for unsymmetric padding. * Modified thd_zeropad.c to allow for producing an empty copy of the zero-padded dataset (so that you have to fill it up later). * Modified 3drotate.c and 3dvolreg.c to adjust the time-offset z-origin when the new dataset axes z-origin is adjusted. * Added a rint() function to mri_free.c (why there? why not?) if NO_RINT is defined in machdep.h -- that way I don't have to worry about it. * Modified 3drotate.c to shift time-offsets when the dz is large enough to warrant it. * Modified 3drefit.c to add new "-notoff" option, to reset time-offsets to zero. * Modified to3d.c to include "AFNI" in fallback resources, per the suggestion of J Bacon of MCW (copying what AFNI itself does). 13 Feb 2001 * Modified thd_shear3d.c function rot_to_shear_matvec() to modify the input matrix to make sure it is orthogonal (using the transpose of DMAT_svdrot(q) as the orthogonal matrix closest to q). User-input matrices may not be precisely orthogonal, which leads to problems in the shear calculation. Ugh. Squared. * Added function THD_rotcom_to_matvec() to thd_rotangles.c -- this computes the matrix/vector of a transformation, given the "-rotate .. -ashift .." string. * Modified thd_zeropad.c (and 3dZeropad.c) so that padding can be specified in mm instead of slices. 14 Feb 2001 * Modified 3dvolreg.c to include -rotparent/-gridparent options, a la 3drotate.c. * Edited edt_volpad.c to include new function MRI_zeropad(). * Modified thd_read_vecmat.c to include "-rotate ..." input option. * Added new function THD_rota3D_matvec() to thd_rot3d.c. * Added multiply and inverse macros for double vecmats to vecmat.h * Moved function DBLE_mat_to_dicomm() from 3drotate.c to thd_rotangles.c. * Replaced all copies of axcode() and handedness() with the library calls to THD_axcode() and THD_handedness() in thd_rotangles.c (changes to 3drotate.c, 3dvolreg.c, plug_nudge.c, plug_realtime.c, and plug_volreg.c). 15 Feb 2001 * Added thd_tshift.c, which does what 3dTshift.c does (in place). * Used this to add -tshift option to 3dvolreg.c. * Also added -ignore option to 3dTshift.c. 16 Feb 2001 * Added traceback information to mcw_malloc.c. * Added program 3dOverlap.c. * Added function THD_newprefix() in thd_newprefix.c. 20 Feb 2001 * Added EXIT and TRACEBACK macros to debugtrace.h. 21 Feb 2001 * Modified afni.c to disable use of mmap() from malloc() on Linux (malloc() would fail when memory was still available!). * Modified thd_mastery.c to force dset[] inputs to be relabeled as bucket types if they are not time-dependent. This is to prevent interpretation as fico, etc. * Modified 3dmerge.c to allow use of sub-brick selectors on input datasets. * Modified thd_trusthost.c to make it easier to add hosts by name or by number, using a new function TRUST_addhost(). * Added function PLUTO_turnoff_options() to afni_plugin.c; used this in plug_realtime.c to turn off all input options after processing. * Added AFNI_TRUSTHOST to afni_pplug_env.c so that user can add trusted hosts (for plugins/plugouts) interactively. * Modified thd_mastery.c and thd_loaddblk.c to allow for sub-ranging on dataset input, using the syntax on the command line. 22 Feb 2001 * Added program 3dClipLevel.c to estimate the cutoff value to excise background regions from anatomical datasets (especially EPI). * Added AFNI_CWD variable to afni_pplug_env.c, to let user change working directory (where output files like "Save:One" go). * Modified 3dOverlap.c to optionally save counts to a new dataset. * Fixed thd_mastery.c so that works properly (<= vs. <). 26 Feb 2001 * Modified plot_cox.c to allow copying, rescaling, and appending of vector plots, and plot_x11.c to allow setting rendering to a sub-box of the window (rather than the whole window). * Modified imseq.[ch] to allow fetching of a vector plot to be rendered into the window. * Modified afni_splash.c to draw "friends" stuff into the splash screen (after the first popup). * Added function mri_zeropad_2D() in mri_zeropad.c. Changed name of MRI_zeropad() to mri_zeropad_3D() in edt_volpad.c. 27 Feb 2001 * Added macro SAVEUNDERIZE() to xutil.h, and used it to make popup menus have the SaveUnder property in imseq.c, afni_graph.c, afni_widg.c, and plug_render.c. * Modified imseq.c to use AFNI_IMAGE_MINFRAC environment variable to set minimum size for image windows. Also added this to the variables that can be controlled by afni_pplug_env.c. * Added fields does_saveunders and does_backingstore to display.[hc] (but don't use them anywhere - yet). * Modified thd_mismatch.c to do MISMATCH_DELTA only if voxel sizes differ by at least a factor of 0.001 (rather than perfect ==). Also fixed a typobug where the datasets would always compare as identical. * Modified 3dvolreg.c to fail if stupid users try to register dataset to base that doesn't match. 28 Feb 2001 * New program 3dZregrid.c is for resampling a dataset along the slice- direction to change the grid spacing, etc. Mostly intended to fixup user stupidities (e.g., not acquiring data on the same subject using the same slice thickness; d'oh!). * Modified thd_filestuff.c to remove '/' from THD_filename_ok() function. This lets the "-prefix" option of 3d* programs put the output dataset into a new directory. New function THD_filename_pure() also checks for the '/'. 29 Feb 2001 * Modified thd_initdkptr.c to properly treat directory components stored in prefixname. [Ugh] 01 Mar 2001 * Added "Max Count" input to plug_histog.c. * Fixed incorrect error message for "-nrep" option in 3dWinsor.c. * Added -blackman and -hamming options to 3dTsmooth.c [per MSB]. 02 Mar 2001 * Added thd_entropy16.c to compute entropy (bits/short) of a dataset. * Used entropy to force gzip of highly redundant datasets in thd_writedblk.c -- if AFNI_AUTOGZIP is on. * Modified afni_environ.c so that yesenv() and noenv() use my_getenv(). * Modified afni_pplug_env.c to include AFNI_AUTOGZIP. * Modified afni.c to put DBG_trace= statements inside #ifdef USE_TRACING. * Modified 3dZeropad.c to not overwrite existing datasets [Oopsie squared]. * Modified 3dmerge.c to print warning message for default indexes (if -1dindex and/or -1tindex is not used). * Added 3ddelay.c from Ziad Saad. 03 Mar 2001 * Modified 3dTsmooth (yet again) to allow for different options for dealing with points past the beginning and end of time. 04 Mar 2001 * New program ent16.c computes 16-bit entropy of stdin stream. Can be used in a script to decide when to gzip datasets. 05 Mar 2001 * Modified Ziad Saad's plug_delay_V2.h to use remainder() instead of drem() for Solaris, since Solaris doesn't have that BSD function for some stupid SysV reason. 06 Mar 2001 * Modified display.[ch] to store RGB bytes for the underlay and overlay colors in the MCW_DC structure. This is preparation for allowing direct RGB overlays into imseq.c. * Modified mri_new.c (and mcw_glob.c) to allow use of the special filename ALLZERO in 3D: input. This will make it simple to create an empty dataset using to3d, for example. * Added -min and -max options to 3dTstat.c. * Modified 3dClipLevel.c to use all sub-bricks instead of just the first. * Added function ISQ_overlay() into imseq.[ch], to do the overlaying of underlay and color of MRI_short and MRI_rgb in all cases. 07 Mar 2001 * Modified imseq.[ch] to add controls and functions for translucent color overlays, if X11 Visual is TrueColor. * Modified to3d.c, afni_plugin.c, and plug_render.c to turn off the overlay opacity arrowval for their particular image windows (since they don't use overlays anyhoo). * Modified rwc.xbm logo bitmap to include NIH logo along with MCW logo. 08 Mar 2001 * Added median+MAD function to cs_qmed.c. * Added display of median+MAD to popup stats in afni_graph.[ch]. * Added thd_dsetrow.c, thd_rowfillin.c, 3dRowFillin.c to do row filling between gaps (zeros) of like values. Intended to complement the drawing plugin. * Modified plug_render.c to allow user to display the xhairs in the color overlay (meaning they can ShowThru). 09 Mar 2001 * Fixed 1deval.c so that "-v" option becomes "-verb" (since "-v" had another meaning in that program). Also modified several other programs so that "-verb" is accepted (instead of "-v" or "-verbose"). * Modified imseq.c to de/re-sensitize overlay opacity arrowval when "See Overlay" is turned off/on. 12 Mar 2001 * Modified mri_read.c to read Siemens Vision format .ima files. * Modified mrilib.h to have global variables MRILIB_* that hold orientation info from image files, if present. Modified to3d.c to use this information. * New program siemens_vision.c prints out info from the .ima format files' header. 15 Mar 2001 * Fixed bug in thd_shift2.c: when the shift was larger than the data line size, buffer overrun could occur. In this case, the proper result is all zeros, so that's what I substituted. 19 Mar 2001 * Fixed bug in thd_dsetrow.c, where putting a row back in for byte or float cases didn't have break statements, so it would be put twice, which is real bad (i.e., segment fault). * Added Linear Fillin to plug_drawdset.c. 20 Mar 2001 * Added 3dDeconvolve.c update from Doug Ward. * Modified plug_histog.c to add "Aboot" feature. 21 Mar 2001 * Modified coxplot to draw filled rectangles when thickness is set to -1.0. Files affected are coxplot.h, plot_cox.c, plot_ps.c, plot_ps2.c, and plot_x11.c. * Added program 1dgrayplot.c to plot timeseries files (vertically) in grayscale, a la SPM. * Modified afni_plugin.c to remove the MCW_TIMER_KILL from the ButtonPress frivolity in image popups. Also, hid this stuff behind the NO_FRIVOLITIES macro and NO_frivolities global variable. * Added program 3dToutcount.c to count outliers at each time point in a 3D+time dataset (idea from Bill Eddy). 22 Mar 2001 * Added -save option to 3dToutcount.c, to leave markers of outliers behind. * Added script moveAFNI to install changed files from afni98.tgz into the current directory. 23 Mar 2001 * Added thd_fetchdset.c, to get a dataset from a Web link. This is called from THD_open_dataset() in thd_mastery.c. Thus, you can now do something like afni -dset http://some.place/dir/anat+orig and see the dataset! 26 Mar 2001 * Modified afni_func.c, afni_widg.c to add a "Read Web" button. * Modified thd_fetchdset.c to allow fetch of *.1D files as well. 30 Mar 2001 * Added "Rota" buttons to afni_widg.c and plug_render.c, to rotate the colors on the pbars. * Added range hints to the pbar in afni_func.c and plug_render.c. 03 Apr 2001 * Modified xim.[ch] to add a "force rgb" option to function XImage_to_mri(), so that one can always be sure of getting a MRI_rgb image (and so be sure of writing a PPM file with mri_write_pnm()). Modified imseq.c and afni_graph.c to fit the new usage. 10 Apr 2001 * Fixed a bug in 3dvolreg.c, where the "-base dset" option used a sub-brick index "bb" that was no longer initialized (bug reported by Tom Ross of MCW). 18 Apr 2001 * Added some more printouts to 3dcalc.c and thd_loaddblk.c when malloc() fails on dataset input. * Added "-sum" and "-sqr" options to 3dMean.c. * Added program 1dsum.c. * Added machdep.c to do machine-dependent runtime startup (supplementing machine-dependent compiletime stuff in machdep.h). 20 Apr 2001 * Added "addto_args" to a bunch of programs, to let them use the '-@' command line switch. * Added call to machdep() in a bunch of programs. 23 Apr 2001 * Modified imseq.c to draw "EMTPY IMAGE" string into image window if a NULL image is returned. 24 Apr 2001 * Added "record" capability to imseq.[ch]. 25 Apr 2001 * Modified imseq.c recording a little. * Fixed a bug in 3dAttribute.c in which the tross_Expand_string() result might be NULL, in which case printing it would crash on some systems. Also, free()-ed the data from that call. 30 Apr 2001 * Modified mcw_glob.c to print an message if an attempted expansion produces no files. 04 May 2001 * Modified thd_loaddblk.c to print a message if a mmap()-ed file isn't big enough for the dataset byte count. 09 May 2001 * Fixed a scale-resize bug in Solaris (why does this keep happening, and only on Solaris?!) in afni.c, afni_func.c, and plug_render.c. 10 May 2001 * Fixed a bug in to3d.c with the Analyze/Siemens header geometry info: it was only processed AFTER the autosave test was executed. It was moved before the autosave. Also added the -zorigin option to let the user set the slice offset (a la 3drefit). 16 May 2001 * Modified waver.c to add new -tstim option (for specifying stimulus times directly on command line). 18 May 2001 * Modified afni_plugin.[ch] to STATUS() an error message if a plugin library cannot be loaded into the system. 22 May 2001 * Modified thd_iochan.[ch] to add function iochan_recvloop(), which loops to receive as much data as possible without waiting. 23 May 2001 * Modified thd_iochan.[ch] to add function iochan_fork_delay(), which allows relays of data from a shm IOCHAN to a tcp IOCHAN through a child process. 24 May 2001 * Modified afni_plugin.c to fprintf(stderr) the error message if a plugin library cannot be loaded into the system. (This way it always appears, even if trace is turned off.) 04 Jun 2001 * Modified thd_iochan.c iochan_fork_delay() to retry communications, and to print more error messages. * Added DONT_USE_DEBUGTHISFILE to machdep.h and debugtrace.h. 05 Jun 2001 * Modified afni_plugin.c to move some routines into the "always compiled" section; and afni_plugin.h to reflect this change. Small changes also to afni.h, afni_func.c, and afni_pplug_*.c. (All of this is to get afni to compile again without plugins.) 06 Jun 2001 * Added directory qhulldir/ to contain the qhull program from UMN. * Fixed afni_vcheck.c to reflect the new webserver. 07 Jun 2001 * Add cs_qhull.c to drive qhull program and compute Voronoi areas on sphere surface. 18 Jun 2001 * Modified mri_read_ascii() in mri_read.c to skip lines that start with '#' character. 19 Jun 2001 * Modified 3drotate.c to take the new -dfile/1Dfile options, per the request of David Glahn of UCLA. 22 Jun 2001 * Fixed a bug in 3dUndump.c where it checked the wrong value against the z coordinate bounds - it would report illegal inputs when the (x,y,z) values were in fact legal. 26 Jun 2001 * Added function THD_is_executable() in thd_filestuff.c. * Added thd_getpathprogs.c to get list of all executables in the path. 27 Jun 2001 * Added ability to save images in various formats (.jpg, .gif, etc.) to imseq.[ch], using external programs such as ppmtogif, etc. 29 Jun 2001 * Added program strblast.c to blast strings out of image files. * Modified 3dclust.c to use THD_open_dataset() instead of THD_open_one_dataset(). 03 Jul 2001 * Modified imseq.c to correct usage of pnmtotiff, which is NOT the same as ppm2tiff (first one writes to stdout, second to a file named on the command line). 05 Jul 2001 * Modified afni.[ch] to include CM's from Talairach Daemon database, and re-enabled the long-dormant "Talairach to" button. * Added option "-nosum" to 3dclust.c. * Modified thd_loaddblk.c to skip byte order tests if all sub-bricks have byte datum. 06 Jul 2001 * Modified 3dUndump.c to print a message if a voxel is written to more than once. * Added Doug Ward's changes to 3dDeconvolve.c, 3dConvolve.c, etc. 09 Jul 2001 * Modified AFNI_transform_vector() in afni.c to use anat_parent transformations if the datasets aren't directly related. * Used this to modify the "Talairach to" feature (AFNI_talto_CB() in afni.c) to allow jumping even if the dataset is not in Talairach view, but just has a way of transforming the vector to Talairach view. 10 Jul 2001 * Added "Where Am I?" Talairach Daemon feature to afni_widg.c, afni.[ch]. Actual calculations done in thd_ttatlas_query.c. * Modified xutil.[ch] to add function to alter contents of a textwin. * Added edt_sortmask.c to sort a MCW_cluster based on its contents. 11 Jul 2001 * Modified xutil.[ch] to add function MCW_unregister_hint(). * Modified afni.c to add hint/help to "Where Am I?" textwin (and to remove help when the window is destroyed). 12 Jul 2001 * Added afni_ttren.c, to control the colors of the display of the Talairach atlas regions (when I get around to it, that is). 13 Jul 2001 * OK, made afni_ttren.c work with the volume renderer. * Modified mcw_glob.c to only print warning message if allowed to. Modifed various codes that use MCW_file_expand() to turn such messages on or off, depending on what I feel like. 24 Jul 2001 * Modified thd_ttatlas_query.c to return up to 9 results, and to print a cautionary tail. * Modified plug_render.c to display TT atlas regions. 25 Jul 2001 * Modified plug_render.c to histogram new dataset bricks and choose 99.5% point as the default upper level for scaling. * Modified afni.c, afni_func.c, afni_widg.c, afni_warp.c to enable rendering of TT Atlas regions as overlays in 2D image viewers. 26 Jul 2001 * Modified imseq.[ch] to allow 'Save One' to be independent of the output filter (e.g., so can save a montage into a JPEG file). 27 Jul 2001 * Modified imseq.[ch] to add 'Sav:aGif' to save a sequence of images into animated GIF format (using gifsicle or whirlgif). * Included gifsicle directory into AFNI distribution, and added to Makefile.INCLUDE to make gifsicle (whirlgif was already there). However, neither of these program is made by default. 29 Jul 2001 * Modified imseq.[ch] to add a range hint to the intensity bar. 30 Jul 2001 * Fixed color pbar hintize alterations when user changes sub-bricks, in plug_render.c. 31 Jul 2001 * Modified xutil.[ch] to add a routine to NULL out an arbitrary pointer when a widget is destroyed. * Used the above in afni.c to NULL out the pointer to the "Where Am I?" text window when the text window is destroyed because the user destroyed its parent imseq. 01 Aug 2001 * Realized that the TT atlas overlay was setup for the small Talairach box, and most people now have large Talairach box datasets. To make the system work, modified thd_ttatlas_query.c to allow programs to load an atlas with 141 I-S slices (the one on disk), or an atlas with 151 I-S slices (created via zero-padding). Then modified places that retrieved the atlas dataset: afni_func.c, plug_render.c. Ugh. * Also modified afni.c so that the "Atlas Colors" popup button is only enabled in +tlrc view. * Modified waver.c to add to -EXPR option. * Added -stdin option to 1dplot.c. 02 Aug 2001 * Fixed bug in waver.c -EXPR option, so that if waveform_EXPR(t) is called with t < 0, it returns 0. * Included mpeg_encode directory into AFNI distribution, and added to Makefile.INCLUDE to make mpeg_encode. However, neither of these program is made by default. * Added Sav:mpeg to imseq.[ch]. 06 Aug 2001 * Modified coxplot/plot_motif.c to have plotting window close when user presses 'Q' or 'q' keystroke in the drawing area. 07 Aug 2001 * Modified afni_graph.[ch] and afni.c to extend graph baseline concept to have a global baseline for all graphs (that doesn't change when the user moves around). * Modified afni_graph.[ch] to add a new Double Plot mode Plus/Minus to make the transformed function be added/subtracted from the dataset's time series, so we can see error bars from 3dDeconvolve's -iresp/-sresp outputs! * Added afni_pplug_1dfunc.c to make 1DChain pseudoplugin (also affected afni_func.c and afni_widg.c). 08 Aug 2001 * Modified afni_graph.c and xutil.c to use new environment variable AFNI_DONT_MOVE_MENUS - if this is "Yes", then the menu movement functions will be skipped. Also added this to afni_pplug_env.c. (As usual, this is in response to a problem on Solaris.) * Added program 3dZcutup.c to cut slices out of a dataset. * Modified various functions to work with single-slice datasets. Probably missing some still. 09 Aug 2001 * Added program 3dZcat.c to put datasets together in the slice direction. * (Re)modified to3d.c to allow creation of 1 slice datasets. Hope it works out this time. 10 Aug 2001 * Added TENT() function to parser.f and parser.inc. * Added thd_dsetto3D.c, to extract/scale a float copy of a sub-brick. * New program 3dTqual.c computes a 'quality index' of each sub-brick in a 3D+time dataset. * Modified 1dplot.c so that -stdin option can read more than 1 column. 11 Aug 2001 * Modified plug_scatplot.c to print correlation coefficient. 12 Aug 2001 * Fixed bug in 3dClipLevel.c that used 1 past the end of the histogram array (bad Bob, bad). * Added functions thd_median_brick() and thd_cliplevel() in files THD_median.c and THD_cliplevel.c to the library. * Modified 3dTqual.c to use these library functions. * Modified 3dToutcount.c to have -autoclip option. 13 Aug 2001 * Added -dt option to 3dcalc.c. * Added routine AFNI_logger() in afni_logger.c. 14 Aug 2001 * Modified a bunch of programs to use AFNI_logger(). 15 Aug 2001 * Modified 3dToutcount.c to have a -range option, a la 3dTqual.c. * Added function THD_outlier_count() to do more or less what 3dToutcount.c does. * Used this in to3d.c to automatically check new 3D+time datasets for outliers. 16 Aug 2001 * Modified afni_func.c to hintize the pbar in function AFNI_underlay_CB(). * Modified the outlier stuff in to3d.c some. 20 Aug 2001 * Incorporated revised TD database from San Antone. Also penciled in the Nucleus Accumbens, since they seem to have missed it. 22 Aug 2001 * Modified plug_drawdset.c to allow loading of overlay data from the TTatlas+tlrc dataset, on a region-by-region basis. 23 Aug 2001 * Added program 3dTcorrelate.c to compute correlation coefficient of 2 3D+time datasets, voxel by voxel. * New file thd_correlate.c computes various correlation coefficients between vectors. * Added constant detrending to thd_detrend.c. 24 Aug 2001 * Modified 3dTcorrelate.c to have "-polort -1" option. * Modified afni_friends.c. * Modified to3d.c, which tried to popup outlier message in batch mode. Also, made it check for negatives again after 2swap; skip outlier check if too many negatives (more than 1%); print percentage of negatives in negatives report. 26 Aug 2001 * Modified to3d.c to have -save_outliers option. 28 Aug 2001 * Modified thd_correlate.c Pearson routine to initialize sums (oops). 29 Aug 2001 * Created cs_sort_template.h, a file to generate quicksort functions from a macro-defined type and macro-defined order. * Adapted 1st version of agni.[ch] to fit into afni, for surface display. Changes also to afni.c (to draw the damn thing), imseq.c, and some other minor junk. 30 Aug 2001 * Modified coxplot/plot_cox.c to have a flip_memplot() function, for use in imseq.c graphing overlay. * Modified coxplot/plot_x11.c to draw a Point rather than a Rectangle if the rectangle has width=height=0. * Modified afni.c to draw surface nodes in correct places, rather than in center of their voxels. Also involved changes to thd_coords.c, to have new functions for floating point coords in FD_bricks. 05 Sep 2001 * Modified machdep.[ch] to provide some support for Mac OSX (Darwin). * Modified agni.c to do volume map (vmap) correctly, and faster. 06 Sep 2001 * Modified afni_plugout.[ch] to have "NO_ACK" option, so that plugout messages aren't acknowledged. This is necessary to avoid race conditions with a plugout that both sends and receives messages. * Modified afni_plugout.[ch] to allow sending and receiving of SURFID for surface node identifiers. * Wrote plugout_surf.c as a demo of the SURFID interchange. 07 Sep 2001 * Modified agni.[ch] to put a mask into the vmap to mark the level of expansion at which the voxel was mapped. * Modified agni.c to using ENTRY/RETURN. * Modified agni.c to check for duplicate node id's when creating a surface. * Modified afni.c and afni_plugout.c to strip off the vmap mask when querying this array. * Modified machdep.c to get the _Xsetlocale() fixup function; added machdep() to a lot of programs (for Mac OS X compilation). 11 Sep 2001 * Modified mri_render.[ch] and plug_render.c to allow depth cueing of ShowThru overlays (new option ST+Dcue on overlay opacity menu). 12 Sep 2001 * Wrote thd_autonudge.c and 3dAnatNudge.c to try to fit EPI volume on top of scalped SPGR volume. 13 Sep 2001 * Modified afni_plugin.c and NLfit_model.c to properly load .so objects on Mac OS X (DARWIN). 17 Sep 2001 * Modified mri_read.c to add new function mri_read_ppm_header(), and to make mri_read_ppm() scale a PPM image to maxval=255. * Modified afni_splash.c to look for .afnisplash*.ppm files for the splash image override. 18 Sep 2001 * Added mri_drawing.c to draw things into RGB images, and mri_coxplot.c, to use that to draw coxplot stuff into RGB images. 19 Sep 2001 * In imseq.c, realized that the "Empty Image" memplot was bei