2018-04-09 05:46:01 +03:00
|
|
|
|
# 样例 {#guide_samples}
|
|
|
|
|
|
|
|
|
|
样例在 `<sdk>/samples` 目录,其提供了不同接口层的使用范例。
|
|
|
|
|
|
|
|
|
|
* `api`, API 层接口,依赖 OpenCV 。
|
|
|
|
|
* `device`,中间层接口,不依赖 OpenCV 。
|
|
|
|
|
* `uvc`,底层接口。
|
|
|
|
|
|
|
|
|
|
> 目前 API 层接口,正在实现中。
|
|
|
|
|
|
|
|
|
|
## 依赖
|
|
|
|
|
|
|
|
|
|
* [OpenCV](https://opencv.org/),用于显示图像。
|
|
|
|
|
|
2018-04-23 18:11:11 +03:00
|
|
|
|
<!--
|
|
|
|
|
```cmd
|
|
|
|
|
>set OpenCV_DIR=C:\opencv
|
|
|
|
|
```
|
|
|
|
|
-->
|
|
|
|
|
|
2018-04-09 05:46:01 +03:00
|
|
|
|
## 编译
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
make samples
|
|
|
|
|
```
|
|
|
|
|
|
|
|
|
|
## 运行
|
|
|
|
|
|
|
|
|
|
运行 `device` 层接口样例,显示图像并输出 IMU 。
|
|
|
|
|
|
|
|
|
|
```bash
|
|
|
|
|
./samples/_output/bin/device/camera_d
|
|
|
|
|
```
|