Open Inventor Release 2024.2.0
 
Loading...
Searching...
No Matches
SoVectorizePSAction Class Reference

HardCopy Realizes the vectorization of a scene graph to a file in PostScript format. More...

#include <HardCopy/SoVectorizePSAction.h>

+ Inheritance diagram for SoVectorizePSAction:

Public Member Functions

virtual SoType getTypeId () const
 Returns the type identifier for this specific instance.
 
 SoVectorizePSAction ()
 Constructor.
 
virtual ~SoVectorizePSAction ()
 Destructor.
 
SoPSVectorOutputgetPSVectorOutput () const
 Returns the SoPSVectorOutput instance in action.
 
- Public Member Functions inherited from SoVectorizeAction
virtual ~SoVectorizeAction ()
 
virtual SoVectorOutputgetVectorOutput () const
 Output access method.
 
virtual void apply (SoNode *node)
 Initiates an action on the graph specified by a node.
 
virtual void apply (SoPath *path)
 Initiates an action on the graph specified by a path.
 
virtual void apply (const SoPathList &pathList, SbBool obeysRules=FALSE)
 Initiates an action on the graph specified by list of paths.
 
virtual void beginPage (const SbVec2f &startPagePosition, const SbVec2f &pageSize, DimensionUnit u=MM)
 Begin a new page.
 
virtual void endPage ()
 Ends a page.
 
virtual void setDrawingDimensions (float w, float h, DimensionUnit u=MM)
 Sets the dimensions of the drawing on the sheet of paper.
 
virtual void setDrawingDimensions (const SbVec2f &d, DimensionUnit u=MM)
 Sets the dimensions of the drawing on the sheet of paper.
 
virtual SbVec2f getDrawingDimensions (DimensionUnit u=MM) const
 Returns the dimensions of the drawing on the sheet of paper.
 
virtual void setStartPosition (float x, float y, DimensionUnit u=MM)
 Sets the start position of the drawing on the sheet of paper.
 
virtual void setStartPosition (const SbVec2f &p, DimensionUnit u=MM)
 Sets the start position of the drawing on the sheet of paper.
 
virtual SbVec2f getStartPosition (DimensionUnit u=MM) const
 Returns the start position of the drawing on the sheet of paper.
 
virtual void setOrientation (Orientation o)
 Sets the orientation of the drawing on the sheet of paper.
 
virtual Orientation getOrientation () const
 Returns the orientation of the drawing on the sheet of paper.
 
virtual void setBorder (float width)
 Sets the width of the border of the clipping limits.
 
virtual void setBorder (float width, SbColor color)
 Sets the color and the width of the border of the clipping limits.
 
virtual void getBorder (float *w, SbColor *color) const
 Returns the color and the width of the border of the clipping limits.
 
virtual void setBackgroundColor (SbBool bg)
 Enables or disables the background and sets its color to white.
 
virtual void setBackgroundColor (SbBool bg, SbColor color)
 Sets the color of the background.
 
virtual SbBool getBackgroundColor (SbColor *color) const
 Returns the color of the background.
 
virtual void setNominalWidth (float w, DimensionUnit u=MM)
 Sets the nominal width.
 
virtual float getNominalWidth (DimensionUnit u=MM) const
 Returns the nominal width.
 
virtual void setLinePatternSize (float w, DimensionUnit u=MM)
 Sets the line pattern size, i.e., the association between printer pattern (16 printer "points") and the size of the line pattern on the hard copy output.
 
virtual float getLinePatternSize (DimensionUnit u=MM) const
 Returns the line pattern scale factor.
 
virtual void setPixelImageSize (float w, DimensionUnit u=MM)
 Sets the size of a pixel for image primitives.
 
virtual float getPixelImageSize (DimensionUnit u=MM) const
 Returns the size of a pixel.
 
virtual void setColorTranslationMethod (ColorTranslationMethod method)
 Sets the method for choosing the color of the drawing on the sheet of paper.
 
virtual ColorTranslationMethod getColorTranslationMethod () const
 Returns the method for choosing the color of the drawing on the sheet of paper.
 
virtual void setLineEndStyle (EndLineStyle style)
 Sets the style for line ends.
 
virtual EndLineStyle getLineEndStyle () const
 Returns the style for line ends.
 
virtual void setLineJoinsStyle (JoinLineStyle style)
 Sets the style for line joins.
 
virtual JoinLineStyle getLineJoinsStyle () const
 Returns the style for line joins.
 
virtual void setMiterLimit (float limit)
 Sets the miter limit.
 
virtual float getMiterLimit () const
 Returns the miter limit.
 
virtual void setPenDescription (int num_pens, const SbColor *colors=0, const float *widths=0, DimensionUnit u=MM)
 Sets the description of the color and the width of each pen.
 
virtual void getPenDescription (SbColor *colors, float *widths, DimensionUnit u=MM) const
 Returns the description of the color and the width of each pen.
 
