How do I add generated audio to a silent video?
6 views (last 30 days)
Show older comments
Shilpa Sonawane
on 3 Feb 2025
Commented: Image Analyst
on 6 Feb 2025
I have written following code to add generated audio into a silent video. It executes smoothly. But the audio doesn't get added into the "newvideo.avi" file.
videoFReader = vision.VideoFileReader('silent_pgwl1s.avi');
% videoFWriter = vision.VideoFileWriter('newvideo.avi','AudioInputPort',true);
videoFWriter = vision.VideoFileWriter('newvideo.avi','AudioInputPort',true);
for i=1:75
% videoFrame = step(videoFReader);
% step(videoFWriter, videoFrame,predgwo);
videoFrame= step(videoFReader);
videoFWriter(videoFrame,orgvf) ;
end
release(videoFReader);
release(videoFWriter);
0 Comments
Accepted Answer
Image Analyst
on 3 Feb 2025
3 Comments
Image Analyst
on 6 Feb 2025
@Shilpa Sonawane, sorry, I haven't tried it and I don't have time. Try calling tech support.
More Answers (0)
See Also
Categories
Find more on Audio and Video Data in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!