convert video from rgb to hsv
by this way u can edit the video and make it again video
split it to image and do what u want
this the input
http://www.youtube.com/watch?v=WiUsRbTegEg&feature=youtu.be
the output
http://www.youtube.com/watch?v=2HCnCrudz0A&feature=youtu.be
the matlab code
mkdir('workingDir');mkdir('workingDir','images');shuttleVideo = VideoReader('723493_558567347510592_214063615_n.mp4');for ii = 1:shuttleVideo.NumberOfFramesimg = read(shuttleVideo,ii);img=rgb2hsv(img); % u can edit all here :)imwrite(img,fullfile('workingDir','images',sprintf('img%d.jpg',ii)));endimageNames = dir(fullfile('workingDir','images','*.jpg'));imageNames = {imageNames.name}';imageStrings = regexp([imageNames{:}],'(\d*)','match');imageNumbers = str2double(imageStrings);[~,sortedIndices] = sort(imageNumbers);sortedImageNames = imageNames(sortedIndices);outputVideo = VideoWriter(fullfile('workingDir','shuttle_out.avi'));outputVideo.FrameRate = shuttleVideo.FrameRate;open(outputVideo);for ii = 1:length(sortedImageNames)img = imread(fullfile('workingDir','images',sortedImageNames{ii}));writeVideo(outputVideo,img);endclose(outputVideo);
ليست هناك تعليقات:
إرسال تعليق