ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

RVIZ não exibe cores de malha COLLADA

asked 2021-01-26 10:15:24 -0500

mateusguilherme gravatar image

updated 2021-01-26 16:19:14 -0500

Hello

I created a COLLADA .dae file with sketchup 2018. I am publishing a marker message with this ".dae" object, however rviz does not display colors, the object appears in gray. I'm using ros kinetic and ubuntu 16.04.

already tried the "mesh_use_embedded_materials" options true and false and it didn't solve

Here is my COLLADA file: https://drive.google.com/file/d/1bzFO...

    dockMarker = Marker()
    dockMarker.header.frame_id = "/map"
    dockMarker.header.stamp = rospy.get_rostime()
    dockMarker.ns = "dock"
    dockMarker.id = 0
    dockMarker.type = dockMarker.MESH_RESOURCE
    dockMarker.action = 0
    dockMarker.pose.position.x =data.pose.pose.position.x
    dockMarker.pose.position.y =data.pose.pose.position.y
    dockMarker.pose.orientation.x = 0.0
    dockMarker.pose.orientation.y = 0.0
    dockMarker.pose.orientation.z = data.pose.pose.orientation.z
    dockMarker.pose.orientation.w = data.pose.pose.orientation.w
    dockMarker.scale.x = 1.0
    dockMarker.scale.y = 1.0
    dockMarker.scale.z = 1.0

    dockMarker.mesh_resource = "package://auto_docking/meshes/dock_model.dae"

    dockMarker.mesh_use_embedded_materials =  True
    dockMarker.color.r = 0.0
    dockMarker.color.g = 0.0
    dockMarker.color.b = 0.0
    dockMarker.color.a = 0.0

    markerPub.publish(dockMarker)

any suggestion?

thanks

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted
0

answered 2021-01-31 17:43:31 -0500

mateusguilherme gravatar image

it looks like rviz has a problem displaying colors from a ".dae" file. I resolved by placing an image as a texture of the .dae object

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2021-01-26 10:15:24 -0500

Seen: 58 times

Last updated: Jan 31 '21