A video edited using this program
So uh this is a tool I coded to automatically edit my modded map playthrough videos. At first, I decided to release this on gamebanana, but in the end, after reviewing my crappy program, I decided to keep it private. However, someone asked me to upload it so I did and so it's here on gamebanana.
Why this program is crap
Code is sloppy. Security is questionable (as it rely on batch). Only works on windows. Has a lot of restrictions on file name and file type. Has no GUI (doesn't even have a tkinter window). I've only tested the python scripts on my windows 10, and I haven't used the ctrl+t function, not even once.
Why the restrictions
This wasn't intended to be released, and after I decided to release it I'm too lazy to change anything.
A failed attempt to improve the program
I tried making a gui for this program using tkinter. But it doesn't support input grabbing when the program isn't in focus (or something like that). So in the end the gui program was abandoned.
And I hope you can understand what I'm saying.
Also if you want to improve this crappy program just go do it.
Download the zip file. ffmpeg and python are needed.
When you're going to record your gameplay, start the flag maker first (so that it can receive the ctrl+s input), then open whatever recording software you're using. Bind ctrl+s as the start recording hotkey (this step is optional). Input video needs to be in mp4 format. Press ctrl+s to start both programs (or press ctrl+s and the start recording hotkey in quick succession to maximize synchronization rate). Start recording before entering the map you're going to record.
Press ctrl+f to flag the current second.
Press ctrl+t to flag the current second - 5 (5 second before the current second)
Press ctrl+e to end the program. End the program after exiting the map.
After ending the program, a input.txt file that store all your flags in second should appear.
3. After recording
Move your recorded video to the same folder containing the two programs and the batch file. Rename it as input.mp4. Then run the batch file. It should produce a file named output.txt that store all the black screen starts and the black screen ends in second. Finally, run the automated editor file. And output.mkv should be generated which contains all desired segments concatted together that contain your input flags. You can delete other auxiliary files if you want.
This program may fail when at some point of the game the game window is nearly pure black. Edit the pixel threshold in the batch file to 1 in this case (pix_th option with the [out0] behind it). Unless the screen is really pure black or the screen transition is the kind seen in, for example, Sunset Boulevard, this can prevent the issue. A known case of this is a certain part of Old Abyss.