|
AuboStudio SDK
0.6.3
|
|
|
|
|
\chinese 渲染接口 提供 3D 渲染相关的显示选项控制,包括地面、机器人模型、坐标系、轨迹和点等元素的 显示/隐藏。 \endchinese \english RenderInterface Provides display option controls related to 3D rendering, including show/hide of ground, robot models, coordinate systems, trajectories and points. 更多...
#include <render_interface.h>
Public 类型 | |
| enum | ShowOptions : uint16_t { None = 0 , Ground = 0x01 , TargetRobot = 0x02 , RealRobot = 0x04 , Coordinate = 0x08 , Track = 0x10 , Point = 0x20 , View = 0x40 , Obstacle = 0x80 , SafetyPlane = 0x0100 , ToolPosition = 0x0200 , PointCloud = 0x0400 , All = 0xFFFF } |
Public 成员函数 | |
| RenderInterface (RenderInterface &f) | |
| RenderInterface (RenderInterface &&f) | |
| virtual | ~RenderInterface () |
| void | setRenderEmbeded (bool is_embeded, QGridLayout *gly) |
| \chinese 设置 Render 窗口嵌入/移除(isEmbeded) 布局 gly 中 | |
| void | setShowOptions (uint16_t options) |
| \chinese 设置显示模式,控制各种元素的显隐 | |
| void | addPointCloud (const std::string &name, const std::vector< std::vector< double > > &points, const std::vector< double > &color) |
| \chinese 添加/修改点云 | |
| void | removePointCloud (const std::string &name) |
| \chinese 移除指定名称的点云 | |
| bool | hasPointCloud (const std::string &name) |
| \chinese 查找指定名称的点云是否存在 | |
| void | clearPointCloud () |
| \chinese 移除所有的点云 \endchinese \english Remove all point clouds. | |
| bool | addWaypoint (void *wp, const std::vector< double > &pose, const std::vector< double > &color={ 0.0, 1.0, 0.0, 1.0 }, bool axis_visible=false) |
| \chinese 添加/修改路点 | |
| void | removeWaypoint (void *wp) |
| \chinese 移除指定路点 | |
| bool | hasWaypoint (void *wp) |
| \chinese 查找指定路点是否存在 | |
| void | clearWaypoints () |
| \chinese 移除所有的路点 \endchinese \english Remove all waypoints. | |
| void | setMoveTrack (void *wp, const std::vector< std::vector< double > > &track) |
| \chinese 添加/修改指定路点的交融轨迹 | |
| void | setBlendTrack (void *wp, const std::vector< std::vector< double > > &track) |
| \chinese | |
| void | setMoveTrack (void *wp, const std::vector< std::vector< double > > &track, const std::vector< double > &color) |
| \chinese | |
| void | setBlendTrack (void *wp, const std::vector< std::vector< double > > &track, const std::vector< double > &color) |
| \chinese | |
| void | addCoordinate (const std::string &name, const std::vector< double > &pose) |
| \chinese 添加/修改坐标轴 | |
| void | removeCoordinate (const std::string &name) |
| \chinese 移除指定坐标轴 | |
| bool | hasCoordinate (const std::string &name) |
| \chinese 查找指定坐标轴是否存在 | |
| void | addLine (const std::string &name, const std::vector< std::vector< double > > &points, const std::vector< double > &color) |
| \chinese 添加/修改线 | |
| void | addLine (const std::string &name, int link_num, const std::vector< double > &pose, const std::vector< std::vector< double > > &points, const std::vector< double > &color) |
| \chinese | |
| void | removeLine (const std::string &name) |
| \chinese 移除指定线 | |
| void | clearLines () |
| \chinese 移除所有的线 \endchinese \english Remove all lines. | |
| void | addPlane (const std::string &name, const std::vector< double > &pose, const std::vector< double > &size, const std::vector< double > &color) |
| \chinese 添加/修改平面 | |
| void | addPlane (const std::string &name, int link_num, const std::vector< double > &pose, const std::vector< double > &size, const std::vector< double > &color) |
| \chinese | |
| void | removePlane (const std::string &name) |
| \chinese 移除指定平面 | |
| void | clearPlanes () |
| \chinese 移除所有的平面 \endchinese \english Remove all planes. | |
| void | addCube (const std::string &name, const std::vector< double > &pose, const std::vector< double > &size, const std::vector< double > &color, int type=0) |
| \chinese 添加/修改立方体 | |
| void | addCube (const std::string &name, int link_num, const std::vector< double > &pose, const std::vector< double > &size, const std::vector< double > &color, int type=0) |
| \chinese | |
| void | addCube (const std::string &name, const std::vector< double > &pose, float length_min, float length_max, float width_min, float width_max, float height_min, float height_max, const std::vector< double > &color, int type=0) |
| \chinese 添加/修改立方体(带尺寸范围) | |
| void | addCube (const std::string &name, int link_num, const std::vector< double > &pose, float length_min, float length_max, float width_min, float width_max, float height_min, float height_max, const std::vector< double > &color, int type=0) |
| \chinese | |
| void | removeCube (const std::string &name) |
| \chinese 移除指定立方体 | |
| void | clearCubes () |
| \chinese 移除所有的立方体 \endchinese \english Remove all cubes. | |
| int | addMesh (const std::string &name, int link_num, const std::string &model_path, const std::vector< double > &pose) |
| addMesh 添加任意模型文件 | |
| std::vector< std::string > | getMeshes (int link_num) |
| getMeshes 获取关节 link_num 的外设模型名字 | |
| int | removeMesh (const std::string &name) |
| removeMesh | |
| int | clearMeshes (int link_num) |
| clearMeshes | |
Private 成员函数 | |
| RenderInterface () | |
Private 属性 | |
| void * | d_ { nullptr } |
友元 | |
| class | DataSwitch |
\chinese 渲染接口 提供 3D 渲染相关的显示选项控制,包括地面、机器人模型、坐标系、轨迹和点等元素的 显示/隐藏。 \endchinese \english RenderInterface Provides display option controls related to 3D rendering, including show/hide of ground, robot models, coordinate systems, trajectories and points.
\endenglish
在文件 render_interface.h 第 28 行定义.
| enum arcs::aubo_scope::RenderInterface::ShowOptions : uint16_t |
| 枚举值 | |
|---|---|
| None | |
| Ground | |
| TargetRobot | |
| RealRobot | |
| Coordinate | |
| Track | |
| Point | |
| View | |
| Obstacle | |
| SafetyPlane | |
| ToolPosition | |
| PointCloud | |
| All | |
在文件 render_interface.h 第 31 行定义.
| arcs::aubo_scope::RenderInterface::RenderInterface | ( | RenderInterface & | f | ) |
| arcs::aubo_scope::RenderInterface::RenderInterface | ( | RenderInterface && | f | ) |
|
virtual |
|
private |
| void arcs::aubo_scope::RenderInterface::addCoordinate | ( | const std::string & | name, |
| const std::vector< double > & | pose ) |
\chinese 添加/修改坐标轴
| name | 坐标轴名称 |
| pose | 位姿 x,y,z,rx,ry,rz \endchinese \english Add/modify coordinate axis. |
| name | coordinate name |
| pose | pose x,y,z,rx,ry,rz \endenglish |
| void arcs::aubo_scope::RenderInterface::addCube | ( | const std::string & | name, |
| const std::vector< double > & | pose, | ||
| const std::vector< double > & | size, | ||
| const std::vector< double > & | color, | ||
| int | type = 0 ) |
\chinese 添加/修改立方体
| name | 立方体名称 |
| link_num | -1: TCP; 0: 底座; 1~6: 关节; |
| pose | 位置 |
| size | 立方体大小(长,宽,高) |
| color | 立方体颜色 {r, g, b, a}, 范围是 0.0~1.0 |
| type | 立方体绘制类型 0 代表画 6 个平面,1 代表只画边框线 \endchinese \english Add/modify cube. |
| name | cube name |
| link_num | -1: TCP; 0: base; 1~6: joints; |
| pose | position |
| size | cube size (length, width, height) |
| color | cube color {r, g, b, a}, range 0.0~1.0 |
| type | cube rendering type: 0 for 6 planes, 1 for wireframe \endenglish |
| void arcs::aubo_scope::RenderInterface::addCube | ( | const std::string & | name, |
| const std::vector< double > & | pose, | ||
| float | length_min, | ||
| float | length_max, | ||
| float | width_min, | ||
| float | width_max, | ||
| float | height_min, | ||
| float | height_max, | ||
| const std::vector< double > & | color, | ||
| int | type = 0 ) |
\chinese 添加/修改立方体(带尺寸范围)
| name | 立方体名称 |
| pose | 位置 |
| length_min | 最小长度 |
| length_max | 最大长度 |
| width_min | 最小宽度 |
| width_max | 最大宽度 |
| height_min | 最小高度 |
| height_max | 最大高度 |
| color | 立方体颜色 {r, g, b, a}, 范围是 0.0~1.0 |
| type | 立方体绘制类型 0 代表画 6 个平面,1 代表只画边框线 \endchinese \english Add/modify cube with size ranges. |
| name | cube name |
| pose | position |
| length_min | |
| length_max | |
| width_min | |
| width_max | |
| height_min | |
| height_max | |
| color | cube color {r, g, b, a}, range 0.0~1.0 |
| type | cube rendering type: 0 for 6 planes, 1 for wireframe \endenglish |
| void arcs::aubo_scope::RenderInterface::addCube | ( | const std::string & | name, |
| int | link_num, | ||
| const std::vector< double > & | pose, | ||
| const std::vector< double > & | size, | ||
| const std::vector< double > & | color, | ||
| int | type = 0 ) |
\chinese
addCube 添加立方体
| name | 立方体名称 |
| link_num | 关节编号 |
| pose | 位姿 |
| size | 大小 |
| color | 颜色 |
| type | 类型 \endchinese \english |
addCube
| name | |
| link_num | |
| pose | |
| size | |
| color | |
| type | \endenglish |
| void arcs::aubo_scope::RenderInterface::addCube | ( | const std::string & | name, |
| int | link_num, | ||
| const std::vector< double > & | pose, | ||
| float | length_min, | ||
| float | length_max, | ||
| float | width_min, | ||
| float | width_max, | ||
| float | height_min, | ||
| float | height_max, | ||
| const std::vector< double > & | color, | ||
| int | type = 0 ) |
\chinese
addCube 添加立方体
| name | 立方体名称 |
| link_num | 关节编号 |
| pose | 位姿 |
| length_min | 最小长度 |
| length_max | 最大长度 |
| width_min | 最小宽度 |
| width_max | 最大宽度 |
| height_min | 最小高度 |
| height_max | 最大高度 |
| color | 颜色 |
| type | 类型 \endchinese \english |
addCube
| name | |
| link_num | |
| pose | |
| length_min | |
| length_max | |
| width_min | |
| width_max | |
| height_min | |
| height_max | |
| color | |
| type | \endenglish |
| void arcs::aubo_scope::RenderInterface::addLine | ( | const std::string & | name, |
| const std::vector< std::vector< double > > & | points, | ||
| const std::vector< double > & | color ) |
\chinese 添加/修改线
| name | 线名称 |
| link_num | -1: TCP; 0: 底座; 1~6: 关节; |
| pose | 点的参考坐标系, 默认 6 个 0 |
| points | 点集合 |
| color | 线颜色 {r, g, b, a}, 范围是 0.0~1.0 \endchinese \english Add/modify line. |
| name | line name |
| link_num | -1: TCP; 0: base; 1~6: joints; |
| pose | reference coordinate system for points, default 6 zeros |
| points | point collection |
| color | line color {r, g, b, a}, range 0.0~1.0 \endenglish |
| void arcs::aubo_scope::RenderInterface::addLine | ( | const std::string & | name, |
| int | link_num, | ||
| const std::vector< double > & | pose, | ||
| const std::vector< std::vector< double > > & | points, | ||
| const std::vector< double > & | color ) |
\chinese
addLine 添加线
| name | 线名称 |
| link_num | 关节编号 |
| pose | 位姿 |
| points | 点集合 |
| color | 颜色 \endchinese \english |
addLine
| name | |
| link_num | |
| pose | |
| points | |
| color | \endenglish |
| int arcs::aubo_scope::RenderInterface::addMesh | ( | const std::string & | name, |
| int | link_num, | ||
| const std::string & | model_path, | ||
| const std::vector< double > & | pose ) |
addMesh 添加任意模型文件
| name | 唯一标识 |
| link_num | -1: TCP; 0: 底座; 1~6: 关节; |
| model_path | 3ds 文件绝对路径 |
| pose | 模型文件安装位置 {x, y, z, rx, ry, rz} |
| void arcs::aubo_scope::RenderInterface::addPlane | ( | const std::string & | name, |
| const std::vector< double > & | pose, | ||
| const std::vector< double > & | size, | ||
| const std::vector< double > & | color ) |
\chinese 添加/修改平面
| void arcs::aubo_scope::RenderInterface::addPlane | ( | const std::string & | name, |
| int | link_num, | ||
| const std::vector< double > & | pose, | ||
| const std::vector< double > & | size, | ||
| const std::vector< double > & | color ) |
\chinese
addPlane 添加平面
| name | 平面名称 |
| link_num | 关节编号 |
| pose | 位姿 |
| size | 大小 |
| color | 颜色 \endchinese \english |
addPlane
| name | |
| link_num | |
| pose | |
| size | |
| color | \endenglish |
| void arcs::aubo_scope::RenderInterface::addPointCloud | ( | const std::string & | name, |
| const std::vector< std::vector< double > > & | points, | ||
| const std::vector< double > & | color ) |
\chinese 添加/修改点云
| name | 点云名称 |
| points | 点集合 |
| color | 点云颜色 rgba \endchinese \english Add/modify point cloud. |
| name | point cloud name |
| points | point collection |
| color | point cloud color rgba \endenglish |
| bool arcs::aubo_scope::RenderInterface::addWaypoint | ( | void * | wp, |
| const std::vector< double > & | pose, | ||
| const std::vector< double > & | color = { 0.0, 1.0, 0.0, 1.0 }, | ||
| bool | axis_visible = false ) |
\chinese 添加/修改路点
| wp | 代表路点的唯一对象 |
| pose | 路点位姿 x,y,z,rx,ry,rz |
| color | 路点颜色 {r, g, b, a}, 范围是 0.0~1.0 |
| axis_visible | 路点上是否显示位姿方向箭头 |
| true | 成功 |
| false | 失败 \endchinese \english Add/modify waypoint. |
| wp | the unique object representing the waypoint |
| pose | waypoint pose x,y,z,rx,ry,rz |
| color | waypoint color {r, g, b, a}, range 0.0~1.0 |
| axis_visible | whether to show pose direction arrows on the waypoint |
| true | success |
| false | failure \endenglish |
| void arcs::aubo_scope::RenderInterface::clearCubes | ( | ) |
\chinese 移除所有的立方体 \endchinese \english Remove all cubes.
\endenglish
| void arcs::aubo_scope::RenderInterface::clearLines | ( | ) |
\chinese 移除所有的线 \endchinese \english Remove all lines.
\endenglish
| int arcs::aubo_scope::RenderInterface::clearMeshes | ( | int | link_num | ) |
clearMeshes
| link_num |
| void arcs::aubo_scope::RenderInterface::clearPlanes | ( | ) |
\chinese 移除所有的平面 \endchinese \english Remove all planes.
\endenglish
| void arcs::aubo_scope::RenderInterface::clearPointCloud | ( | ) |
\chinese 移除所有的点云 \endchinese \english Remove all point clouds.
\endenglish
| void arcs::aubo_scope::RenderInterface::clearWaypoints | ( | ) |
\chinese 移除所有的路点 \endchinese \english Remove all waypoints.
\endenglish
| std::vector< std::string > arcs::aubo_scope::RenderInterface::getMeshes | ( | int | link_num | ) |
| bool arcs::aubo_scope::RenderInterface::hasCoordinate | ( | const std::string & | name | ) |
\chinese 查找指定坐标轴是否存在
| name | 坐标轴名称 |
| true | 存在 |
| false | 不存在 \endchinese \english Check whether the specified coordinate axis exists. |
| name | coordinate name |
| true | exists |
| false | does not exist \endenglish |
| bool arcs::aubo_scope::RenderInterface::hasPointCloud | ( | const std::string & | name | ) |
\chinese 查找指定名称的点云是否存在
| name | 点云名称 |
| true | 存在 |
| false | 不存在 \endchinese \english Check whether the point cloud with the specified name exists. |
| name | point cloud name |
| true | exists |
| false | does not exist \endenglish |
| bool arcs::aubo_scope::RenderInterface::hasWaypoint | ( | void * | wp | ) |
\chinese 查找指定路点是否存在
| wp | 代表路点的唯一对象 |
| true | 存在 |
| false | 不存在 \endchinese \english Check whether the specified waypoint exists. |
| wp | the unique object representing the waypoint |
| true | exists |
| false | does not exist \endenglish |
| void arcs::aubo_scope::RenderInterface::removeCoordinate | ( | const std::string & | name | ) |
\chinese 移除指定坐标轴
| name | 坐标轴名称 \endchinese \english Remove the specified coordinate axis. |
| name | coordinate name \endenglish |
| void arcs::aubo_scope::RenderInterface::removeCube | ( | const std::string & | name | ) |
\chinese 移除指定立方体
| name | 立方体名称 \endchinese \english Remove the specified cube. |
| name | cube name \endenglish |
| void arcs::aubo_scope::RenderInterface::removeLine | ( | const std::string & | name | ) |
\chinese 移除指定线
| name | 线名称 \endchinese \english Remove the specified line. |
| name | line name \endenglish |
| int arcs::aubo_scope::RenderInterface::removeMesh | ( | const std::string & | name | ) |
removeMesh
| name |
| void arcs::aubo_scope::RenderInterface::removePlane | ( | const std::string & | name | ) |
\chinese 移除指定平面
| name | 名称 \endchinese \english Remove the specified plane. |
| name | plane name \endenglish |
| void arcs::aubo_scope::RenderInterface::removePointCloud | ( | const std::string & | name | ) |
\chinese 移除指定名称的点云
| name | 点云名称 \endchinese \english Remove the point cloud with the specified name. |
| name | point cloud name \endenglish |
| void arcs::aubo_scope::RenderInterface::removeWaypoint | ( | void * | wp | ) |
\chinese 移除指定路点
| wp | 代表路点的唯一对象 \endchinese \english Remove the specified waypoint. |
| wp | the unique object representing the waypoint \endenglish |
| void arcs::aubo_scope::RenderInterface::setBlendTrack | ( | void * | wp, |
| const std::vector< std::vector< double > > & | track ) |
\chinese
setBlendTrack 设置混合轨迹
| wp | 路点对象 |
| track | 轨迹集合 \endchinese \english |
setBlendTrack
| wp | |
| track | \endenglish |
| void arcs::aubo_scope::RenderInterface::setBlendTrack | ( | void * | wp, |
| const std::vector< std::vector< double > > & | track, | ||
| const std::vector< double > & | color ) |
\chinese
setBlendTrack 设置混合轨迹
| wp | 路点对象 |
| track | 轨迹集合 |
| color | 颜色 \endchinese \english |
setBlendTrack
| wp | |
| track | |
| color | \endenglish |
| void arcs::aubo_scope::RenderInterface::setMoveTrack | ( | void * | wp, |
| const std::vector< std::vector< double > > & | track ) |
\chinese 添加/修改指定路点的交融轨迹
| wp | 代表路点的唯一对象 |
| track | 路点位姿 x,y,z,rx,ry,rz 集合 \endchinese \english Add/modify the move track for the specified waypoint. |
| wp | the unique object representing the waypoint |
| track | waypoint pose collection x,y,z,rx,ry,rz \endenglish |
| void arcs::aubo_scope::RenderInterface::setMoveTrack | ( | void * | wp, |
| const std::vector< std::vector< double > > & | track, | ||
| const std::vector< double > & | color ) |
\chinese
setMoveTrack 设置移动轨迹
| wp | 路点对象 |
| track | 轨迹集合 |
| color | 颜色 \endchinese \english |
setMoveTrack
| wp | |
| track | |
| color | \endenglish |
| void arcs::aubo_scope::RenderInterface::setRenderEmbeded | ( | bool | is_embeded, |
| QGridLayout * | gly ) |
\chinese 设置 Render 窗口嵌入/移除(isEmbeded) 布局 gly 中
| is_embeded | 是否嵌入 |
| gly | 布局 \endchinese \english Set the render window to be embedded/removed in the layout gly. |
| is_embeded | whether to embed |
| gly | the layout \endenglish |
| void arcs::aubo_scope::RenderInterface::setShowOptions | ( | uint16_t | options | ) |
\chinese 设置显示模式,控制各种元素的显隐
| options | 选项值,详情查看 ShowOptions 枚举 \endchinese \english Set the display mode to control the visibility of various elements. |
| options | option value, see ShowOptions enum for details \endenglish |
|
friend |
|
private |
在文件 render_interface.h 第 684 行定义.