OpenCV Sample Code in C++

Overview

OpenCV Sample Code

demo.mp4

undistortion_calibration

00_doc/undistortion_calibration.jpg

  • Basic camera calibration using chessboard pattern

undistortion_manual_unified_projection

00_doc/undistortion_manual_unified_projection.jpg

  • Manual camera calibration using the unified projection model for fisheye / omnidirectional camera

projection_points_3d_to_2d

  • Projection (3D points (world coordinate) to a 2D image plane) using editable camera parameters
projection_points_3d_to_2d_floor.mp4
projection_points_3d_to_2d_wall.mp4

projection_image_3d_to_2d

  • Projection (image in world coordinate to a 2D image plane) using editable camera parameters
projection_image_3d_to_2d.mp4

transformation_topview_projection

  • Transformation to top view image using projection

00_doc/transformation_topview_projection.jpg

transformation_homography

  • Homobraphy transformation
transformation_homography.mp4

distance_calculation

  • Distance calculation on ground plane

00_doc/distance_calculation.jpg

dnn_face

  • Face Detection using YuNet
  • Head Pose Estimatino Using SolvePnP
  • Overlay icon with transparent mask

00_doc/dnn_face.jpg 00_doc/dnn_face_mask.jpg

License

  • Copyright 2021 iwatake2222
  • Licensed under the Apache License, Version 2.0

Acknowledgements

You might also like...
Mixed reality VR laser tag using Oculus Quest 2 and OAK-D depth cameras. First prize winner for North America region in OpenCV AI Competition 2021.
Mixed reality VR laser tag using Oculus Quest 2 and OAK-D depth cameras. First prize winner for North America region in OpenCV AI Competition 2021.

Mixed Reality Laser Tag Copyright 2021 Bart Trzynadlowski Overview This is the source code to my Mixed Reality Laser Tag project, which won first priz

A simple facial recognition script using OpenCV's FaceRecognizer module implemented in C++
A simple facial recognition script using OpenCV's FaceRecognizer module implemented in C++

Local Binary Patterns Histogram Recognizer A proyect that implements the LBPHRecognizer class of the OpenCV library to determine if a detected face co

Standard project template for C++ projects, modeled after OpenCV's GitHub

C++ Project Template Generic C++ modular template for projects. Project Structure The project structure is created to maximize modularity, increase co

Starting with OpenCV and Qt on MacOS is a bit of difficult if you haven't installed and used libraries in XCode.
Starting with OpenCV and Qt on MacOS is a bit of difficult if you haven't installed and used libraries in XCode.

OpenCV and Qt on MacOS Introduction Starting with OpenCV and Qt on MacOS is a bit of difficult if you haven't installed and used libraries in XCode. T

A crude untested example showing how to retrieve and display images from multiple cameras with OpenCV and wxWidgets.

About wxOpenCVCameras is a crude untested example of how to retrieve and display images from multiple cameras, using OpenCV to grab images from a came

Libcamera with OpenCV in Raspberry Pi 64 bit Bullseye

Libcamera OpenCV RPi Bullseye 64OS Libcamera + OpenCV on a Raspberry Pi 4 with 64-bit Bullseye OS In the new Debian 11, Bullseye, you can only capture

liteCV is greater than OpenCV :)

liteCV liteCV is lightweight image processing library for C++11. Unlike OpenCV, liteCV must be SIMPLE. Unlike OpenCV, liteCV must be INDEPENDENCE. Ach

Helper Class for Deep Learning Inference Frameworks: TensorFlow Lite, TensorRT, OpenCV, ncnn, MNN, SNPE, Arm NN, NNAbla
Helper Class for Deep Learning Inference Frameworks: TensorFlow Lite, TensorRT, OpenCV, ncnn, MNN, SNPE, Arm NN, NNAbla

InferenceHelper This is a helper class for deep learning frameworks especially for inference This class provides an interface to use various deep lear

Example of using  ultralytics YOLO V5 with OpenCV 4.5.4, C++ and Python
Example of using ultralytics YOLO V5 with OpenCV 4.5.4, C++ and Python

yolov5-opencv-cpp-python Example of performing inference with ultralytics YOLO V5, OpenCV 4.5.4 DNN, C++ and Python Looking for YOLO V4 OpenCV C++/Pyt

