Open 213cy opened 4 years ago
pause(2) for a= 1:3 filename = ['a',num2str(a),'.jpeg']; eval(['!ffmpeg -y -f gdigrab -i desktop -frames:v 1 -vf "scale=iw/2:ih/2" ',... filename ,' 2>nul']) pause(0.01) A = imread(filename); figure imshow(A) end !ffmpeg -y -f gdigrab -i desktop -frames:v 1 -vf "scale=iw/2:ih/2" a.jpeg 2>nul A = imread('a.jpeg'); figure imshow(A)
https://github.com/cyfile/Matlab-miscellanies/issues/13
system('program arg1 arg2'); % blocking, synchronous system('program arg1 arg2 &'); % non-blocking, asynchronous