View Full Version : request for Avisynth to get Date/Time Stamp of clips
medp7060
27th December 2005, 01:40
I have sought help on how to get the Date/Time Stamp of clips within Avisynth and I am not successful. It seems that there is no such functions or filters available. The Time (string) can get current system date/time. I hope somebody can make avisynth to get the Date/Time Stamp of clips.
esby
27th December 2005, 12:23
What do you means by date timestamp of clips?
Date time of last modification or creation of avi file loaded via the clip?
Date time of when the 'avs clip' object were created in memory?
Date time of the avs file creation?
esby
ariga
27th December 2005, 13:22
Looks like it originated here :)
http://forum.doom9.org/showthread.php?t=104527
medp7060
29th December 2005, 11:44
Esby,
I mean the date/time of last modification of avi file loaded via the clip. I know little about programming, but I guess all the three date/time stamps (Created, Modified and Accessed) of an avi clip loaded in an avs can be easily extracted by switches.
Ariga,
yes. A CORE or a filter would make it much easy.
stickboy
29th December 2005, 12:01
Such information isn't meaningful for a clip. For example, let's say you have:
clip1 = AVISource("foo.avi")
clip2 = AVISource("bar.avi")
clip3 = clip1 ++ clip2Okay, what would such a function return for clip3?
What would be more appropriate is a general function that retrieved properties of files. I guess this weekend I could write a plugin to do it if no one else feels like doing it.
Backwoods
29th December 2005, 20:20
This would be nice for MPEG2 files transfered from HDV cameras. They contain TimeStamp, Iris, Gain, etc etc.
esby
30th December 2005, 01:28
Okay, what would such a function return for clip3?
Well the question also exists for tag properties that can exist in an avi.
For informations like (c), author, etc.
The generic answer would be to have filters not affects these information.
Now for mutiples childs, there is a need to defined special handling, such as:
* concatenation if different.
* strip.
* override of one clip properties by the other ones.
* override of the resulting properties by a filter.
Basically it still (meta) information applied to a clip, but you need to define properly the method that will handle it. A bit like what getFrame() is doing for the frame associated to the clip, or like getAudioFrame() is doing...
Now that supposes tricks or extra properties transfered which does not exists with 2.5 structures.
esby
medp7060
30th December 2005, 05:06
stickboy,
I am glad that you are going to bother to write a plugin for this. I think "DateTime.dll" would be similar to the "Call.dll", since it is only to run once in a script to get the date/time of a loaded clip. The format of the returned Date and Time is similar to the Time(string) of the Core. Something like:
LoadPlugin("DateTime.dll")
V=AviClip #A clip without date/time stamp at 30 fps
Modified_D=DateTime(V,-D, "-2") # swith -d for the date and -2 "to operate before any encoding starts" from the readme of Call
Modified_T=DateTime(V,-T, "-2") # swith -T for the date
DirectShowSource(V,30)
Subtitle(Modified_D)
ShowSMPTE(30,offset=Modified_T)
the above script will impose Date and Time into the video. That is what I am doing for avi clips by Canon except that I manually get the date/time through file properties. But I feel like that a plugin will make a batch conversion.
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.