Changeset 445


Ignore:
Timestamp:
Dec 1, 2011, 4:54:47 PM (13 years ago)
Author:
acolaitis
Message:

PYTHON. Fixed playback rate of double pass in movie encoding. Movies should now play with any player with the correct playback rate

Location:
trunk/UTIL/PYTHON
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/UTIL/PYTHON/planetoplot.py

    r444 r445  
    486486    if mrate is not None:
    487487        print "Re-encoding movie.. first pass"
    488         video.first_pass(filename=moviename,quality=mquality)
     488        video.first_pass(filename=moviename,quality=mquality,rate=mrate)
    489489        print "Re-encoding movie.. second pass"
    490         video.second_pass(filename=moviename,quality=mquality)   
     490        video.second_pass(filename=moviename,quality=mquality,rate=mrate)   
    491491
    492492    ###############
  • trunk/UTIL/PYTHON/videosink.py

    r444 r445  
    2222            self.p.stdin.write(image.tostring())
    2323
    24     def first_pass(self,filename="output",quality=False) :
     24    def first_pass(self,filename="output",quality=False,rate=10) :
    2525
    2626
     
    3131                     '-of', 'rawvideo',
    3232                     '-nosound',
     33                     '-ofps',str(rate),
    3334                     '-ovc', 'x264',
    3435                     '-x264encopts', 'subq=1:frameref=1:bitrate='+bitrate+':bframes=1:pass=1',
     
    3839             subprocess.call(cmdstring,shell=False)
    3940
    40     def second_pass(self,filename="output",quality=False) :
     41    def second_pass(self,filename="output",quality=False,rate=10) :
    4142             bitrate="7200"
    4243             if quality:bitrate="50000"
     
    4546                     '-of', 'rawvideo',
    4647                     '-nosound',
     48                     '-ofps',str(rate),
    4749                     '-ovc', 'x264',
    4850                     '-x264encopts', 'subq=6:frameref=5:bitrate='+bitrate+':me=umh:partitions=all:bframes=1:me_range=16:cabac:weightb:deblock:pass=2',
Note: See TracChangeset for help on using the changeset viewer.