Quantcast Replacing DVD Rebuilder's Encode Phase with Manual Encoding? - Page 3 - digitalFAQ.com Forums [Archives]
Go Back    digitalFAQ.com Forums [Archives] > Video Production Forums > Video Encoding and Conversion

Reply
 
LinkBack Thread Tools
  #41  
07-27-2004, 12:49 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Well, I've made some progress. I have Perl code that produces a correct AVS for file size prediction, and have started the C++ version. Right now it reads in the REBUILDER.INF and REBUILDER.ECL files, and am about to make it generate an AVS and ECL for file size prediction. Then it'll fire up CCE to do the encode, and then I'll write the Newton method search to find the best Q factor. Eventually it'll then rewrite the REBUILDER.INF and REBUILDER.ECL files with the correct settings so that DVD-RB's encode phase can be run.

Hopefully I'll get a decent amount of code written today. It's just a command line tool at the moment. The GUI will probably be the last thing I do.
Reply With Quote
Someday, 12:01 PM
admin's Avatar
Site Staff / Ad Manager
 
Join Date: Dec 2002
Posts: 42
Thanks: ∞
Thanked 42 Times in 42 Posts
  #42  
07-27-2004, 02:25 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
I asked a couple of questions regarding REBUILDER.INF in the DVD-RB Doom9 forum, and got a response from robot1, the author of RB-Opt. It's ended up with him emailing me the source for RB-Opt, because it would probably be a lot simpler to add OPV prediction to that rather than recode the entire thing myself...

I'll keep you updated .
Reply With Quote
  #43  
07-27-2004, 06:45 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Okay, I have the RB-Opt source code and I'm busily adding OPV prediction to it...

Obviously it'll be a little slow-going because I'm trying to figure out the existing code as well as write my own, but I'm hoping to have something together within the next couple of days.
Reply With Quote
  #44  
07-27-2004, 07:08 PM
Dialhot Dialhot is offline
Free Member
 
Join Date: May 2003
Posts: 10,463
Thanks: 0
Thanked 0 Times in 0 Posts
I think we can wait .
That's true that RB-OPT with OPV... the idea is freaking.
Reply With Quote
  #45  
07-27-2004, 08:20 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Yes, it should be pretty nifty .
Reply With Quote
  #46  
07-28-2004, 04:05 PM
Zyphon Zyphon is offline
Free Member
 
Join Date: Oct 2003
Location: London, England (UK)
Posts: 1,035
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by SansGrip
Okay, I have the RB-Opt source code and I'm busily adding OPV prediction to it...

Obviously it'll be a little slow-going because I'm trying to figure out the existing code as well as write my own, but I'm hoping to have something together within the next couple of days.
This is great news SansGrip and very nice of Robot1 to give the source of his code for you to play around with.

Good luck with your tests and coding buddy I and many cannot wait to see the fruits of your labour.
__________________
Regards.

Michael.
Reply With Quote
  #47  
07-28-2004, 07:00 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Here's a little something to whet your appetite...

Reply With Quote
  #48  
07-28-2004, 07:14 PM
Dialhot Dialhot is offline
Free Member
 
Join Date: May 2003
Posts: 10,463
Thanks: 0
Thanked 0 Times in 0 Posts
Amazing !

Can you please add a "Starting Q value to use" somewhere? I generally encode at 20/25 and find anything above 30 to bad. So I don't see the reason to start the test with 32...

IMHO...
Reply With Quote
  #49  
07-28-2004, 07:19 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by Dialhot
Can you please add a "Starting Q value to use" somewhere? I generally encode at 20/25 and find anything above 30 to bad. So I don't see the reason to start the test with 32...
It guesses the start value based on frame count and target size -- this sample was with 3h10m of 720x480 video (no black bars at all) plus full-size two-channel AC3 and subs in two languages...

The formula for guessing a good start value is pretty darn accurate, in my experience. But when using the Newton method it really doesn't matter what you pick to start, it could be 1, it could be 99. It'll (almost) always find the right Q within 2 or 3 passes no matter what the start value.
Reply With Quote
  #50  
