Cast: Use VideoFrame::GetTimestamp() to calculate the timestamp
Cast: Use VideoFrame::GetTimestamp() to calculate the timestamp

We used to timestamp a frame when it is delivered to CastVideoSink in
the renderer. The TimeTicks obtained are jittery. We should use the
TimeTicks when the frame is captured. However this information is lost
in VideoCaptureImpl and transformed into a TimeDelta with 0 as the
reference value.

The method to reconstruct the capture time is by adding the TimeDelta
of each frame with the TimeTicks when the first frame is delivered. The
resultant TimeTicks is less jittery but has a built-in delay. We're okay
with this approach now until audio/video synchronization becomes a
problem.

BUG=335330

Review URL: https://codereview.chromium.org/196303002

git-svn-id: de016e52bd170d2d4f2344f9bf92d50478b649e0@257340 0039d316-1c4b-4281-b951-d872f2087c98

dednal/chromium.src,axinging/chromium-crosswalk,krieger-od/nwjs_chromium.src,axinging/chromium-crosswalk,Jonekee/chromium.src,dednal/chromium.src,ondra-novak/chromium.src,dushu1203/chromium.src,TheTypoMaster/chromium-crosswalk,krieger-od/nwjs_chromium.src,Fireblend/chromium-crosswalk,Pluto-tv/chromium-crosswalk,bright-sparks/chromium-spacewalk,markYoungH/chromium.src,crosswalk-project/chromium-crosswalk-efl,jaruba/chromium.src,crosswalk-project/chromium-crosswalk-efl,Fireblend/chromium-crosswalk,patrickm/chromium.src,M4sse/chromium.src,littlstar/chromium.src,patrickm/chromium.src,Fireblend/chromium-crosswalk,mohamed--abdel-maksoud/chromium.src,jaruba/chromium.src,Pluto-tv/chromium-crosswalk,Just-D/chromium-1,dushu1203/chromium.src,mohamed--abdel-maksoud/chromium.src,littlstar/chromium.src,hgl888/chromium-crosswalk,hgl888/chromium-crosswalk-efl,Jonekee/chromium.src,chuan9/chromium-crosswalk,krieger-od/nwjs_chromium.src,markYoungH/chromium.src,krieger-od/nwjs_chromium.src,Fireblend/chromium-crosswalk,krieger-od/nwjs_chromium.src,jaruba/chromium.src,Chilledheart/chromium,dednal/chromium.src,krieger-od/nwjs_chromium.src,littlstar/chromium.src,ondra-novak/chromium.src,TheTypoMaster/chromium-crosswalk,dushu1203/chromium.src,bright-sparks/chromium-spacewalk,Just-D/chromium-1,patrickm/chromium.src,dushu1203/chromium.src,mohamed--abdel-maksoud/chromium.src,fujunwei/chromium-crosswalk,krieger-od/nwjs_chromium.src,PeterWangIntel/chromium-crosswalk,hgl888/chromium-crosswalk-efl,patrickm/chromium.src,dednal/chromium.src,fujunwei/chromium-crosswalk,jaruba/chromium.src,chuan9/chromium-crosswalk,ondra-novak/chromium.src,Chilledheart/chromium,PeterWangIntel/chromium-crosswalk,Just-D/chromium-1,dednal/chromium.src,PeterWangIntel/chromium-crosswalk,axinging/chromium-crosswalk,patrickm/chromium.src,jaruba/chromium.src,littlstar/chromium.src,hgl888/chromium-crosswalk,bright-sparks/chromium-spacewalk,Jonekee/chromium.src,mohamed--abdel-maksoud/chromium.src,fujunwei/chromium-crosswalk,Fireblend/chromium-crosswalk,Just-D/chromium-1,Jonekee/chromium.src,littlstar/chromium.src,bright-sparks/chromium-spacewalk,fujunwei/chromium-crosswalk,littlstar/chromium.src,hgl888/chromium-crosswalk-efl,crosswalk-project/chromium-crosswalk-efl,TheTypoMaster/chromium-crosswalk,jaruba/chromium.src,mohamed--abdel-maksoud/chromium.src,mohamed--abdel-maksoud/chromium.src,dushu1203/chromium.src,hgl888/chromium-crosswalk-efl,M4sse/chromium.src,TheTypoMaster/chromium-crosswalk,Chilledheart/chromium,hgl888/chromium-crosswalk,ondra-novak/chromium.src,axinging/chromium-crosswalk,Just-D/chromium-1,Pluto-tv/chromium-crosswalk,Jonekee/chromium.src,hgl888/chromium-crosswalk-efl,PeterWangIntel/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,ltilve/chromium,ondra-novak/chromium.src,Pluto-tv/chromium-crosswalk,krieger-od/nwjs_chromium.src,dednal/chromium.src,chuan9/chromium-crosswalk,Just-D/chromium-1,patrickm/chromium.src,Chilledheart/chromium,Jonekee/chromium.src,ltilve/chromium,bright-sparks/chromium-spacewalk,Jonekee/chromium.src,M4sse/chromium.src,bright-sparks/chromium-spacewalk,M4sse/chromium.src,fujunwei/chromium-crosswalk,Fireblend/chromium-crosswalk,chuan9/chromium-crosswalk,dednal/chromium.src,dushu1203/chromium.src,ondra-novak/chromium.src,hgl888/chromium-crosswalk,dushu1203/chromium.src,markYoungH/chromium.src,Chilledheart/chromium,PeterWangIntel/chromium-crosswalk,hgl888/chromium-crosswalk-efl,chuan9/chromium-crosswalk,hgl888/chromium-crosswalk-efl,Jonekee/chromium.src,dednal/chromium.src,Jonekee/chromium.src,crosswalk-project/chromium-crosswalk-efl,ltilve/chromium,Jonekee/chromium.src,axinging/chromium-crosswalk,fujunwei/chromium-crosswalk,M4sse/chromium.src,jaruba/chromium.src,dushu1203/chromium.src,Chilledheart/chromium,hgl888/chromium-crosswalk,markYoungH/chromium.src,chuan9/chromium-crosswalk,Just-D/chromium-1,dednal/chromium.src,Pluto-tv/chromium-crosswalk,markYoungH/chromium.src,markYoungH/chromium.src,axinging/chromium-crosswalk,axinging/chromium-crosswalk,jaruba/chromium.src,PeterWangIntel/chromium-crosswalk,Pluto-tv/chromium-crosswalk,jaruba/chromium.src,M4sse/chromium.src,Fireblend/chromium-crosswalk,markYoungH/chromium.src,mohamed--abdel-maksoud/chromium.src,TheTypoMaster/chromium-crosswalk,fujunwei/chromium-crosswalk,jaruba/chromium.src,hgl888/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,axinging/chromium-crosswalk,Chilledheart/chromium,Pluto-tv/chromium-crosswalk,M4sse/chromium.src,patrickm/chromium.src,dednal/chromium.src,bright-sparks/chromium-spacewalk,Jonekee/chromium.src,crosswalk-project/chromium-crosswalk-efl,markYoungH/chromium.src,PeterWangIntel/chromium-crosswalk,dushu1203/chromium.src,hgl888/chromium-crosswalk,hgl888/chromium-crosswalk-efl,dushu1203/chromium.src,bright-sparks/chromium-spacewalk,chuan9/chromium-crosswalk,Fireblend/chromium-crosswalk,krieger-od/nwjs_chromium.src,ondra-novak/chromium.src,mohamed--abdel-maksoud/chromium.src,markYoungH/chromium.src,M4sse/chromium.src,axinging/chromium-crosswalk,M4sse/chromium.src,hgl888/chromium-crosswalk,M4sse/chromium.src,dednal/chromium.src,Fireblend/chromium-crosswalk,ltilve/chromium,markYoungH/chromium.src,ondra-novak/chromium.src,ltilve/chromium,Pluto-tv/chromium-crosswalk,fujunwei/chromium-crosswalk,TheTypoMaster/chromium-crosswalk,littlstar/chromium.src,Chilledheart/chromium,Pluto-tv/chromium-crosswalk,M4sse/chromium.src,axinging/chromium-crosswalk,krieger-od/nwjs_chromium.src,patrickm/chromium.src,PeterWangIntel/chromium-crosswalk,hgl888/chromium-crosswalk-efl,ltilve/chromium,PeterWangIntel/chromium-crosswalk,Chilledheart/chromium,mohamed--abdel-maksoud/chromium.src,markYoungH/chromium.src,crosswalk-project/chromium-crosswalk-efl,dushu1203/chromium.src,crosswalk-project/chromium-crosswalk-efl,ltilve/chromium,mohamed--abdel-maksoud/chromium.src,hgl888/chromium-crosswalk-efl,bright-sparks/chromium-spacewalk,hgl888/chromium-crosswalk,chuan9/chromium-crosswalk,ltilve/chromium,krieger-od/nwjs_chromium.src,ondra-novak/chromium.src,jaruba/chromium.src,fujunwei/chromium-crosswalk,crosswalk-project/chromium-crosswalk-efl,TheTypoMaster/chromium-crosswalk,axinging/chromium-crosswalk,Just-D/chromium-1,littlstar/chromium.src,patrickm/chromium.src,chuan9/chromium-crosswalk,ltilve/chromium,mohamed--abdel-maksoud/chromium.src,Just-D/chromium-1