virtual int getPenNum () const
 Returns the number of pens.
 
virtual void setColorPriority (SbBool priority)
 Sets the color priority flag.
 
virtual SbBool getColorPriority (void) const
 Returns the color priority.
 
virtual void setHLHSRMode (HLHSRMode mode)
 Sets the Hidden Line and Hidden Surface Removal mode.
 
HLHSRMode getHLHSRMode () const
 Returns the Hidden Line and Hidden Surface Removal mode.
 
void setHLHSRRasterQuality (float quality)
 Sets the quality of the raster image generated to vectorize visible primitives with the HLHSR_RASTER algorithm.
 
float getHLHSRRasterQuality () const
 Returns the raster image quality value.
 
void setHLHSRRasterCaching (SbBool enable)
 Enables/disables the use of OpenGL display lists to generate the raster image with the HLHSR_RASTER algorithm.
 
SbBool getHLHSRRasterCaching () const
 Returns the raster caching flag.
 
virtual void enableLighting (SbBool flag)
 Allows the user to enable/disable the taking into account of lights in the scene graph during the computation of the vectorized file.
 
SbBool isLightingEnabled () const
 Returns TRUE if lighting is enabled.
 
void setShadeModel (ShadeModel model)
 Selects FLAT or SMOOTH shading.
 
ShadeModel getShadeModel ()
 Returns the shade model.
 
void setPolygonOffset (float offset)
 Method to set the Z offset to be applied to polygons in normalized device coordinates (-1 to 1 space).
 
void setLineOffset (float offset)
 Sets line offset.
 
void setMarkerOffset (float offset)
 Sets marker offset.
 
float getPolygonOffset () const
 Returns polygon offset.
 
float getLineOffset () const
 Returns line offset.
 
float getMarkerOffset () const
 Returns marker offset.
 
- Public Member Functions inherited from SoAction
virtual ~SoAction ()
 Destructor.
 
