OpenCVSharp 4.5 跑一遍OpenCV官方教程(全为手敲代码,如有雷同都是我的错)
图像金字塔
OpenCV教程链接:https://docs.opencv.org/4.5.0/d4/d1f/tutorial_pyramids.html
核心语句
- pyrUp()
- pyrDown()
关于图像金字塔的介绍,推荐这一篇:https://blog.youkuaiyun.com/zhu_hongji/article/details/81536820
using OpenCvSharp;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace ConsoleApp1
{
class tutorial8 : ITutorial
{
const string window_name = "Pyramids Demo";
public void Run()
{
Mat src = Cv2.ImRead("i:\\csharp\\images\\chicky_512.png");
// Check if image is loaded fine
if (src.Empty())
{
Console.WriteLine(" Error opening image\n");

本文通过C#代码展示了如何利用OpenCVSharp4.5库进行图像金字塔的构建,包括图像的放大(pyrUp)和缩小(pyrDown)操作。通过实例代码解释了如何读取图像并应用这些操作,帮助读者理解图像金字塔的概念。
最低0.47元/天 解锁文章
9573

被折叠的 条评论
为什么被折叠?



