Home My Page Projects Code Snippets Project Openings diderot
Summary Activity Tracker Tasks SCM

SCM Repository

[diderot] Diff of /branches/vis12/src/compiler/nrrd/nrrd-enums.sml
ViewVC logotype

Diff of /branches/vis12/src/compiler/nrrd/nrrd-enums.sml

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 2044, Sat Oct 20 18:46:50 2012 UTC revision 2045, Sun Oct 21 14:33:29 2012 UTC
# Line 13  Line 13 
13    
14    (* the subset of the axis kinds that Diderot can read and write *)    (* the subset of the axis kinds that Diderot can read and write *)
15      datatype axis_kind      datatype axis_kind
16        = KindSpace               (* spatial domain *)        = KindDomain              (* any image domain *)
17          | KindSpace               (* spatial domain *)
18        | KindList                (* flat vector of values; used to represent tensors that do *)        | KindList                (* flat vector of values; used to represent tensors that do *)
19                                  (* not have one of the shapes recoognized by Teem *)                                  (* not have one of the shapes recoognized by Teem *)
20        | KindScalar              (* scalar *)        | KindScalar              (* scalar *)
# Line 27  Line 28 
28     * http://teem.sourceforge.net/nrrd/format.html#kinds for info)     * http://teem.sourceforge.net/nrrd/format.html#kinds for info)
29     *)     *)
30      fun kindFromString s = (case s      fun kindFromString s = (case s
31             of "space" => SOME KindSpace             of "domain" => SOME KindDomain
32                | "space" => SOME KindSpace
33              | "list" => SOME KindList              | "list" => SOME KindList
34              | "scalar" => SOME KindScalar              | "scalar" => SOME KindScalar
35              | "2-vector" => SOME Kind2Vector              | "2-vector" => SOME Kind2Vector
# Line 40  Line 42 
42    
43    (* convert an axis kind to its nrrd enum constant *)    (* convert an axis kind to its nrrd enum constant *)
44      fun kindToEnum k = (case k      fun kindToEnum k = (case k
45             of KindSpace => "nrrdKindSpace"             of KindDomain => "nrrdKindDomain"
46                | KindSpace => "nrrdKindSpace"
47              | KindList => "nrrdKindList"              | KindList => "nrrdKindList"
48              | KindScalar => "nrrdKindScalar"              | KindScalar => "nrrdKindScalar"
49              | Kind2Vector => "nrrdKind2Vector"              | Kind2Vector => "nrrdKind2Vector"

Legend:
Removed from v.2044  
changed lines
  Added in v.2045

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0