VTK
|
00001 /*========================================================================= 00002 00003 Program: Visualization Toolkit 00004 Module: vtkFreeTypeStringToImage.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 =========================================================================*/ 00015 00026 #ifndef __vtkFreeTypeStringToImage_h 00027 #define __vtkFreeTypeStringToImage_h 00028 00029 #include "vtkRenderingFreeTypeModule.h" // For export macro 00030 #include "vtkStringToImage.h" 00031 #include "vtkSmartPointer.h" // For SP ivars 00032 00033 class VTKRENDERINGFREETYPE_EXPORT vtkFreeTypeStringToImage : public vtkStringToImage 00034 { 00035 public: 00036 vtkTypeMacro(vtkFreeTypeStringToImage, vtkStringToImage); 00037 virtual void PrintSelf(ostream &os, vtkIndent indent); 00038 00039 static vtkFreeTypeStringToImage *New(); 00040 00042 00051 virtual vtkVector2i GetBounds(vtkTextProperty *property, 00052 const vtkUnicodeString& string); 00053 virtual vtkVector2i GetBounds(vtkTextProperty *property, 00054 const vtkStdString& string); 00056 00058 00064 virtual int RenderString(vtkTextProperty *property, 00065 const vtkUnicodeString& string, 00066 vtkImageData *data, 00067 int textDims[2] = NULL); 00068 virtual int RenderString(vtkTextProperty *property, 00069 const vtkStdString& string, 00070 vtkImageData *data, 00071 int textDims[2] = NULL); 00073 00076 virtual void SetScaleToPowerOfTwo(bool scale); 00077 00079 void DeepCopy(vtkFreeTypeStringToImage *utility); 00080 00081 protected: 00082 vtkFreeTypeStringToImage(); 00083 ~vtkFreeTypeStringToImage(); 00084 00085 class Internals; 00086 Internals* Implementation; 00087 00088 private: 00089 vtkFreeTypeStringToImage(const vtkFreeTypeStringToImage &); // Not implemented. 00090 void operator=(const vtkFreeTypeStringToImage &); // Not implemented. 00091 }; 00092 00093 #endif //__vtkFreeTypeStringToImage_h