[longomatch] Fix frame stepping bug when getting a wrong accurate value
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [longomatch] Fix frame stepping bug when getting a wrong accurate value
- Date: Mon, 14 Sep 2009 22:58:56 +0000 (UTC)
commit 69b14986953f4259aac0777d6f11590700c6fb21
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Mon Sep 14 17:00:34 2009 +0200
Fix frame stepping bug when getting a wrong accurate value
libcesarplayer/src/bacon-video-widget-gst-0.10.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/libcesarplayer/src/bacon-video-widget-gst-0.10.c b/libcesarplayer/src/bacon-video-widget-gst-0.10.c
index b91a6c6..bfa5c04 100644
--- a/libcesarplayer/src/bacon-video-widget-gst-0.10.c
+++ b/libcesarplayer/src/bacon-video-widget-gst-0.10.c
@@ -3237,6 +3237,8 @@ bacon_video_widget_seek_to_next_frame (BaconVideoWidget *bvw, gfloat rate, gbool
fps = (bvw->priv->video_fps_n + bvw->priv->video_fps_d/2) /
bvw->priv->video_fps_d;
pos = bacon_video_widget_get_accurate_current_time(bvw);
+ if (pos==0)
+ return FALSE;
final_pos = pos*GST_MSECOND + 1*GST_SECOND/fps;
/*#ifdef WIN32
@@ -3283,6 +3285,8 @@ gboolean bacon_video_widget_seek_to_previous_frame (BaconVideoWidget *bvw,gfloa
pos = bacon_video_widget_get_accurate_current_time(bvw);
final_pos = pos*GST_MSECOND - 1*GST_SECOND/fps;
+ if (pos==0)
+ return FALSE;
/*#ifdef WIN32
bacon_video_widget_play(bvw);
#endif
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]