159731 Assignment 3
Due: 7/6/2024
Your task for this assignment is to write a program to perform video stabilisation.
On stream is a short video shot with no video stabilisation. For this assignment you must write a C++ program using
OpenCV to produce a stabilised video. You will need to find cumulative homography matrices for a number of
sequential frames (initially try a 19 frame window). These matrices need to be relative to the first frame but must be
calculated by multiplying a cumulative matrix (initially the identity matrix) by the homography between the current and
previous frames. You can use any method you like to find the homography, try feature point matching or optical flow.
You must then smooth the central matrix using a Gaussian weighted average. Using this smoothed matrix and the
unsmoothed previous matrix, find a new matrix that will warp the central frame using warpPerspective() and then
display it. Display the output image with a green border as shown above. You will need a buffer of N frames and a
buffer of N matrices where N is the smoothing window size. Wait until N frames have been captured before displaying
any output and keep displaying frames until the buffer is empty.
Test different values for the size and standard deviation of the Gaussian filter window, once you have values which give
smooth motion, you can hard code them in the program.
I will test your code on different videos and using a webcam.
Your code must be in C++, you must use OpenCV version 4 or later. Use the CMake example provided to make sure I
can compile your code. Submit a single .cpp file on stream (no zip files), if your solution does not compile and run on
my machine, you will lose marks. Your program should take an optional single parameter, the name of the video file. If
the video file name is missing you should open the webcam with index 0.
The assignment is worth 10 marks.
Submit your assignment on Stream by the due date.
请加QQ:99515681 邮箱:99515681@qq.com WX:codinghelp
- 赛诺威盛:大孔径专科化CT领航者
- 网易硬刚腾讯 两大游戏玩家之间的口水仗不断
- 全球“最独特”的一台华为 nova 6 5G 版手机是什么样子的?
- 拼多多抖音淘宝京东,谁是真低价?
- 老杨第一次再度抓握住一瓶水,他由此产生了新的憧憬
- 丰田章男称未来依然需要内燃机 已经启动电动机新项目
- B站更新决策机构名单:共有 29 名掌权管理者,包括陈睿、徐逸、李旎、樊欣等人
- 苹果罕见大降价,华为的压力给到了?
- 三明列东又有房子要拆迁!住这里的人要发了!
- 放大招后,广州又忍不住了…
- 私募积极加仓,百亿股票私募仓位指数创出近八周新高
- 他,传闻中马云最想见的人
- 升级的脉脉,正在以招聘业务铺开商业化版图
- 如何经营一家好企业,需要具备什么要素特点
- 智慧驱动 共创未来| 东芝硬盘创新数据存储技术