Apollo
10.0
自动驾驶开放平台
smartereye_device.h
浏览该文件的文档.
1
/******************************************************************************
2
* Copyright 2020 The Apollo Authors. All Rights Reserved.
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*****************************************************************************/
16
17
#pragma once
18
19
#include <math.h>
20
#include <stdio.h>
21
22
#include <iostream>
23
#include <memory>
24
#include <sstream>
25
#include <string>
26
27
#include "
cyber/cyber.h
"
28
#include "modules/drivers/smartereye/proto/config.pb.h"
29
#include "
modules/drivers/smartereye/smartereye_handler.h
"
30
#include "third_party/camera_library/smartereye/include/LdwDataInterface.h"
31
#include "third_party/camera_library/smartereye/include/calibrationparams.h"
32
#include "third_party/camera_library/smartereye/include/camerahandler.h"
33
#include "third_party/camera_library/smartereye/include/disparityconvertor.h"
34
#include "third_party/camera_library/smartereye/include/frameid.h"
35
#include "third_party/camera_library/smartereye/include/obstacleData.h"
36
#include "third_party/camera_library/smartereye/include/rotationmatrix.h"
37
#include "third_party/camera_library/smartereye/include/satpext.h"
38
#include "third_party/camera_library/smartereye/include/stereocamera.h"
39
#include "third_party/camera_library/smartereye/include/taskiddef.h"
40
41
namespace
apollo
{
42
namespace
drivers {
43
namespace
smartereye {
44
45
using
apollo::drivers::smartereye::config::Config
;
46
47
class
SmartereyeDevice
{
48
public
:
49
SmartereyeDevice
();
50
virtual
~SmartereyeDevice
();
51
virtual
bool
init
(
const
std::shared_ptr<Config> &camera_config);
52
bool
is_capturing
();
53
bool
wait_for_device
();
54
int
uninit
();
55
bool
SetCallback
(
CallbackFunc
ptr);
56
int
poll
();
57
58
private
:
59
bool
is_capturing_ =
false
;
60
bool
inited_ =
false
;
61
std::shared_ptr<Config> config_;
62
StereoCamera *pcamera_ =
nullptr
;
63
SmartereyeHandler
*pcameraHandler_ =
nullptr
;
64
};
65
66
}
// namespace smartereye
67
}
// namespace drivers
68
}
// namespace apollo
apollo::drivers::smartereye::SmartereyeDevice
Definition
smartereye_device.h:47
apollo::drivers::smartereye::SmartereyeDevice::SmartereyeDevice
SmartereyeDevice()
Definition
smartereye_device.cc:30
apollo::drivers::smartereye::SmartereyeDevice::init
virtual bool init(const std::shared_ptr< Config > &camera_config)
Definition
smartereye_device.cc:34
apollo::drivers::smartereye::SmartereyeDevice::SetCallback
bool SetCallback(CallbackFunc ptr)
Definition
smartereye_device.cc:43
apollo::drivers::smartereye::SmartereyeDevice::is_capturing
bool is_capturing()
Definition
smartereye_device.cc:68
apollo::drivers::smartereye::SmartereyeDevice::uninit
int uninit()
Definition
smartereye_device.cc:56
apollo::drivers::smartereye::SmartereyeDevice::poll
int poll()
Definition
smartereye_device.cc:49
apollo::drivers::smartereye::SmartereyeDevice::wait_for_device
bool wait_for_device()
Definition
smartereye_device.cc:70
apollo::drivers::smartereye::SmartereyeDevice::~SmartereyeDevice
virtual ~SmartereyeDevice()
Definition
smartereye_device.cc:32
apollo::drivers::smartereye::SmartereyeHandler
Definition
smartereye_handler.h:34
cyber.h
apollo::drivers::smartereye::CallbackFunc
std::function< bool(RawImageFrame *rawFrame)> CallbackFunc
Definition
smartereye_handler.h:32
apollo
class register implement
Definition
arena_queue.h:37
smartereye_handler.h
apollo::drivers::smartereye::config::Config
Definition
config.proto:17
modules
drivers
smartereye
smartereye_device.h