gazebo仿真之Model Appearance

这部分的内容是如何将模型进行外观的优化显示。官网教程:http://gazebosim.org/tutorials?cat=guided_i&tut=guided_i2
两个工具:freecad和blender,需要提前下载
对于Model Appearance:官网的介绍:Models with textures and 3D meshes can improve your visual experience, and more importantly improve the realism of an environment. Simulated cameras that feed information to vision processing algorithms will benefit from models that appear realistic as well.
《一》通过官网的教程,我们得到两个模型文件:velodyne_base.dae and velodyne_top.dae.

(1)为了能够使我们的模型能直接在gazebo上调用,我们将模型放在~/.gazebo/models这个路径下。在该路径下创建一个文件夹velodyne_hdl32存放我们的模型文件包括.config 和 .sdf 文件
官网给的模板(文件名为model.config):

    <?xml version="1.0"?>
    
    <model>
      <name>Velodyne HDL-32</name>
      <version>1.0</version>
      <sdf version="1.5">model.sdf</sdf>
    
      <author>
        <name>Optional: YOUR NAME</name>
        <email>Optional: YOUR EMAIL</email>
      </author>
    
      <description>
        A model of a Velodyne HDL-32 LiDAR sensor.
      </description>
    
    </model>

一开始我们的sdf文件的内容如下:

<?xml version="1.0" ?>
<sdf version="1.5">

<model name="velodyne_hdl-32">
 <!-- Give the base link a unique name -->
  <link name="base">
 <!-- Offset the base by half the lenght of the cylinder -->
  <pose>0 0 0.029335 0 0 0</pose>

  <inertial>
    <mass>1.2</mass>
    <inertia>
	<ixx>0.001087473</ixx>
	<iyy>0.001087473</iyy>
	<izz>0.001092437</izz>
	<ixy>0</ixy>
	<ixz>0</ixz>
	<iyz>0</iyz>
    </inertia>
  </inertial>

  <collision name="base_collision">
   <geometry>
    <cylinder>
	<!-- Radius and length provide by Velodyne -->
	 <radius>.04267</radius>
	 <length>.05867</length>
    </cylinder>
   </geometry>
  </collision>
 <!-- The visual is mostly a copy of the collision -->
    <visual name="base_visual">
      <geometry>
        <cylinder>
          <radius>.04267</radius>
        
  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值