-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcamera_demo.world
66 lines (66 loc) · 1.93 KB
/
camera_demo.world
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
<!-- How to use camera and publish image to a ros topic.-->
<?xml version="1.0"?>
<sdf version='1.6'>
<world name='default'>
<model name='unit_box'>
<static>true</static>
<pose>0 0 2.5 0 -0 0</pose>
<link name='link'>
<visual name='visual'>
<geometry>
<box>
<size>1 1 1</size>
</box>
</geometry>
</visual>
</link>
</model>
<light name='user_directional_light_0' type='directional'>
<pose>0 0 1 0 0 0</pose>
</light>
<model name='camera'>
<static>true</static>
<pose>-1 0 2 0 1 0</pose>
<link name='link'>
<visual name='visual'>
<geometry>
<box>
<size>0.1 0.1 0.1</size>
</box>
</geometry>
</visual>
<sensor name='my_camera' type='camera'>
<camera>
<horizontal_fov>1.047</horizontal_fov>
<image>
<width>600</width>
<height>400</height>
</image>
<clip>
<near>0.1</near>
<far>100</far>
</clip>
</camera>
<always_on>1</always_on>
<update_rate>30</update_rate>
<!-- plugin, publish to the rostopic -->
<plugin name="camera_controller" filename="libgazebo_ros_camera.so">
<alwaysOn>true</alwaysOn>
<updateRate>0.0</updateRate>
<cameraName>camera1</cameraName>
<imageTopicName>image_raw</imageTopicName>
<cameraInfoTopicName>camera_info</cameraInfoTopicName>
<frameName>camera_link</frameName>
<hackBaseline>0.07</hackBaseline>
<distortionK1>0.0</distortionK1>
<distortionK2>0.0</distortionK2>
<distortionK3>0.0</distortionK3>
<distortionT1>0.0</distortionT1>
<distortionT2>0.0</distortionT2>
</plugin>
<!-- /plugin -->
</sensor>
</link>
</model>
</world>
</sdf>