07-28-2004, 07:20 PM
Dialhot Dialhot is offline
Free Member
 
Join Date: May 2003
Posts: 10,463
Thanks: 0
Thanked 0 Times in 0 Posts
Okay !
(Mathilda - The professional)
Reply With Quote
  #51  
07-28-2004, 07:22 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
Though, that said, I could certainly add a "Start Q" box if the guessing algorithm turns out to be inaccurate .

I'd rather spend tonight tracking down stray bugs, because it's more or less "finished" and the sooner I can get the source back to robot1 the sooner he can release it and we can start testing .
Reply With Quote
  #52  
07-29-2004, 02:02 PM
Zyphon Zyphon is offline
Free Member
 
Join Date: Oct 2003
Location: London, England (UK)
Posts: 1,035
Thanks: 0
Thanked 0 Times in 0 Posts
Your right SansGrip this does certainly wet my appetite, im looking forward to seeing the further developments.
__________________
Regards.

Michael.
Reply With Quote
  #53  
07-29-2004, 03:07 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
The "new" source (i.e. including the OPV prediction stuff) has been sent back to robot1. There is a small complication in that he uses VC++6 and I use version 7, but I think I made the changes in such a way that he'll be able to compile it too without upgrading his compiler.

Hopefully all will be well and he'll make a release in the next couple of days...

Reply With Quote
  #54  
07-30-2004, 07:27 AM
vmesquita vmesquita is offline
Invalid Email / Banned / Spammer
 
Join Date: May 2003
Posts: 3,726
Thanks: 0
Thanked 0 Times in 0 Posts
Dialhot,

