This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
if [[ "$#" -lt 2 ]]; then | |
echo "Usage:" | |
echo " $0 <input_file> <output_dir> [delimiter]" | |
echo | |
echo " input_file" | |
echo " Paramater file. Input file contents should be in the form:" | |
echo " <videoFileName>=<start>=<duration>=<cut_name>"i | |
echo " example:" | |
echo " Mozart Concerto no. 23 maestros.mp4=00:02:55=00:01:13=Mozart 1st movementA.mp4" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Cross-platform sleep function for C | |
* @param int milliseconds | |
*/ | |
void sleep_ms(int milliseconds) | |
{ | |
#ifdef WIN32 | |
Sleep(milliseconds); | |
#elif _POSIX_C_SOURCE >= 199309L | |
struct timespec ts; |