胡斌

1.0.8

using the name of first audio or video as the output ts file's main name
... ... @@ -799,10 +799,17 @@ int concate_files_and_adjust_timecode(const char * output_dest_file){
int get_output_file_name(int i, const char * file_prefix, char * outputfile){
char prefix[24];
strncpy(prefix, file_prefix, 18);
prefix[18] = 0;
sprintf(outputfile, "%s_%d.ts", prefix, i);
char prefix[128];
const char * p = strstr(file_prefix, ".");
if (p) {
strncpy(prefix, file_prefix, p - file_prefix);
prefix[p - file_prefix] = 0;
}
else {
strcpy(prefix, file_prefix);
}
sprintf(outputfile, "%s.ts", prefix, i);
return 0;
}
... ... @@ -997,7 +1004,7 @@ void get_outinfo_file_name(char * input)
int main(int argc, char * argv[])
{
if (argc < 2) {
printf(" merge_av 1.0.7\n");
printf(" merge_av 1.0.8\n");
printf(" run ffmpeg to merge audio and video files according to the record info file,\nusage:");
printf("\n %s record_info_filename [-p] [-k]", argv[0]);
printf("\n -p :only print the command,don't run ffmpeg");
... ...