virtual void clearApplyResult ()
 When applied, an action may reference nodes or create objects (e.g.
 
virtual void invalidateState ()
 Invalidates the current traversal state in the action, forcing it to be recreated when the action is next applied.
 
void stopActionInBranch ()
 This function stops the action in the current Scene Graph branch.
 
SbBool getContinueActionInBranchFlag () const
 This function indicates if the action must stop in the current branch.
 
void resetContinueActionInBranchFlag ()
 This function resets the continue action flag.
 
void useAlternateRep (const SbBool enable)
 Tell the action to use alternate representations during traversal when available.
 
SbBool isUsingAlternateRep () const
 Returns TRUE if current action is using alternate representations.
 
void setSceneManager (SoSceneManager *mgr)
 Set the scene manager associated with this action (if any ).
 
SoSceneManagergetSceneManager () const
 Return the SoSceneManager associated with this action.
 
virtual void forwardTraversal (SoNode *node)
 Traverse a node that is not part of the current scenegraph.
 
virtual void forwardTraversal (SoPath *path)
 Traverse a path that is not part of the current scenegraph.
 
DistribMode getDistribMode () const
 Returns the distribution mode of this action across a cluster (ScaleViz-Cluster only).
 
AppliedCode getWhatAppliedTo () const
 Returns code indicating what action is being applied to.
 
SoNodegetNodeAppliedTo () const
 Returns the node the action is being applied to.
 
SoPathgetPathAppliedTo () const
 Returns the path the action is being applied to.
 
const SoPathListgetPathListAppliedTo () const
 Returns the path list the action is being applied to.
 
const SoPathListgetOriginalPathListAppliedTo () const
 Returns the original path list the action is being applied to.
 
SbBool isLastPathListAppliedTo () const
 Returns TRUE if the current list is the last one from the original.
 
PathCode getPathCode (int &numIndices, const int *&indices)
 Returns path code based on where current node (the node at the end of the current path) lies with respect to the path(s) the action is being applied to.
 
PathCode getPathCodeMI (int &numIndices, const int *&indices, const int *&instanceIndices)
 Extender API: available to programmers who wish to extend the toolkit
 
void traverse (SoNode *node)
 Does traversal of a graph rooted by a node.
 
SbBool hasTerminated () const
 Returns TRUE if the traversal has reached a termination condition.
 
const SoPathgetCurPath ()
 Returns the path accumulated during traversal, i.e., the chain of nodes from the root of the traversed graph to the current node being traversed.
 
SoStategetState () const
 Gets the state from the action.
 
virtual void setUpState ()
 Creates state if it is NULL or it is no longer valid because new elements have been enabled since it was created.
 
void setPipeId (int id)
 Sets pipe identifier in the range [1..N] associated to this render action while running a ScaleViz Multipipe configuration.
 
int getPipeId () const
 Gets pipe identifier in the range [1..N] associated to this render action while running a ScaleViz Multipipe configuration.
 
bool isBeingApplied ()
 Returns TRUE if this action is currently being applied.
 
virtual bool preDelayedTraversal ()
 Method called by SoMultiPassManager before delayed pass traversals.
 
virtual void postDelayedTraversal ()
 Method called by SoMultiPassManager after delayed pass traversals.
 
- Public Member Functions inherited from SoTypedObject
SbBool isOfType (const SoType &type) const
 Returns TRUE if this object is of the type specified in type or is derived from that type.
 
template<typename TypedObjectClass >
SbBool isOfType () const
 Returns TRUE if this object is of the type of class TypedObjectClass or is derived from that class.
 

Static Public Member Functions

static SoType getClassTypeId ()
 Returns the type identifier for this class.
 
- Static Public Member Functions inherited from SoVectorizeAction
static SoType getClassTypeId ()
 Returns the type identifier for this class.
 
- Static Public Member Functions inherited from SoAction
static SoType getClassTypeId ()
 Returns the type identifier for this class.
 
static void nullAction (SoAction *, SoNode *)
 Null action method that can be stored in lookup table when desired.
 
- Static Public Member Functions inherited from SoTypedObject
static SoType getClassTypeId ()
 Returns the type identifier for this class.
 

Additional Inherited Members

- Public Types inherited from SoVectorizeAction
enum  DimensionUnit {
  INCH ,
  MM ,
  METER
}
 Dimension unit. More...
 
enum  ShadeModel {
  FLAT ,
  SMOOTH
}
 Shading models. More...
 
enum  Orientation {
  PORTRAIT ,
  LANDSCAPE
}
 Orientation type. More...
 
enum  ColorTranslationMethod {
  REVERSE_ONLY_BLACK_AND_WHITE ,
  AS_IS ,
  REVERSE
}
 Color translation methods. More...
 
enum  JoinLineStyle {
  NO_JOIN ,
  MITERED_JOIN ,
  MITERED_BEVELED_JOIN ,
  BEVELED_JOIN ,
  TRIANGULAR_JOIN ,
  ROUNDED_JOIN
}
 Join line style. More...
 
enum  EndLineStyle {
  BUTT_END ,
  SQUARE_END ,
  TRIANGULAR_END ,
  ROUND_END
}
 End line style. More...
 
enum  HLHSRMode {
  NO_HLHSR ,
  HLHSR_SIMPLE_PAINTER ,
  HLHSR_PAINTER ,
  HLHSR_PAINTER_SURFACE_REMOVAL ,
  HLHSR_RASTER ,
  HIDDEN_LINES_REMOVAL
}
 HLHSR (Hidden Line and Hidden Surface Removal) mode. More...
 
- Public Types inherited from SoAction
enum  DistribMode {
  LOCAL_ONLY ,
  CLUSTER_ONLY ,
  ALL
}
 This is used to define the way an action is distributed across a cluster. More...
 
enum  AppliedCode {
  NODE ,
  PATH ,
  PATH_LIST
}
 This enum is used to determine what the action is being applied to. More...
 
enum  PathCode {
  NO_PATH ,
  IN_PATH ,
  BELOW_PATH ,
  OFF_PATH
}
 This enum may be used during traversal of nodes to indicate where the node is with respect to the path being traversed. More...
 

Detailed Description

HardCopy Realizes the vectorization of a scene graph to a file in PostScript format.

This class is used for vectorizing scene graphs to PostScript format files. It contains an SoPSVectorOutput instance which writes by default to standard output. Methods on SoPSVectorOutput can be called to specify what file to write to.

Limitations:

  • End line style TRIANGULAR is not supported; end line style ROUND is assumed instead.
  • Join line style NONE, MITERED_BEVELED, and TRIANGULAR are not supported; join line styles BEVELED, MITERED, and ROUNDED are assumed instead.
  • For LANDSCAPE orientation, the start position is the upper-left corner.
  • See additional limitations in SoVectorizeAction.

Definition at line 148 of file SoVectorizePSAction.h.

Constructor & Destructor Documentation

◆ SoVectorizePSAction()

SoVectorizePSAction::SoVectorizePSAction ( )

Constructor.

◆ ~SoVectorizePSAction()

virtual SoVectorizePSAction::~SoVectorizePSAction ( )
virtual

Destructor.

Member Function Documentation

◆ getClassTypeId()

static SoType SoVectorizePSAction::getClassTypeId ( )
static

Returns the type identifier for this class.


◆ getPSVectorOutput()

SoPSVectorOutput * SoVectorizePSAction::getPSVectorOutput ( ) const

Returns the SoPSVectorOutput instance in action.

◆ getTypeId()

virtual SoType SoVectorizePSAction::getTypeId ( ) const
virtual

Returns the type identifier for this specific instance.

Reimplemented from SoVectorizeAction.


The documentation for this class was generated from the following file: