VTK
|
Class for drawing 2D primitives using GL2PS. More...
#include <vtkGL2PSContextDevice2D.h>
Public Types | |
typedef vtkOpenGLContextDevice2D | Superclass |
![]() | |
typedef vtkContextDevice2D | Superclass |
![]() | |
enum | TextureProperty { Nearest = 0x01, Linear = 0x02, Stretch = 0x04, Repeat = 0x08 } |
typedef vtkObject | Superclass |
![]() | |
typedef vtkObjectBase | Superclass |
Public Member Functions | |
virtual int | IsA (const char *type) |
vtkGL2PSContextDevice2D * | NewInstance () const |
virtual void | PrintSelf (ostream &os, vtkIndent indent) |
virtual void | DrawQuadStrip (float *, int) |
virtual void | DrawPolygon (float *, int) |
virtual void | DrawQuad (float *points, int n) |
virtual void | DrawString (float *point, const vtkStdString &string) |
virtual void | DrawString (float *point, const vtkUnicodeString &string) |
virtual void | DrawMathTextString (float point[2], const vtkStdString &string) |
void | ApplyPen (vtkPen *pen) |
virtual void | SetPointSize (float size) |
virtual void | SetLineWidth (float width) |
virtual void | SetLineType (int type) |
virtual void | DrawPoly (float *f, int n, unsigned char *colors=0, int nc_comps=0) |
virtual void | DrawPoints (float *points, int n, unsigned char *colors=0, int nc_comps=0) |
virtual void | DrawPointSprites (vtkImageData *sprite, float *points, int n, unsigned char *colors=0, int nc_comps=0) |
virtual void | DrawEllipseWedge (float x, float y, float outRx, float outRy, float inRx, float inRy, float startAngle, float stopAngle) |
virtual void | DrawEllipticArc (float x, float y, float rX, float rY, float startAngle, float stopAngle) |
virtual void | DrawMarkers (int shape, bool highlight, float *points, int n, unsigned char *colors=0, int nc_comps=0) |
![]() | |
vtkOpenGLContextDevice2D * | NewInstance () const |
virtual void | DrawImage (float p[2], float scale, vtkImageData *image) |
void | DrawImage (const vtkRectf &pos, vtkImageData *image) |
virtual void | SetColor4 (unsigned char color[4]) |
virtual void | SetColor (unsigned char color[3]) |
virtual void | SetTexture (vtkImageData *image, int properties=0) |
virtual void | MultiplyMatrix (vtkMatrix3x3 *m) |
virtual void | SetMatrix (vtkMatrix3x3 *m) |
virtual void | GetMatrix (vtkMatrix3x3 *m) |
virtual void | PushMatrix () |
virtual void | PopMatrix () |
virtual void | SetClipping (int *x) |
virtual void | EnableClipping (bool enable) |
virtual void | Begin (vtkViewport *viewport) |
virtual void | End () |
virtual void | BufferIdModeBegin (vtkAbstractContextBufferId *bufferId) |
virtual void | BufferIdModeEnd () |
bool | SetStringRendererToFreeType () |
bool | SetStringRendererToQt () |
bool | HasGLSL () |
virtual void | ReleaseGraphicsResources (vtkWindow *window) |
virtual void | SetMaximumMarkerCacheSize (int) |
virtual int | GetMaximumMarkerCacheSize () |
virtual void | ComputeStringBounds (const vtkStdString &string, float bounds[4]) |
virtual void | ComputeStringBounds (const vtkUnicodeString &string, float bounds[4]) |
virtual vtkOpenGLRenderWindow * | GetRenderWindow () |
![]() | |
vtkContextDevice2D * | NewInstance () const |
virtual void | DrawMathTextString (float *point, const vtkStdString &string)=0 |
virtual bool | MathTextIsSupported () |
void | ApplyPen (vtkPen *pen) |
void | ApplyBrush (vtkBrush *brush) |
void | ApplyTextProp (vtkTextProperty *prop) |
virtual int | GetWidth () |
virtual int | GetHeight () |
virtual void | DisableClipping () |
virtual bool | GetBufferIdMode () const |
virtual void | SetViewportSize (const vtkVector2i &size) |
virtual void | SetViewportRect (const vtkRecti &rect) |
virtual vtkPen * | GetPen () |
virtual vtkBrush * | GetBrush () |
virtual vtkTextProperty * | GetTextProp () |
![]() | |
vtkObject * | NewInstance () const |
virtual void | DebugOn () |
virtual void | DebugOff () |
unsigned char | GetDebug () |
void | SetDebug (unsigned char debugFlag) |
virtual void | Modified () |
virtual unsigned long | GetMTime () |
unsigned long | AddObserver (unsigned long event, vtkCommand *, float priority=0.0f) |
unsigned long | AddObserver (const char *event, vtkCommand *, float priority=0.0f) |
vtkCommand * | GetCommand (unsigned long tag) |
void | RemoveObserver (vtkCommand *) |
void | RemoveObservers (unsigned long event, vtkCommand *) |
void | RemoveObservers (const char *event, vtkCommand *) |
int | HasObserver (unsigned long event, vtkCommand *) |
int | HasObserver (const char *event, vtkCommand *) |
void | RemoveObserver (unsigned long tag) |
void | RemoveObservers (unsigned long event) |
void | RemoveObservers (const char *event) |
void | RemoveAllObservers () |
int | HasObserver (unsigned long event) |
int | HasObserver (const char *event) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
template<class U , class T > | |
unsigned long | AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f) |
int | InvokeEvent (unsigned long event, void *callData) |
int | InvokeEvent (const char *event, void *callData) |
int | InvokeEvent (unsigned long event) |
int | InvokeEvent (const char *event) |
![]() | |
const char * | GetClassName () const |
virtual void | Delete () |
virtual void | FastDelete () |
void | Print (ostream &os) |
virtual void | Register (vtkObjectBase *o) |
virtual void | UnRegister (vtkObjectBase *o) |
void | SetReferenceCount (int) |
void | PrintRevisions (ostream &) |
virtual void | PrintHeader (ostream &os, vtkIndent indent) |
virtual void | PrintTrailer (ostream &os, vtkIndent indent) |
int | GetReferenceCount () |
Static Public Member Functions | |
static int | IsTypeOf (const char *type) |
static vtkGL2PSContextDevice2D * | SafeDownCast (vtkObjectBase *o) |
static vtkGL2PSContextDevice2D * | New () |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkOpenGLContextDevice2D * | SafeDownCast (vtkObjectBase *o) |
static vtkOpenGLContextDevice2D * | New () |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkContextDevice2D * | SafeDownCast (vtkObjectBase *o) |
![]() | |
static int | IsTypeOf (const char *type) |
static vtkObject * | SafeDownCast (vtkObjectBase *o) |
static vtkObject * | New () |
static void | BreakOnError () |
static void | SetGlobalWarningDisplay (int val) |
static void | GlobalWarningDisplayOn () |
static void | GlobalWarningDisplayOff () |
static int | GetGlobalWarningDisplay () |
![]() | |
static int | IsTypeOf (const char *name) |
static vtkObjectBase * | New () |
Additional Inherited Members | |
![]() | |
int | Geometry [2] |
vtkRenderer * | Renderer |
vtkStringToImage * | TextRenderer |
bool | InRender |
vtkOpenGLRenderWindow * | RenderWindow |
Private * | Storage |
![]() | |
int | Geometry [2] |
vtkVector2i | ViewportSize |
vtkRecti | ViewportRect |
vtkAbstractContextBufferId * | BufferId |
vtkPen * | Pen |
vtkBrush * | Brush |
vtkTextProperty * | TextProp |
![]() | |
unsigned char | Debug |
vtkTimeStamp | MTime |
vtkSubjectHelper * | SubjectHelper |
![]() | |
vtkAtomicInt< vtkTypeInt32 > | ReferenceCount |
vtkWeakPointerBase ** | WeakPointers |
Class for drawing 2D primitives using GL2PS.
This class takes care of drawing the 2D primitives for the vtkContext2D class. In general this class should not be used directly, but is used internally by the vtkGL2PSExporter.
Definition at line 36 of file vtkGL2PSContextDevice2D.h.
Definition at line 40 of file vtkGL2PSContextDevice2D.h.
|
protected |
|
protectedvirtual |
|
static |
|
virtual |
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h.
Reimplemented from vtkOpenGLContextDevice2D.
|
static |
|
protectedvirtual |
Reimplemented from vtkOpenGLContextDevice2D.
vtkGL2PSContextDevice2D* vtkGL2PSContextDevice2D::NewInstance | ( | ) | const |
|
virtual |
Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes.
Reimplemented from vtkOpenGLContextDevice2D.
|
static |
|
virtual |
Draw a poly line using the points - fastest code path due to memory layout of the coordinates. The line will be colored by colors array which has nc_comps components. If colors is not set and the current Pen's alpha channel is zero, no OpenGL calls are emitted.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw a series of points - fastest code path due to memory layout of the coordinates. The colors and nc_comps are optional - color array.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw a series of point sprites, images centred at the points supplied. The supplied vtkImageData is the sprite to be drawn, only squares will be drawn and the size is set using SetPointSize.
colors | is an optional array of colors. |
nc_comps | is the number of components for the color. |
Reimplemented from vtkOpenGLContextDevice2D.
Draw a quad using the specified number of points.
Reimplemented from vtkOpenGLContextDevice2D.
Draw a polygon using the specified number of points.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw an elliptic wedge with center at x, y, outer radii outRx, outRy, inner radii inRx, inRy between angles startAngle and stopAngle (expressed in degrees).
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw an elliptic arc with center at x,y with radii rX and rY between angles startAngle and stopAngle (expressed in degrees).
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw a series of markers centered at the points supplied. The shape argument controls the marker shape, and can be one of - VTK_MARKER_CROSS - VTK_MARKER_PLUS - VTK_MARKER_SQUARE - VTK_MARKER_CIRCLE - VTK_MARKER_DIAMOND
colors | is an optional array of colors. |
nc_comps | is the number of components for the color. |
Reimplemented from vtkOpenGLContextDevice2D.
Draws a rectangle
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw some text to the screen!
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw some text to the screen.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Draw text using MathText markup for mathematical equations. See http://matplotlib.sourceforge.net/users/mathtext.html for more information.
Reimplemented from vtkOpenGLContextDevice2D.
void vtkGL2PSContextDevice2D::ApplyPen | ( | vtkPen * | pen | ) |
Apply the supplied pen which controls the outlines of shapes, as well as lines, points and related primitives. This makes a deep copy of the vtkPen object in the vtkContext2D, it does not hold a pointer to the supplied object.
|
virtual |
Set the point size for glyphs/sprites.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Set the line width for glyphs/sprites.
Reimplemented from vtkOpenGLContextDevice2D.
|
virtual |
Set the line type type (using anonymous enum in vtkPen).
Reimplemented from vtkOpenGLContextDevice2D.