VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkExternalOpenGLCamera.h 00005 00006 Copyright (c) Ken Martin, Will Schroeder, Bill Lorensen 00007 All rights reserved. 00008 See Copyright.txt or http://www.kitware.com/Copyright.htm for details. 00009 00010 This software is distributed WITHOUT ANY WARRANTY; without even 00011 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR 00012 PURPOSE. See the above copyright notice for more information. 00013 00014 =========================================================================*/ 00024 #ifndef __vtkExternalOpenGLCamera_h 00025 #define __vtkExternalOpenGLCamera_h 00026 00027 #include "vtkRenderingExternalModule.h" // For export macro 00028 #include "vtkOpenGLCamera.h" 00029 00030 class VTKRENDERINGEXTERNAL_EXPORT vtkExternalOpenGLCamera : 00031 public vtkOpenGLCamera 00032 { 00033 public: 00034 static vtkExternalOpenGLCamera *New(); 00035 vtkTypeMacro(vtkExternalOpenGLCamera, vtkOpenGLCamera); 00036 virtual void PrintSelf(ostream& os, vtkIndent indent); 00037 00039 void Render(vtkRenderer *ren); 00040 00042 void SetViewTransformMatrix(const double elements[16]); 00043 00045 void SetProjectionTransformMatrix(const double elements[16]); 00046 00047 protected: 00048 vtkExternalOpenGLCamera(); 00049 ~vtkExternalOpenGLCamera() {} 00050 00052 00054 void ComputeProjectionTransform(double aspect, 00055 double nearz, 00056 double farz); 00058 00061 void ComputeViewTransform(); 00062 00063 private: 00064 bool UserProvidedProjectionTransform; 00065 bool UserProvidedViewTransform; 00066 00067 vtkExternalOpenGLCamera(const vtkExternalOpenGLCamera&); // Not implemented. 00068 void operator=(const vtkExternalOpenGLCamera&); // Not implemented. 00069 }; 00070 00071 #endif