[xiph-commits] r16290 - in trunk/ffmpeg2theora: . src

j at svn.xiph.org j at svn.xiph.org
Thu Jul 16 01:42:53 PDT 2009


Author: j
Date: 2009-07-16 01:42:53 -0700 (Thu, 16 Jul 2009)
New Revision: 16290

Modified:
   trunk/ffmpeg2theora/ChangeLog
   trunk/ffmpeg2theora/get_ffmpeg_svn.sh
   trunk/ffmpeg2theora/src/avinfo.c
   trunk/ffmpeg2theora/src/theorautils.c
Log:
cleanup

Modified: trunk/ffmpeg2theora/ChangeLog
===================================================================
--- trunk/ffmpeg2theora/ChangeLog	2009-07-15 21:39:59 UTC (rev 16289)
+++ trunk/ffmpeg2theora/ChangeLog	2009-07-16 08:42:53 UTC (rev 16290)
@@ -1,6 +1,9 @@
 svn
     - fix input from codecs where width/height is not encoded width/height
     - fix a/v sync issues with some mov/mp4 files with strange framerates
+    - add new option --info outputs json info about source
+    - frontend mode outputs one json dict per line now
+    - update to ffmpeg trunk
 
 0.24 2009-03-12
     - fix to make --max_size --no_upscaling work

Modified: trunk/ffmpeg2theora/get_ffmpeg_svn.sh
===================================================================
--- trunk/ffmpeg2theora/get_ffmpeg_svn.sh	2009-07-15 21:39:59 UTC (rev 16289)
+++ trunk/ffmpeg2theora/get_ffmpeg_svn.sh	2009-07-16 08:42:53 UTC (rev 16290)
@@ -1,8 +1,7 @@
 #!/bin/sh
 
 #optional, if you have those libs installed:
-#apt-get install libamrnb-dev libamrwb-dev
-#extra=" --enable-libamr_nb --enable-libamr_wb --enable-nonfree"
+#extra=" --enable-libopencore-amrnb --enable-libopencore-amrwb"
 
 #apt-get install liba52-dev libfaad-dev libgsm1-dev
 #extra=" --enable-libfaad --enable-libgsm"

Modified: trunk/ffmpeg2theora/src/avinfo.c
===================================================================
--- trunk/ffmpeg2theora/src/avinfo.c	2009-07-15 21:39:59 UTC (rev 16289)
+++ trunk/ffmpeg2theora/src/avinfo.c	2009-07-16 08:42:53 UTC (rev 16290)
@@ -74,8 +74,8 @@
     if (file) {
         fseeko(file, 0, SEEK_END);
         size = ftello(file);
+        fclose(file);
     }
-    fclose(file);
     return size;
 }
 
@@ -391,7 +391,8 @@
 #else
     sprintf(hash,"%016qx", gen_oshash(filename));
 #endif
-    json_add_key_value(output, "oshash", (void *)hash, JSON_STRING, 0, indent);
+    if (strcmp(hash,"0000000000000000") > 0)
+        json_add_key_value(output, "oshash", (void *)hash, JSON_STRING, 0, indent);
 }
 
 

Modified: trunk/ffmpeg2theora/src/theorautils.c
===================================================================
--- trunk/ffmpeg2theora/src/theorautils.c	2009-07-15 21:39:59 UTC (rev 16289)
+++ trunk/ffmpeg2theora/src/theorautils.c	2009-07-16 08:42:53 UTC (rev 16290)
@@ -282,7 +282,7 @@
 
         vorbis_comment_init (&info->vc);
         vorbis_comment_add_tag (&info->vc, "ENCODER",PACKAGE_STRING);
-        if (strcmp(info->oshash,"0") > 0) {
+        if (strcmp(info->oshash,"0000000000000000") > 0) {
             vorbis_comment_add_tag (&info->vc, "SOURCE_OSHASH", info->oshash);
         }
         /* set up the analysis state and auxiliary encoding storage */
@@ -648,13 +648,13 @@
         );
         fflush (info->frontend);
     }
-    else {
+    else if (timebase > 0 ) {
         if (!remaining) {
             remaining = time(NULL) - info->start_time;
             remaining_seconds = (long) remaining % 60;
             remaining_minutes = ((long) remaining / 60) % 60;
             remaining_hours = (long) remaining / 3600;
-            fprintf (stderr,"\r      %d:%02d:%02d.%02d audio: %dkbps video: %dkbps, time elapsed: %02d:%02d:%02d                            ",
+            fprintf (stderr,"\r      %d:%02d:%02d.%02d audio: %dkbps video: %dkbps, time elapsed: %02d:%02d:%02d ",
                 hours, minutes, seconds, hundredths,
                 info->akbps, info->vkbps,
                 remaining_hours, remaining_minutes, remaining_seconds



More information about the commits mailing list