################################################################### LATEST EMAIL UPDATE: 28 Jul 2015 ################################################################### Here is another minor update with new functionality, new documentation, and many small doc and bug fixes. New (~45M) tarfiles are at: http://www.cogsci.ucsd.edu/~sereno/.tmp/dist/csurf/UPDATES.txt http://www.cogsci.ucsd.edu/~sereno/.tmp/dist/csurf/csurf0.8-linux-150728.tgz http://www.cogsci.ucsd.edu/~sereno/.tmp/dist/csurf/csurf0.8-linux64-150728.tgz http://www.cogsci.ucsd.edu/~sereno/.tmp/dist/csurf/csurf0.8-mac-150728.tgz Getting a Middle-Click from Late Model Mac OS X I improved the instructions in README.txt for getting a middle click out of late-model Mac OS X (10.9+), which has hidden the middle-click functionality. On Mac, with a Mac scroll-ball mouse, use System Preferences -> Mouse to make right mouse button "Secondary Button" and middle mouse button/scroll wheel "Button 3" to enable right and middle click (needed for edit-to-black and edit-to-white in tkmedit and help and alternate functions on many tksurfer buttons). In Mac OS X 10.9 (Mavericks) and 10.10 (Yosemite) with an apple 'trackpad' mouse, there will be no longer be any Expert Preferences mouse options for a middle click. However, a standard 3-button USB mouse will still give a middle-click in 10.9 and 10.10 if the following three options are ticked on the X11 -> Preferences -> Input tab: x Emulate three button mouse x Follow system keyboard layout x Enable key equivalents under X11 With just a trackpad (no mouse), you can still get left, middle, and right clicks using: left click: click trackpad middle click: option-click trackpad right click: command-click trackpad This is fine for accessing overloaded buttons, but is inconvenient for using tkmedit to edit 3D volume datasets (middle-click is fill, right-click is edit-to-black). Get a real 3-button mouse to do that. Interative Register/Upsample Native ROI BRIKs w/tkmedit In the previous update, I added a way to generate a 3D native AFNI BRIK ROI's from a surface label in *tksurfer* (shift-middle-click on "label:" line "D" button). The current update allows *tkmedit* to use the same files. In [fn]-F2 tkmedit interface, the "roi:" button toggles between two states: roiup: => ROI registered and upsampled to 1x1x1 roin: => ROI native Clicking on the label toggles it to "roin:", which allows reading, registering, and upsampling the native resolution ROI into alignment with the structural scan (no write). The default "roiup:" state reads and writes registered, already upsampled-to-1x1x1mm ROI BRIKs (e.g., for smooth, structural resolution ROI's and masks). These two button states and functions are parallel to "valn:" and "valup:" (and "mskn:" and "mskup:"). Percent peak-to-peak phase-encoded activation over label or vertex A shfit-right-click on the label: line "T" button calculates the average precent periodic response for vertices in a label (ignoring phase). N.B.: this requires first loading the *3D* raw fourier stat BRIKs (_x,_y), into tksurfer, which can be done by clicking "val:" to change it to "val3d:", the selecting the _x BRIK and clicking "R" (auto-reads complex). Tksurfer hacking An alternate treatment of cut borders (set $bordneiflag to 1) when inflating a cut surface with area_shrink (tksurfer-internal inflation) has been added. N.B.: inflating a surface with cuts is not a standard operation (I used this on my cerebellum). Another new area_shrink flag removes vertices with no second-order non-border neighbors (set $rmvtx2nonbordflag to 1). Tkmedit hacking Added 3D gradient calculations (calcgradamp, calcgradampdd -- nearest x,y,z neighbor and Gaussian directional derivative versions). Also added multi-threaded local normalize functions (locnorm_allslices by median or smoothed histogram max, not that useful yet). Finally, can also swap the contents of the editable and COMPARE buffers (swap_imim2). Interface improvements The overloaded buttons on tksurfer -- where using a middle click or adding shift change the action (esp. on the "label:" line) -- now all report what is about to happen to avoid confusion. Bug Fixes (1) If you use the "X" button on the "label:" line (surface-based searchlight cross-correlation) you couldn't change what you decided to correlate after the first popup, now fixed. (2) holding down tkmedit arrows to change slices now stops changing slices on up-button (was playing out buffered key repeats). (3) using ctrl-middle-click to display timecourse wasn't catching ctrl-up, so next left-click would magnify around vertex instead of selecting vertex ### 28 Jul 2015 (read native ROI, bugfixes/help) 1) HOWTO get middle click! 2) tkmedit read ROI 2-state: "roiup:" (reg'd/upsampled) <=> "roin:" (native) 3) percent peak-to-peak response (fourier-analyzed) 4) bug fixes, INPROG tksurfer, tkmedit hacks To install the new csurf: cd mv csurf csurf-YYMMDD tar xvfz csurf0.8-{mac,linux}-YYMMDD.tgz cheers, marty ######################################### Latest addition to $CSURF_DIR/UPDATES.txt ######################################### ---------------- 28Jul2015 FreeSurfer0.8/csurf0.8 tarballs ------------------- --lib/help/tksurfer/label_timecourse: update --tksurfer.c: fix missed ctrl key-up w/long read_rawdata --tksurfer.c: ctrl-mid-click vertex prints pcntsigpk2pk if 3D stats loaded --tksurfer.tcl: shift-right-T to get avg pcnt change from label --tksurfer.tcl: ROI butt pop-up warns fill to stat/complexamp/real ([s]fthresh) --tksurfer.tcl: pop-up pre-report value: line CLR actions --tksurfer.tcl: pop-up pre-report def/nondef label D,C,CLR,R,RC,W butt actions --tksurfer.c: label timecourses opt reports pcnt activ for label to pcntsigpk2pk --bin/noarch/runra.{sh,csh,tcl}: add directory setup example --tksurfer.tcl: report 3rd file (avg float tcourse) now written by "T" button --tksurfer.c: rawdata_avgtseries: int->float, write out 3rd file (avg raw t) --lib/help/csurf/{tkmedit,makenewsubj,reconall}: update --lib/help/tkmedit/{saveimg,compare,wmfilterstd,wmfiltergau,test1}: updates --tkmedit.tcl: mid-click F3 TEST runs locnorm_allslices hacks (median/histmax) --tkmedit.c: calcgradampdd from dir. deriv. Gaussian functs --tkmedit.c: calcgradamp from x,y,z neighbors (from tksurfer) --tkmedit.tcl: mid-clk-COMPARE swaps *contents* of editable and COMPARE buffers --tkmedit.c: don't kill tkmedit if shift-right-clk w/o register.dat (!) --tkmedit.c: shift-mid-clk print3dhist: dump loc 3D hist, disp in gnuplot --tkmedit.c: locnorm_allslices: alt norm uses smoothed hist max -> abandon both --tkmedit.c: fix wintitle on read new editable (like already working im2) --tkmedit.c: multi-thread locnorm_allslices (8x faster on i7) --lib/help/tksurfer/label: update for cross-corr over label (X) button --tksurfer.tcl: put corrctrls at top of do_corr (else prevents change cmptype!) --tksurfer.tcl: warn/block FILL if label loaded but not shown --tksurfer.c: display/clear label/MGHannot sets annotloadedflag, export it --tksurfer.tcl: don't set swap_*_explain vars so overloaded S/V always reports --tkmedit.c: mediannorm_allslices: normalize by mult by avgbrain/3Dmedian --tkstrip.c: allow -outim to overwrite built-in scripts default outfiles --lib/help/tksurfer/patch_cut: typos --csurf: MGHTools -> Register Surface (to symm) wired up --tksurfer.c: shrink_area: bordneiflag: add 2% tangential force fix ragged edge --tksurfer.c: write_binary_areas{2}: b/c vtx correct, restore 2x bug at outfile --tksurfer.c: fix compute_normals_areas compute vertexwise area for quads --tksurfer.c: move read_binary_areas oldarea 0.5x correct: areatotal->vtxlevel --mk0{.csh}: update for new help file --lib/help/csurf/inflatepatchhires: new help file --tksurfer.c: rmvtx2nonbordflag to block rip vtx w/no 2nd order non-bord nei --tksurfer.c: area_shrink() rips vertices w/no 2nd order non-border neighbors --csurf: tksurferinflatepatch: interactive initial pose adj, final surf inspect --csurf: reconallcmd warns missing MGH license file --csurf: tksurferinflatepatch allows write tiffs --README.txt: update Mac middle-click/X11->input help --csurf: SubjectTools -> Inflate Surface Patch (hi-res): tksurferinflatepatch --tksurfer.c: add compute_normals_areas reportflag arg to fix too-verbose shrink --csurf: change to subject at startup if csurf started in subject's script dir --lib/help/tksurfer/restore: documents really_center_brain --tksurfer.tcl: shift-mid-click RESTORE overload: does really_center_brain --tksurfer.c: shrink_area: alt border policy: bordneiflag (avg of non-bord nei) --tksurfer.c: smooth_logarat: catch zero area (e.g., from def FS midline) --tksurfer.tcl: if areaflag, recalc full area on white, else def zero midline --tested->OK: brik2cor:native _f -> zz.mgz, tkmedit:read zz.mgz as native stat --tkmedit.tcl: read native stats (valn): accept .mgz/mgh, load to valn dropdown --tkmedit.c: read mgz/mgh float stats: extend mknativestatbufs, read_native_stat --tkmedit.c: new funct: get_mgzdatatypedims, get_mgzdatatype wrapper discards --tkmedit.c: fix repeat-arrowkey overhang GL win (slower, 1 down skipped after) --lib/help/csurf/tkmedit: document toggle roi button, correct s->up typo --tkmedit.tcl: re-enable SEND/GOTO if turn off all3 while zoomed --tkmedit.c: allow -scalefac,-offset w/byte images --tkmedit.c: make options work w/2arg: tkmedit orig.mgz -opt ... --tksurfer.tcl: popup reports samp lims in label->ROI-BRIK like tksurfer.c --tkmedit.c: better help/err for float mgz --brik2cor.c: flag (-floatmgzout) to output a float mgz --tksurfer.tcl: warn $scandir equals __noscandir__ for MGH label -> 3D ROI BRIK --tksurfer.c: 3D ROI from label incl samp lims in BRIK name {fr/mm}={min}to{max} --tkmedit.c: check/require read_regdat done for read_native_{stat,roi} --tkmedit.tcl: readnativeroi: read_native_roi,do_regupsamp_roi,labelflag,redraw --csurflib.c/h: add makeshort3D/freeshort3D (for tkmedit read native ROI) --tkmedit.c: write/export read_native_roi(), do_regupsamp_roi() --lib/help/tksurfer/label_read: explain overloaded function --lib/help/tkmedit/{valn_read, roiup}: fix typos --mk0{.csh}: update for prev renames --lib/help/tkmedit/{roin2up,roin,roin_read}: new helpfiles --lib/help/tkmedit: rename roi_{read,write,time} -> roiup_{*}, roi -> roiup --tkmedit.tcl: toggle roin/roiup state (native vs. upsamp) of 3D ROI label line --tkmedit.tcl: rename $label->$uplabel, add $rawlabel --tkmedit.c: rename label->uplabel, add rawlabel, tclexports, -rawlabel cmdline --csurf: mid-clk "fsavg" button sets oppfsavghemiflag (disp on opp fsavg hemi) --tkmedit.tcl: fix bug in error message, add help for read non-conforming ROI --lib/help/tksurfer/{arrownorm,swapstatval,val_clear}: top summaries --README.txt: rm anachronisms, intro FUNCT/STRUCT DIRS, say cp MGH fsaverage --csurf: mknewfunct: fix "mvlog mv ..." bug in attempting to mv aside session --tksurfer.tcl: Dijk checks if MGH geodesic binary is there (e.g., not in 5.1) ---------------- 13May2015 FreeSurfer0.8/csurf0.8 tarballs ------------------- --fix bug: forgot-to-global-brainregioncnt prevented using do_corr w/MGH annot --fix bug: lastcolscale was -1 on first complex swap from dup'd fixcolscale var --csurf: SubjTools->ReMake surf 1hemi only tessellates 1 despite possible stale --lib/help/csurf/tksurfer: label button overloads, top summaries, writearea, GR --lib/help/tksurfer/area_{disp,read}: top summaries --lib/help/tksurfer/{label_{read,readcut,clear,read2val,write}: top summaries --tksurfer.tcl: warn popups for non-def overload actions "label:" line "D" butt --tksurfer.c: annotcol2brainregionname exp->tcl, write outp to $brainregionname --lib/help/tksurfer/label_read: new "D" overloads --tksurfer.tcl: "label:" ctrl-shift-left-"D" conv all annot regions to ROIs --tksurfer.tcl: "label:" shift-left-"D" conv 1 clicked annot region to ROI mask --tksurfer.tcl: "label:" shift-mid-"D" conv label to AFNI ROI mask BRIK ...