[Insight-developers] itkIndex & itkOffset

Lorensen, William E (CRD) lorensen@crd.ge.com
Fri, 6 Apr 2001 14:18:34 -0400


The following decision was made at today's tcon.

itkIndex will become signed
The following operations will be supported between itkIndex and itkOffset. These were proposed by
Josh Cates and refined by the tcon participants.
Index - Index = Offset
Index - Offset = Index
Index + Offset = Index
Offset + Offset = Offset
Offset - Offset = Offset
Index + Index is undefined.

Paul H suggested that this approach is analgous to pointer/integer semantics.

Bill


> > > If itkOffset is the difference  twn two itkIndex it follows that:
> > > 
> > >  itkIndex - itkIndex  = itkOffset
> > >  itkIndex - itkOffset = itkIndex
> > >  itkIndex + itkOffset = itkIndex
> > >  itkIndex + itkIndex  = itkOffset? itkIndex? or undefined?
> > > 
> > > Another issue is whether to check the itkIndex - itkOffset case for
> > > negative results, which will produce undefined values in itkIndex.
> > > What do others think?
> > > 
> > > Josh.
> > > 
> > > ______________________________
> > >  Josh Cates
> > >  School of Computer Science
> > >  University of Utah
> > >  Email: cates@cs.utah.edu
> > >  Phone: (801) 587-7697
> > >  URL:   www.cs.utk.edu/~cates
> > > 
> > > _______________________________________________
> > > Insight-developers mailing list
> > > Insight-developers@public.kitware.com
> > > http://public.kitware.com/mailman/listinfo/insight-developers
> > 
> > -- 
> > ===============================================
> > Stephen R. Aylward
> > Assistant Professor of Radiology
> > Adjunct Assistant Professor of Computer Science
> > http://www.cs.unc.edu/~aylward
> > aylward@unc.edu
> > (919) 966-9695
> > 
>