Example of using YOLO v4 with OpenCV, C++ and Python
Example of using YOLO v4 with OpenCV, C++ and Python

yolov4-opencv-cpp-python Example of performing inference with Darknet YOLO V4, OpenCV 4.4.0 DNN, C++ and Python Looking for YOLO V5 OpenCV C++/Python

yolov5-deepsort+opencv.kcf+TensorRT+QT
yolov5-deepsort+opencv.kcf+TensorRT+QT

tracker yolov5-deepsort+opencv.kcf+TensorRT+QT 第一篇博客,可能格式不会太规范,就是记录一下。现在工作主要是cv算法部署英伟达开发板加算法开发,由于工作需求做了一个界面, 在基于deepsort的基础上加入了临时绘制跟踪目标的功能,并行运行kcf跟踪,u

cvnp: pybind11 casts between numpy and OpenCV, possibly with shared memory

cvnp: pybind11 casts and transformers between numpy and OpenCV, possibly with shared memory Explicit transformers between cv::Mat / cv::Matx and numpy

Arduino sample code to help you get started using the Soracom IoT Starter Kit!
Arduino sample code to help you get started using the Soracom IoT Starter Kit!

Soracom IoT Starter Kit The Soracom IoT Starter Kit includes everything you need to build your first connected device. It includes an Arduino MKR GSM

Sample app code for LPR deployment on DeepStream
Sample app code for LPR deployment on DeepStream

Sample For Car License Recognization Description Performance Prerequisition Download Build and Run Notice Description This sample is to show how to us

Provide sample code of efficient operator implementation based on the Cambrian Machine Learning Unit (MLU) .

Cambricon CNNL-Example CNNL-Example 提供基于寒武纪机器学习单元(Machine Learning Unit,MLU)开发高性能算子、C 接口封装的示例代码。 依赖条件 操作系统: 目前只支持 Ubuntu 16.04 x86_64 寒武纪 MLU SDK: 编译和

HMS Core Scene Kit Slim Mesh Demo sample code demonstrates how to invoke external interfaces of SlimMesh to perform mesh simplification.

HMS Core Scene Kit Slim Mesh Demo English | 中文 Table of Contents Introduction Environments Requirements Result License Introduction The Slim Mesh is a

Vulkan Video Sample Application demonstrating an end-to-end, all-Vulkan, processing of h.264/5 compressed video content.
Vulkan Video Sample Application demonstrating an end-to-end, all-Vulkan, processing of h.264/5 compressed video content.

This project is a Vulkan Video Sample Application demonstrating an end-to-end, all-Vulkan, processing of h.264/5 compressed video content. The application decodes the h.264/5 compressed content using an HW accelerated decoder, the decoded YCbCr frames are processed with Vulkan Graphics and then presented via the Vulkan WSI.

ESP32 drum computer / sample player / midi sequencer (Arduino audio project)

esp32_drum_computer ESP32 drum computer / sample player / midi sequencer (Arduino audio project) The project can be seen in my video https://youtu.be/

A bespoke sample compression codec for 64k intros
A bespoke sample compression codec for 64k intros

pulsejet A bespoke sample compression codec for 64K intros codec pulsejet lifts a lot of ideas from Opus, and more specifically, its CELT layer, which

