[longomatch] Emit tick event when framestepping to update the timescale
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Emit tick event when framestepping to update the timescale
- Date: Wed, 29 Sep 2010 20:45:16 +0000 (UTC)
commit 44335beda44584448fe634f751058d147a698fb6
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Tue Sep 21 12:26:45 2010 +0200
Emit tick event when framestepping to update the timescale
CesarPlayer/gtk-gui/gui.stetic | 2 +-
LongoMatch/gtk-gui/gui.stetic | 4 ++--
libcesarplayer/src/bacon-video-widget-gst-0.10.c | 10 ++++++++--
3 files changed, 11 insertions(+), 5 deletions(-)
---
diff --git a/CesarPlayer/gtk-gui/gui.stetic b/CesarPlayer/gtk-gui/gui.stetic
index 1421d4b..f78e4fb 100644
--- a/CesarPlayer/gtk-gui/gui.stetic
+++ b/CesarPlayer/gtk-gui/gui.stetic
@@ -5,7 +5,7 @@
<target-gtk-version>2.12</target-gtk-version>
</configuration>
<import>
- <widget-library name="../bin/Release/CesarPlayer.dll" internal="true" />
+ <widget-library name="../a.dll" internal="true" />
</import>
<widget class="Gtk.Window" id="LongoMatch.Gui.VolumeWindow" design-size="31 204">
<property name="MemberName" />
diff --git a/LongoMatch/gtk-gui/gui.stetic b/LongoMatch/gtk-gui/gui.stetic
index 2fe008e..8a3f0f0 100644
--- a/LongoMatch/gtk-gui/gui.stetic
+++ b/LongoMatch/gtk-gui/gui.stetic
@@ -5,8 +5,8 @@
<target-gtk-version>2.12</target-gtk-version>
</configuration>
<import>
- <widget-library name="../../CesarPlayer/bin/Release/CesarPlayer.dll" />
- <widget-library name="../bin/Release/LongoMatch.exe" internal="true" />
+ <widget-library name="../../CesarPlayer/a.dll" />
+ <widget-library name="../bin/Debug/LongoMatch.exe" internal="true" />
</import>
<icon-factory>
<icon-set id="longomatch">
diff --git a/libcesarplayer/src/bacon-video-widget-gst-0.10.c b/libcesarplayer/src/bacon-video-widget-gst-0.10.c
index 452c76f..199ec0c 100644
--- a/libcesarplayer/src/bacon-video-widget-gst-0.10.c
+++ b/libcesarplayer/src/bacon-video-widget-gst-0.10.c
@@ -1715,7 +1715,7 @@ got_time_tick (GstElement * play, gint64 time_nanos, BaconVideoWidget * bvw)
GST_INFO ("%" GST_TIME_FORMAT ",%" GST_TIME_FORMAT " %s",
GST_TIME_ARGS (bvw->priv->current_time),
GST_TIME_ARGS (bvw->priv->stream_length),
- (seekable) ? "TRUE" : "FALSE");
+ (seekable) ? "TRUE" : "FALSE");
*/
g_signal_emit (bvw, bvw_signals[SIGNAL_TICK], 0,
@@ -3238,6 +3238,7 @@ gboolean
bacon_video_widget_seek_to_next_frame (BaconVideoWidget * bvw, gfloat rate,
gboolean in_segment)
{
+ gint64 pos = -1;
gboolean ret;
g_return_val_if_fail (bvw != NULL, FALSE);
@@ -3247,6 +3248,9 @@ bacon_video_widget_seek_to_next_frame (BaconVideoWidget * bvw, gfloat rate,
gst_element_send_event(bvw->priv->play,
gst_event_new_step (GST_FORMAT_BUFFERS, 1, 1.0, TRUE, FALSE));
+ pos = bacon_video_widget_get_accurate_current_time (bvw);
+ got_time_tick (GST_ELEMENT (bvw->priv->play), pos * GST_MSECOND, bvw);
+
gst_x_overlay_expose (bvw->priv->xoverlay);
return ret;
@@ -3275,7 +3279,7 @@ bacon_video_widget_seek_to_previous_frame (BaconVideoWidget * bvw,
if (pos == 0)
return FALSE;
-
+
if (bacon_video_widget_is_playing (bvw))
bacon_video_widget_pause (bvw);
@@ -3287,6 +3291,8 @@ bacon_video_widget_seek_to_previous_frame (BaconVideoWidget * bvw,
final_pos, GST_SEEK_TYPE_NONE, GST_CLOCK_TIME_NONE);
gst_x_overlay_expose (bvw->priv->xoverlay);
+ got_time_tick (GST_ELEMENT (bvw->priv->play), pos * GST_MSECOND, bvw);
+
return ret;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]