Main Page Class Hierarchy Alphabetical List Compound List File List Compound Members File Members Related Pages

# Rendering/vtkVolumeProVG500Mapper.h

Go to the documentation of this file.

    00001 /*=========================================================================
    00002
    00003   Program:   Visualization Toolkit
    00004   Module:    $RCSfile: vtkVolumeProVG500Mapper.h,v $
    00005   Language:  C++
    00006
    00007   Copyright (c) 1993-2002 Ken Martin, Will Schroeder, Bill Lorensen
    00008   All rights reserved.
    00009   See Copyright.txt or http://www.kitware.com/Copyright.htm for details.
    00010
    00011      This software is distributed WITHOUT ANY WARRANTY; without even
    00012      the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
    00013      PURPOSE.  See the above copyright notice for more information.
    00014
    00015 =========================================================================*/
    00064 #ifndef __vtkVolumeProVG500Mapper_h
    00065 #define __vtkVolumeProVG500Mapper_h
    00066
    00067 #include "vtkVolumeProMapper.h"
    00068
    00069 #ifdef _WIN32
    00070 // This ugly thing will prevent MS Visual Studio .NET from complaining
    00071 // about mixing new and old IOStream. This is necessary due to lack of
    00072 // platform independency in vli.h. It probably will not work or
    00073 // anything, but it will at least compile.
    00074 # if ( defined(_MSC_VER) && (_MSC_VER >= 1300) && !defined(_INC_IOSTREAM) )
    00075 #   define _INC_IOSTREAM
    00076 #   define _VTK_HACKED_UP_INCLUDE_BLOCKER
    00077 # endif
    00078 # include "VolumePro/inc/vli.h" // Needed for VLI internals
    00079 # if defined(_VTK_HACKED_UP_INCLUDE_BLOCKER)
    00080 #   undef _INC_IOSTREAM
    00081 #   undef _VTK_HACKED_UP_INCLUDE_BLOCKER
    00082 # endif
    00083 #else
    00084 # include "vli/include/vli.h" // Needed for VLI internals
    00085 #endif
    00086
    00087 #ifdef VTK_USE_VOLUMEPRO
    00088 #define VTK_VOLUMEPRO_EXPORT VTK_RENDERING_EXPORT
    00089 #else
    00090 #define VTK_VOLUMEPRO_EXPORT
    00091 #endif
    00092
    00093 class VTK_VOLUMEPRO_EXPORT vtkVolumeProVG500Mapper : public vtkVolumeProMapper
    00094 {
    00095 public:
    00096   vtkTypeRevisionMacro(vtkVolumeProVG500Mapper,vtkVolumeProMapper);
    00097   static vtkVolumeProVG500Mapper *New();
    00098   virtual void PrintSelf(ostream& os, vtkIndent indent);
    00099
    00101
    00102   virtual void Render( vtkRenderer *, vtkVolume * );
    00103   virtual int GetAvailableBoardMemory();
    00104   virtual void GetLockSizesForBoardMemory( unsigned int type,
    00105                                            unsigned int *xSize,
    00106                                            unsigned int *ySize,
    00107                                            unsigned int *zSize );
    00109 protected:
    00110   vtkVolumeProVG500Mapper();
    00111   ~vtkVolumeProVG500Mapper();
    00112
    00113   // Update the camera - set the camera matrix
    00114   void UpdateCamera( vtkRenderer *, vtkVolume * );
    00115
    00116   // Update the lights
    00117   void UpdateLights( vtkRenderer *, vtkVolume * );
    00118
    00119   // Update the properties of the volume including transfer functions
    00120   // and material properties
    00121   void UpdateProperties( vtkRenderer *, vtkVolume * );
    00122
    00123   // Update the volume - create it if necessary
    00124   // Set the volume matrix.
    00125   void UpdateVolume( vtkRenderer *, vtkVolume * );
    00126
    00127   // Set the crop box (as defined in the vtkVolumeMapper superclass)
    00128   void UpdateCropping( vtkRenderer *, vtkVolume * );
    00129
    00130   // Set the cursor
    00131   void UpdateCursor( vtkRenderer *, vtkVolume * );
    00132
    00133   // Update the cut plane
    00134   void UpdateCutPlane( vtkRenderer *, vtkVolume * );
    00135
    00136   // Render the hexagon to the screen
    00137   // Defined in the specific graphics implementation.
    00138   virtual void RenderHexagon( vtkRenderer  * vtkNotUsed(ren),
    00139                               vtkVolume    * vtkNotUsed(vol),
    00140                               VLIPixel     * vtkNotUsed(basePlane),
    00141                               int          size[2],
    00142                               VLIVector3D  hexagon[6],
    00143                               VLIVector2D  textureCoords[6] )
    00144     {(void)size; (void)hexagon; (void)textureCoords;}
    00145
    00146   // Make the base plane size a power of 2 for OpenGL
    00147   void CorrectBasePlaneSize( VLIPixel *inBase, int inSize[2],
    00148                              VLIPixel **outBase, int outSize[2],
    00149                              VLIVector2D textureCoords[6] );
    00150
    00151   // Keep track of the size of the data loaded so we know if we can
    00152   // simply update when a change occurs or if we need to release and
    00153   // create again
    00154   int LoadedDataSize[3];
    00155
    00156 private:
    00157   vtkVolumeProVG500Mapper(const vtkVolumeProVG500Mapper&);  // Not implemented.
    00158   void operator=(const vtkVolumeProVG500Mapper&);  // Not implemented.
    00159 };
    00160
    00161
    00162
    00163 #endif
    00164
    00165
    00166