Mako 7.3.0 API
JawsMako::CTransformState Class Reference

Class for tracking the graphics state leading to the point where a transform is applied. More...

#include <transforms.h>

Public Member Functions

 CTransformState (const IDOMNodePtr &node)
 Initialise to the state that would be active inside the given node. An atttempt will be made to determine the complete state by contatenating the state of all the parents of the given node. The best results will occur when the node's parents lead to an IDOMFixedPage.
 
CTransformState stateInsideNode (const IDOMNodePtr &node, bool updateTransform=true, bool updateClip=true, bool updateRenderingIntent=true, bool updateEdgeMode=true) const
 Return a new state consisting of this state concatenated with the state implied by the given node. More...
 
CTransformState stateInsideBrush (const IDOMBrushPtr &brush, eBrushUsage brushUsage) const
 Return a new state consisting of this state concatenated with the state implied by the given brush. More...
 

Public Attributes

FMatrix transform
 The current transformation from default coordinates.
 
bool hasClipBounds
 True if clipBounds is valid.
 
FRect clipBounds
 The bounds of the current clipping area.
 
IDOMColorSpacePtr groupColorSpace
 The current group color space.
 
bool hasRenderingIntent
 True if an explicit rendering intent has been applied.
 
eRenderingIntent renderingIntent
 Ignored if hasRenderingIntent is false.
 
eBlackPointCompensation blackPointCompensation
 The current black point compensation.
 
eEdgeMode edgeMode
 The current edge mode.
 
eBrushUsage brushUsage
 Set when we descend into a brush.
 
bool inUncoloredTilingBrush
 
void * transformPriv
 

Detailed Description

Class for tracking the graphics state leading to the point where a transform is applied.

Consider for example the IImageDownsamplerTransform described later in this header. In order to determine how to downsample an image, the transform needs to know how large the image will eventually be. The CTransformState provides this information by providing the combined transform that applies to the image based on the RenderTransforms of all the nodes entered leading to the point where the image is actually encountered.

Other transforms need access to other information, such as the approximate clip area, the current group color space, the renderingIntent (if present), the current antialiasing mode (edge mode) and/or how a brush is used.

Member Function Documentation

◆ stateInsideBrush()

CTransformState JawsMako::CTransformState::stateInsideBrush ( const IDOMBrushPtr &  brush,
eBrushUsage  brushUsage 
) const

Return a new state consisting of this state concatenated with the state implied by the given brush.

Parameters
brushThe brush whose state we wish to apply.
brushUsageThe way the brush would be used; ie for filling, stroking, or for use as an opacity mask.
Returns
The new state.

◆ stateInsideNode()

CTransformState JawsMako::CTransformState::stateInsideNode ( const IDOMNodePtr &  node,
bool  updateTransform = true,
bool  updateClip = true,
bool  updateRenderingIntent = true,
bool  updateEdgeMode = true 
) const

Return a new state consisting of this state concatenated with the state implied by the given node.

Parameters
nodeThe node whose state we wish to apply.
updateTransformIf true, update the transform entry, and also the related black point compensation entry.
updateClipIf true, update the clipBounds entry
updateRenderingIntentIf true, update the rendering intent.
Returns
The new state.

Member Data Documentation

◆ inUncoloredTilingBrush

bool JawsMako::CTransformState::inUncoloredTilingBrush

Set to true when we descend into an uncolored tiling brush (An IDOMTilingPatternBrush with PaintType == 2)

◆ transformPriv

void* JawsMako::CTransformState::transformPriv

Private contextual information for use by the transform implementation


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