Mujoco xml建模

背景

参考Mujoco官方提供的darwin模型


step1 建立场景

worldbody的一些属性

1 light 灯光

2 geom 外观,涉及到尺寸,位置等

 <mujoco model="darwin v1.31">
    <compiler angle="radian" inertiafromgeom="true" meshdir="meshes/"/>
    <size nconmax="100" njmax="500" nstack="-1"/>
    <default>
        <geom material="MatFrame" margin='0.001' />
        <joint limited='true'  frictionloss="0.2" damping="1.06" armature="0.011" axis="0 0 1" pos="0 0 0"/>
        <position ctrllimited='true' kp='2.65'/>
    </default>
    <asset>       
        <texture type="skybox" builtin="gradient" rgb1="1 1 1" rgb2="0 0 0" width="100" height="100"/>
        <texture name="groundplane" type="2d" builtin="checker" rgb1=".7 .7 .75" 
            rgb2=".9 .9 .95" width="500" height="500" mark="edge" markrgb=".1 .1 .1"/>

        <material name="MatPlastic" specular=".8" shininess=".6" reflectance="0.5" rgba=".4 .41 .4 1"/>
        <material name="MatFrame" specular="1.2" shininess=".1" reflectance="0.5" rgba=".21 .2 .2 1"/>
        <material name="MatGnd" texture="groundplane"  texrepeat="5 5" specular=".5" shininess=".01" reflectance="0.1"/>
   </asset>

 
    <worldbody>
        <light directional="false" cutoff="60" exponent="1" diffuse=".5 .5 .5" specular=".1 .1 .1" pos="0.5 0.1 0.8" dir="-0.5 -0.1 -0.8"/>
        <geom name="ground" pos="0 0 0" size="5 5 5" material="MatGnd" type="plane"/>
 
    </worldbody>
</mujoco>

在这里插入图片描述

  • 0
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值