Skip to content

Commit 175afb7

Browse files
authored
Add instructions to bitmask world (#377)
Signed-off-by: Louise Poubel <[email protected]>
1 parent 88fb59d commit 175afb7

File tree

1 file changed

+14
-84
lines changed

1 file changed

+14
-84
lines changed

examples/worlds/shapes_bitmask.sdf

+14-84
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,15 @@
11
<?xml version="1.0" ?>
2+
<!--
3+
Demonstrates the use of collide bitmasks.
4+
5+
The world has 3 boxes with the following bitmasks:
6+
* redBox: 0x01 (01)
7+
* greenBox: 0x02 (10)
8+
* yellowBox: 0x03 (11)
9+
10+
Which means that green and red can't collide with each other, but they both
11+
collide with yellow. Move them around to see it working!
12+
-->
213
<sdf version="1.6">
314
<world name="shapes_bitmask">
415
<physics name="1ms" type="ignored">
@@ -23,87 +34,6 @@
2334
<background>0.8 0.8 0.8</background>
2435
</scene>
2536

26-
<gui fullscreen="0">
27-
28-
<!-- 3D scene -->
29-
<plugin filename="GzScene3D" name="3D View">
30-
<ignition-gui>
31-
<title>3D View</title>
32-
<property type="bool" key="showTitleBar">false</property>
33-
<property type="string" key="state">docked</property>
34-
</ignition-gui>
35-
36-
<engine>ogre2</engine>
37-
<scene>scene</scene>
38-
<ambient_light>1.0 1.0 1.0</ambient_light>
39-
<background_color>0.8 0.8 0.8</background_color>
40-
<camera_pose>-6 0 6 0 0.5 0</camera_pose>
41-
</plugin>
42-
43-
<!-- World control -->
44-
<plugin filename="WorldControl" name="World control">
45-
<ignition-gui>
46-
<title>World control</title>
47-
<property type="bool" key="showTitleBar">false</property>
48-
<property type="bool" key="resizable">false</property>
49-
<property type="double" key="height">72</property>
50-
<property type="double" key="width">121</property>
51-
<property type="double" key="z">1</property>
52-
53-
<property type="string" key="state">floating</property>
54-
<anchors target="3D View">
55-
<line own="left" target="left"/>
56-
<line own="bottom" target="bottom"/>
57-
</anchors>
58-
</ignition-gui>
59-
60-
<play_pause>true</play_pause>
61-
<step>true</step>
62-
<start_paused>true</start_paused>
63-
<service>/world/shapes_bitmask/control</service>
64-
<stats_topic>/world/shapes_bitmask/stats</stats_topic>
65-
66-
</plugin>
67-
68-
<!-- World statistics -->
69-
<plugin filename="WorldStats" name="World stats">
70-
<ignition-gui>
71-
<title>World stats</title>
72-
<property type="bool" key="showTitleBar">false</property>
73-
<property type="bool" key="resizable">false</property>
74-
<property type="double" key="height">110</property>
75-
<property type="double" key="width">290</property>
76-
<property type="double" key="z">1</property>
77-
78-
<property type="string" key="state">floating</property>
79-
<anchors target="3D View">
80-
<line own="right" target="right"/>
81-
<line own="bottom" target="bottom"/>
82-
</anchors>
83-
</ignition-gui>
84-
85-
<sim_time>true</sim_time>
86-
<real_time>true</real_time>
87-
<real_time_factor>true</real_time_factor>
88-
<iterations>true</iterations>
89-
<topic>/world/shapes_bitmask/stats</topic>
90-
91-
</plugin>
92-
93-
<!-- Entity tree -->
94-
<plugin filename="EntityTree" name="Entity tree">
95-
<ignition-gui>
96-
<property type="bool" key="showTitleBar">false</property>
97-
<property type="string" key="state">docked</property>
98-
</ignition-gui>
99-
</plugin>
100-
101-
<!-- Transform Control -->
102-
<plugin filename="TransformControl" name="Transform Control">
103-
</plugin>
104-
105-
</gui>
106-
10737
<light type="directional" name="sun">
10838
<cast_shadows>true</cast_shadows>
10939
<pose>0 0 10 0 0 0</pose>
@@ -144,7 +74,7 @@
14474
</link>
14575
</model>
14676

147-
<model name="boxA">
77+
<model name="redBox">
14878
<pose>0 0 1.0 0 0 0</pose>
14979
<link name="link">
15080
<inertial>
@@ -185,7 +115,7 @@
185115
</link>
186116
</model>
187117

188-
<model name="boxB">
118+
<model name="greenBox">
189119
<pose>0 0 3.0 0 0 0</pose>
190120
<link name="link">
191121
<inertial>
@@ -226,7 +156,7 @@
226156
</link>
227157
</model>
228158

229-
<model name="boxC">
159+
<model name="yellowBox">
230160
<pose>0 0 6.0 0 0 0</pose>
231161
<link name="link">
232162
<inertial>

0 commit comments

Comments
 (0)