MCPcopy Create free account
hub / github.com/FFmpeg/FFmpeg / opt_recording_timestamp

Function opt_recording_timestamp

fftools/ffmpeg_opt.c:783–804  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

781}
782
783static int opt_recording_timestamp(void *optctx, const char *opt, const char *arg)
784{
785 OptionsContext *o = optctx;
786 char buf[128];
787 int64_t recording_timestamp;
788 int ret;
789 struct tm time;
790
791 ret = av_parse_time(&recording_timestamp, arg, 0);
792 if (ret < 0)
793 return ret;
794
795 recording_timestamp /= 1e6;
796 time = *gmtime((time_t*)&recording_timestamp);
797 if (!strftime(buf, sizeof(buf), "creation_time=%Y-%m-%dT%H:%M:%S%z", &time))
798 return -1;
799 parse_option(o, "metadata", buf, options);
800
801 av_log(NULL, AV_LOG_WARNING, "%s is deprecated, set the 'creation_time' metadata "
802 "tag instead.\n", opt);
803 return 0;
804}
805
806int find_codec(void *logctx, const char *name,
807 enum AVMediaType type, int encoder, const AVCodec **pcodec)

Callers

nothing calls this directly

Calls 3

av_parse_timeFunction · 0.85
parse_optionFunction · 0.85
av_logFunction · 0.85

Tested by

no test coverage detected