VTK
dox/Widgets/vtkScalarBarRepresentation.h
Go to the documentation of this file.
00001 /*=========================================================================
00002 
00003   Program:   Visualization Toolkit
00004   Module:    vtkScalarBarRepresentation.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 
00016 /*
00017  * Copyright 2008 Sandia Corporation.
00018  * Under the terms of Contract DE-AC04-94AL85000, there is a non-exclusive
00019  * license for use of this work by or on behalf of the
00020  * U.S. Government. Redistribution and use in source and binary forms, with
00021  * or without modification, are permitted provided that this Notice and any
00022  * statement of authorship are reproduced on all copies.
00023  */
00024 
00042 #ifndef __vtkScalarBarRepresentation_h
00043 #define __vtkScalarBarRepresentation_h
00044 
00045 #include "vtkBorderRepresentation.h"
00046 
00047 class vtkScalarBarActor;
00048 
00049 class VTK_WIDGETS_EXPORT vtkScalarBarRepresentation : public vtkBorderRepresentation
00050 {
00051 public:
00052   vtkTypeMacro(vtkScalarBarRepresentation, vtkBorderRepresentation);
00053   virtual void PrintSelf(ostream &os, vtkIndent indent);
00054   static vtkScalarBarRepresentation *New();
00055 
00057 
00058   vtkGetObjectMacro(ScalarBarActor, vtkScalarBarActor);
00059   virtual void SetScalarBarActor(vtkScalarBarActor *);
00061 
00063 
00064   virtual void BuildRepresentation();
00065   virtual void WidgetInteraction(double eventPos[2]);
00066   virtual void GetSize(double size[2])
00067     {size[0]=2.0; size[1]=2.0;}
00069 
00071 
00073   virtual void GetActors2D(vtkPropCollection *collection);
00074   virtual void ReleaseGraphicsResources(vtkWindow *window);
00075   virtual int RenderOverlay(vtkViewport*);
00076   virtual int RenderOpaqueGeometry(vtkViewport*);
00077   virtual int RenderTranslucentPolygonalGeometry(vtkViewport*);
00078   virtual int HasTranslucentPolygonalGeometry();
00080 
00082 
00083   void SetOrientation(int orient);
00084   int GetOrientation();
00086 
00087 protected:
00088   vtkScalarBarRepresentation();
00089   ~vtkScalarBarRepresentation();
00090 
00091   vtkScalarBarActor *ScalarBarActor;
00092 private:
00093   vtkScalarBarRepresentation(const vtkScalarBarRepresentation &); // Not implemented
00094   void operator=(const vtkScalarBarRepresentation &);   // Not implemented
00095 };
00096 
00097 #endif //__vtkScalarBarRepresentation_h