You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@guacamole.apache.org by mj...@apache.org on 2016/10/03 18:39:45 UTC

[1/2] incubator-guacamole-server git commit: GUACAMOLE-110: Fix guacenc framerate rounding affecting video length

Repository: incubator-guacamole-server
Updated Branches:
  refs/heads/master 701e44a0c -> 3c459100d


GUACAMOLE-110: Fix guacenc framerate rounding affecting video length


Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/3a3de3e8
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/3a3de3e8
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/3a3de3e8

Branch: refs/heads/master
Commit: 3a3de3e87d74c3354eb00883e981349210d08d67
Parents: 701e44a
Author: Roman <ro...@google.com>
Authored: Mon Oct 3 11:51:24 2016 -0400
Committer: Roman <ro...@google.com>
Committed: Mon Oct 3 11:51:24 2016 -0400

----------------------------------------------------------------------
 src/guacenc/video.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/blob/3a3de3e8/src/guacenc/video.c
----------------------------------------------------------------------
diff --git a/src/guacenc/video.c b/src/guacenc/video.c
index e0624a2..874dd16 100644
--- a/src/guacenc/video.c
+++ b/src/guacenc/video.c
@@ -209,6 +209,8 @@ static int guacenc_video_flush_frame(guacenc_video* video) {
 int guacenc_video_advance_timeline(guacenc_video* video,
         guac_timestamp timestamp) {
 
+    guac_timestamp next_timestamp = timestamp;
+
     /* Flush frames as necessary if previously updated */
     if (video->last_timestamp != 0) {
 
@@ -220,6 +222,10 @@ int guacenc_video_advance_timeline(guacenc_video* video,
         if (elapsed == 0)
             return 0;
 
+        /* Use frame time as last_timestamp */
+        next_timestamp = video->last_timestamp
+                        + elapsed * 1000 / GUACENC_VIDEO_FRAMERATE;
+
         /* Flush frames to bring timeline in sync, duplicating if necessary */
         do {
             guacenc_video_flush_frame(video);
@@ -228,7 +234,7 @@ int guacenc_video_advance_timeline(guacenc_video* video,
     }
 
     /* Update timestamp */
-    video->last_timestamp = timestamp;
+    video->last_timestamp = next_timestamp;
     return 0;
 
 }


[2/2] incubator-guacamole-server git commit: GUACAMOLE-110: Merge fix for timestamp rounding bug in guacenc.

Posted by mj...@apache.org.
GUACAMOLE-110: Merge fix for timestamp rounding bug in guacenc.


Project: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/commit/3c459100
Tree: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/tree/3c459100
Diff: http://git-wip-us.apache.org/repos/asf/incubator-guacamole-server/diff/3c459100

Branch: refs/heads/master
Commit: 3c459100d7d957a850fc4f6e92a4da417bc3be4a
Parents: 701e44a 3a3de3e
Author: Michael Jumper <mj...@apache.org>
Authored: Mon Oct 3 11:38:41 2016 -0700
Committer: Michael Jumper <mj...@apache.org>
Committed: Mon Oct 3 11:38:41 2016 -0700

----------------------------------------------------------------------
 src/guacenc/video.c | 8 +++++++-
 1 file changed, 7 insertions(+), 1 deletion(-)
----------------------------------------------------------------------