You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
(12) |
Jul
(42) |
Aug
(106) |
Sep
(2) |
Oct
|
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
|
Feb
|
Mar
(17) |
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2006 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(2) |
Aug
(2) |
Sep
|
Oct
(1) |
Nov
(2) |
Dec
(1) |
2007 |
Jan
(3) |
Feb
(3) |
Mar
|
Apr
(2) |
May
(10) |
Jun
(9) |
Jul
(20) |
Aug
(34) |
Sep
(29) |
Oct
(10) |
Nov
(9) |
Dec
(6) |
2008 |
Jan
(8) |
Feb
(15) |
Mar
(34) |
Apr
(20) |
May
(8) |
Jun
(16) |
Jul
(32) |
Aug
(14) |
Sep
(24) |
Oct
(14) |
Nov
(33) |
Dec
(69) |
2009 |
Jan
(123) |
Feb
(31) |
Mar
(54) |
Apr
(49) |
May
(116) |
Jun
(95) |
Jul
(68) |
Aug
(21) |
Sep
(20) |
Oct
(34) |
Nov
(9) |
Dec
(13) |
2010 |
Jan
(5) |
Feb
(6) |
Mar
(28) |
Apr
(47) |
May
(73) |
Jun
(74) |
Jul
(38) |
Aug
(45) |
Sep
(32) |
Oct
(1) |
Nov
|
Dec
|
2013 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
(1) |
Oct
(2) |
Nov
|
Dec
|
2015 |
Jan
(1) |
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: News: <asf...@ca...> - 2007-02-26 07:45:15
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"text/html; charset=3Diso-8859-1"> <META content=3D"MSHTML 6.00.2900.2912" name=3D"GENERATOR"> </HEAD> <BODY> <DIV align=3Dleft><FONT face=3DArial size=3D2><B><I>GDKI IS THE TRUE SUPERNOVA</I></B></FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2>GOLDMARK INDUSTRIES - PUTTING HABANA BLUES ON THE MAP!</FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>Ticker: <B>GDKI</B> </FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>Trade: <B>February 26 Monday, 2007</B> </FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>GDKI Price: $0.13 </FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2>2007-02-20 05:39 ET - News Release</FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2><U>LOS ANGELES & NEW YORK -- (BizWire)</U></FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>Habana Blues Continues to Generate International and Domestic Buzz; the Award Winning Film to Be Featured at the Exclusive Latin American Film Festival Champaign, Illinois -- February 23rd to March 1st</FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2><U><B>WATCH GDKI SHOOT THROUGH THE SKY MONDAY!</U></B></FONT></DIV></BODY></HTML> |
From: Annalisa P. <sam...@sb...> - 2007-02-02 17:57:36
|
Hi, Via_qra $1, 80 Ciqlis $3, 00 Levvtra $3, 35 http://www.progenyid.%com ( Important Remove "%" ) -- sunlight. Wonder how the Durmstrang students are getting back, said Ron. D you reckon they can steer that ship without Karkaroff? |
From: Joshua T. <ju...@ab...> - 2007-01-27 10:20:39
|
Hi, Vixxagra $3, 35 Vaxxlium $1, 20 Cixxalis $3, 75 Xaxxnax $1, 45 Amxxbien $2, 90 http://www.44rx.*com Remove "*" to make the link working! -- Sirius managing to get back without being caught was something. He couldnt deny either that the idea that Sirius was much nearer was reassuring; at least he wouldnt have to wait so long for a response |
From: Ramona <kru...@se...> - 2007-01-26 10:08:54
|
hi (download), start playing US players are welcome most fair casino you don't know internet at all if you don't know this casino http://0wworld.org |
From: control <anm...@ch...> - 2006-11-29 07:35:29
|
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> <HTML><HEAD> <META http-equiv=3DContent-Type content=3D"text/html; charset=3Diso-8859-1"> <META content=3D"MSHTML 6.00.2900.2912" name=3D"GENERATOR"> </HEAD> <BODY> <DIV align=3Dleft><FONT face=3DArial size=3D2><b>Company:</b> Bralorne Mining Company (<b>BLNM.OB</b>) is China Telcom & China Netcom's</FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>Primary VOIP Network Agent.</FONT></DIV> <DIV align=3Dleft><FONT face=3DArial size=3D2>Huge VOIP Contract Signed With Beijing Oriental Inc.</FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D3><b>BLNM.OB Price Climbs 81% and Volume is up 10000% In Just Three Days Trading! It's not to late to get in!</b></FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2>BLNM, via Beijing QTC, lands another huge contract with Beijing Oriental Inc. Beijing Oriental Inc. is China's leading exhibition and conference holding company. Beijing QTC (BLNM) agrees to provide Beijing Oriental with its 3GenisIP Integrated Access System. This provides them with local, and long distance calling, international numbers and a broadband connection in a single solution.</FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2><b>BLNM.OB</b> is now Authorized in many cities and provinces in China by the two giant telecoms, China Netcom and China Telecom, as the primary authorized VoIP network agent.</FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2>This company keeps expanding. They are landing one deal after another. And they are fast become one of the big players in the worlds fastest growing telcom market. This news will make BLNM make huge jumps in the market tomorrow. BLNM has already climbed 82% since last week when these series of news releases began.</FONT></DIV><BR> <DIV align=3Dleft><FONT face=3DArial size=3D2><b><u>Stay ahead of the growth, get on board with BLNM Wed morning, first thing.</u></b></FONT></DIV> </BODY> </HTML> |
From: Chelsea S. <Che...@ea...> - 2006-11-11 23:50:31
|
"good god! what is the matter?" cried he, with more feeling than politeness; then recollecting<BR>and i do not think it of light importance that he should have attentive and conciliatory manner towards<BR>"i dare say she will; she has got over the most trying age."<BR>an example as hers, he might become a very agreeable companion. but on the following morning,<BR>"mr. collins," said she, "speaks highly both of lady catherine and her daughter; but from some<BR>elizabeth; dwelling emphatically on every expression of the latter which, in her ladyship's<BR>elizabeth felt that they had entirely misunderstood his character, but said nothing.<BR>before she set off for the north, received at first an absolute negative. but jane and elizabeth, who<BR>"in such cases, a woman has not often much beauty to think of."<BR>elizabeth's spirits were so high on this occasion, that though she did not often speak<BR>"it must have been his sister's doing. they were certainly no friends to his acquaintance with me,<BR>"i never saw anyone so shocked. he could not speak a word for full ten minutes. my mother was<BR>either with pleasure or pain. i am glad of one thing, that he comes alone; because we shall see the less<BR>"what is mr. darcy to me, pray, that i should be afraid of him? i am sure we owe him no such<BR>"removed!" cried bingley. "it must not be thought of. my sister, i am sure, will not hear of her<BR>as it happened that elizabeth had much rather not, she endeavoured in her answer to put an end<BR>"that is not an unnatural surmise," said fitzwilliam, "but it is a lessening of the honour of my<BR>accusations might have been suppressed, had i, with greater policy, concealed my struggles, and<BR>about in her chair, get up, sit down again, wonder, and bless herself.<BR> |
From: Kathleen H. <jua...@1-...> - 2006-08-28 16:36:53
|
Hello Investor/Stock owner, We are a stock promotion company and we can promote any kind of stocks. We are in search of serious partners with whom we can make bussines together.That proposal is for you if you are: Stock owner You own an underrated stock and the market price of your stock is from 0.001 to 1$ We can increase the price of your stock and we can increase average day trading volume. We can increase price up to 200-250% in 2-3 weeks and also we can increase volume by 10 times each trading day. You don't have to pay anything in advance. First we increase the price and the volume, then you pay. We will prove it for 1 day for free. Payment: Our price for that is 6% from the daily volume. We count it by the following formula: (prev. close price + today open price)/2 * daily volume. WE GUARANTY LONG TERM GROWTH WE PROMOTE THE COMPANY AND IT'S BUSINESS Investor You want to invest some money and you want to make big profits? Our company can help you in that. We know exactly which stocks will increase in price and wich will be falling down. We will give you advices and according to that advices you will make decisions. We will prove it for 1 day for free. We will tell you the price of the stock in advance and you will see that our stock promotion group works hard in order to make your investment portfolio grow. Payment: Our price for that is 25-30% from your income. Before the deal you are telling us on which ammount of money you are buying/selling stock and we are counting the future profit and take 30% from that profit. You don't have to pay anything in advance, you pay only then you receive your profit. If you are interested in our proposal please write me back to the following email: J O B (at) thesecpay4. i n f o |
From: Wagner <bri...@ad...> - 2006-08-22 08:56:06
|
<HTML><HEAD> <META http-equiv=Content-Type content="text/html; charset=iso-8859-1"> </HEAD> <BODY> <DIV><img src="cid:L7J628LP02EQ4QJCI5TF"></DIV> <DIV>hidden from thee.' 'That may be well. We of the Ludhiana Sikhs' - he'So it comes with all faiths.' 'Thinkest thou? The books of myBodhisat in meditation, brushed through the turnstiles. Kim followedwas but a little wooden cubicle partitioned off from theHast thou not told me that some day a Red Bull will come out of ataking on new grooms; swearing, shouting, arguing, and chaffering inshould have been better off than his father. Nine hundred first-class</DIV> <DIV>baleen assiduity absent bernini</DIV> </BODY></HTML> |
From: Content-filter at mg5.xecu.n. <pos...@mg...> - 2006-07-24 19:45:52
|
Your message to: qu...@xe... has triggered our SpamAssassin SPAM filte= rs=20 and has been rejected. The email you sent with the following subject has=20 NOT BEEN DELIVERED: Subject: Start earning the salary you deserve by obtaining the appropriate = University Degree. Our company uses a set of email filters to help block the delivery of unsolicited commercial email, otherwise known as SPAM. For more information on SPAM, please visit http://spam.abuse.net. If you believe that you have received this message in error, please accept our sincere apologies. We ask that you please forward this email message to su...@xe.... When we receive your message, we will investigate the situation and add you to our whitelist of approved senders should that be warranted. Please note that this is a manual process and is only done during business hours. The report below will help you determine why your message was flagged as SPAM. If you continue to have problems, please contact Xecunet Support at 877-XECUNET. Thank you very much, Postmaster SpamAssassin report: Spam detection software, running on the system "mg5.xecu.net", has identified this incoming email as possible spam. The original message has been attached to this so you can view it (if it isn't spam) or block similar future email. If you have any questions, see su...@xe... for details. Content preview: Want the degree but can=92t find the time? WHAT A GREAT IDEA! We provide a concept that will allow anyone with sufficient work experience to obtain a fully verifiable University Degree. Bachelors, Masters or even a Doctorate. Think of it, within four to six weeks, you too could be a college graduate. Many people share the same frustration, they are all doing the work of the person that has the degree and the person that has the degree is getting all the money. Don=92t you think that it is time you were paid fair compensation for the level of work you are already doing? This is your chance to finally make the right move and receive your due benefits. If you are like most people, you are more than qualified with your experience, but are lacking that prestigious piece of paper known as a diploma that is o ften the passport to success. CALL US TODAY AND GIVE YOUR WORK EXPERIENCE THE CHANCE TO EARN YOU THE HIGHER COMPENSATION YOU DESERVE! CALL NOW: 1-815-828-2222 [...]=20 Content analysis details: (6.6 points, 5.0 required) pts rule name description ---- ---------------------- -----------------------------------------------= --- 0.0 HTML_MESSAGE BODY: HTML included in message 0.1 HTML_FONT_BIG BODY: HTML has a big font 0.5 HTML_20_30 BODY: Message is 20% to 30% HTML 0.1 MIME_HTML_ONLY BODY: Message only has text/html MIME parts 0.1 HTML_FONTCOLOR_RED BODY: HTML font color is red 2.3 RCVD_IN_XBL RBL: Received via a relay in Spamhaus XBL [213.17.248.82 listed in sbl-xbl.spamhaus.org] 1.8 INVALID_MSGID Message-Id is not valid, according to RFC 2822 1.7 HTML_MIME_NO_HTML_TAG HTML-only message, but there is no HTML tag |
From: Tom C. <te...@us...> - 2004-03-18 01:39:59
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30742/cli Modified Files: cli.py Log Message: Added remaining encoding functions (mp3/ogg audio, divx/xvid/mpeg2 video, avi/ogm container) Added ability to detect PAL/NTSC/NTSCPROG format Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** cli.py 7 Mar 2004 23:34:28 -0000 1.7 --- cli.py 18 Mar 2004 01:30:26 -0000 1.8 *************** *** 151,156 **** print "(m) Mplayer path: \t%s" % (self.config['mplayer']) print "(e) Mencoder path: \t%s" % (self.config['mencoder']) ! print "(t) Transcode path: \t%s" % (self.config['transcode']) ! print "(o) Ogmmerge path: \t%s" % (self.config['ogmmerge']) print "(p) Output directory: \t%s" % (self.config['outputdir']) print "(d) DVD device: \t%s" % (self.config['dvd_device']) --- 151,156 ---- print "(m) Mplayer path: \t%s" % (self.config['mplayer']) print "(e) Mencoder path: \t%s" % (self.config['mencoder']) ! print "(o) Oggenc path: \t%s" % (self.config['oggenc']) ! print "(g) Ogmmerge path: \t%s" % (self.config['ogmmerge']) print "(p) Output directory: \t%s" % (self.config['outputdir']) print "(d) DVD device: \t%s" % (self.config['dvd_device']) *************** *** 178,186 **** 'param' : 'mencoder', 'object' : self.config } ! self.choices['t'] = { 'question' : 'Enter new path for transcode: ', 'options' : '^[\w\/]+$', ! 'param' : 'transcode', 'object' : self.config } ! self.choices['o'] = { 'question' : 'Enter new path for ogmmerge: ', 'options' : '^[\w\/]+$', 'param' : 'ogmmerge', --- 178,186 ---- 'param' : 'mencoder', 'object' : self.config } ! self.choices['o'] = { 'question' : 'Enter new path for oggenc: ', 'options' : '^[\w\/]+$', ! 'param' : 'oggenc', 'object' : self.config } ! self.choices['g'] = { 'question' : 'Enter new path for ogmmerge: ', 'options' : '^[\w\/]+$', 'param' : 'ogmmerge', *************** *** 228,232 **** end = "mpeg" elif self.config['audiocodec'] == 'ogg': ! end = "ogg" else: end = "avi" --- 228,232 ---- end = "mpeg" elif self.config['audiocodec'] == 'ogg': ! end = "ogm" else: end = "avi" *************** *** 413,421 **** slashn = "" # Finish off last pass' line ! #if passtype != "audio": ! # sys.stdout.write(" 100% ") ! # for i in range(self.n): ! # sys.stdout.write("=") ! # sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") sys.stdout.flush() --- 413,421 ---- slashn = "" # Finish off last pass' line ! if passtype != "audio": ! sys.stdout.write(" 100% ") ! for i in range(self.n): ! sys.stdout.write("=") ! sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") sys.stdout.flush() *************** *** 438,443 **** if int(perc) <= 9: sys.stdout.write(" " + str(int(perc)) + "% |") ! else: sys.stdout.write(" " + str(int(perc)) + "% |") # Rewrite bar sys.stdout.write("=" * n) --- 438,445 ---- if int(perc) <= 9: sys.stdout.write(" " + str(int(perc)) + "% |") ! elif int(perc) < 100: sys.stdout.write(" " + str(int(perc)) + "% |") + else: + sys.stdout.write(" " + str(int(perc)) + "% |") # Rewrite bar sys.stdout.write("=" * n) |
From: Tom C. <te...@us...> - 2004-03-18 01:39:58
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30742 Modified Files: base.py Log Message: Added remaining encoding functions (mp3/ogg audio, divx/xvid/mpeg2 video, avi/ogm container) Added ability to detect PAL/NTSC/NTSCPROG format Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** base.py 7 Mar 2004 23:36:03 -0000 1.8 --- base.py 18 Mar 2004 01:30:26 -0000 1.9 *************** *** 67,70 **** --- 67,72 ---- 'oggenc': ['paths', self.findProgram("oggenc")], \ 'ogmmerge': ['paths', self.findProgram("ogmmerge")], \ + 'ffmpeg': ['paths', self.findProgram("ffmpeg")], \ + 'tcmplex': ['paths', self.findProgram("tcmplex")], \ 'outputdir': ['paths', os.path.expanduser("~")], \ 'dvd_device': ['paths', os.path.join("/", "dev", "dvd")], \ *************** *** 176,180 **** if self.config['logging'] == 'Off': return ! elif self.config['logging'] == 'Normal' and level == 'Normal': if not os.path.isfile(self.config['logfile']): create_log = open(self.config['logfile'], 'w') --- 178,182 ---- if self.config['logging'] == 'Off': return ! elif self.config['logging'] in ['Normal', 'Debug'] and level == 'Normal': if not os.path.isfile(self.config['logfile']): create_log = open(self.config['logfile'], 'w') *************** *** 182,189 **** create_log.close() log = open(self.config['logfile'], 'a') ! log.write(entry + "\n") log.close() # The following functions are threaded, but are processed in the order # in which they appear here. - biggs --- 184,208 ---- create_log.close() log = open(self.config['logfile'], 'a') ! log.write("\n\n\n" + entry + "\n") ! log.close() ! elif self.config['logging'] == 'Debug' and level == 'Debug': ! if not os.path.isfile(self.config['logfile']): ! create_log = open(self.config['logfile'], 'w') ! create_log.write("QuickRip log file\n\n") ! create_log.close() ! #entry = re.sub('\n', '', entry) ! log = open(self.config['logfile'], 'a') ! log.write(entry) log.close() + def cleanCWD(self): + """Clean out the current working directory""" + for file in ['/frameno.avi', '/audio.wav', '/audio.ogg', '/audio.mpa', \ + '/video.mpv', '/video.mpg', '/video.avi']: + os.popen("".join(["rm ", self.config['outputdir'], file, \ + " 2>/dev/null"])) + + # The following functions are threaded, but are processed in the order # in which they appear here. - biggs *************** *** 206,209 **** --- 225,229 ---- for t in self.raw_dvd.tracks: title = {} + title['format'] = 'pal' title['rip'] = 'no' title['id'] = t['trackno'] *************** *** 229,233 **** self.titles.append(title) self.notify_dispTitle(title) - self.notify_finishScanning() --- 249,252 ---- *************** *** 255,271 **** for title in self.torip: # Clean up output directory ! os.popen("".join(["rm ", self.config['outputdir'], "/frameno.avi", \ ! " 2>/dev/null"])) ! os.popen("".join(["rm ", self.config['outputdir'], "/audio.wav", \ ! " 2>/dev/null"])) ! os.popen("".join(["rm ", self.config['outputdir'], "/audio.ogg", \ ! " 2>/dev/null"])) ! os.popen("".join(["rm ", self.config['outputdir'], "/video.avi", \ ! " 2>/dev/null"])) self.notify_newTitle(title['name'], i, self.numrips, title['vbr']) i = i + 1 ! # Look for cropping if not title.has_key('crop'): sstep = int(title['length']) / 31 --- 274,283 ---- for title in self.torip: # Clean up output directory ! self.cleanCWD() self.notify_newTitle(title['name'], i, self.numrips, title['vbr']) i = i + 1 ! # Look for cropping and format if not title.has_key('crop'): sstep = int(title['length']) / 31 *************** *** 282,286 **** # Rip title if self.config['videocodec'] == 'mpeg2': ! self.ripSVCD(title) while self.state == 'ripping': sleep(1) --- 294,310 ---- # Rip title if self.config['videocodec'] == 'mpeg2': ! self.ripWavAudio(title) ! while self.state == 'ripping': ! sleep(1) ! self.ffmpegEnc(title) ! while self.state == 'ripping': ! sleep(1) ! self.ripVideo(title) ! while self.state == 'ripping': ! sleep(1) ! self.extractRawVideo(title) ! while self.state == 'ripping': ! sleep(1) ! self.tcmplex(title) while self.state == 'ripping': sleep(1) *************** *** 292,301 **** while self.state == 'ripping': sleep(1) ! #self.ripVideo(title) ! #while self.state == 'ripping': ! # sleep(1) ! #self.ogmMerge(title) ! #while self.state == 'ripping': ! # sleep(1) else: self.ripMp3Audio(title) --- 316,325 ---- while self.state == 'ripping': sleep(1) ! self.ripVideo(title) ! while self.state == 'ripping': ! sleep(1) ! self.ogmMerge(title) ! while self.state == 'ripping': ! sleep(1) else: self.ripMp3Audio(title) *************** *** 305,318 **** while self.state == 'ripping': sleep(1) ! self.notify_finishRipping() def cropDetect(self, lines, data): re_crop = re.compile('.*-vop crop=(\d*:\d*:\d*:\d*).*') crop_options = {} common_crop = "" cc_hits = 0 title = data for line in lines: if re_crop.search(line): --- 329,348 ---- while self.state == 'ripping': sleep(1) ! ! # Clean up and notify of end of process ! self.cleanCWD() self.notify_finishRipping() def cropDetect(self, lines, data): + """Detect cropping and video format""" re_crop = re.compile('.*-vop crop=(\d*:\d*:\d*:\d*).*') + re_ntscprog = re.compile('24fps progressive NTSC content detected') + re_pal = re.compile('25.000 fps') crop_options = {} common_crop = "" cc_hits = 0 title = data + found_format = 0 for line in lines: if re_crop.search(line): *************** *** 324,342 **** except: crop_options[crop] = 1 title['crop'] = common_crop - - - def ripSVCD(self, title): - """Rip a DVD title for an SVCD""" - self.notify_newPass("svcd") - self.state = "ripping" - - # Work out filename - output = os.path.join(self.config['outputdir'], str(title['name'])) - output = ''.join([output, ".mpeg"]) - - ## Assemble basic command - # I tried transcode, but failed to understand it - # I'll look into mencvcd (in mplayer source tarball in mplayer/TOOLS) --- 354,367 ---- except: crop_options[crop] = 1 + # Based on freevo code (www.freevo.org) + if re_ntscprog.search(line): + title['format'] = 'ntscprog' + found_format = 1 + if re_pal.search(line): + title['format'] = 'pal' + found_format = 1 + if not found_format: + title['format'] = 'ntsc' title['crop'] = common_crop *************** *** 346,350 **** self.state = "ripping" # Work out options to send to mplayer ! arguments = ["-dvd", str(title['id']), "-alang", title['alang'], \ "-ao", "pcm", "-vo", "null", "-vc", "dummy", "-aofile", \ os.path.join(self.config['outputdir'], "audio.wav")] --- 371,375 ---- self.state = "ripping" # Work out options to send to mplayer ! arguments = ["-dvd", str(title['id']), "-alang", title['alang'], '-waveheader', \ "-ao", "pcm", "-vo", "null", "-vc", "dummy", "-aofile", \ os.path.join(self.config['outputdir'], "audio.wav")] *************** *** 358,370 **** self.notify_newPass("oggenc") self.state = "ripping" ! # Work out options to send to mplayer arguments = [''.join(["-b", str(title['abr'])]), ''.join(["-o", \ os.path.join(self.config['outputdir'], "audio.ogg")]), \ os.path.join(self.config['outputdir'], "audio.wav")] ! # Run mplayer self.run('oggenc', arguments, self.pipeFinished, self.oggencProgress, \ flushbuffer=100, data=("oggenc",title)) def ripMp3Audio(self, title): """Rip the audio in mp3 format""" --- 383,408 ---- self.notify_newPass("oggenc") self.state = "ripping" ! # Work out options to send to oggenc arguments = [''.join(["-b", str(title['abr'])]), ''.join(["-o", \ os.path.join(self.config['outputdir'], "audio.ogg")]), \ os.path.join(self.config['outputdir'], "audio.wav")] ! # Run oggenc self.run('oggenc', arguments, self.pipeFinished, self.oggencProgress, \ flushbuffer=100, data=("oggenc",title)) + def ffmpegEnc(self, title): + """Encode a wav into an ogg""" + self.notify_newPass("ffmpeg") + self.state = "ripping" + # Work out options to send to ffmpeg + arguments = ['-y', '-i', os.path.join(self.config['outputdir'], "audio.wav"), \ + '-ab', str(title['abr']), '-ar', '44100', '-ac', '2', '-f', 'mp2', \ + os.path.join(self.config['outputdir'], "audio.mpa")] + # Run ffmpeg + self.run('ffmpeg', arguments, self.pipeFinished, self.ffmpegProgress, \ + flushbuffer=100, data=("ffmpeg",title)) + + def ripMp3Audio(self, title): """Rip the audio in mp3 format""" *************** *** 391,396 **** # Work out filename ! output = os.path.join(self.config['outputdir'], str(title['name'])) ! output = ''.join([output, ".avi"]) ## Work out options to send to mencoder --- 429,439 ---- # Work out filename ! if self.config['audiocodec'] == 'ogg': ! output = os.path.join(self.config['outputdir'], 'video.avi') ! elif self.config['videocodec'] == 'mpeg2': ! output = os.path.join(self.config['outputdir'], 'video.mpg') ! else: ! output = os.path.join(self.config['outputdir'], str(title['name'])) ! output = ''.join([output, ".avi"]) ## Work out options to send to mencoder *************** *** 398,408 **** if self.config['pdamode'] == 'On': resolution = "320" else: resolution = "720" - # Audio? - if self.config['audiocodec'] == 'mp3': - oac = "copy" - else: - oac = "null" # Video? if self.config['videocodec'] == 'xvid': --- 441,448 ---- if self.config['pdamode'] == 'On': resolution = "320" + elif self.config['videocodec'] == 'mpeg2': + resolution = "480" else: resolution = "720" # Video? if self.config['videocodec'] == 'xvid': *************** *** 411,414 **** --- 451,459 ---- ovc_opts = "".join(["4mv:me_quality=6:mod_quant:quant_range=1-31/1-31:", \ "bitrate=", str(int(title['vbr']))]) + elif self.config['videocodec'] == 'mpeg2': + ovc = "lavc" + ovc_opts_type = "-lavcopts" + ovc_opts = "".join(["vcodec=mpeg1video:vhq:vrc_minrate=300:vrc_maxrate=2400:", \ + "vbitrate=", str(int(title['vbr']))]) else: ovc = "lavc" *************** *** 416,427 **** ovc_opts = "".join(["vcodec=mpeg4:vhq:vbitrate=", str(int(title['vbr']))]) # Cropping ! vop = "".join(["scale,crop=", title['crop']]) # Deinterlacing? if self.config['deinterlacing'] == 'On': vop = "".join([vop, ",dint"]) # Build it all up ! arguments = ["-dvd", str(title['id']), "-alang", title['alang'], "-oac", oac, \ "-ovc", ovc, ovc_opts_type, ovc_opts, "-vop", vop, "-zoom", \ ! "-xy", resolution, "-o", output] # Non-default aspect ratio? if self.config['aspectratio'] != 'Default': --- 461,492 ---- ovc_opts = "".join(["vcodec=mpeg4:vhq:vbitrate=", str(int(title['vbr']))]) # Cropping ! if self.config['videocodec'] == 'mpeg2': ! vop = "".join(["scale=480:576,expand=480:576,crop=", title['crop']]) ! else: ! vop = "".join(["scale,crop=", title['crop']]) # Deinterlacing? if self.config['deinterlacing'] == 'On': vop = "".join([vop, ",dint"]) + # FPS, based on video format + if title['format'] == 'pal': + fps = '25' + elif title['format'] == 'ntsc': + fps = '30' + elif title['format'] == 'ntscprog': + fps = '24' # Build it all up ! arguments = ["-dvd", str(title['id']), "-alang", title['alang'], \ "-ovc", ovc, ovc_opts_type, ovc_opts, "-vop", vop, "-zoom", \ ! "-ofps", fps, "-xy", resolution, "-o", output] ! # Audio? ! if self.config['audiocodec'] in ['ogg', 'mpeg2']: ! arguments.insert(4, "-nosound") ! else: ! arguments.insert(4, "-oac") ! arguments.insert(5, "copy") ! # Output format? ! if self.config['videocodec'] == 'mpeg2': ! arguments.insert(4, "-of") ! arguments.insert(5, "mpeg") # Non-default aspect ratio? if self.config['aspectratio'] != 'Default': *************** *** 437,440 **** --- 502,560 ---- + def ogmMerge(self, title): + """Merge the OGG and AVI files into an OGM""" + self.notify_newPass("ogmmerge") + self.state = "ripping" + + # Work out filenames + video = os.path.join(self.config['outputdir'], str(title['name'])) + video = ''.join([video, ".avi"]) + output = os.path.join(self.config['outputdir'], str(title['name'])) + output = ''.join([output, ".ogm"]) + + # Work out options to send to ogmmerge + arguments = ["-o", output, '-A', video, 'audio.ogg'] + + # Run ogmmerge + self.run('ogmmerge', arguments, self.pipeFinished, self.ogmmergeProgress, \ + flushbuffer=100, data=("ogmmerge",title)) + + + def extractRawVideo(self, title): + """Extract raw video""" + self.state = "ripping" + + # Work out filenames + video = os.path.join(self.config['outputdir'], 'video.mpg') + vidtmp = os.path.join(self.config['outputdir'], 'video.mpv') + + # Work out options to send to mplayer + arguments = ["-noframedrop", '-vc', 'dummy', '-vo', 'null', '-dumpvideo', \ + '-dumpfile', vidtmp, video] + + # Run mplayer to extract raw video + self.run('mplayer', arguments, self.pipeFinishedSilent, None, \ + flushbuffer=100, data=("mplayer",title)) + + + def tcmplex(self, title): + """Merge video with audio into an MPEG""" + self.notify_newPass("tcmplex") + self.state = "ripping" + + # Work out filenames + audio = os.path.join(self.config['outputdir'], 'audio.mpa') + vidtmp = os.path.join(self.config['outputdir'], 'video.mpv') + output = os.path.join(self.config['outputdir'], str(title['name'])) + output = ''.join([output, ".mpeg"]) + + # Work out options to send to tcmplex + arguments = ["-m", 's', '-i', vidtmp, '-p', audio, '-o', output] + + # Run tcmplex + self.run('tcmplex', arguments, self.pipeFinished, self.tcmplexProgress, \ + flushbuffer=100, data=("tcmplex",title)) + + def mencodeProgress(self, line, (passtype,title)): """Report progress of mencoder pass""" *************** *** 466,469 **** --- 586,625 ---- trem = re_progress.search(line).group(2) self.notify_updateProgress(perc, trem, passtype) + + + def ffmpegProgress(self, line, (passtype,title)): + """Report progress of ffmpeg pass""" + perc = 0 + re_progress = re.compile('time=(\d+.\d)') + if re_progress.search(line): + progress = re_progress.search(line).group(1) + perc = int((float(progress) / float(title['length']) * 100)) + self.notify_updateProgress(perc, None, passtype) + + + def ogmmergeProgress(self, line, (passtype,title)): + """Report progress of ogmmerge pass""" + perc = 0 + re_progress = re.compile('frames \((\d+)\%\)') + if re_progress.search(line): + perc = float(re_progress.search(line).group(1)) + self.notify_updateProgress(perc, None, passtype) + + + def tcmplexProgress(self, line, (passtype,title)): + """Report progress of ogmmerge pass""" + perc = 0 + re_video = re.compile('Scanning video stream: (\d*)\%') + re_audio = re.compile('Scanning audio stream: (\d*)\%') + re_mplex = re.compile('Multiplexing: (\d*)\%') + if re_video.search(line): + perc = float(re_video.search(line).group(1)) * (1.0/3.0) + self.notify_updateProgress(perc, None, passtype) + elif re_audio.search(line): + perc = (float(re_audio.search(line).group(1)) * (1.0/3.0)) + (100.0/3.0) + self.notify_updateProgress(perc, None, passtype) + elif re_mplex.search(line): + perc = (float(re_mplex.search(line).group(1)) * (1.0/3.0)) + (100.0/1.5) + self.notify_updateProgress(perc, None, passtype) *************** *** 473,476 **** --- 629,638 ---- sleep(2) self.state = "still" + + + def pipeFinishedSilent(self, lines, passtype): + """Finish off odds and ends after pipe silently""" + sleep(2) + self.state = "still" *************** *** 547,557 **** else: totallines.append(line) if self.updateFunc: self.updateFunc(line, self.data) - #try: - # stderr_line = os.read(self.pipe.childerr.fileno(), 100) - # self.log('Debug', stderr_line) - #except: - # pass except: # For PyGtk... weird! --- 709,715 ---- else: totallines.append(line) + self.parent.log('Debug', line) if self.updateFunc: self.updateFunc(line, self.data) except: # For PyGtk... weird! |
From: <te...@us...> - 2004-03-07 23:59:56
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2782 Modified Files: README base.py config.py Log Message: - I never committed the README for 0.9-alpha - Added methods to rip wav audio and encode as ogg - Made various bug fixes to accomodate new methods in base.py - Added 'mpeg2' to list of audio codecs in config.py Index: README =================================================================== RCS file: /cvsroot/quickrip/ng/README,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** README 1 Mar 2004 17:00:39 -0000 1.1.1.1 --- README 7 Mar 2004 23:36:03 -0000 1.2 *************** *** 1,3 **** ! QuickRip v0.7 README ------------------- --- 1,3 ---- ! QuickRip v0.9-cvs README ------------------- *************** *** 17,20 **** --- 17,23 ---- but I don't promise anything. + THIS IS AN ALPHA. It only comes with a command line interface (CLI) and may + be very buggy. Please report all bugs. + THIS COMES WITH NO WARRANTY! Check the LICENSE file to find out more about the GNU General Public License under which this is released. *************** *** 23,34 **** 2. INSTALLATION: ---------------- ! Ensure you have Python (>= 2.2), Qt (>= 3.1), PyQt (>= 3.5), Mplayer and ! Transcode installed. The installation script will check that you've got these ! components, so don't worry if you're not sure. ! Mplayer will also need to be compiled with libmp3lame support. Transcode ! should be compiled with libdvdcss support. This is accomplished in both ! instances by compiling MPlayer or Transcode after you've compiled and ! installed libmp3lame and libdvdcss. Once you've satisfied Quickrip's dependencies, you simply do this: --- 26,35 ---- 2. INSTALLATION: ---------------- ! Ensure you have Python (>= 2.2), mmpython and Mplayer installed. The ! installation script will check that you've got these components, so don't ! worry if you're not sure. ! Mplayer will also need to be compiled with libmp3lame, libdvdread and ! libdvdcss support. Once you've satisfied Quickrip's dependencies, you simply do this: *************** *** 42,46 **** hostname$ mkdir -p /usr/share/quickrip ! hostname$ cp *.py *.ui LICENSE README quickriprc /usr/share/quickrip hostname$ ln -sf /usr/share/quickrip/quickrip.py /usr/bin/quickrip --- 43,47 ---- hostname$ mkdir -p /usr/share/quickrip ! hostname$ cp *.py LICENSE README /usr/share/quickrip hostname$ ln -sf /usr/share/quickrip/quickrip.py /usr/bin/quickrip *************** *** 54,58 **** Usage: /usr/bin/quickrip [options] ! Options: (with none, runs PyQt GUI mode) -h, --help print this help message -c, --cli run in command line interface mode --- 55,59 ---- Usage: /usr/bin/quickrip [options] ! Options: (with none, runs CLI mode) -h, --help print this help message -c, --cli run in command line interface mode *************** *** 60,77 **** the terminal is resized (small performance hit) - Hopefully it's very easy and obvious to use GUI QuickRip - that is the main purpose - afterall. Basically, you "Scan DVD", wait until it's finished, then select the tracks - you want to rip, and set the options for how they will be ripped. Each track will - have its own set of options, so you need to select each track and set its options - in turn. You can change the names of tracks by right-clicking on their name at - present (by default: 01, 02, etc.) - - Once you're ready, hit the "Rip DVD" button, and then click on "Start". You can - stop and start the process at any time, but at present you cannot resume the - process, so stopping and starting will make the process start all over again. - - To run with the command line interface (CLI), simply run as "quickrip -cli" and - follow the on-screen instructions to rip your DVD :) - For a more thorough user guide, consult the online documentation at: http://quickrip.sf.net/docs.shtml --- 61,64 ---- Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** base.py 5 Mar 2004 16:15:51 -0000 1.7 --- base.py 7 Mar 2004 23:36:03 -0000 1.8 *************** *** 65,69 **** 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ ! 'transcode': ['paths', self.findProgram("transcode")], \ 'ogmmerge': ['paths', self.findProgram("ogmmerge")], \ 'outputdir': ['paths', os.path.expanduser("~")], \ --- 65,69 ---- 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ ! 'oggenc': ['paths', self.findProgram("oggenc")], \ 'ogmmerge': ['paths', self.findProgram("ogmmerge")], \ 'outputdir': ['paths', os.path.expanduser("~")], \ *************** *** 257,260 **** --- 257,266 ---- os.popen("".join(["rm ", self.config['outputdir'], "/frameno.avi", \ " 2>/dev/null"])) + os.popen("".join(["rm ", self.config['outputdir'], "/audio.wav", \ + " 2>/dev/null"])) + os.popen("".join(["rm ", self.config['outputdir'], "/audio.ogg", \ + " 2>/dev/null"])) + os.popen("".join(["rm ", self.config['outputdir'], "/video.avi", \ + " 2>/dev/null"])) self.notify_newTitle(title['name'], i, self.numrips, title['vbr']) *************** *** 275,288 **** # Rip title ! self.ripMp3Audio(title) ! while self.state == 'ripping': ! sleep(1) ! self.ripVideo(title) ! while self.state == 'ripping': ! sleep(1) ! #if self.config['audiocodec'] == 'ogg': #self.ogmMerge(title) ! #while self.state == 'ripping': ! # sleep(1) self.notify_finishRipping() --- 281,308 ---- # Rip title ! if self.config['videocodec'] == 'mpeg2': ! self.ripSVCD(title) ! while self.state == 'ripping': ! sleep(1) ! elif self.config['audiocodec'] == 'ogg': ! self.ripWavAudio(title) ! while self.state == 'ripping': ! sleep(1) ! self.oggEnc(title) ! while self.state == 'ripping': ! sleep(1) ! #self.ripVideo(title) ! #while self.state == 'ripping': ! # sleep(1) #self.ogmMerge(title) ! #while self.state == 'ripping': ! # sleep(1) ! else: ! self.ripMp3Audio(title) ! while self.state == 'ripping': ! sleep(1) ! self.ripVideo(title) ! while self.state == 'ripping': ! sleep(1) self.notify_finishRipping() *************** *** 306,311 **** --- 326,372 ---- title['crop'] = common_crop + + def ripSVCD(self, title): + """Rip a DVD title for an SVCD""" + self.notify_newPass("svcd") + self.state = "ripping" + + # Work out filename + output = os.path.join(self.config['outputdir'], str(title['name'])) + output = ''.join([output, ".mpeg"]) + + ## Assemble basic command + # I tried transcode, but failed to understand it + # I'll look into mencvcd (in mplayer source tarball in mplayer/TOOLS) + + + def ripWavAudio(self, title): + """Rip the audio in wav format""" + self.notify_newPass("audio") + self.state = "ripping" + # Work out options to send to mplayer + arguments = ["-dvd", str(title['id']), "-alang", title['alang'], \ + "-ao", "pcm", "-vo", "null", "-vc", "dummy", "-aofile", \ + os.path.join(self.config['outputdir'], "audio.wav")] + # Run mplayer + self.run('mplayer', arguments, self.pipeFinished, self.mplayerProgress, \ + flushbuffer=100, data=("audio",title)) + + + def oggEnc(self, title): + """Encode a wav into an ogg""" + self.notify_newPass("oggenc") + self.state = "ripping" + # Work out options to send to mplayer + arguments = [''.join(["-b", str(title['abr'])]), ''.join(["-o", \ + os.path.join(self.config['outputdir'], "audio.ogg")]), \ + os.path.join(self.config['outputdir'], "audio.wav")] + # Run mplayer + self.run('oggenc', arguments, self.pipeFinished, self.oggencProgress, \ + flushbuffer=100, data=("oggenc",title)) + def ripMp3Audio(self, title): + """Rip the audio in mp3 format""" self.notify_newPass("audio") self.state = "ripping" *************** *** 320,325 **** os.path.join(self.config['outputdir'], "frameno.avi")] # Run mencoder ! self.run('mencoder', arguments, self.mencodeFinished, self.mencodeProgress, \ ! flushbuffer=1, data="audio") --- 381,386 ---- os.path.join(self.config['outputdir'], "frameno.avi")] # Run mencoder ! self.run('mencoder', arguments, self.pipeFinished, self.mencodeProgress, \ ! flushbuffer=100, data=("audio",title)) *************** *** 372,381 **** arguments.insert(5, title['slang']) # Go for it! ! self.run('mencoder', arguments, self.mencodeFinished, self.mencodeProgress, \ ! flushbuffer=1, data="video") ! def mencodeProgress(self, line, passtype): ! """Run mencoder with given arguments and report progress""" perc = 0 trem = 0 --- 433,442 ---- arguments.insert(5, title['slang']) # Go for it! ! self.run('mencoder', arguments, self.pipeFinished, self.mencodeProgress, \ ! flushbuffer=100, data=("video",title)) ! def mencodeProgress(self, line, (passtype,title)): ! """Report progress of mencoder pass""" perc = 0 trem = 0 *************** *** 385,396 **** trem = re_progress.search(line).group(2) self.notify_updateProgress(perc, trem, passtype) ! def mencodeFinished(self, lines, passtype): ! """Finish off odds and ends after rip""" self.notify_finishTitle(passtype) sleep(2) self.state = "still" ## INHERIT THE CLASS AND SUBSTITUE THESE CLASS METHODS WITH YOUR ## OWN UI HOOKS --- 446,478 ---- trem = re_progress.search(line).group(2) self.notify_updateProgress(perc, trem, passtype) + + + def mplayerProgress(self, line, (passtype,title)): + """Report progress of mplayer pass""" + perc = 0 + re_progress = re.compile('A:\s*(\d+)\.\d .*') + if re_progress.search(line): + progress = re_progress.search(line).group(1) + perc = int((float(progress) / float(title['length']) * 100)) + self.notify_updateProgress(perc, None, passtype) + + + def oggencProgress(self, line, (passtype,title)): + """Report progress of oggenc pass""" + perc = 0 + re_progress = re.compile('\[\s*(\d*\.\d)\%\] \[[ ](\d*m\d*s)') + if re_progress.search(line): + perc = float(re_progress.search(line).group(1)) + trem = re_progress.search(line).group(2) + self.notify_updateProgress(perc, trem, passtype) ! def pipeFinished(self, lines, passtype): ! """Finish off odds and ends after pipe""" self.notify_finishTitle(passtype) sleep(2) self.state = "still" + ## INHERIT THE CLASS AND SUBSTITUE THESE CLASS METHODS WITH YOUR ## OWN UI HOOKS *************** *** 451,458 **** self.lock.acquire() ! #if DEBUG: ! # print self.command ! ! self.pipe = popen2.Popen3(self.command, 1) pid = self.pipe.pid totallines = [] --- 533,537 ---- self.lock.acquire() ! self.pipe = popen2.Popen4(self.command) pid = self.pipe.pid totallines = [] *************** *** 460,464 **** try: if self.flushbuffer: ! line = self.pipe.fromchild.read(100) else: line = self.pipe.fromchild.readline() --- 539,543 ---- try: if self.flushbuffer: ! line = self.pipe.fromchild.read(self.flushbuffer) else: line = self.pipe.fromchild.readline() Index: config.py =================================================================== RCS file: /cvsroot/quickrip/ng/config.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** config.py 5 Mar 2004 00:57:18 -0000 1.4 --- config.py 7 Mar 2004 23:36:03 -0000 1.5 *************** *** 28,32 **** # Options for options :) video_codecs = ['divx', 'xvid', 'mpeg2'] ! audio_codecs = ['mp3', 'ogg'] aspect_ratios = ['Default', '4:3', '16:9', '2.35:1'] audio_bitrates = ['32', '48', '64', '96', '128', '160', '192', '256', '350'] --- 28,32 ---- # Options for options :) video_codecs = ['divx', 'xvid', 'mpeg2'] ! audio_codecs = ['mp3', 'ogg', 'mpeg2'] aspect_ratios = ['Default', '4:3', '16:9', '2.35:1'] audio_bitrates = ['32', '48', '64', '96', '128', '160', '192', '256', '350'] |
From: <te...@us...> - 2004-03-07 23:58:20
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv2506/cli Modified Files: cli.py Log Message: Small changes and bugfixes Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** cli.py 5 Mar 2004 16:15:15 -0000 1.6 --- cli.py 7 Mar 2004 23:34:28 -0000 1.7 *************** *** 225,233 **** print output.bold("QuickRip will now rip the following tracks:") numtitles_to_rip = 0 for t in self.titles: if t['rip'] == 'yes': numtitles_to_rip += 1 ! print "- Track %2s (%s/%s.avi) at %skbps" % (t['id'], \ ! self.config['outputdir'], t['name'], str(int(t['vbr']))) # Have they selected any titles? if numtitles_to_rip is 0: --- 225,239 ---- print output.bold("QuickRip will now rip the following tracks:") numtitles_to_rip = 0 + if self.config['videocodec'] == 'mpeg2': + end = "mpeg" + elif self.config['audiocodec'] == 'ogg': + end = "ogg" + else: + end = "avi" for t in self.titles: if t['rip'] == 'yes': numtitles_to_rip += 1 ! print "- Track %2s (%s/%s.%s) at %skbps" % (t['id'], \ ! self.config['outputdir'], t['name'], end, str(int(t['vbr']))) # Have they selected any titles? if numtitles_to_rip is 0: *************** *** 314,318 **** self.askOption() # Change the option ! self.choices[self.choice]['object'][self.choices[self.choice]['param']] = self.option_choice # Maybe change filesize/bitrate? if self.choices[self.choice]['param'] in ['vbr', 'abr']: --- 320,350 ---- self.askOption() # Change the option ! self.choices[self.choice]['object'][self.choices[self.choice]['param']] = \ ! self.option_choice ! # Check they have't changed the aspect ratio when vc+ac = mpeg2 ! if self.choices[self.choice]['param'] == 'aspectratio' and \ ! self.option_choice != '4:3' and self.config['audiocodec'] == 'mpeg2': ! print output.red("MPEG2 videos for SVCD can only have a 4:3 aspect ratio") ! self.config['aspectratio'] = '4:3' ! try: ! null = raw_input("") ! del null ! self.switch('configuration') ! except KeyboardInterrupt: ! print "\n\nExiting..." ! sys.exit(2) ! # If changing ac/vc to mpeg2, change the other ! if self.choices[self.choice]['param'] in ['audiocodec', 'videocodec']: ! if self.option_choice == 'mpeg2': ! self.config['videocodec'] = 'mpeg2' ! self.config['audiocodec'] = 'mpeg2' ! self.config['aspectratio'] = '4:3' ! # If changing ac/vc from mpeg2, change the other ! if self.choices[self.choice]['param'] == 'audiocodec' and \ ! self.option_choice != 'mpeg2' and self.config['videocodec'] == 'mpeg2': ! self.config['videocodec'] = 'divx' ! if self.choices[self.choice]['param'] == 'videocodec' and \ ! self.option_choice != 'mpeg2' and self.config['audiocodec'] == 'mpeg2': ! self.config['audiocodec'] = 'mp3' # Maybe change filesize/bitrate? if self.choices[self.choice]['param'] in ['vbr', 'abr']: *************** *** 381,389 **** slashn = "" # Finish off last pass' line ! if passtype != "audio": ! sys.stdout.write(" 100% ") ! for i in range(self.n): ! sys.stdout.write("=") ! sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") sys.stdout.flush() --- 413,421 ---- slashn = "" # Finish off last pass' line ! #if passtype != "audio": ! # sys.stdout.write(" 100% ") ! # for i in range(self.n): ! # sys.stdout.write("=") ! # sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") sys.stdout.flush() *************** *** 407,411 **** sys.stdout.write(" " + str(int(perc)) + "% |") else: ! sys.stdout.write(" " + str(int(perc)) + "% |") # Rewrite bar sys.stdout.write("=" * n) --- 439,443 ---- sys.stdout.write(" " + str(int(perc)) + "% |") else: ! sys.stdout.write(" " + str(int(perc)) + "% |") # Rewrite bar sys.stdout.write("=" * n) |
From: <te...@us...> - 2004-03-05 16:37:56
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv812 Modified Files: base.py Log Message: Completed MP3 & DiVX/XViD ripping support Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** base.py 5 Mar 2004 00:57:18 -0000 1.6 --- base.py 5 Mar 2004 16:15:51 -0000 1.7 *************** *** 12,16 **** from __future__ import generators from time import sleep ! import sys, os, re, popen2, ConfigParser, copy import config # QuickRip global configuration try: --- 12,16 ---- from __future__ import generators from time import sleep ! import sys, os, re, popen2, ConfigParser, copy, threading, thread import config # QuickRip global configuration try: *************** *** 44,47 **** --- 44,48 ---- """the 'actual' init function""" self.cwd = os.getcwd() + self.state = "still" self.numtitles = 0 self.titles = [] *************** *** 74,78 **** 'audiocodec': ['aencode', 'mp3'], \ 'volumead': ['aencode', '0'], \ ! 'logging': ['general', 'Off'] \ } --- 75,81 ---- 'audiocodec': ['aencode', 'mp3'], \ 'volumead': ['aencode', '0'], \ ! 'logging': ['general', 'Normal'], \ ! 'logfile': ['general', \ ! os.path.join(os.path.expanduser("~"), "quickrip_log")] \ } *************** *** 147,150 **** --- 150,188 ---- return 1 + def run(self, program, arguments, finalfunc=None, updatefunc=None, flushbuffer=0, \ + data=None, lock=None): + """Runs a program; supply program name (string) and arguments (list)""" + command = arguments + command[:0] = [self.config[program]] + if lock is None: + lock = thread.allocate_lock() + self.lock = lock + + self.thread = CommandThread(self, command, updatefunc, finalfunc, + flushbuffer, data, self.lock) + self.thread.start() + log_entry = '' + for arg in arguments: + log_entry = ''.join([log_entry, ' ', arg]) + self.log('Normal', log_entry) + + + def log(self, level, entry): + """Log an event in the UI, and possibly in a log file""" + # Send program events to UI + if level == 'Normal': + self.notify_log(entry) + # Write to log file? + if self.config['logging'] == 'Off': + return + elif self.config['logging'] == 'Normal' and level == 'Normal': + if not os.path.isfile(self.config['logfile']): + create_log = open(self.config['logfile'], 'w') + create_log.write("QuickRip log file\n\n") + create_log.close() + log = open(self.config['logfile'], 'a') + log.write(entry + "\n") + log.close() + # The following functions are threaded, but are processed in the order *************** *** 172,176 **** title['name'] = ''.join([self.raw_dvd.label, '-', str(t['trackno'])]) title['size'] = 680.0 ! title['vbr'] = float(min(2000, self.calcRate(int(t['length']), 96, 680.0))) title['abr'] = 128 title['length'] = t['length'] --- 210,214 ---- title['name'] = ''.join([self.raw_dvd.label, '-', str(t['trackno'])]) title['size'] = 680.0 ! title['vbr'] = float(min(4000, self.calcRate(int(t['length']), 96, 680.0))) title['abr'] = 128 title['length'] = t['length'] *************** *** 196,202 **** --- 234,395 ---- def ripDVD(self): + """Rip the selected titles on the DVD, spawning off + appropriate ripping methods""" self.notify_startRipping() + # Set-up QuickRip to be in the correct directory + try: + os.chdir(self.config['outputdir']) + except OSError, msg: + print "Unable to change to directory %s: %s" % \ + (self.config['outputdir'], msg) + + # Build list of titles to rip + self.torip = [] + for title in self.titles: + if title['rip'] == 'yes': + self.torip.append(title) + self.numrips = len(self.torip) + self.ripssofar = 0 + + i = 1 + for title in self.torip: + # Clean up output directory + os.popen("".join(["rm ", self.config['outputdir'], "/frameno.avi", \ + " 2>/dev/null"])) + + self.notify_newTitle(title['name'], i, self.numrips, title['vbr']) + i = i + 1 + + # Look for cropping + if not title.has_key('crop'): + sstep = int(title['length']) / 31 + if not sstep: + sstep = 1 + arguments = [''.join(["dvd://", str(title['id'])]), "-vop", \ + "cropdetect", "-nosound", "-vo", "null", "-frames", "10", \ + "-sstep", str(sstep)] + self.run('mplayer', arguments, self.cropDetect, None, 0, title) + # Wait until cropping has been found + while not title.has_key('crop'): + sleep(1) + + # Rip title + self.ripMp3Audio(title) + while self.state == 'ripping': + sleep(1) + self.ripVideo(title) + while self.state == 'ripping': + sleep(1) + #if self.config['audiocodec'] == 'ogg': + #self.ogmMerge(title) + #while self.state == 'ripping': + # sleep(1) + self.notify_finishRipping() + + + def cropDetect(self, lines, data): + re_crop = re.compile('.*-vop crop=(\d*:\d*:\d*:\d*).*') + crop_options = {} + common_crop = "" + cc_hits = 0 + title = data + for line in lines: + if re_crop.search(line): + crop = re_crop.search(line).group(1) + try: + crop_options[crop] = crop_options[crop] + 1 + if crop_options[crop] > cc_hits: + common_crop = crop + except: + crop_options[crop] = 1 + title['crop'] = common_crop + + + def ripMp3Audio(self, title): + self.notify_newPass("audio") + self.state = "ripping" + # Work out options to send to mencoder + if not self.config['volumead']: + vol = "".join([":vol=", str(self.config['volumead'])]) + else: + vol = "" + lameopts = "".join(["cbr=", str(title['abr']), str(vol)]) + arguments = ["-dvd", str(title['id']), "-alang", title['alang'], \ + "-oac", "mp3lame", "-lameopts", lameopts, "-ovc", "frameno", "-o", \ + os.path.join(self.config['outputdir'], "frameno.avi")] + # Run mencoder + self.run('mencoder', arguments, self.mencodeFinished, self.mencodeProgress, \ + flushbuffer=1, data="audio") + + + def ripVideo(self, title): + """Rip the video from a DVD title, and optionally merge with audio""" + self.notify_newPass("video") + self.state = "ripping" + + # Work out filename + output = os.path.join(self.config['outputdir'], str(title['name'])) + output = ''.join([output, ".avi"]) + ## Work out options to send to mencoder + # PDA? + if self.config['pdamode'] == 'On': + resolution = "320" + else: + resolution = "720" + # Audio? + if self.config['audiocodec'] == 'mp3': + oac = "copy" + else: + oac = "null" + # Video? + if self.config['videocodec'] == 'xvid': + ovc = "xvid" + ovc_opts_type = "-xvidencopts" + ovc_opts = "".join(["4mv:me_quality=6:mod_quant:quant_range=1-31/1-31:", \ + "bitrate=", str(int(title['vbr']))]) + else: + ovc = "lavc" + ovc_opts_type = "-lavcopts" + ovc_opts = "".join(["vcodec=mpeg4:vhq:vbitrate=", str(int(title['vbr']))]) + # Cropping + vop = "".join(["scale,crop=", title['crop']]) + # Deinterlacing? + if self.config['deinterlacing'] == 'On': + vop = "".join([vop, ",dint"]) + # Build it all up + arguments = ["-dvd", str(title['id']), "-alang", title['alang'], "-oac", oac, \ + "-ovc", ovc, ovc_opts_type, ovc_opts, "-vop", vop, "-zoom", \ + "-xy", resolution, "-o", output] + # Non-default aspect ratio? + if self.config['aspectratio'] != 'Default': + arguments.insert(4, "-aspect") + arguments.insert(5, self.config['aspectratio']) + # Subtitles? + if title['slang'] != 'None': + arguments.insert(4, "-slang") + arguments.insert(5, title['slang']) + # Go for it! + self.run('mencoder', arguments, self.mencodeFinished, self.mencodeProgress, \ + flushbuffer=1, data="video") + + + def mencodeProgress(self, line, passtype): + """Run mencoder with given arguments and report progress""" + perc = 0 + trem = 0 + re_progress = re.compile('(\d+)\%\) .*Trem:\s*(\d+\w+)\s+') + if re_progress.search(line): + perc = re_progress.search(line).group(1) + trem = re_progress.search(line).group(2) + self.notify_updateProgress(perc, trem, passtype) + + + def mencodeFinished(self, lines, passtype): + """Finish off odds and ends after rip""" + self.notify_finishTitle(passtype) + sleep(2) + self.state = "still" ## INHERIT THE CLASS AND SUBSTITUE THESE CLASS METHODS WITH YOUR *************** *** 204,207 **** --- 397,403 ---- def notify_Error(self, message): pass + + def notify_log(self, entry): + pass def notify_startScanning(self): *************** *** 231,235 **** def notify_updateProgress(self, perc, trem, tpass): pass ! def notify_finishRipping(self): pass --- 427,503 ---- def notify_updateProgress(self, perc, trem, tpass): pass ! ! def notify_finishTitle(self, passtype): ! pass ! def notify_finishRipping(self): pass + + + + class CommandThread(threading.Thread): + """Handle threading of external commands""" + def __init__(self, parent, command, updatefunc, finalfunc, flushbuffer, data, lock): + threading.Thread.__init__(self) + self.parent = parent + self.updateFunc = updatefunc + self.finalFunc = finalfunc + self.flushbuffer = flushbuffer + self.command = command + self.data = data + self.lock = lock + + def run(self): + self.lock.acquire() + + #if DEBUG: + # print self.command + + self.pipe = popen2.Popen3(self.command, 1) + pid = self.pipe.pid + totallines = [] + while 1: + try: + if self.flushbuffer: + line = self.pipe.fromchild.read(100) + else: + line = self.pipe.fromchild.readline() + + if not line: + break + else: + totallines.append(line) + if self.updateFunc: + self.updateFunc(line, self.data) + #try: + # stderr_line = os.read(self.pipe.childerr.fileno(), 100) + # self.log('Debug', stderr_line) + #except: + # pass + except: + # For PyGtk... weird! + continue + + # Clean up process table--you already handle exceptions in the function + self.kill_pipe() + + try: + os.waitpid(pid, os.WNOHANG) + except: + pass + + if self.finalFunc != None: + self.finalFunc(totallines, self.data) + + self.lock.release() + + sys.exit(2) + + + def kill_pipe(self): + """Kills current process (pipe)""" + try: + os.kill(self.pipe.pid, 9) + os.waitpid(self.pipe.pid, os.WNOHANG) + except: + pass \ No newline at end of file |
From: <te...@us...> - 2004-03-05 16:37:19
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv590/cli Modified Files: cli.py Log Message: Bugfixes, mostly in notify_* methods Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** cli.py 5 Mar 2004 00:57:18 -0000 1.5 --- cli.py 5 Mar 2004 16:15:15 -0000 1.6 *************** *** 229,233 **** numtitles_to_rip += 1 print "- Track %2s (%s/%s.avi) at %skbps" % (t['id'], \ ! self.config['outputdir'], t['name'], t['vbr']) # Have they selected any titles? if numtitles_to_rip is 0: --- 229,233 ---- numtitles_to_rip += 1 print "- Track %2s (%s/%s.avi) at %skbps" % (t['id'], \ ! self.config['outputdir'], t['name'], str(int(t['vbr']))) # Have they selected any titles? if numtitles_to_rip is 0: *************** *** 247,251 **** self.ripDVD() print "" ! print output.bold("Ripping complete. Hit enter to return to the main menu") null = raw_input("") del null --- 247,252 ---- self.ripDVD() print "" ! print "" ! print output.bold("* Ripping complete. Hit enter to return to the main menu") null = raw_input("") del null *************** *** 372,381 **** ! def int_newTitle(self, name, number, total, vbr): ! #print "" print "* Ripping title %2s (%s of %s)" % (name, number, total) ! def int_newPass(self, passtype): slashn = "" # Finish off last pass' line --- 373,382 ---- ! def notify_newTitle(self, name, number, total, vbr): ! print "" print "* Ripping title %2s (%s of %s)" % (name, number, total) ! def notify_newPass(self, passtype): slashn = "" # Finish off last pass' line *************** *** 386,409 **** sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") # (Re)set progress meter for new pass self.spinner = "\|/-\|/-" self.spinpos = 0 width = os.popen("tput cols").read() ! width = float(width) ! self.jumper = 100 / (width - 20) self.n = 0 ! def int_updateProgress(self, perc, trem, tpass): # Auto-resize UI? for opt in sys.argv: if opt in ['-a', '--autoresize']: width = os.popen("tput cols").read() ! width = float(width) ! self.jumper = 100 / (width - 20) ! n = int(int(perc) / self.jumper) # Rewrite percentage if int(perc) <= 9: ! sys.stdout.write(" " + str(int(perc)) + "% |") else: sys.stdout.write(" " + str(int(perc)) + "% |") --- 387,409 ---- sys.stdout.write("|\n") sys.stdout.write(slashn + passtype + " |") + sys.stdout.flush() # (Re)set progress meter for new pass self.spinner = "\|/-\|/-" self.spinpos = 0 width = os.popen("tput cols").read() ! self.jumper = 100.0 / (float(width) - 20.0) self.n = 0 ! def notify_updateProgress(self, perc, trem, passtype): # Auto-resize UI? for opt in sys.argv: if opt in ['-a', '--autoresize']: width = os.popen("tput cols").read() ! self.jumper = 100.0 / (float(width) - 20.0) ! n = int(float(perc) / self.jumper) # Rewrite percentage if int(perc) <= 9: ! sys.stdout.write(" " + str(int(perc)) + "% |") else: sys.stdout.write(" " + str(int(perc)) + "% |") *************** *** 411,417 **** sys.stdout.write("=" * n) # Rewrite spinner ! sys.stdout.write(self.spinner[self.spinpos]) self.spinpos=(self.spinpos+1)%8 sys.stdout.flush() def main(): --- 411,426 ---- sys.stdout.write("=" * n) # Rewrite spinner ! if int(perc) == 100: ! sys.stdout.write("|") ! else: ! sys.stdout.write(self.spinner[self.spinpos]) self.spinpos=(self.spinpos+1)%8 sys.stdout.flush() + # Wipe out spinner + sys.stdout.write("\b" * (8+n)) + + + def notify_finishTitle(self, passtype): + self.notify_updateProgress(100, 0, passtype) def main(): |
From: <te...@us...> - 2004-03-05 16:20:39
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28491 Removed Files: quickriprc Log Message: Removed until stable (it's only an example file) --- quickriprc DELETED --- |
From: <te...@us...> - 2004-03-05 01:19:15
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30870 Modified Files: base.py config.py Log Message: CLI now fully implemented Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** base.py 5 Mar 2004 00:12:29 -0000 1.5 --- base.py 5 Mar 2004 00:57:18 -0000 1.6 *************** *** 194,197 **** --- 194,202 ---- self.notify_finishScanning() + + def ripDVD(self): + self.notify_startRipping() + self.notify_finishRipping() + ## INHERIT THE CLASS AND SUBSTITUE THESE CLASS METHODS WITH YOUR Index: config.py =================================================================== RCS file: /cvsroot/quickrip/ng/config.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** config.py 5 Mar 2004 00:12:29 -0000 1.3 --- config.py 5 Mar 2004 00:57:18 -0000 1.4 *************** *** 59,62 **** "ug": "Uighur", "uk": "Ukrainian", "ur": "Urdu", "uz": "Uzbek", "vi": "Vietnamese", \ "vo": "Volapuk", "wo": "Wolof", "xh": "Xhosa", "yi": "Yiddish", "yo": "Yoruba", "za": "Zhuang", \ ! "zh": "Chinese", "zu": "Zulu" \ } --- 59,62 ---- "ug": "Uighur", "uk": "Ukrainian", "ur": "Urdu", "uz": "Uzbek", "vi": "Vietnamese", \ "vo": "Volapuk", "wo": "Wolof", "xh": "Xhosa", "yi": "Yiddish", "yo": "Yoruba", "za": "Zhuang", \ ! "zh": "Chinese", "zu": "Zulu", "None": "None" \ } |
From: <te...@us...> - 2004-03-05 01:19:00
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv30870/cli Modified Files: cli.py Log Message: CLI now fully implemented Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** cli.py 5 Mar 2004 00:12:28 -0000 1.4 --- cli.py 5 Mar 2004 00:57:18 -0000 1.5 *************** *** 52,55 **** --- 52,58 ---- self.level = 'configure' self.configure() + elif mode == 'rip': + self.level = 'ripping' + self.ripScreen() *************** *** 103,108 **** print "(a) Audio bitrate: \t%skbps" % (str(int(title['abr']))) print "" ! print "(l) Audio language: \t%s" % (title['alang']) ! print "(s) Subtitles: \t%s" % (title['slang']) print "" print output.bold("Enter letter to change information, or 'b' to go back to the title listing") --- 106,111 ---- print "(a) Audio bitrate: \t%skbps" % (str(int(title['abr']))) print "" ! print "(l) Audio language: \t%s" % (config.langs[title['alang']]) ! print "(s) Subtitles: \t%s" % (config.langs[title['slang']]) print "" print output.bold("Enter letter to change information, or 'b' to go back to the title listing") *************** *** 218,221 **** --- 221,256 ---- self.askLevelOrQuestion() + + def ripScreen(self): + print output.bold("QuickRip will now rip the following tracks:") + numtitles_to_rip = 0 + for t in self.titles: + if t['rip'] == 'yes': + numtitles_to_rip += 1 + print "- Track %2s (%s/%s.avi) at %skbps" % (t['id'], \ + self.config['outputdir'], t['name'], t['vbr']) + # Have they selected any titles? + if numtitles_to_rip is 0: + print "" + print output.red("You don't seem to have selected any tracks to rip!") + print output.red("Hit enter to return to the main menu") + null = raw_input() + del null + self.switch("toplevel") + # Ok, rip DVD + print output.bold("Hit enter to begin ripping, or 'b' to return to the main menu") + null = raw_input("> ") + if null == 'b': + self.switch("toplevel") + del null + print "" + self.ripDVD() + print "" + print output.bold("Ripping complete. Hit enter to return to the main menu") + null = raw_input("") + del null + self.switch("toplevel") + + def askLevelOrQuestion(self): *************** *** 232,241 **** print output.bold("Goodbye") sys.exit(2) - elif self.choice == 'b' and self.level != 'toplevel': - self.switch('toplevel') elif self.choice == 'c' and self.level == 'toplevel': self.switch('configure') elif self.choice not in self.choices.keys(): ! print output.bold("You chose '%s', which isn't a valid choice. Try again." % (self.choice)) self.askLevelOrQuestion() else: --- 267,278 ---- print output.bold("Goodbye") sys.exit(2) elif self.choice == 'c' and self.level == 'toplevel': self.switch('configure') + elif self.choice == 'r' and self.level == 'toplevel': + self.switch('rip') + elif self.choice == 'b' and self.level != 'toplevel': + self.switch('toplevel') elif self.choice not in self.choices.keys(): ! print output.red("You chose '%s', which isn't a valid choice. Try again." % (self.choice)) self.askLevelOrQuestion() else: *************** *** 260,269 **** if isinstance(self.choices[self.choice]['options'], type([])): if self.option_choice not in self.choices[self.choice]['options']: ! print output.bold("You chose '%s', which isn't a valid choice. Try again." % \ (self.option_choice)) self.askOption() else: if not re.search(self.choices[self.choice]['options'], self.option_choice): ! print output.bold("You chose '%s', which isn't a valid choice. Try again." % (self.option_choice)) self.askOption() # Maybe check the path is valid? --- 297,306 ---- if isinstance(self.choices[self.choice]['options'], type([])): if self.option_choice not in self.choices[self.choice]['options']: ! print output.red("You chose '%s', which isn't a valid choice. Try again." % \ (self.option_choice)) self.askOption() else: if not re.search(self.choices[self.choice]['options'], self.option_choice): ! print output.red("You chose '%s', which isn't a valid choice. Try again." % (self.option_choice)) self.askOption() # Maybe check the path is valid? *************** *** 273,277 **** msg = "You chose '%s', which isn't a valid choice. Try again." \ % (self.option_choice) ! print output.bold(msg) self.askOption() # Change the option --- 310,314 ---- msg = "You chose '%s', which isn't a valid choice. Try again." \ % (self.option_choice) ! print output.red(msg) self.askOption() # Change the option *************** *** 305,325 **** print output.bold("ERROR: %s" % (message)) sys.exit(2) ! ! def notify_startScanning(self): sys.stdout.write("* Scanning\n") ! ! def notify_dispDVD(self, label, numtitles): print "DVD label: %s" % (label) print "Titles: " + str(numtitles) def notify_dispTitle(self, title): print "%s: %s" % (title['id'], title['timelabel']) def notify_finishScanning(self): print "* Finished scanning" def main(): #print "QuickRip v0.6, (C) Tom Chance, 2003" --- 342,418 ---- print output.bold("ERROR: %s" % (message)) sys.exit(2) ! ! def notify_startScanning(self): sys.stdout.write("* Scanning\n") ! ! ! def notify_noTitles(self): ! print """ ! *** ERROR: No DVD tracks found *** ! *** Check: ! *** - You can play DVDs on your computer ! *** (libdvdread and libdvdcss must be installed) ! *** - There is a DVD in the drive ! """ ! sys.exit(2) ! ! def notify_dispDVD(self, label, numtitles): print "DVD label: %s" % (label) print "Titles: " + str(numtitles) + def notify_dispTitle(self, title): print "%s: %s" % (title['id'], title['timelabel']) + def notify_finishScanning(self): print "* Finished scanning" + def int_newTitle(self, name, number, total, vbr): + #print "" + print "* Ripping title %2s (%s of %s)" % (name, number, total) + + + def int_newPass(self, passtype): + slashn = "" + # Finish off last pass' line + if passtype != "audio": + sys.stdout.write(" 100% ") + for i in range(self.n): + sys.stdout.write("=") + sys.stdout.write("|\n") + sys.stdout.write(slashn + passtype + " |") + # (Re)set progress meter for new pass + self.spinner = "\|/-\|/-" + self.spinpos = 0 + width = os.popen("tput cols").read() + width = float(width) + self.jumper = 100 / (width - 20) + self.n = 0 + + + def int_updateProgress(self, perc, trem, tpass): + # Auto-resize UI? + for opt in sys.argv: + if opt in ['-a', '--autoresize']: + width = os.popen("tput cols").read() + width = float(width) + self.jumper = 100 / (width - 20) + n = int(int(perc) / self.jumper) + # Rewrite percentage + if int(perc) <= 9: + sys.stdout.write(" " + str(int(perc)) + "% |") + else: + sys.stdout.write(" " + str(int(perc)) + "% |") + # Rewrite bar + sys.stdout.write("=" * n) + # Rewrite spinner + sys.stdout.write(self.spinner[self.spinpos]) + self.spinpos=(self.spinpos+1)%8 + sys.stdout.flush() + def main(): #print "QuickRip v0.6, (C) Tom Chance, 2003" |
From: <te...@us...> - 2004-03-05 00:34:03
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22847/cli Modified Files: cli.py Log Message: Finished configuration screen in cli.py (including support work in base.py and config.py) Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** cli.py 4 Mar 2004 02:30:02 -0000 1.3 --- cli.py 5 Mar 2004 00:12:28 -0000 1.4 *************** *** 121,126 **** 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : ['32', '48', '64', '96', '128', '160', '192', \ ! '256', '350'], 'param' : 'abr', 'object' : self.titles[t_index] } --- 121,125 ---- 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : config.audio_bitrates, 'param' : 'abr', 'object' : self.titles[t_index] } *************** *** 144,147 **** --- 143,148 ---- print output.bold('Configure QuickRip') print "" + print "(l) Logging: \t\t%s" % (self.config['logging']) + print "" print "Paths:" print "(m) Mplayer path: \t%s" % (self.config['mplayer']) *************** *** 154,165 **** print "Encoding:" print "(v) Video codec: \t%s" % (self.config['videocodec']) ! print "(s) Video aspect ratio:\t%s" % (self.config['aspectratio']) print "(i) De-interlacing: \t%s" % (self.config['deinterlacing']) print "(z) PDA Mode: \t\t%s" % (self.config['pdamode']) print "(a) Audio codec: \t%s" % (self.config['audiocodec']) ! print "(v) Volume adjustment: \t%s" % (self.config['volumead']) print "" print output.bold("Enter letter to change option, or 'b' to return to the title list screen") self.choices = {} self.askLevelOrQuestion() --- 155,219 ---- print "Encoding:" print "(v) Video codec: \t%s" % (self.config['videocodec']) ! print "(r) Video aspect ratio:\t%s" % (self.config['aspectratio']) print "(i) De-interlacing: \t%s" % (self.config['deinterlacing']) print "(z) PDA Mode: \t\t%s" % (self.config['pdamode']) print "(a) Audio codec: \t%s" % (self.config['audiocodec']) ! print "(j) Volume adjustment: \t%s" % (self.config['volumead']) print "" print output.bold("Enter letter to change option, or 'b' to return to the title list screen") self.choices = {} + self.choices['l'] = { 'question' : 'Choose a logging level: ', + 'options' : ['Off', 'Normal', 'Debug'], + 'param' : 'logging', + 'object' : self.config } + self.choices['m'] = { 'question' : 'Enter new path for mplayer: ', + 'options' : '^[\w\/]+$', + 'param' : 'mplayer', + 'object' : self.config } + self.choices['e'] = { 'question' : 'Enter new path for mencoder: ', + 'options' : '^[\w\/]+$', + 'param' : 'mencoder', + 'object' : self.config } + self.choices['t'] = { 'question' : 'Enter new path for transcode: ', + 'options' : '^[\w\/]+$', + 'param' : 'transcode', + 'object' : self.config } + self.choices['o'] = { 'question' : 'Enter new path for ogmmerge: ', + 'options' : '^[\w\/]+$', + 'param' : 'ogmmerge', + 'object' : self.config } + self.choices['p'] = { 'question' : 'Enter the new output directory: ', + 'options' : '^[\w\/]+$', + 'param' : 'outputdir', + 'object' : self.config } + self.choices['d'] = { 'question' : 'Enter the path to the DVD device: ', + 'options' : '^[\w\/]+$', + 'param' : 'dvd_device', + 'object' : self.config } + self.choices['v'] = { 'question' : 'Enter the new video codec: ', + 'options' : config.video_codecs, + 'param' : 'videocodec', + 'object' : self.config } + self.choices['r'] = { 'question' : 'Enter the new video aspect ratio: ', + 'options' : config.aspect_ratios, + 'param' : 'aspectratio', + 'object' : self.config } + self.choices['i'] = { 'question' : 'Do you want de-interlacing? ', + 'options' : ['On', 'Off'], + 'param' : 'deinterlacing', + 'object' : self.config } + self.choices['z'] = { 'question' : 'Do you want use the PDA mode? ', + 'options' : ['On', 'Off'], + 'param' : 'pdamode', + 'object' : self.config } + self.choices['a'] = { 'question' : 'Enter the new audio codec: ', + 'options' : config.audio_codecs, + 'param' : 'audiocodec', + 'object' : self.config } + self.choices['j'] = { 'question' : 'Volume adjustment: ', + 'options' : ['0', '1', '2', '3', '4', '5', '6', '7', '8', \ + '9', '10'], + 'param' : 'volumead', + 'object' : self.config } self.askLevelOrQuestion() *************** *** 204,218 **** sys.exit(2) # Check the input is valid ! try: ! self.choices[self.choice]['options'].append if self.option_choice not in self.choices[self.choice]['options']: print output.bold("You chose '%s', which isn't a valid choice. Try again." % \ (self.option_choice)) self.askOption() ! except: if not re.search(self.choices[self.choice]['options'], self.option_choice): ! print output.bold("You chose '%s', which isn't a valid choice. Try again." % \ ! (self.option_choice)) self.askOption() # Change the option self.choices[self.choice]['object'][self.choices[self.choice]['param']] = self.option_choice --- 258,278 ---- sys.exit(2) # Check the input is valid ! if isinstance(self.choices[self.choice]['options'], type([])): if self.option_choice not in self.choices[self.choice]['options']: print output.bold("You chose '%s', which isn't a valid choice. Try again." % \ (self.option_choice)) self.askOption() ! else: if not re.search(self.choices[self.choice]['options'], self.option_choice): ! print output.bold("You chose '%s', which isn't a valid choice. Try again." % (self.option_choice)) self.askOption() + # Maybe check the path is valid? + if self.choices[self.choice]['param'] in self.variables.keys(): + if self.variables[self.choices[self.choice]['param']][0] == 'paths': + if not os.path.exists(self.option_choice): + msg = "You chose '%s', which isn't a valid choice. Try again." \ + % (self.option_choice) + print output.bold(msg) + self.askOption() # Change the option self.choices[self.choice]['object'][self.choices[self.choice]['param']] = self.option_choice *************** *** 227,231 **** self.choices[self.choice]['object']['length'], \ self.choices[self.choice]['object']['abr'], \ ! self.choices[self.choice]['object']['size']) # Return to appropriate level if self.choices[self.choice]['object'].has_key('id'): --- 287,294 ---- self.choices[self.choice]['object']['length'], \ self.choices[self.choice]['object']['abr'], \ ! self.choices[self.choice]['object']['size']) ! # Maybe save the config file? ! if self.choices[self.choice]['object'] is self.config: ! self.saveConfig() # Return to appropriate level if self.choices[self.choice]['object'].has_key('id'): |
From: <te...@us...> - 2004-03-05 00:34:03
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv22847 Modified Files: base.py config.py Log Message: Finished configuration screen in cli.py (including support work in base.py and config.py) Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** base.py 4 Mar 2004 02:30:16 -0000 1.4 --- base.py 5 Mar 2004 00:12:29 -0000 1.5 *************** *** 46,51 **** self.numtitles = 0 self.titles = [] - self.dio = config.dio - self.aro = config.dio self.configfile = os.path.join(os.path.expanduser("~"), ".quickriprc") self.loadConfig() --- 46,49 ---- *************** *** 56,63 **** self.parser = ConfigParser.ConfigParser() if not os.path.isfile(self.configfile): ! self.parser.write(open(self.configfile, 'w')) ! self.parser.readfp(open(self.configfile, 'r')) ! variables = { \ 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ --- 54,65 ---- self.parser = ConfigParser.ConfigParser() if not os.path.isfile(self.configfile): ! cfg = open(self.configfile, 'w') ! self.parser.write(cfg) ! cfg.close() ! cfg = open(self.configfile, 'r') ! self.parser.readfp(cfg) ! cfg.close() ! self.variables = { \ 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ *************** *** 67,79 **** 'dvd_device': ['paths', os.path.join("/", "dev", "dvd")], \ 'deinterlacing': ['vencode', 'Off'], \ ! 'aspectratio': ['vencode', 0], \ 'videocodec': ['vencode', 'divx'], \ ! 'pdamode': ['vencode', 0], \ 'audiocodec': ['aencode', 'mp3'], \ ! 'volumead': ['aencode', 0], \ } ! for key in variables.keys(): ! self.cautiousLoad(variables[key][0], key, variables[key][1]) --- 69,82 ---- 'dvd_device': ['paths', os.path.join("/", "dev", "dvd")], \ 'deinterlacing': ['vencode', 'Off'], \ ! 'aspectratio': ['vencode', 'Default'], \ 'videocodec': ['vencode', 'divx'], \ ! 'pdamode': ['vencode', 'Off'], \ 'audiocodec': ['aencode', 'mp3'], \ ! 'volumead': ['aencode', '0'], \ ! 'logging': ['general', 'Off'] \ } ! for key in self.variables.keys(): ! self.cautiousLoad(self.variables[key][0], key, self.variables[key][1]) *************** *** 90,94 **** self.parser.add_section(section) self.parser.set(section, var, default) ! self.parser.write(open(self.configfile, 'w')) --- 93,99 ---- self.parser.add_section(section) self.parser.set(section, var, default) ! cfg = open(self.configfile, 'w') ! self.parser.write(cfg) ! cfg.close() *************** *** 102,105 **** --- 107,119 ---- + def saveConfig(self): + """Save the configuration file""" + for key in self.variables.keys(): + self.parser.set(self.variables[key][0], key, self.config[key]) + cfg = open(self.configfile, 'w') + self.parser.write(cfg) + cfg.close() + + def calcRate(self, length, audiobr, filesize): """Calculate bitrate for video based on: Index: config.py =================================================================== RCS file: /cvsroot/quickrip/ng/config.py,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** config.py 4 Mar 2004 02:30:16 -0000 1.2 --- config.py 5 Mar 2004 00:12:29 -0000 1.3 *************** *** 12,15 **** --- 12,16 ---- import os + # Basic information app = "QuickRip" author = "Tom Chance <tom...@gm...>" *************** *** 18,28 **** copyright = "(C) 2003 Tom Chance" license = "GNU General Public License (GPL) (see LICENSE file)" paths = os.environ['PATH'].split(":") required_programs = ['mplayer', 'mencoder'] icon = os.path.join("icons", "quickrip.xpm") qr_dir = "/usr/share/quickrip" ! aro = {0: 'Default', 1: '4:3', 2: '16:9', 3: '2.35:1'} ! dio = {0 : 'None', 1: 'dint', 2: 'il', 3: 'lavcdeint', 4: 'pp=lb'} ! abr = {0: 64, 1: 96, 2: 128, 3: 160, 4: 190} langs = { \ " ": "Not Specified", "aa": "Afar", "ab": "Abkhazian", "af": "Afrikaans", "am": "Amharic", \ --- 19,34 ---- copyright = "(C) 2003 Tom Chance" license = "GNU General Public License (GPL) (see LICENSE file)" + + # Misc paths = os.environ['PATH'].split(":") required_programs = ['mplayer', 'mencoder'] icon = os.path.join("icons", "quickrip.xpm") qr_dir = "/usr/share/quickrip" ! ! # Options for options :) ! video_codecs = ['divx', 'xvid', 'mpeg2'] ! audio_codecs = ['mp3', 'ogg'] ! aspect_ratios = ['Default', '4:3', '16:9', '2.35:1'] ! audio_bitrates = ['32', '48', '64', '96', '128', '160', '192', '256', '350'] langs = { \ " ": "Not Specified", "aa": "Afar", "ab": "Abkhazian", "af": "Afrikaans", "am": "Amharic", \ |
From: <te...@us...> - 2004-03-04 02:51:08
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25234 Modified Files: base.py config.py Log Message: Made ogmmerge and transcode optional dependencies (base.py & config.py). Started configuration screen in cli.py and added audio/subtitle language to title screen options. Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** base.py 3 Mar 2004 01:45:15 -0000 1.3 --- base.py 4 Mar 2004 02:30:16 -0000 1.4 *************** *** 62,77 **** 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ - 'tcprobe': ['paths', self.findProgram("tcprobe")], \ 'transcode': ['paths', self.findProgram("transcode")], \ ! #'ogmmerge': ['paths', self.findProgram("ogmmerge")], \ 'outputdir': ['paths', os.path.expanduser("~")], \ 'dvd_device': ['paths', os.path.join("/", "dev", "dvd")], \ ! 'deinterlacing': ['vencode', 0], \ 'aspectratio': ['vencode', 0], \ ! 'videocodec': ['vencode', 0], \ 'pdamode': ['vencode', 0], \ ! 'audiocodec': ['aencode', 0], \ 'volumead': ['aencode', 0], \ - 'audiobitrate': ['aencode', 1] \ } --- 62,75 ---- 'mplayer': ['paths', self.findProgram("mplayer")], \ 'mencoder': ['paths', self.findProgram("mencoder")], \ 'transcode': ['paths', self.findProgram("transcode")], \ ! 'ogmmerge': ['paths', self.findProgram("ogmmerge")], \ 'outputdir': ['paths', os.path.expanduser("~")], \ 'dvd_device': ['paths', os.path.join("/", "dev", "dvd")], \ ! 'deinterlacing': ['vencode', 'Off'], \ 'aspectratio': ['vencode', 0], \ ! 'videocodec': ['vencode', 'divx'], \ 'pdamode': ['vencode', 0], \ ! 'audiocodec': ['aencode', 'mp3'], \ 'volumead': ['aencode', 0], \ } *************** *** 100,104 **** if os.path.isfile(os.path.join(path, program)): return os.path.join(path, program) ! self.notify_Error("Couldn't find the program '%s'" % (program)) --- 98,103 ---- if os.path.isfile(os.path.join(path, program)): return os.path.join(path, program) ! if program in config.required_programs: ! self.notify_Error("Couldn't find the program '%s'" % (program)) *************** *** 168,175 **** timelabel = (t['length'] / 60) title['timelabel'] = "%s mins" % (timelabel) title['alangs'] = [] for a in t['audio']: title['alangs'].append(a['language']) ! title['subtitles'] = t['subtitles'] self.titles.append(title) self.notify_dispTitle(title) --- 167,178 ---- timelabel = (t['length'] / 60) title['timelabel'] = "%s mins" % (timelabel) + title['alang'] = 'en' + title['slang'] = 'None' title['alangs'] = [] for a in t['audio']: title['alangs'].append(a['language']) ! title['slangs'] = ['None'] ! for sl in t['subtitles']: ! title['slangs'].append(sl) self.titles.append(title) self.notify_dispTitle(title) Index: config.py =================================================================== RCS file: /cvsroot/quickrip/ng/config.py,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** config.py 1 Mar 2004 17:00:39 -0000 1.1.1.1 --- config.py 4 Mar 2004 02:30:16 -0000 1.2 *************** *** 19,22 **** --- 19,23 ---- license = "GNU General Public License (GPL) (see LICENSE file)" paths = os.environ['PATH'].split(":") + required_programs = ['mplayer', 'mencoder'] icon = os.path.join("icons", "quickrip.xpm") qr_dir = "/usr/share/quickrip" |
From: <te...@us...> - 2004-03-04 02:51:08
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv25234/cli Modified Files: cli.py Log Message: Made ogmmerge and transcode optional dependencies (base.py & config.py). Started configuration screen in cli.py and added audio/subtitle language to title screen options. Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** cli.py 3 Mar 2004 01:45:15 -0000 1.2 --- cli.py 4 Mar 2004 02:30:02 -0000 1.3 *************** *** 49,52 **** --- 49,55 ---- self.level = 'title' self.showTitle(title) + elif mode == 'configure': + self.level = 'configure' + self.configure() *************** *** 94,101 **** print "(n) Name: \t\t%s" % (title['name']) print " Length: \t\t%s" % (title['timelabel']) ! print "(s) File size: \t%sMB" % (str(int(title['size']))) print "(v) Video bitrate: \t%skbps" % (str(int(title['vbr']))) print "(a) Audio bitrate: \t%skbps" % (str(int(title['abr']))) ! print "(r) Rip title? \t%s" % (title['rip']) print "" print output.bold("Enter letter to change information, or 'b' to go back to the title listing") --- 97,108 ---- print "(n) Name: \t\t%s" % (title['name']) print " Length: \t\t%s" % (title['timelabel']) ! print "(r) Rip title? \t%s" % (title['rip']) ! print "" ! print "(f) File size: \t%sMB" % (str(int(title['size']))) print "(v) Video bitrate: \t%skbps" % (str(int(title['vbr']))) print "(a) Audio bitrate: \t%skbps" % (str(int(title['abr']))) ! print "" ! print "(l) Audio language: \t%s" % (title['alang']) ! print "(s) Subtitles: \t%s" % (title['slang']) print "" print output.bold("Enter letter to change information, or 'b' to go back to the title listing") *************** *** 105,109 **** 'param' : 'name', 'object' : self.titles[t_index] } ! self.choices['s'] = { 'question' : 'Enter new file size in MB:', 'options' : '\d+', 'param' : 'size', --- 112,116 ---- 'param' : 'name', 'object' : self.titles[t_index] } ! self.choices['f'] = { 'question' : 'Enter new file size in MB:', 'options' : '\d+', 'param' : 'size', *************** *** 114,124 **** 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : ['32', '48', '64', '96', '128', '160', '192', '256', '350'], 'param' : 'abr', 'object' : self.titles[t_index] } ! self.choices['r'] = { 'question' : 'Rip title? [yes/no]:', ! 'options' : ['yes', 'no'], 'param' : 'rip', 'object' : self.titles[t_index] } self.askLevelOrQuestion() --- 121,165 ---- 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : ['32', '48', '64', '96', '128', '160', '192', \ ! '256', '350'], 'param' : 'abr', 'object' : self.titles[t_index] } ! self.choices['r'] = { 'question' : 'Rip title? [yes/no]:', ! 'options' : ['yes', 'no'], 'param' : 'rip', 'object' : self.titles[t_index] } + self.choices['l'] = { 'question' : 'Choose an audio language: ', + 'options' : title['alangs'], + 'param' : 'alang', + 'object' : self.titles[t_index] } + self.choices['s'] = { 'question' : 'Choose an subtitle language: ', + 'options' : title['slangs'], + 'param' : 'slang', + 'object' : self.titles[t_index] } + self.askLevelOrQuestion() + + + def configure(self): + """show the configuration screen""" + print output.bold('Configure QuickRip') + print "" + print "Paths:" + print "(m) Mplayer path: \t%s" % (self.config['mplayer']) + print "(e) Mencoder path: \t%s" % (self.config['mencoder']) + print "(t) Transcode path: \t%s" % (self.config['transcode']) + print "(o) Ogmmerge path: \t%s" % (self.config['ogmmerge']) + print "(p) Output directory: \t%s" % (self.config['outputdir']) + print "(d) DVD device: \t%s" % (self.config['dvd_device']) + print "" + print "Encoding:" + print "(v) Video codec: \t%s" % (self.config['videocodec']) + print "(s) Video aspect ratio:\t%s" % (self.config['aspectratio']) + print "(i) De-interlacing: \t%s" % (self.config['deinterlacing']) + print "(z) PDA Mode: \t\t%s" % (self.config['pdamode']) + print "(a) Audio codec: \t%s" % (self.config['audiocodec']) + print "(v) Volume adjustment: \t%s" % (self.config['volumead']) + print "" + print output.bold("Enter letter to change option, or 'b' to return to the title list screen") + self.choices = {} self.askLevelOrQuestion() |
From: <te...@us...> - 2004-03-03 02:05:18
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28094 Modified Files: base.py Removed Files: base.pyc config.pyc output.pyc Log Message: Minor additions to base and cli. Removed .pyc files from repository. Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** base.py 1 Mar 2004 23:17:22 -0000 1.2 --- base.py 3 Mar 2004 01:45:15 -0000 1.3 *************** *** 109,115 **** - size of resultant file (MB)""" try: ! self.filesize = int(filesize) ! self.length = int(length) ! self.audiobr = int(audiobr) self.rate = ((self.filesize * 8192) / self.length) - self.audiobr self.rate = self.rate * 0.98 # Correction based on addition of credits and usual error --- 109,115 ---- - size of resultant file (MB)""" try: ! self.filesize = float(filesize) ! self.length = float(length) ! self.audiobr = float(audiobr) self.rate = ((self.filesize * 8192) / self.length) - self.audiobr self.rate = self.rate * 0.98 # Correction based on addition of credits and usual error *************** *** 125,131 **** - bitrate of title (Kbps)""" try: ! self.length = int(length) ! self.audiobr = int(audiobr) ! self.bitrate = int(bitrate) self.filesize = ((self.bitrate + self.audiobr) * self.length) / 8192 self.filesize = self.filesize * (1 / 0.98) # Correction based on addition of credits and usual error --- 125,131 ---- - bitrate of title (Kbps)""" try: ! self.length = float(length) ! self.audiobr = float(audiobr) ! self.bitrate = float(bitrate) self.filesize = ((self.bitrate + self.audiobr) * self.length) / 8192 self.filesize = self.filesize * (1 / 0.98) # Correction based on addition of credits and usual error *************** *** 158,163 **** title['id'] = t['trackno'] title['name'] = ''.join([self.raw_dvd.label, '-', str(t['trackno'])]) ! title['size'] = 680 ! title['vbr'] = min(2000, self.calcRate(int(t['length']), 96, 680)) title['abr'] = 128 title['length'] = t['length'] --- 158,163 ---- title['id'] = t['trackno'] title['name'] = ''.join([self.raw_dvd.label, '-', str(t['trackno'])]) ! title['size'] = 680.0 ! title['vbr'] = float(min(2000, self.calcRate(int(t['length']), 96, 680.0))) title['abr'] = 128 title['length'] = t['length'] --- base.pyc DELETED --- --- config.pyc DELETED --- --- output.pyc DELETED --- |
From: <te...@us...> - 2004-03-03 02:05:18
|
Update of /cvsroot/quickrip/ng/cli In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv28094/cli Modified Files: cli.py Removed Files: cli.pyc Log Message: Minor additions to base and cli. Removed .pyc files from repository. Index: cli.py =================================================================== RCS file: /cvsroot/quickrip/ng/cli/cli.py,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** cli.py 1 Mar 2004 17:00:42 -0000 1.1.1.1 --- cli.py 3 Mar 2004 01:45:15 -0000 1.2 *************** *** 28,40 **** class CLI(QuickRip): """CLI-specific functions to add a CLI to the QuickRip base class: ! switch() - send user into various modes (entry, toplevel, title) ! front() - show the front screen ! toplevel() - show the top level screen ! showTitle() - show the title information screen ! configure() - show the configuration screen ! askLevel() - select new level or question to ask ! askOption() - ask for new value for option, and change option""" def switch(self, mode, title=1): os.system("clear") print output.bold("%s v%s, %s\n" % (__app__, __version__, __copyright__)) --- 28,41 ---- class CLI(QuickRip): """CLI-specific functions to add a CLI to the QuickRip base class: ! switch() - send user into various modes (entry, toplevel, title) ! front() - show the front screen ! toplevel() - show the top level screen ! showTitle() - show the title information screen ! configure() - show the configuration screen ! askLevelOrQuestion() - select new level or question to ask ! askOption() - ask for new value for option, and change option""" def switch(self, mode, title=1): + """send user into various modes (entry, toplevel, title)""" os.system("clear") print output.bold("%s v%s, %s\n" % (__app__, __version__, __copyright__)) *************** *** 51,54 **** --- 52,56 ---- def front(self): + """show the front screen""" print output.bold("\nHit enter to scan DVD") try: *************** *** 63,66 **** --- 65,69 ---- def toplevel(self): + """show the top level screen""" print output.bold(''.join(["Disc: ", self.raw_dvd['label']])) print "Titles on DVD: ((*) means title will be ripped)" *************** *** 76,83 **** print output.bold("Enter letter/title number to edit information, or 'r' to start ripping") self.choices = {} ! self.askLevel() def showTitle(self, id): title = None for t in self.titles: --- 79,87 ---- print output.bold("Enter letter/title number to edit information, or 'r' to start ripping") self.choices = {} ! self.askLevelOrQuestion() def showTitle(self, id): + """show the title information screen""" title = None for t in self.titles: *************** *** 90,96 **** print "(n) Name: \t\t%s" % (title['name']) print " Length: \t\t%s" % (title['timelabel']) ! print "(s) File size: \t%sMB" % (str(title['size'])) ! print "(v) Video bitrate: \t%skbps" % (str(title['vbr'])) ! print "(a) Audio bitrate: \t%skbps" % (str(title['abr'])) print "(r) Rip title? \t%s" % (title['rip']) print "" --- 94,100 ---- print "(n) Name: \t\t%s" % (title['name']) print " Length: \t\t%s" % (title['timelabel']) ! print "(s) File size: \t%sMB" % (str(int(title['size']))) ! print "(v) Video bitrate: \t%skbps" % (str(int(title['vbr']))) ! print "(a) Audio bitrate: \t%skbps" % (str(int(title['abr']))) print "(r) Rip title? \t%s" % (title['rip']) print "" *************** *** 110,114 **** 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : '\d+', 'param' : 'abr', 'object' : self.titles[t_index] } --- 114,118 ---- 'object' : self.titles[t_index] } self.choices['a'] = { 'question' : 'Enter new audio bitrate in kbps:', ! 'options' : ['32', '48', '64', '96', '128', '160', '192', '256', '350'], 'param' : 'abr', 'object' : self.titles[t_index] } *************** *** 117,124 **** 'param' : 'rip', 'object' : self.titles[t_index] } ! self.askLevel() ! def askLevel(self): try: self.choice = raw_input("> ") --- 121,129 ---- 'param' : 'rip', 'object' : self.titles[t_index] } ! self.askLevelOrQuestion() ! def askLevelOrQuestion(self): ! """select new level or question to ask""" try: self.choice = raw_input("> ") *************** *** 131,135 **** elif self.choice == 'q' and self.level == 'toplevel': print output.bold("Goodbye") ! sys.exit(42) elif self.choice == 'b' and self.level != 'toplevel': self.switch('toplevel') --- 136,140 ---- elif self.choice == 'q' and self.level == 'toplevel': print output.bold("Goodbye") ! sys.exit(2) elif self.choice == 'b' and self.level != 'toplevel': self.switch('toplevel') *************** *** 138,142 **** elif self.choice not in self.choices.keys(): print output.bold("You chose '%s', which isn't a valid choice. Try again." % (self.choice)) ! self.askLevel() else: self.askOption() --- 143,147 ---- elif self.choice not in self.choices.keys(): print output.bold("You chose '%s', which isn't a valid choice. Try again." % (self.choice)) ! self.askLevelOrQuestion() else: self.askOption() *************** *** 144,148 **** def askOption(self): ! print output.bold(self.choices[self.choice]['question']) try: self.option_choice = raw_input("> ") --- 149,160 ---- def askOption(self): ! """ask for new value for option, and change option""" ! question = self.choices[self.choice]['question'] ! if isinstance(self.choices[self.choice]['options'], type([])): ! question = ''.join([question, ' [']) ! for o in self.choices[self.choice]['options']: ! question = ''.join([question, ' ', o, ' ']) ! question = ''.join([question, ']']) ! print output.bold(question) try: self.option_choice = raw_input("> ") *************** *** 164,167 **** --- 176,190 ---- # Change the option self.choices[self.choice]['object'][self.choices[self.choice]['param']] = self.option_choice + # Maybe change filesize/bitrate? + if self.choices[self.choice]['param'] in ['vbr', 'abr']: + self.choices[self.choice]['object']['size'] = self.calcFileSize(\ + self.choices[self.choice]['object']['length'], \ + self.choices[self.choice]['object']['abr'], \ + self.choices[self.choice]['object']['vbr']) + elif self.choices[self.choice]['param'] == 'size': + self.choices[self.choice]['object']['vbr'] = self.calcRate(\ + self.choices[self.choice]['object']['length'], \ + self.choices[self.choice]['object']['abr'], \ + self.choices[self.choice]['object']['size']) # Return to appropriate level if self.choices[self.choice]['object'].has_key('id'): *************** *** 177,181 **** def notify_Error(self, message): print output.bold("ERROR: %s" % (message)) ! sys.exit(42) --- 200,204 ---- def notify_Error(self, message): print output.bold("ERROR: %s" % (message)) ! sys.exit(2) --- cli.pyc DELETED --- |
From: <te...@us...> - 2004-03-01 23:36:35
|
Update of /cvsroot/quickrip/ng In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv5781 Modified Files: base.py Log Message: Added disc label to title names to make them more descriptive Index: base.py =================================================================== RCS file: /cvsroot/quickrip/ng/base.py,v retrieving revision 1.1.1.1 retrieving revision 1.2 diff -C2 -d -r1.1.1.1 -r1.2 *** base.py 1 Mar 2004 17:00:40 -0000 1.1.1.1 --- base.py 1 Mar 2004 23:17:22 -0000 1.2 *************** *** 157,161 **** title['rip'] = 'no' title['id'] = t['trackno'] ! title['name'] = str(t['trackno']) title['size'] = 680 title['vbr'] = min(2000, self.calcRate(int(t['length']), 96, 680)) --- 157,161 ---- title['rip'] = 'no' title['id'] = t['trackno'] ! title['name'] = ''.join([self.raw_dvd.label, '-', str(t['trackno'])]) title['size'] = 680 title['vbr'] = min(2000, self.calcRate(int(t['length']), 96, 680)) |