Changeset 283 for trunk/odf.tcl


Ignore:
Timestamp:
Dec 4, 2009 5:03:28 PM (11 years ago)
Author:
toby
Message:

# on 2000/09/25 20:08:45, toby did:
Add texture index

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/odf.tcl

    • Property rcs:date changed from 2000/07/20 22:03:39 to 2000/09/25 20:08:45
    • Property rcs:rev changed from 1.1 to 1.2
    • Property rcs:lines set to +12 -1
    r235 r283  
    324324    #     ODFterms -- a list of the {l m n} values for each ODF term (*)
    325325    #     ODFcoefXXX -- the ODF coefficient for for ODF term XXX (*)
     326    set textureindex 1.0
    326327    foreach lmn [phaseinfo $expgui(curPhase) ODFterms] {
    327328        # make sure that numbers are separated by spaces
     
    344345        set entryvar(ODFcoef$term) [eval $entrycmd(ODFcoef$term)]
    345346        grid columnconfig $expgui(odfFrameCanvas).fr $col -pad 12
     347        set textureindex [expr {$textureindex + \
     348                ($entryvar(ODFcoef$term) * $entryvar(ODFcoef$term)) \
     349                / ((2. * [lindex $lmn 0]) + 1.)}]
    346350    }
    347351
     
    350354                -anchor center] \
    351355                -column 0 -row 0 -sticky nsew
     356    } else {
     357        incr row 2
     358        grid [label $expgui(odfFrameCanvas).fr.last \
     359                -bd 2 -relief sunken -anchor center \
     360                -text "Texture index = [format %.4f $textureindex]" ] \
     361                -column 1 -columnspan 6 -row $row -sticky ew
     362        grid rowconfig $expgui(odfFrameCanvas).fr $row -pad 12
    352363    }
    353364    # resize
Note: See TracChangeset for help on using the changeset viewer.