Two videos sampling frequency sync
显示 更早的评论
Hello, i have two different videos. one was sampled at 30Hz, the other is sampled at 9Hz.
i want to sync the both videos on 30Hz. How can i do it?
right now i'm kind of deviding the number manually by (30/9)
for ii=1:frame_sampeled
%sample freq adaptetion
VO_temp(:,:,:,ii) = vid_VO.readFrame();
VO=squeeze(VO_temp(:,:,:,ii));
ii_ir=1+uint8((ii/10)*3);
if ii_ir ~= last_ii_ir
IR_temp(:,:,:,ii_ir) = vid_IR.readFrame();
IR=squeeze(IR_temp(:,:,:,ii_ir));
last_ii_ir=ii_ir;
end
3 个评论
Anurag Agrawal
2020-3-31
You can explore this function and see if it helps:
Dhananjay Kumar
2020-3-31
编辑:Dhananjay Kumar
2020-3-31
Here 30Hz and 9Hz are frame frequencies , right?
Or Amselem
2020-3-31
回答(1 个)
Dhananjay Kumar
2020-3-31
0 个投票
If you have Vision HDL toolbox. This might help:
2 个评论
Or Amselem
2020-3-31
Dhananjay Kumar
2020-3-31
I guess you want to make the frame count in the two videos same. I am not aware of any function which will resample frames of one video to make the frame counts same as another video.
If you want to make the running time of the videos same then you can adjust the frame rate(number of frames displayed per second) using VideoWriter object. Note that this will not change the total frame count of a video.
类别
在 帮助中心 和 File Exchange 中查找有关 Video Formats and Interfaces 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!