Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove culling property #356

Merged
merged 5 commits into from
Feb 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 8 additions & 1 deletion delphyne_gui/visualizer/layout2_with_teleop.config
Original file line number Diff line number Diff line change
Expand Up @@ -81,8 +81,15 @@
</plugins>
</menus>
</window>
<plugin filename="delphyne_gui_render_widget">
<plugin filename="Scene3D">
<engine>ogre</engine>
<pose_topic>/visualizer/pose_update</pose_topic>
<scene>scene</scene>
<service>/get_scene</service>
<has_titlebar>false</has_titlebar>
<ambient_light>0 0 1</ambient_light>
<background_color>0.8 0.8 0.8</background_color>
<camera_pose>-6 0 6 0 0.5 0</camera_pose>
</plugin>

<plugin filename="WorldControl">
Expand Down
7 changes: 0 additions & 7 deletions delphyne_gui/visualizer/render_widget.cc
Original file line number Diff line number Diff line change
Expand Up @@ -379,13 +379,6 @@ ignition::rendering::VisualPtr RenderWidget::RenderMesh(const ignition::msgs::Vi
std::max(maxXYZ.Y() + _vis.pose().position().y(), maxBBScene.Y()),
std::max(maxXYZ.Z() + _vis.pose().position().z(), maxBBScene.Z()));

if (mesh_uri.Query().Str().find("culling=off") != std::string::npos) {
DELPHYNE_VALIDATE(mesh->GeometryCount() == 1, std::runtime_error, "Expected one geometry.");
auto subMesh = mesh->GeometryByIndex(0);
/* TODO: Enable once ignition-rendering2 supports culling
subMesh->Material()->SetCulling(ignition::rendering::CullMode::CM_NONE);*/
}

setPoseFromMessage(_vis, mesh);

return mesh;
Expand Down