Comments
  • 3D Points

    3D Points

    @iwatake2222 Hi,

    Thanks for sharing. I have some questions about the reconstruction.

    1. Can we use MIDAS V3?
    2. How can I save 3D Points and display them on another viewer?
    3. How can I measure?
    opened by sctrueew 7
  • face detection onnx: dynamic 'zero' shapes are not supported

    face detection onnx: dynamic 'zero' shapes are not supported

    While running face detection, net_ = cv::dnn::readNetFromONNX(model_filename);, throws the following error. Can you please help me how to solve this problem?

    [ERROR:[email protected]] global /home/opencv_build/opencv/modules/dnn/src/onnx/onnx_importer.cpp (2564) parseShape DNN/ONNX(Shape): dynamic 'zero' shapes are not supported, input 243 [ 0 0 0 51 ] [ERROR:[email protected]] global /home/opencv_build/opencv/modules/dnn/src/onnx/onnx_importer.cpp (1042) handleNode DNN/ONNX: ERROR during processing node with 1 inputs and 1 outputs: [Shape]:(onnx_node!Shape_70) from domain='ai.onnx' terminate called after throwing an instance of 'cv::Exception' what(): OpenCV(4.6.0-dev) /home/opencv_build/opencv/modules/dnn/src/onnx/onnx_importer.cpp:1064: error: (-2:Unspecified error) in function 'handleNode'

    Node [[email protected]]:(onnx_node!Shape_70) parse error: OpenCV(4.6.0-dev) /home/opencv_build/opencv/modules/dnn/src/onnx/onnx_importer.cpp:2565: error: (-215:Assertion failed) !isDynamicShape in function 'parseShape'

    Aborted (core dumped)

    opened by fisakhan 3
  • Undefined DepthEngine::kModelFilename

    Undefined DepthEngine::kModelFilename

    Hello!

    First of all thanks for the samples.

    I am trying to use reconstruction_depth_to_3d but I get the following issue:

    /mnt/external/cv/opencv_sample/reconstruction_depth_to_3d/depth_engine.cpp:40: undefined reference to `DepthEngine::kModelFilename'

    /mnt/external/cv/opencv_sample/reconstruction_depth_to_3d/depth_engine.cpp:47: undefined reference to `DepthEngine::kModelFilename'

    Any idea why?

    Thanks in advance!

    opened by TiagoCortinhal 1
  • Distance calculation on ground plane

    Distance calculation on ground plane

    Hi @iwatake2222,

    Thanks for sharing it, I have a GPS point and I want to get the lat/long of each pixel point when I move the mouse. Could you give some info about it to do that?

    Thanks in advance

    opened by sctrueew 1
Owner
iwatake
iwatake
This is a C++17 deployment of deep-learning based image inpainting algorithm on Windows10, using Libtorch, Opencv and Qt.

This is a desktop software for image inpainting. It is a C++ deployment of image inpainting algorithm on Windows10, based on C++17 and implemented using vs2019.

null 4 May 13, 2022
A crude untested example showing how to retrieve and display images from multiple cameras with OpenCV and wxWidgets.

About wxOpenCVCameras is a crude untested example of how to retrieve and display images from multiple cameras, using OpenCV to grab images from a came

PB 8 Dec 14, 2022
Sample project to use ImGui + GLFW + OpenGL3

About just a sample project to use ImGui ( https://github.com/ocornut/imgui ) Note Windows 11 Visual Studio 2019 + cmake-gui WSL2 on Windows 11 apt in

iwatake 4 Dec 23, 2021
You can use this to compile the code and output images into a word doc for assignment purposes

Code_n_Ouput_to_docx You can use this to compile the code and output images into a word doc for assignment purposes Basic requirements: Python 3.7 or

Aaditya Prabu K 0 Aug 21, 2022
DCT, IDCT, Quantization, DeQuantization operation code

DCT DCT, IDCT, Quantization, DeQuantization operation code 경희대학교 실감미디어 시스템 과제결과를 바탕으로 작성한 코드입니다. 작성자 : 정철현 해당 코드는 DCT, IDCT, Quantization, De-Quantiza

정철현 3 Oct 27, 2021
This is a sample ncnn android project, it depends on ncnn library and opencv

This is a sample ncnn android project, it depends on ncnn library and opencv

null 248 Jan 6, 2023
GPU PyTorch TOP in TouchDesigner with CUDA-enabled OpenCV

PyTorchTOP This project demonstrates how to use OpenCV with CUDA modules and PyTorch/LibTorch in a TouchDesigner Custom Operator. Building this projec

David 65 Jun 15, 2022
The minimal opencv for Android, iOS and ARM Linux

opencv-mobile ✔️ This project provides the minimal build of opencv library for the Android, iOS and ARM Linux platforms. ✔️ We provide prebuild binary

null 992 Dec 27, 2022
The SCRFD face detection, depends on ncnn library and opencv

The SCRFD face detection, depends on ncnn library and opencv

null 157 Jan 5, 2023
This is a C++17 deployment of deep-learning based image inpainting algorithm on Windows10, using Libtorch, Opencv and Qt.

This is a desktop software for image inpainting. It is a C++ deployment of image inpainting algorithm on Windows10, based on C++17 and implemented using vs2019.

null 4 May 13, 2022