/[escript]/trunk/pyvisi/py_src/imagereslice.py
ViewVC logotype

Diff of /trunk/pyvisi/py_src/imagereslice.py

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

revision 1197 by jongui, Mon Jun 18 02:08:34 2007 UTC revision 1199 by jongui, Wed Jun 20 05:01:30 2007 UTC
# Line 23  import vtk Line 23  import vtk
23  class ImageReslice:  class ImageReslice:
24      """      """
25      Class that defines an image reslice used to resize static      Class that defines an image reslice used to resize static
26      (no interaction capability) images.      (no interaction capability) images (i.e. logo).
27      """      """
28    
29      def __init__(self):      def __init__(self):
# Line 53  class ImageReslice: Line 53  class ImageReslice:
53    
54      def setSize(self, size):      def setSize(self, size):
55          """          """
56          Set the size of the image (logo in particular), between 0 and 2.          Set the size of the image, between 0 and 2.
57          Size 1 (one) displays the image in its original size          Size 1 (one) displays the image in its original size
58          (which is the default).            (which is the default).  
59    
# Line 64  class ImageReslice: Line 64  class ImageReslice:
64          # By default, with image reslice, the larger the output spacing, the          # By default, with image reslice, the larger the output spacing, the
65          # smaller the image. Similarly, the smaller the output spacing, the          # smaller the image. Similarly, the smaller the output spacing, the
66          # larger the image. This behaviour is reversed so that the larger the          # larger the image. This behaviour is reversed so that the larger the
67          # size the image. Similarly, the smaller the size, the smaller the          # size the larger the image. Similarly, the smaller the size, the
68          # image.          # smaller the image.
69          if(size > 1):          if(size > 1):
70              size = 1 - (size - 1)              size = 1 - (size - 1)
71              self.__vtk_image_reslice.SetOutputSpacing(size, size, size)              self.__vtk_image_reslice.SetOutputSpacing(size, size, size)

Legend:
Removed from v.1197  
changed lines
  Added in v.1199

  ViewVC Help
Powered by ViewVC 1.1.26