I just tested the subtitle stuff. It turns out that spumux can't mux .sub anymore but... There's submux-dvd (http://ip51cf87c4.direct-adsl.nl/panteltje/dvd/) which can. submux-dvd also comes with a nice subtitle extractor (vob2sub), which grabs subtitles directly in winsubmux format.
I am currently using with a DVD I wanted to add an extra subtitle track, so I'll mux the original subtitle track with submux-dvd, then I'll mux the new subtitle track (srt) with spumux, author with dvdauthor and import in dvd-lab. I'll let you know the results.

EDIT: The old subttile did not show up in the authored DVD (by dvdauthor). It's enabled but did not show up for some reason. I tried to import the pallete and it didn't help (just messed the colors of the new subs)
Reply With Quote
  #55  
07-30-2004, 08:29 AM
Dialhot Dialhot is offline
Free Member
 
Join Date: May 2003
Posts: 10,463
Thanks: 0
Thanked 0 Times in 0 Posts
Quote:
Originally Posted by vmesquita
EDIT: The old subttile did not show up in the authored DVD (by dvdauthor). It's enabled but did not show up for some reason. I tried to import the pallete and it didn't help (just messed the colors of the new subs)
A way to definitely finish with subtile colormap headache : subremap !
Try it, you won't regret it

Just do a "load ifo" then "default" then "save ifo". That's it
Reply With Quote
  #56  
07-30-2004, 11:20 AM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
So I talked to robot1 and he agreed to let you guys give this thing a workout. Remember, this is the very first version of OPV prediction and it might not work all that well (results have varied from 4% off to bang on target). Still, I'd appreciate your testing. No-one is as dedicated as you guys when it comes to testing software .

It's here.

(There was a bug regarding temporary directory creation. I don't know if this executable has the fix in it or not, and can't just recompile the latest source because last night Windows decided to corrupt my registry beyond repair, so I'm currently reinstalling everything. If you get a message about not being able to enumerate a particular directory, that's because it doesn't exist yet. Just create the directory it's complaining about and all should be well.)

Basically you run the DVD-RB Prepare phase, then (without exiting DVD-RB) load RB-Opt. Hit the button to load in the correct REBUILDER.INF, then change whatever settings you like (AVS, CCE, etc.). I always set DC precision to 8, GOP length to 15, and choose the Notch matrix.

Then hit the OPV Prediction button. You'll see a dialog similar to the one I posted a screenshot of earlier. Here's a rundown of the parameters:

Min/max bitrate: You don't need me to explain this one
GOPs per range: The number of GOPs in each "piece" of the sample
Sample size: The percentage of the movie to run for a sample
Safety margin: The calculated target size will be reduced by this percentage before running prediction
Error margin: How close the prediction has to get to perfect before it stops trying. I usually set this to zero and it stops when the "new Q" is the same as the old one. This parameter will probably be removed for the next version.

Then hit "Go" and it'll ask you for the path to your CCE (or EclCCE) executable. It remembers this path so you won't have to tell it again. Then it does its calculations, fires up CCE a few times, and ends up rewriting the DVD-RB files with the correct info.

Close RB-Opt and run the Encode phase in DVD-RB. Wait. Run Rebuild phase in DVD-RB. Check resulting size. Gasp with astonishment.

(Last step optional.)



I obtained a perfectly sized result by using:

Min: 0 Max: 9000 GOPs: 1 Sample: 1 Safety: 2 Error: 0

But, as usual, YMMV. I'd really appreciate as much input as possible. Try it even if you've never used DVD-RB. You might just like it .

In a while I shall post details of the prediction algorithm (it's not really very complicated) and we'll have a go at refining it, maybe. You guys know a lot more than me about file size prediction now...
Reply With Quote
  #57  
07-30-2004, 12:19 PM
incredible incredible is offline
Free Member
 
Join Date: May 2003
Location: Germany
Posts: 3,189
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to incredible
Quote:
Try it even if you've never used DVD-RB. You might just like it
Participating testings is one of my favorite deeds
But Im horrible working in my Job now and so Uääääää

Im shure Ill like that DVD-rb
Reply With Quote
  #58  
07-30-2004, 12:51 PM
bazzy2004 bazzy2004 is offline
Free Member
 
Join Date: May 2004
Posts: 84
Thanks: 0
Thanked 0 Times in 0 Posts
gr8... but 1 questions, just asking... this u can fit 1 movie, on 1 dvd, ace quality.. but is there a way for more then 1??

love to have more then 1 movie on a dvd, n with all the extras and stuff on it

thanx in advance

Bazzy
__________________
im a noob, sorry!
Reply With Quote
  #59  
07-30-2004, 01:48 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
It should be possible to do that in an authoring program. Just use RB-Opt's "global options" to change the target size to 2000mb (or whatever) instead of 4000mb (or whatever). Then encode and rebuild as normal. Do this for both movies.

You'll then need to find an authoring program that can import actual VOBs instead of just separate video/audio/sub streams (I believe there are some that can do it). In the authoring program you can make a VMG menu to choose between the two.

That's all theory. I've not tried it .
Reply With Quote
  #60  
07-30-2004, 01:50 PM
SansGrip SansGrip is offline
Free Member
 
Join Date: Nov 2002
Location: Ontario, Canada
Posts: 1,135
Thanks: 0
Thanked 0 Times in 0 Posts
By the way, please don't distribute this release or the link to it. This is a prerelease version and definitely will change (we're going to implement OPV on a VOB ID basis rather than doing entire title sets, for example).
Reply With Quote
Reply




Similar Threads
Thread Thread Starter Forum Replies Last Post
Bitrates: Problem with preparing phase Encoder Master Video Encoding and Conversion 17 01-15-2005 11:20 AM
DVD-RB / DVD-RB OPT or manual encode? break Video Encoding and Conversion 7 10-20-2004 02:44 PM
KVCD: problems with the prediction phase prior to encoding in TMPENc? Blubear Video Encoding and Conversion 5 07-06-2004 11:52 AM
HeadAC3he: Bad audio Sync, words out of phase from video CheronAph Audio Conversion 11 09-23-2003 05:30 AM
Avisynth: Interlace artifacts or phase-shifting? ozjeff99 Avisynth Scripting 0 04-29-2003 10:15 PM




 
All times are GMT -5. The time now is 07:22 AM  —  vBulletin © Jelsoft Enterprises Ltd