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

Annotation of /trunk/pyvisi/py_src/texture.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 948 - (hide annotations)
Thu Feb 1 07:23:34 2007 UTC (13 years, 7 months ago) by jongui
File MIME type: text/x-python
File size: 620 byte(s)
fixed some bugs in pyvisi and added more epydocs.
1 jongui 943 """
2     @author: John NGUI
3     """
4    
5     import vtk
6    
7     class Texture:
8     """
9 jongui 947 Class that defines a texture for the rendered object.
10 jongui 943 """
11    
12     def __init__(self, image):
13     """
14     Initialise the texture.
15    
16 jongui 948 @type image: vtkImageData
17     @param image: Image data from which data is read
18 jongui 943 """
19    
20     self.__image = image
21     self.__vtk_texture = vtk.vtkTexture()
22    
23     self.__setInput()
24    
25     def __setInput(self):
26     """
27     Set the input for the texture.
28     """
29    
30     self.__vtk_texture.SetInput(self.__image)
31    
32     def _getTexture(self):
33     """
34     Return the texture.
35    
36     @rtype: vtkTexture
37 jongui 947 @return: Texture of the rendered object
38 jongui 943 """
39    
40     return self.__vtk_texture
41    

  ViewVC Help
Powered by ViewVC 1.1.26