OSDN Git Service

implement new demuxer encoding test.
authorgn64_jp <gn64_jp@4e526526-5e11-4fc0-8910-f8fd03428081>
Fri, 11 Feb 2011 13:34:18 +0000 (13:34 +0000)
committergn64_jp <gn64_jp@4e526526-5e11-4fc0-8910-f8fd03428081>
Fri, 11 Feb 2011 13:34:18 +0000 (13:34 +0000)
git-svn-id: svn+ssh://svn.sourceforge.jp/svnroot/rec10@830 4e526526-5e11-4fc0-8910-f8fd03428081

rec10/trunk/src/ts2x264.py

index 59ff700..3038671 100644 (file)
@@ -75,11 +75,30 @@ def ts2x264(pin, pout, opts):#sizeは"HD"か"SD"
             encodeMencoderSar_lavf(pin, pout,size,is24fps,quality,crf,deinterlace)\r
         except Exception, inst:\r
             recdblist.addCommonlogEX("Error in X", "ts2x264(ts2x264.py)", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+    elif re.search("Y",opts):\r
+        try:\r
+            encodeMencoderSar_lavf(pin, pout,size,is24fps,quality,crf,deinterlace)\r
+            if os.path.exists(pout):\r
+                if not os.path.getsize(pout)>1*1000:\r
+                    recdblist.addCommonlogEX("Warning", "Old mencoder option used.", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+                    try:\r
+                        encodeMencoderSar(pin, pout,size,is24fps,quality,crf,deinterlace)\r
+                    except Exception, inst:\r
+                        recdblist.addCommonlogEX("Error", "ts2x264_mencoder_old(ts2x264.py)", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+            else:\r
+                recdblist.addCommonlogEX("Warning", "Old mencoder option used.", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+                try:\r
+                    encodeMencoderSar(pin, pout,size,is24fps,quality,crf,deinterlace)\r
+                except Exception, inst:\r
+                    recdblist.addCommonlogEX("Error", "ts2x264_mencoder_old(ts2x264.py)", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+        except Exception, inst:\r
+            recdblist.addCommonlogEX("Error", "ts2x264(ts2x264.py)", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
     else:\r
         try:\r
             encodeMencoderSar(pin, pout,size,is24fps,quality,crf,deinterlace)\r
         except Exception, inst:\r
             recdblist.addCommonlogEX("Error", "ts2x264(ts2x264.py)", str(type(inst)), str(inst)+traceback.format_exc(),log_level=200)\r
+\r
 def encodeMencoderSar(pin,pout,size,is24fps,quality,crf,deinterlace=1):\r
     mencoder=configreader.getConfPath("mencoder")\r
     tee=configreader.getConfPath("tee")\r