Wednesday, May 20, 2020
How to make a movie from your screen and then edit frames in ImageJ
Task: I want to make a movie of the 3D flyby of the microscope model, but since the control of rotation is not perfect, need to edit the frames
Step1: Record movie. use VLC media player, choose Media>Open Capture device> capture Device>Capture Mode: choose "Desktop"; then change "play" to "convert". Now another window pops out: choose the file format you want to same and where you want to save. Then click "start". You are now recording your screen. I saved into MP4.
Step2: Install FFMEG. MP4 cannot be imported by Imagej. Even if you convert it into avi by VLC media player, it is still cannot be imported by imagej. So I need to convert it to avi. This could be best achieved by FFMEG, which is an open-source video converting software. Download it from its website and install it. Here is how:https://www.youtube.com/watch?v=qjtmgCb8NcE
Step3: With FFMEG, I first tried this command (ffmpeg -i mimsflyby2.mp4 mimsflyb2.avi), but get an error when I tried to open the avi file with imagej "("/An error occured reading the AVI file. Unsupported compresion: 34504d46 'FMP4".). Then I found another command from here http://imagej.1557.x6.nabble.com/Importing-avi-td5000582.html, and it worked: ffmpeg -i myInputFile.avi -pix_fmt nv12 -f avi -vcodec rawvideo convertedFile.avi
Now we could edit frames in ImageJ!
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment