-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathcamera_bb2.orogen
63 lines (52 loc) · 2.61 KB
/
camera_bb2.orogen
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
name "camera_bb2"
# Optionally declare the version number
# version "0.1"
using_library "frame_helper"
# If new data types need to be defined, they have to be put in a separate C++
# header, and this header will be loaded here
# Finally, it is pretty common that headers are directly loaded from an external
# library. In this case, the library must be first used (the name is the
# library's pkg-config name) and then the header can be used. Following Rock
# conventions, a common use-case would be:
#
# using_library "camera_bb2"
# import_types_from "camera_bb2/CustomType.hpp"
# If this project uses data types that are defined in other oroGen projects,
# these projects should be imported there as well.
import_types_from "base"
import_types_from "frame_helper/Calibration.h"
# Declare a new task context (i.e., a component)
#
# The corresponding C++ class can be edited in tasks/Task.hpp and
# tasks/Task.cpp, and will be put in the camera_bb2 namespace.
task_context "Task" do
# This is the default from now on, and should not be removed. Rock will
# transition to a setup where all components use a configuration step.
needs_configuration
# A configuration property (here, a std::string). Its value can be retrieved
# in the C++ code with # _config_value.get() and _config_value.set(new_value).
property("calibration_parameters","frame_helper/StereoCalibration").
doc 'Intrinsic and extrinsic camera calibration parameters'+
'for a full parameter list have a look at frame_helper'
property("output_format", "/base/samples/frame/frame_mode_t", :MODE_GRAYSCALE).
doc "The frames coming from the input port are converted into this format before they are written to the output port. Used for De-Bayering here."
property("undistort", "bool", true).
doc "output the camera images undistorted/rectified"
#*****************************
#******* Input Ports *********
#*****************************
input_port('frame_in', ro_ptr('base::samples::frame::Frame')).
doc 'Input frame from camera firewire'
#******************************
#******* Output Ports *********
#******************************
output_port('left_frame', ro_ptr('base::samples::frame::Frame')).
doc 'Left camera frame.'
output_port('right_frame', ro_ptr('base::samples::frame::Frame')).
doc 'Right camera frame.'
# If you want that component's updateHook() to be executed when the "input"
# port gets data, uncomment this and comment the 'periodic' line
# port_driven "input"
# By default, the task will be periodic with a period of 0.1
port_driven
end