Update guide docs
This commit is contained in:
parent
505b7df188
commit
b0b12c2cc7
|
@ -15,6 +15,18 @@ cd mynt-eye-sdk-2/
|
|||
make init
|
||||
```
|
||||
|
||||
### [OpenCV](https://opencv.org/)
|
||||
|
||||
编译前,可在系统终端(Windows 命令提示符)里如下指定 OpenCV 路径,其为 `OpenCVConfig.cmake` 目录:
|
||||
|
||||
```bash
|
||||
# Linux, macOS
|
||||
export OpenCV_DIR=~/opencv
|
||||
|
||||
# Windows
|
||||
set OpenCV_DIR=C:\opencv
|
||||
```
|
||||
|
||||
## 编译代码
|
||||
|
||||
```bash
|
||||
|
|
|
@ -92,8 +92,18 @@ Init git hooks
|
|||
ERROR: clang-format-diff is not installed!
|
||||
Expect cmake version >= 3.0
|
||||
cmake version 3.10.1
|
||||
How to upgrade cmake in Ubuntu
|
||||
https://askubuntu.com/questions/829310/how-to-upgrade-cmake-in-ubuntu
|
||||
```
|
||||
|
||||
### [OpenCV](https://opencv.org/)
|
||||
|
||||
编译前,可在系统终端(Windows 命令提示符)里如下指定 OpenCV 路径,其为 `OpenCVConfig.cmake` 目录:
|
||||
|
||||
```bash
|
||||
# Linux, macOS
|
||||
export OpenCV_DIR=~/opencv
|
||||
|
||||
# Windows
|
||||
set OpenCV_DIR=C:\opencv
|
||||
```
|
||||
|
||||
## 编译代码
|
||||
|
|
|
@ -1,3 +1,13 @@
|
|||
# OpenCV 依赖 {#guide_opencv}
|
||||
|
||||
目前 SDK 本身未依赖 OpenCV ,仅是样例依赖其显示图像。
|
||||
SDK 提供了三层接口,其 OpenCV 依赖情况如下:
|
||||
|
||||
* `api`, 上层接口,依赖 OpenCV 。
|
||||
* `device`,中间层接口,不依赖 OpenCV 。
|
||||
* `uvc`,底层接口,不依赖 OpenCV 。
|
||||
|
||||
如果不想使用 OpenCV ,你可编辑 `<sdk>/cmake/Option.cmake` 里的 `WITH_API` 选项,设为 `OFF` 就能关闭 `api` 层代码编译:
|
||||
|
||||
```cmake
|
||||
option(WITH_API "Build with API layer, need OpenCV" ON)
|
||||
```
|
||||
|
|
|
@ -2,12 +2,6 @@
|
|||
|
||||
样例在 `<sdk>/samples` 目录,其提供了不同接口层的使用范例。
|
||||
|
||||
* `api`, API 层接口,依赖 OpenCV 。
|
||||
* `device`,中间层接口,不依赖 OpenCV 。
|
||||
* `uvc`,底层接口。
|
||||
|
||||
> 目前 API 层接口,正在实现中。
|
||||
|
||||
## 依赖
|
||||
|
||||
* [OpenCV](https://opencv.org/),用于显示图像。
|
||||
|
@ -29,6 +23,15 @@ make samples
|
|||
|
||||
## 运行
|
||||
|
||||
运行 `api` 层接口样例,显示图像并输出 IMU 。
|
||||
|
||||
```bash
|
||||
./samples/_output/bin/api/camera_a
|
||||
|
||||
# Windows
|
||||
.\samples\_output\bin\api\camera_a.bat
|
||||
```
|
||||
|
||||
运行 `device` 层接口样例,显示图像并输出 IMU 。
|
||||
|
||||
```bash
|
||||
|
|
Loading…
Reference in New Issue
Block a user