Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/FFmpeg/FFmpeg.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOlivier Langlois <olivier@trillion01.com>2014-05-07 01:16:49 +0400
committerMichael Niedermayer <michaelni@gmx.at>2014-05-17 17:51:49 +0400
commitb052bccbe4b5533c3f11fddb14df59fb72dbf463 (patch)
treeafe015f1ab22ce40799862b1a6b299af40e08797 /libavcodec/motion-test.c
parent0eec06ed8747923faa6a98e474f224d922dc487d (diff)
lavc: Use av_gettime_relative()
Whenever av_gettime() is used to measure relative period of time, av_gettime_relative() is prefered as it guarantee monotonic time on supported platforms. Signed-off-by: Olivier Langlois <olivier@trillion01.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Diffstat (limited to 'libavcodec/motion-test.c')
-rw-r--r--libavcodec/motion-test.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/motion-test.c b/libavcodec/motion-test.c
index 53cfedbe76..38616012ca 100644
--- a/libavcodec/motion-test.c
+++ b/libavcodec/motion-test.c
@@ -91,7 +91,7 @@ static void test_motion(const char *name,
emms_c();
/* speed test */
- ti = av_gettime();
+ ti = av_gettime_relative();
d1 = 0;
for(it=0;it<NB_ITS;it++) {
for(y=0;y<HEIGHT-17;y++) {
@@ -103,7 +103,7 @@ static void test_motion(const char *name,
}
emms_c();
dummy = d1; /* avoid optimization */
- ti = av_gettime() - ti;
+ ti = av_gettime_relative() - ti;
printf(" %0.0f kop/s\n",
(double)NB_ITS * (WIDTH - 16) * (HEIGHT - 16) /