Used to convert a view and a DesignObjectLookup of data into a 2D map of primitive data types.
More...
|
| Buffer< PrimitiveClipRegion > | getClipping (const PrimitiveRenderOptions &primitive_options, const Model &model) |
| | Computes the clip regions for a given model within the render context.
|
| void | sortAndDraw (PrimitiveRenderOptions &draw_options) |
| | Sorts collected primitives by distance and invokes the draw callbacks in order.
|
| void | writeGeometryToOptions (PrimitiveRenderOptions &pdf_options, const Matrix< fltp08 > &tr, const Model &model, const Geometry &geo) |
| | Converts a Geometry object into primitive draw operations (lines, points, polygons).
|
|
|
std::function< void(const Font &font, const PrimitiveRenderOptions &pdf_options)> | m_add_font |
| | Callback for registering a font with the output backend.
|
|
fltp08 | m_dpi |
| | The output resolution in dots per inch.
|
|
bool | m_draw_border |
| | Whether to draw a border around the output.
|
|
bool | m_draw_grid |
| | Whether to draw a background grid.
|
|
std::function< void(const PrimitiveDrawImagePolygon &image_id, const PrimitiveRenderOptions &pdf_options)> | m_draw_image |
| | Callback for drawing an image (NOTE: parameter name 'image_id' may be misleading; receives a full PrimitiveDrawImagePolygon).
|
|
std::function< void(const PrimitiveDrawImagePolygon &image_poly, const PrimitiveRenderOptions &pdf_options)> | m_draw_image_poly |
| | Callback for drawing an image polygon primitive.
|
|
std::function< void(const PrimitiveDrawLine &line, const PrimitiveRenderOptions &pdf_options)> | m_draw_line |
| | Callback for drawing a line primitive.
|
|
std::function< void(const PrimitiveDrawPoint &point, const PrimitiveRenderOptions &pdf_options)> | m_draw_point |
| | Callback for drawing a point primitive.
|
|
std::function< void(const PrimitiveDrawPolygon &poly, const PrimitiveRenderOptions &pdf_options)> | m_draw_poly |
| | Callback for drawing a polygon primitive.
|
|
std::function< void(const PrimitiveDrawText &text, const PrimitiveRenderOptions &pdf_options)> | m_draw_text |
| | Callback for drawing a text primitive.
|
|
const DesignObjectLookup * | m_lookup |
| | Pointer to the design object lookup providing scene data access.
|
|
uint04 | m_margins |
| | The margin size in pixels.
|
|
String | m_subject |
| | The document subject metadata.
|
|
String | m_title |
| | The document title metadata.
|
Used to convert a view and a DesignObjectLookup of data into a 2D map of primitive data types.
Definition at line 17 of file ViewToPrimitiveObjects.h.
◆ ViewToPrimitiveObjects()
◆ execute()
| virtual bool ViewToPrimitiveObjects::execute |
( |
const Camera & | camera, |
|
|
const Buffer< UUID > & | objects_to_render, |
|
|
PrimitiveRenderOptions & | options ) |
|
virtual |
Executes the conversion of a camera view and set of objects into primitive draw operations.
- Parameters
-
| [in] | camera | The camera defining the view projection. |
| [in] | objects_to_render | The UUIDs of objects to include in the output. |
| [in] | options | The render options struct to populate with primitive draw data. |
- Returns
- True if the execution succeeded and primitives were generated.
◆ getClipping()
| Buffer< PrimitiveClipRegion > ViewToPrimitiveObjects::getClipping |
( |
const PrimitiveRenderOptions & | primitive_options, |
|
|
const Model & | model ) |
|
protected |
Computes the clip regions for a given model within the render context.
- Parameters
-
| [in] | primitive_options | The current render options providing transform context. |
| [in] | model | The model to compute clip regions for. |
- Returns
- A buffer of PrimitiveClipRegion objects bounding the model.
◆ setdpi()
| virtual void ViewToPrimitiveObjects::setdpi |
( |
fltp08 | dpi | ) |
|
|
virtual |
Sets the output resolution in dots per inch.
- Parameters
-
| [in] | dpi | The desired DPI value. |
◆ setDrawBorder()
| void ViewToPrimitiveObjects::setDrawBorder |
( |
bool | border | ) |
|
Sets whether a border should be drawn around the output.
- Parameters
-
| [in] | border | True to enable border drawing. |
◆ setDrawGrid()
| void ViewToPrimitiveObjects::setDrawGrid |
( |
bool | draw_grid | ) |
|
Sets whether a background grid should be drawn.
- Parameters
-
| [in] | draw_grid | True to enable grid drawing. |
◆ setMargins()
| void ViewToPrimitiveObjects::setMargins |
( |
uint04 | margins | ) |
|
Sets the margin size around the rendered content.
- Parameters
-
| [in] | margins | The margin size in pixels. |
◆ setTitle()
| void ViewToPrimitiveObjects::setTitle |
( |
const String & | title, |
|
|
const String & | subject ) |
Sets the title and subject metadata for the output.
- Parameters
-
| [in] | title | The document title. |
| [in] | subject | The document subject. |
◆ sortAndDraw()
| void ViewToPrimitiveObjects::sortAndDraw |
( |
PrimitiveRenderOptions & | draw_options | ) |
|
|
protected |
Sorts collected primitives by distance and invokes the draw callbacks in order.
- Parameters
-
| [in] | draw_options | The render options containing primitives to sort and draw. |
◆ writeGeometryToOptions()
| void ViewToPrimitiveObjects::writeGeometryToOptions |
( |
PrimitiveRenderOptions & | pdf_options, |
|
|
const Matrix< fltp08 > & | tr, |
|
|
const Model & | model, |
|
|
const Geometry & | geo ) |
|
protected |
Converts a Geometry object into primitive draw operations (lines, points, polygons).
- Parameters
-
| [in] | pdf_options | The render options to append geometry primitives to. |
| [in] | tr | The transform to apply to the geometry. |
| [in] | model | The parent model of the geometry. |
| [in] | geo | The Geometry object to convert. |
The documentation for this class was generated from the following file: