COPASI API
4.16.103
|
#include <CLLayoutRenderer.h>
Public Member Functions | |
void | addToSelection (CLGraphicalObject *pObject) |
void | analyse_render_information (double lx, double ly, double rx, double ry) |
void | change_style (const CLGlobalRenderInformation *pRenderInformation, bool defaultStyle=false) |
void | change_style (const CLLocalRenderInformation *pRenderInformation) |
void | clearSelection () |
CLLayoutRenderer (CLayout *pLayout, const CLGlobalRenderInformation *pRenderInformation, const CCopasiVector< CLGlobalRenderInformation > *pGlobalRenderInformationList, const CModel *pModel, const std::string &baseDir) | |
CLLayoutRenderer (CLayout *pLayout, const CLLocalRenderInformation *pRenderInformation, const CCopasiVector< CLGlobalRenderInformation > *pGlobalRenderInformationList, const CModel *pModel, const std::string &baseDir) | |
std::pair< double, double > | convert_to_model_space (double x, double y) const |
void | draw_layout () |
double | getAspect () const |
const GLfloat * | getFogColor () const |
GLfloat | getFogDensity () const |
const GLfloat * | getHighlightColor () const |
const std::set< const CLGraphicalObject * > & | getHighlightedObjects () const |
std::set< const CLGraphicalObject * > & | getHighlightedObjects () |
bool | getHighlightFlag () const |
std::multiset < CLGraphicalObject *, compareGraphicalObjectsBySize > | getObjectsAt (double x, double y) |
std::multiset < CLGraphicalObject *, compareGraphicalObjectsBySize > | getObjectsAtViewportPosition (unsigned int x, unsigned int y) |
std::vector< CLGraphicalObject * > | getObjectsInBoundingBox (double lx, double ly, double rx, double ry, bool partial=true) |
std::set< CLGraphicalObject * > & | getSelection () |
const std::set < CLGraphicalObject * > & | getSelection () const |
CLBoundingBox * | getSelectionBox () |
const CLBoundingBox * | getSelectionBox () const |
double | getZoomFactor () const |
bool | isSelected (const CLGraphicalObject *) const |
bool | isSetDeduceSpeciesReferenceRoles () const |
void | move_curve_object (CLCurve *pCurve, double dx, double dy, bool leaveStartPoint=false, bool leaveEndpoint=false) |
void | move_graphical_object (CLGraphicalObject *pObject, double dx, double dy) |
void | move_reaction_glyph (CLReactionGlyph *pRG, double dx, double dy, bool moveSelectedAssociation=false) |
void | move_selection (double dx, double dy, bool moveAssociated=true) |
void | move_species_glyph (CLMetabGlyph *pSG, double dx, double dy, bool moveSelectedAssociations=false) |
void | move_species_reference_glyph (CLMetabReferenceGlyph *pSRG, double dx, double dy) |
void | move_text_glyph (CLTextGlyph *pTG, double dx, double dy) |
void | removeFromSelection (CLGraphicalObject *pObject) |
void | resize (GLsizei w, GLsizei h) |
void | set_font_renderer (CLFontRendererBase *pFontRenderer) |
void | setAspect (double aspect) |
void | setDeduceSpeciesReferenceRoles (bool deduce) |
void | setFogColor (const GLfloat c[4]) |
void | setFogDensity (GLfloat dens) |
void | setHighlightColor (const GLfloat c[4]) |
void | setHighlightedObjects (const std::set< const CLGraphicalObject * > &highlightedObjects) |
void | setHighlightFlag (bool flag) |
void | setImageTexturizer (CLImageTexturizer *pTexturizer) |
void | setSelectionBox (const CLBoundingBox *pBox) |
void | setX (double x) |
void | setY (double y) |
void | setZoomFactor (double zoomFactor) |
void | toggleHighlightFlag () |
~CLLayoutRenderer () | |
Static Public Member Functions | |
static double | distance (const CLPoint &p1, const CLPoint &p2) |
static CLBoundingBox * | getCurveBoundingBox (const CLCurve *pCurve) |
static bool | is_curve_segment_visible (const CLLineSegment &segment, double lx, double ly, double rx, double ry, bool partial) |
static bool | is_curve_visible (const CLCurve &curve, double lx, double ly, double rx, double ry, bool partial) |
static CLCurve * | revert_curve (const CLCurve *pCurve) |
Protected Member Functions | |
void | clear_cached_data () |
void | create_gradient_texture (unsigned int size, GLubyte *pData, const CLGradientBase *pGradient, double z_value=0.0) |
void | create_linear_gradient_texture (unsigned int size, GLubyte *pData, const CLLinearGradient *pGradient, double z_value) |
void | create_radial_gradient_texture (unsigned int size, GLubyte *pData, const CLRadialGradient *pGradient, double z_value) |
void | draw_cap (double x1, double y1, double z1, double x2, double y2, double z2, double x3, double y3, double z3, double stroke_width) |
void | draw_curve (const CLCurve *pCurve, bool drawBasepoints=false) |
void | draw_curve (const CLRenderCurve *pCurve, const CLBoundingBox *pBB) |
void | draw_datapoints (GLdouble *pData, size_t numPoints, const CLBoundingBox *pBB, bool doTesselation=false, float xOffset=0.0, float yOffset=0.0, float zOffset=0.0) |
void | draw_ellipse (const CLEllipse *pEllipse, const CLBoundingBox *pBB) |
void | draw_group (const CLGroup *pGroup, const CLBoundingBox *pBB) |
void | draw_image (const CLImage *pImage, const CLBoundingBox *pBB) |
void | draw_line (size_t numPoints, GLdouble *pData) |
void | draw_line_segment (double x1, double y1, double z1, double x2, double y2, double z2, double line_width, bool texture=false, double s1=0.0, double s2=0.0) |
void | draw_object (const CLStyle *pStyle, const CLBoundingBox *pBB) |
void | draw_polygon (const CLPolygon *pPolygon, const CLBoundingBox *pBB) |
void | draw_rectangle (const CLRectangle *pRectangle, const CLBoundingBox *pBB) |
void | draw_selection_box () const |
void | draw_text (const CLStyle *pStyle, const CLBoundingBox *pBB, const CLTextTextureSpec *pTexture) |
void | draw_text (const CLText *pText, const CLBoundingBox *pBB) |
void | draw_text (const CLTextTextureSpec *pTexture, double x, double y, double z, const CLBoundingBox *pBB) |
void | initialize_gl_extension_functions () |
void | map_arrow_head (const CLPoint &p, const CLPoint &v, const std::string &headId) |
void | map_gradient_color (double rel_distance, const CLGradientBase *pGradient, GLubyte *pData) |
void | resolve_color (const std::string &color, GLubyte array[4]) |
void | restore_current_attributes () |
void | save_current_attributes () |
void | segment_data (double length, double ratio, size_t numPoints, GLdouble *pData, std::vector< simple_point > &v) |
void | update_associations () |
void | update_colors (const CLGradientBase *pGradient) |
void | update_drawables (double lx, double ly, double rx, double ry) |
void | update_style_information () |
void | update_textures_and_colors () |
void | update_textures_and_colors (const CLGroup *pGroup, double maxDimension, double height, const std::string &parentFill="", CLFontSpec parentFontSpec=CLFontSpec()) |
Static Protected Member Functions | |
static void | calculate_cubicbezier (double sx, double sy, double sz, double p1x, double p1y, double p1z, double p2x, double p2y, double p2z, double ex, double ey, double ez, unsigned int numPoints, GLdouble *pData) |
static CLPoint * | calculate_intersection (double p1x, double p1y, double p1z, double sx, double sy, double sz, double p2x, double p2y, double p2z, double tx, double ty, double tz) |
static std::pair< double, double > | calculate_intersection_point_2d (double p1x, double p1y, double sx, double sy, double p2x, double p2y, double tx, double ty) |
static void | COMBINE_CALLBACK (GLdouble coords[3], GLdouble **, GLfloat *, GLdouble **dataOut) |
static void | COMBINE_CALLBACK_GRADIENT (GLdouble coords[3], GLdouble *vertex_data[4], GLfloat weight[4], GLdouble **dataOut) |
static const CLPoint | convert_to_absolute (const CLRenderPoint *pRenderPoint, const CLBoundingBox *pBB) |
static void | createGLMatrix (const double *const matrix, GLdouble *glMatrix) |
static CLLineStippleTexture * | createLineStippleTexture (const std::vector< unsigned int > &dasharray) |
static double | distancePointLineSegment (double x, double y, double lx1, double ly1, double lx2, double ly2) |
static void | drawSelectionBox (double x, double y, double width, double height, bool drawHandles=false) |
static void | extract_1d_attributes (const CLGraphicalPrimitive1D *pObject, CLGroupAttributes *attributes) |
static void | extract_2d_attributes (const CLGraphicalPrimitive2D *pObject, CLGroupAttributes *attributes) |
template<typename T > | |
static void | extract_arrowhead_information (const T *pObject, CLGroupAttributes *attributes) |
static void | extract_group_attributes (const CLStyle *pStyle, CLGroupAttributes *attributes) |
static void | extract_group_attributes (const CLGroup *pGroup, CLGroupAttributes *attributes) |
template<typename T > | |
static void | extract_text_attributes (const T *pObject, CLGroupAttributes *attributes) |
static void | extract_transformation_attributes (const CLTransformation *pObject, CLGroupAttributes *attributes) |
static CLFontSpec | getFontSpec (const CLGroup *pGroup, double boxHeight, const CLFontSpec &parentFontSpec=CLFontSpec()) |
static CLFontSpec | getFontSpec (const CLText *pText, double boxHeight, const CLFontSpec &parentFontSpec=CLFontSpec()) |
static bool | isSegmentHit (const CLLineSegment *pLS, double x, double y, double toleranceRadius) |
static const std::string | resolve_text (const CLTextGlyph *pTextGlyph) |
static bool | segments_intersect_2d (double p1x1, double p1y1, double p1x2, double p1y2, double p2x1, double p2y1, double p2x2, double p2y2) |
static void | TESS_ERROR (GLenum error) |
static void | VERTEX_CALLBACK_GRADIENT (GLvoid *vertex) |
Static Protected Attributes | |
static const double | ALMOST_ZERO = 1e-12 |
static const unsigned int | GRADIENT_TEXTURE_SIZE_LIMIT = 512 |
static const unsigned int | NUM_BEZIER_POINTS = 20 |
static const unsigned int | NUM_CIRCLE_SEGMENTS = 60 |
static const unsigned int | NUM_CORNER_SEGMENTS = 10 |
static const double | SELECTION_FRAME_WIDTH = 3.0 |
Definition at line 61 of file CLLayoutRenderer.h.
CLLayoutRenderer::CLLayoutRenderer | ( | CLayout * | pLayout, |
const CLGlobalRenderInformation * | pRenderInformation, | ||
const CCopasiVector< CLGlobalRenderInformation > * | pGlobalRenderInformationList, | ||
const CModel * | pModel, | ||
const std::string & | baseDir | ||
) |
constructor for global render information
Definition at line 103 of file CLLayoutRenderer.cpp.
References change_style(), mFogColor, and mHighlightColor.
CLLayoutRenderer::CLLayoutRenderer | ( | CLayout * | pLayout, |
const CLLocalRenderInformation * | pRenderInformation, | ||
const CCopasiVector< CLGlobalRenderInformation > * | pGlobalRenderInformationList, | ||
const CModel * | pModel, | ||
const std::string & | baseDir | ||
) |
constructor for local render information
Definition at line 140 of file CLLayoutRenderer.cpp.
References change_style(), initialize_gl_extension_functions(), mFogColor, and mHighlightColor.
CLLayoutRenderer::~CLLayoutRenderer | ( | ) |
destructor.
Definition at line 234 of file CLLayoutRenderer.cpp.
References clear_cached_data(), mpFontRenderer, mpResolver, and mpSelectionBox.
void CLLayoutRenderer::addToSelection | ( | CLGraphicalObject * | pObject | ) |
This method adds a graphical object to the set of selected objects.
Definition at line 4968 of file CLLayoutRenderer.cpp.
References draw_layout(), and mSelection.
Referenced by CQGLLayoutPainter::mousePressEvent(), and CQGLLayoutPainter::mouseReleaseEvent().
void CLLayoutRenderer::analyse_render_information | ( | double | lx, |
double | ly, | ||
double | rx, | ||
double | ry | ||
) |
Analyses the render information and creates some of the textures. First it determines which object are drawn based on the viewport coordinates that are passed in. Next it resolves the styles for all the objects that are to be drawn and it determines the size of the textures. Last it creates all textures.
Definition at line 3310 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO, update_drawables(), update_style_information(), and update_textures_and_colors().
Referenced by change_style(), resize(), and setDeduceSpeciesReferenceRoles().
|
staticprotected |
Calculates the points for a cubic bezier curve. The algorithm calculates numPoints and stores them in pData. pData has to be an array with enough space for numPoints*3 GLfloat items.
Definition at line 3036 of file CLLayoutRenderer.cpp.
Referenced by draw_curve(), draw_polygon(), is_curve_segment_visible(), and isSegmentHit().
|
staticprotected |
calculates the intersection point of two lines. The caller has to delete the returned point object.
Definition at line 4574 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO, CLPoint::getX(), CLPoint::getY(), and CLPoint::getZ().
Referenced by draw_cap().
|
staticprotected |
Calculates the intersection point between two lines in 2D. The intersection point is returned. If the lines are parallel, a point with two NaN values is returned. All numbers <= ALMOST_ZERO are considered to be 0.
Definition at line 4470 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO.
Referenced by segments_intersect_2d().
void CLLayoutRenderer::change_style | ( | const CLGlobalRenderInformation * | pRenderInformation, |
bool | defaultStyle = false |
||
) |
This method replaces the current style with the given global render information.
Definition at line 174 of file CLLayoutRenderer.cpp.
References analyse_render_information(), clear_cached_data(), mDeduceSpeciesReferenceRoles, mH, mpFontRenderer, mpGlobalRenderInfoList, mpResolver, mSpeciesReferencesWithDeducedRole, mW, mX, mY, mZoomFactor, CLRenderResolver::setDeducedObjectRoles(), and setDeduceSpeciesReferenceRoles().
Referenced by CQGLLayoutPainter::change_style(), and CLLayoutRenderer().
void CLLayoutRenderer::change_style | ( | const CLLocalRenderInformation * | pRenderInformation | ) |
This method replaces the current style with the given glocal render information.
Definition at line 205 of file CLLayoutRenderer.cpp.
References analyse_render_information(), clear_cached_data(), CLayout::getListOfLocalRenderInformationObjects(), mDeduceSpeciesReferenceRoles, mH, mpFontRenderer, mpGlobalRenderInfoList, mpLayout, mpResolver, mSpeciesReferencesWithDeducedRole, mW, mX, mY, mZoomFactor, and CLRenderResolver::setDeducedObjectRoles().
|
protected |
Removes all entries from all cache maps and frees the memory for the textures.
Definition at line 4378 of file CLLayoutRenderer.cpp.
References mColorMap, mDrawables, mFontTextureMap, mGradientMap, mImageMap, mLineEndingMap, mLinestippleMap, mStyleMap, mTextGlyphMap, and mTextMap.
Referenced by change_style(), setDeduceSpeciesReferenceRoles(), and ~CLLayoutRenderer().
void CLLayoutRenderer::clearSelection | ( | ) |
This method clears the selection.
Definition at line 5020 of file CLLayoutRenderer.cpp.
References mSelection.
Referenced by CQGLLayoutPainter::mousePressEvent(), and CQGLLayoutPainter::mouseReleaseEvent().
|
staticprotected |
This static method is used as a callback for the GLU tesselator. It is needed for polygons that intersect which itself and the tesselator has to create a new vertex at the intersection.
Definition at line 2983 of file CLLayoutRenderer.cpp.
Referenced by draw_datapoints().
|
staticprotected |
This static method is used as a callback for the GLU tesselator. It is needed for polygons that intersect which itself and the tesselator has to create a new vertex at the intersection.
Definition at line 2994 of file CLLayoutRenderer.cpp.
Referenced by draw_datapoints().
|
staticprotected |
Converts a given RenderPoint which can have relative values into a layout Point with only absolute values.
Converts a given CLRenderPoint which can have relative values into a layout CLPoint with only absolute values. Even the absolute values of the point which are relative to the bounding box are translated into absolute coordinates.
Definition at line 924 of file CLLayoutRenderer.cpp.
References CLRelAbsVector::getAbsoluteValue(), CLDimensions::getDepth(), CLBoundingBox::getDimensions(), CLDimensions::getHeight(), CLBoundingBox::getPosition(), CLRelAbsVector::getRelativeValue(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), CLRenderPoint::x(), CLRenderPoint::y(), and CLRenderPoint::z().
Referenced by draw_curve(), draw_image(), draw_polygon(), and draw_rectangle().
std::pair< double, double > CLLayoutRenderer::convert_to_model_space | ( | double | x, |
double | y | ||
) | const |
converts the given coordinates from viewport space into model space.
Definition at line 6575 of file CLLayoutRenderer.cpp.
References mX, mY, and mZoomFactor.
Referenced by getObjectsAtViewportPosition(), CQGLLayoutPainter::mouseMoveEvent(), CQGLLayoutPainter::mouseReleaseEvent(), and CQGLLayoutPainter::update_status_and_cursor().
|
protected |
This method calculates a texture for a given gradient definition and a given size. The data object has to be a vector that can store RGBA values for a rectangle of the given size. The memory has to be allocated before calling the method. The scale specifies by how much the original box has been scaled.
Definition at line 2139 of file CLLayoutRenderer.cpp.
References create_linear_gradient_texture(), and create_radial_gradient_texture().
Referenced by update_textures_and_colors().
|
protected |
This method calculates a texture for a given linear gradient definition and a given size. The data object has to be a vector that can store RGBA values for a rectangle of the given size. The memory has to be allocated before calling the method. The scale specifies by how much the original box has been scaled.
Definition at line 2172 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO, CLGradientStops::color(), CLRelAbsVector::getAbsoluteValue(), CLRelAbsVector::getRelativeValue(), CLLinearGradient::getXPoint1(), CLLinearGradient::getXPoint2(), CLLinearGradient::getYPoint1(), CLLinearGradient::getYPoint2(), CLLinearGradient::getZPoint1(), CLLinearGradient::getZPoint2(), CLRGBAColor::mA, CLRGBAColor::mB, mColorMap, CLRGBAColor::mG, CLRGBAColor::mR, mZoomFactor, and CLGradientStops::update_color().
Referenced by create_gradient_texture().
|
protected |
This method calculates a texture for a given radial gradient definition and a given size. The data object has to be a vector that can store RGBA values for a rectangle of the given size. The memory has to be allocated before calling the method. The scale specifies by how much the original box has been scaled.
Definition at line 2292 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO, CLGradientStops::color(), CLRelAbsVector::getAbsoluteValue(), CLRadialGradient::getCenterX(), CLRadialGradient::getCenterY(), CLRadialGradient::getFocalPointX(), CLRadialGradient::getFocalPointY(), CLRadialGradient::getRadius(), CLRelAbsVector::getRelativeValue(), CLRGBAColor::mA, CLRGBAColor::mB, mColorMap, CLRGBAColor::mG, CLRGBAColor::mR, mZoomFactor, and CLGradientStops::update_color().
Referenced by create_gradient_texture().
|
staticprotected |
Definition at line 3185 of file CLLayoutRenderer.cpp.
Referenced by draw_curve(), draw_datapoints(), draw_group(), draw_image(), and draw_text().
|
staticprotected |
Creates a 1D texture for the line stippling. The caller is responsible for deleting the returned object. If the dasharray does not contain a valid stipple pattern NULL is returned.
Definition at line 3211 of file CLLayoutRenderer.cpp.
Referenced by update_textures_and_colors().
calculates the distance between two layout points.
Definition at line 7136 of file CLLayoutRenderer.cpp.
References CLPoint::getX(), and CLPoint::getY().
Referenced by distancePointLineSegment(), isSegmentHit(), CQGLLayoutPainter::mouseMoveEvent(), update_associations(), and CQGLLayoutPainter::update_status_and_cursor().
|
staticprotected |
Calculates the distance between a point and a line segment. It tries to calculate the intersection point of the line and another line perpendicular to the first line through the given point. If this intersection point is on the line segment, the result is the same as the distance between the two lines, otherwise the distance is the distance of the given point to the closest endpoint of the segment.
Definition at line 5418 of file CLLayoutRenderer.cpp.
References distance().
Referenced by isSegmentHit().
|
protected |
Routine to draw the caps between two line segments. The method takes the three points that make the two line segments and the width of the line.
Definition at line 4164 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO, calculate_intersection(), CLPoint::getX(), CLPoint::getY(), and CLPoint::getZ().
Referenced by draw_datapoints(), and draw_line().
Method that draws a curve from the layout extension. All the other parameter like color, linewidth etc. have to be set before.
Definition at line 353 of file CLLayoutRenderer.cpp.
References calculate_cubicbezier(), createGLMatrix(), draw_line(), CLLineSegment::getBase1(), CLLineSegment::getBase2(), CLLineSegment::getEnd(), CLTransformation::getIdentityMatrix(), CLCurve::getNumCurveSegments(), CLCurve::getSegmentAt(), CLLineSegment::getStart(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), CLLineSegment::isBezier(), CLRGBAColor::mA, map_arrow_head(), CLRGBAColor::mB, mColorMap, mCurrentAttributes, CLGroupAttributes::mEndHead, CLRGBAColor::mG, CLGroupAttributes::mpTransform, CLRGBAColor::mR, CLGroupAttributes::mStartHead, CLGroupAttributes::mStroke, CLGroupAttributes::mStrokeWidth, simple_point::mX, CLGroupAttributes::mX, simple_point::mY, simple_point::mZ, NUM_BEZIER_POINTS, and NUM_CIRCLE_SEGMENTS.
Referenced by draw_group(), and draw_layout().
|
protected |
Method that draws a curve from the render extension. All the other parameter like color, linewidth etc. have to be set before.
Definition at line 729 of file CLLayoutRenderer.cpp.
References CLRenderCubicBezier::basePoint1_X(), CLRenderCubicBezier::basePoint1_Y(), CLRenderCubicBezier::basePoint1_Z(), CLRenderCubicBezier::basePoint2_X(), CLRenderCubicBezier::basePoint2_Y(), CLRenderCubicBezier::basePoint2_Z(), calculate_cubicbezier(), convert_to_absolute(), createGLMatrix(), draw_line(), extract_1d_attributes(), extract_arrowhead_information(), CLRenderCurve::getCurveElement(), CLTransformation::getIdentityMatrix(), CLRenderCurve::getNumElements(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), map_arrow_head(), mColorMap, mCurrentAttributes, CLGroupAttributes::mEndHead, CLGroupAttributes::mpTransform, CLGroupAttributes::mStartHead, CLGroupAttributes::mStroke, simple_point::mX, CLGroupAttributes::mX, simple_point::mY, simple_point::mZ, NUM_BEZIER_POINTS, restore_current_attributes(), save_current_attributes(), CLRenderPoint::x(), CLRenderPoint::y(), and CLRenderPoint::z().
|
protected |
Draw a set of datapoints with the current attributes using the given bounding box.
Method to draw a render polygon from a set of datapoints
Definition at line 2693 of file CLLayoutRenderer.cpp.
References COMBINE_CALLBACK(), COMBINE_CALLBACK_GRADIENT(), createGLMatrix(), draw_cap(), draw_line(), CLGraphicalPrimitive2D::EVENODD, CCopasiMessage::EXCEPTION, CLBoundingBox::getDimensions(), CLDimensions::getHeight(), CLBoundingBox::getPosition(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), CLGraphicalPrimitive2D::INHERIT, CLRGBAColor::mA, CLRGBAColor::mB, mColorMap, mCurrentAttributes, CLGroupAttributes::mFill, CLGroupAttributes::mFillRule, CLRGBAColor::mG, mGradientMap, CLGroupAttributes::mpTransform, CLRGBAColor::mR, CLGroupAttributes::mStroke, CLGroupAttributes::mStrokeWidth, CLGroupAttributes::mX, CLGraphicalPrimitive2D::NONZERO, TESS_ERROR(), CLGraphicalPrimitive2D::UNSET, and VERTEX_CALLBACK_GRADIENT().
Referenced by draw_ellipse(), draw_polygon(), and draw_rectangle().
|
protected |
Method to draw a render ellipse object.
Definition at line 1659 of file CLLayoutRenderer.cpp.
References draw_datapoints(), extract_2d_attributes(), CLRelAbsVector::getAbsoluteValue(), CLEllipse::getCX(), CLEllipse::getCY(), CLEllipse::getCZ(), CLDimensions::getDepth(), CLBoundingBox::getDimensions(), CLDimensions::getHeight(), CLBoundingBox::getPosition(), CLRelAbsVector::getRelativeValue(), CLEllipse::getRX(), CLEllipse::getRY(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), mCurrentAttributes, NUM_CIRCLE_SEGMENTS, restore_current_attributes(), and save_current_attributes().
Referenced by draw_group().
|
protected |
Method to draw an arbitrary object specified by it's bounding box and the style with which it should be drawn.
Definition at line 1346 of file CLLayoutRenderer.cpp.
References createGLMatrix(), draw_curve(), draw_ellipse(), draw_image(), draw_polygon(), draw_rectangle(), draw_text(), extract_group_attributes(), CLBoundingBox::getDimensions(), CLGroup::getElement(), CLDimensions::getHeight(), CLGroup::getNumElements(), CLBoundingBox::getPosition(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), mCurrentAttributes, CLGroupAttributes::mHeight, CLGroupAttributes::mpTransform, CLGroupAttributes::mWidth, CLGroupAttributes::mX, CLGroupAttributes::mY, CLGroupAttributes::mZ, restore_current_attributes(), and save_current_attributes().
Referenced by draw_object(), and map_arrow_head().
|
protected |
Method to draw a render image object.
Definition at line 1702 of file CLLayoutRenderer.cpp.
References convert_to_absolute(), createGLMatrix(), extract_transformation_attributes(), CLRelAbsVector::getAbsoluteValue(), CLBoundingBox::getDimensions(), CLImage::getHeight(), CLDimensions::getHeight(), CLImage::getImageReference(), CLRelAbsVector::getRelativeValue(), CLImage::getWidth(), CLDimensions::getWidth(), CLImage::getX(), CLImage::getY(), CLImage::isSetImageReference(), mBaseDir, mCurrentAttributes, mImageMap, mpImageTexturizer, CLGroupAttributes::mpTransform, CLTextureSpec::mTextureName, CLGroupAttributes::mX, restore_current_attributes(), and save_current_attributes().
Referenced by draw_group().
void CLLayoutRenderer::draw_layout | ( | ) |
Method to draw a given layout with a given render resolver.
Definition at line 939 of file CLLayoutRenderer.cpp.
References draw_curve(), draw_object(), draw_selection_box(), draw_text(), drawSelectionBox(), extract_group_attributes(), CLColorDefinition::getAlpha(), CLRenderResolver::getBackgroundColor(), CLColorDefinition::getBlue(), CLGraphicalObject::getBoundingBox(), CLGlyphWithCurve::getCurve(), getCurveBoundingBox(), CLayout::getDimensions(), CLBoundingBox::getDimensions(), CLColorDefinition::getGreen(), CLDimensions::getHeight(), CLGraphicalObject::getModelObject(), CLCurve::getNumCurveSegments(), CCopasiObject::getObjectParent(), CLBoundingBox::getPosition(), CLColorDefinition::getRed(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), GL_FOG_COORD, GL_FOG_COORD_SRC, initialize_gl_extension_functions(), mCurrentAttributes, mDrawables, mFogColor, mFogDensity, mGLFunctionsInitialized, CLGroupAttributes::mHeight, mHighlight, mHighlightColor, mHighlightedObjects, mpGlFogCoordfEXT, mpLayout, mpResolver, mSelection, CLGroupAttributes::mStroke, CLGroupAttributes::mStrokeWidth, mStyleMap, mTextGlyphMap, CLGroupAttributes::mWidth, CLGroupAttributes::mX, CLGroupAttributes::mY, CLGroupAttributes::mZ, restore_current_attributes(), save_current_attributes(), and CLBoundingBox::setPosition().
Referenced by addToSelection(), CQGLLayoutPainter::draw(), CQGLLayoutPainter::draw_bitmap(), and removeFromSelection().
|
protected |
Method to draw a line made up of a set of points.
Definition at line 3075 of file CLLayoutRenderer.cpp.
References draw_cap(), draw_line_segment(), mCurrentAttributes, mLinestippleMap, CLLineStippleTexture::mPatternLength, CLGroupAttributes::mStrokeDasharray, CLGroupAttributes::mStrokeWidth, CLLineStippleTexture::mTextureLength, CLLineStippleTexture::mTextureName, and segment_data().
Referenced by draw_curve(), and draw_datapoints().
|
protected |
Method that draws a line with the given start and end points. All the other parameter like color, linewidth etc. have to be set before.
Definition at line 265 of file CLLayoutRenderer.cpp.
References ALMOST_ZERO.
Referenced by draw_line().
|
protected |
Method to draw an arbitrary object specified by it's bounding box and the style with which it should be drawn.
Definition at line 1337 of file CLLayoutRenderer.cpp.
References draw_group(), and CLStyle::getGroup().
Referenced by draw_layout().
|
protected |
Method to draw a render polygon object.
Definition at line 1793 of file CLLayoutRenderer.cpp.
References CLRenderCubicBezier::basePoint1_X(), CLRenderCubicBezier::basePoint1_Y(), CLRenderCubicBezier::basePoint1_Z(), CLRenderCubicBezier::basePoint2_X(), CLRenderCubicBezier::basePoint2_Y(), CLRenderCubicBezier::basePoint2_Z(), calculate_cubicbezier(), convert_to_absolute(), draw_datapoints(), extract_2d_attributes(), CLPolygon::getElement(), CLPolygon::getNumElements(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), mCurrentAttributes, simple_point::mX, simple_point::mY, simple_point::mZ, NUM_BEZIER_POINTS, restore_current_attributes(), save_current_attributes(), CLRenderPoint::x(), CLRenderPoint::y(), and CLRenderPoint::z().
Referenced by draw_group().
|
protected |
Method to draw a render rectangle object.
Definition at line 1924 of file CLLayoutRenderer.cpp.
References convert_to_absolute(), draw_datapoints(), extract_2d_attributes(), CLRelAbsVector::getAbsoluteValue(), CLBoundingBox::getDimensions(), CLRectangle::getHeight(), CLDimensions::getHeight(), CLRectangle::getRadiusX(), CLRectangle::getRadiusY(), CLRelAbsVector::getRelativeValue(), CLRectangle::getWidth(), CLDimensions::getWidth(), CLRectangle::getX(), CLRectangle::getY(), CLRectangle::getZ(), mCurrentAttributes, NUM_CORNER_SEGMENTS, restore_current_attributes(), and save_current_attributes().
Referenced by draw_group().
|
protected |
draws the selection box if there is one
Definition at line 6528 of file CLLayoutRenderer.cpp.
References CLBoundingBox::getDimensions(), CLDimensions::getHeight(), CLBoundingBox::getPosition(), CLDimensions::getWidth(), CLPoint::getX(), CLPoint::getY(), mH, mpSelectionBox, mW, mX, mY, and mZoomFactor.
Referenced by draw_layout().
|
protected |
Method to draw a text object specified by it's bounding box and the style with which it should be drawn as well as the actual string.
Definition at line 1267 of file CLLayoutRenderer.cpp.
References CLText::ANCHOR_BOTTOM, CLText::ANCHOR_END, CLText::ANCHOR_MIDDLE, extract_1d_attributes(), extract_text_attributes(), CLBoundingBox::getDimensions(), CLStyle::getGroup(), CLDimensions::getHeight(), CLDimensions::getWidth(), mCurrentAttributes, CLGroupAttributes::mStroke, CLGroupAttributes::mTextAnchor, CLGroupAttributes::mVTextAnchor, restore_current_attributes(), and save_current_attributes().
Referenced by draw_group(), draw_layout(), and draw_text().
|
protected |
Method to draw a render text object.
Definition at line 1520 of file CLLayoutRenderer.cpp.
References draw_text(), extract_1d_attributes(), extract_text_attributes(), CLRelAbsVector::getAbsoluteValue(), CLDimensions::getDepth(), CLBoundingBox::getDimensions(), CLDimensions::getHeight(), CLRelAbsVector::getRelativeValue(), CLDimensions::getWidth(), CLText::getX(), CLText::getY(), CLText::getZ(), CLText::isSetText(), mCurrentAttributes, mTextMap, restore_current_attributes(), and save_current_attributes().
|
protected |
Method to draw a string at the given position within the given bounding box.
pTexture->mScale
pTexture->mScale
Definition at line 1551 of file CLLayoutRenderer.cpp.
References CLText::ANCHOR_BOTTOM, CLText::ANCHOR_END, CLText::ANCHOR_MIDDLE, createGLMatrix(), CLBoundingBox::getPosition(), CLPoint::getX(), CLPoint::getY(), CLPoint::getZ(), mColorMap, mCurrentAttributes, CLGroupAttributes::mpTransform, CLTextTextureSpec::mScale, CLGroupAttributes::mStroke, CLGroupAttributes::mTextAnchor, CLTextureSpec::mTextHeight, CLTextureSpec::mTextureHeight, CLTextureSpec::mTextureName, CLTextureSpec::mTextureWidth, CLTextureSpec::mTextWidth, CLGroupAttributes::mVTextAnchor, CLGroupAttributes::mX, and mZoomFactor.