当前位置:网站首页>Opencv personal notes
Opencv personal notes
2022-07-07 16:30:00 【qq_ fifty-seven million two hundred and fifty-one thousand thre】
One 、 Show how to get a picture and display it on the window
#include <iostream>
#include<opencv2/opencv.hpp>
using namespace std;
using namespace cv;
int main() {
Mat src = imread("D:\\timg (1).jpg", IMREAD_GRAYSCALE);// Read in the data in the form of a matrix , The second parameter represents displaying a grayscale image .
if (src.empty())
{
printf("could not load image");// If the picture doesn't exist Will not be able to read , Print to terminal .
return -1;
}
// Call this function when the image beyond the screen cannot be displayed .
namedWindow(" Input window ", WINDOW_FREERATIO);// Created a new window , Parameters 1 Name , The second parameter represents a free scale
imshow(" Input window ", src);// Indicates that it is displayed on the newly created input window , The first parameter represents the window name ,src Represents a data object Mat
waitKey(0);// Execute to this sentence , Program blocking . The parameter represents the delay time . Company ms
destroyAllWindows();// Destroy the previously created display window
return 0;
}
Two 、 What is an image
The image is on the screen
边栏推荐
- Apache Doris just "graduated": why should we pay attention to this kind of SQL data warehouse?
- Opencv configuration 2019vs
- 【医学分割】attention-unet
- laravel 是怎么做到运行 composer dump-autoload 不清空 classmap 映射关系的呢?
- Personal notes of graphics (3)
- Performance measure of classification model
- [C language] question set of X
- torch. Numel action
- logback. XML configure logs of different levels and set color output
- Prometheus API deletes all data of a specified job
猜你喜欢
HAVE FUN | “飞船计划”活动最新进展
Description of vs common shortcut keys
What are compiled languages and interpreted languages?
MySQL数据库基本操作-DQL-基本查询
无法将“pip”项识别为 cmdlet、函数、脚本文件或可运行程序的名称
Three. JS series (2): API structure diagram-2
Enterprise log analysis system elk
PyTorch 中的乘法:mul()、multiply()、matmul()、mm()、mv()、dot()
The team of East China Normal University proposed the systematic molecular implementation of convolutional neural network with DNA regulation circuit
[flower carving experience] 15 try to build the Arduino development environment of beetle esp32 C3
随机推荐
pycharm 终端部启用虚拟环境
95. (cesium chapter) cesium dynamic monomer-3d building (building)
AutoLISP series (2): function function 2
Personal notes of graphics (2)
面试题 01.02. 判定是否互为字符重排-辅助数组算法
Aerospace Hongtu information won the bid for the database system research and development project of a unit in Urumqi
logback.xml配置不同级别日志,设置彩色输出
torch. Numel action
[C language] question set of X
Geoserver2.18 series (5): connect to SQLSERVER database
hellogolang
分类模型评价标准(performance measure)
95.(cesium篇)cesium动态单体化-3D建筑物(楼栋)
The team of East China Normal University proposed the systematic molecular implementation of convolutional neural network with DNA regulation circuit
Laravel5.1 路由 -路由分组
Communication mode between application program and MATLAB
Bidding announcement: 2022 Yunnan Unicom gbase database maintenance public comparison and selection project (second) comparison and selection announcement
全网“追杀”钟薛高
PHP中exit,exit(0),exit(1),exit(‘0’),exit(‘1’),die,return的区别
记一次项目的迁移过程