Site hosted by Angelfire.com: Build your free website today!
Converting Menus from DVD to SVCD

By Taberis


This here is a little guide I've put together to help you through the process of converting DVD menus over to SVCD format in order to either have carbon copies of your DVDs or just to spruce up your work a bit. I came up with the basic procedure a long time ago, but I must extend my thanks to the members of the Doom9 MPEG forum for inspiring me to develop these ideas and simplify them incredibly. Keep in mind that this is a 1.0 version of the guide, and I am still doing intense research into ways to make it simpler and better.

The difficulty and amount of time needed to do this depend on the complexity of the original menus from the DVD, but I am working on developing a program that will eventually take care of the process for you.



Programs needed:
Vstrip and Vstrip GUI*
DVD2AVI*
avisynth*
CCE/TMPGEnc
BeSweet & BeSweet GUI
BBmpeg*
Image editing app. (Photoshop, Paint Shop Pro, Paint)**
DVD2SVCD
ChapterXtractor
VCDEasy


* - these programs already come with the DVD2SVCD software bundle, and I advise that you use those versions.

** - You'll need your favorite paint program, we'll be using it in conjunction with DVD2AVI's "save bitmap" command to make the avisynth scripting a lot easier as well as for processing still menus.


Alright, first off we'll need to make a directory to be used throughout the guide (e.g. "D:\AH_MY_GODDESS_2"). In that directory create 3 folders, Motion Menus, Stills, and Transitions. It may also be a good idea to clear your DVD2AVI folder of bitmap captures since we'll be using it.

Authenticate your drive and then start up the Vstrip GUI. Click "Add" on the Input tab. Open your DVD drive and add VTS_01_0. You should get this message;



Obviously thats what we want, so click "Ja"

Bypass the IFO tab, we don't want to use the IFO at all here and if you load it it will throw off the rip majorly. Go to the Output tab and for the output select your main directory that you created at the beginning. Name the output "menu", so that Vstrip should look exactly like this



Eh.. ignore the orange thing in the picture, it is essential that Split by CELL-ID is selected. Then just click run and let it go.




Congrats, step one is complete. Next we need to do some organizing to make our lives easier. Go to your main folder, there should be a bunch of .vob files named "menu_V01C__.vob", "menu_V02C__.vob" and so on. These are all of your individual menus. If there are a lot, god help you, if there are a few, you got lucky. Anyway, we need to separate these and put them in the Motion Menus, Transitions, and Stills folders that you created at the beginning. The easiest way to do this is by clicking "arrange icons by size" and "view details" in explorer. The folder should look something like this;



The simple way to do this is knowing that the stills are the 3 digit numbers, transitions, which usually don't last more than 10 seconds, are the 4 digit numbers, and the motion menus are the 5 digit numbers in KB. Stills will usually be between 100 and 200 KB, transitions usually wont be larger than 10 MB, and motion menus run from there up. Note- this is not entirely to-the-letter accurate or always true, I personally check each in DVD2AVI to be certain, but this is the way it will usually turn out in respect to size.

So basically, we can see that 1, 2, 6, and 7 are motion menus, 4, 3, and 5 are transitions, and 8 - 54 are stills.

Go ahead and move each into their folder.




Now its time to frameserve through DVD2AVI and capture our still menus.

Lets cap the stills first. Make sure that C:\Program Files\DVD2SVCD\DVD2AVI is absolutely clear of previously captured bitmaps. Start up DVD2AVI and click open. Load all of your stills from the Stills folder. Unfortunately, DVD2AVI dosent let you add them all to the list at once, so you have to keep clicking add until they're all in the file list.



Click OK. You should now have all of your stills strung together into one continuous project in DVD2AVI. What we do next is simply scroll through each menu with the > button and capture every menu with "Save Bitmap" (note, you'll have to change the Video > Color Space > YUV 4:2:2 to RGB 24-bit). Thankfully, Save Bitmap is also B on the keyboard.

Once you have all of the stills capped, it will be a good idea to skim through the actual captured bitmaps, because DVD2AVI ocasionally chokes and misses a cap or two. If one is missing just go back and cap it again and it should be alright.

At this point you'll want to create 3 new folders inside your Stills folder, "VOB", "Cap" and "Done". Move all of the VOBs into the VOB folder, and move all of your DVD2AVI captures from C:\Program Files\DVD2SVCD\DVD2AVI into the Cap folder. Leave Done alone for awhile as we'll be using that for the complete, edited stills and still MPEGs generated by VCDEasy.




Celebrate, we're finished with the stills for awhile. Now its time to frameserve the motion menus and transitions. Thankfully, there usually arent too many of these (unlike stills).

Return to DVD2AVI and open the first vob in your motion menu folder. Capture any frame from the menu, we'll need it to determine coordinates of selections, something I'll explain in a little while. It will also be a good idea to pay attention to what kind of menu you're dealing with (i.e. main, extras, scene select).

After you have a cap of the menu, click Save Project. Save it in the Motion Menus folder under its proper name (main1, sceneselect4, etc.). Doing so will help us a lot during authoring. Repeat that with the rest of the vobs in your Motion Menu folder.

Finally, open and save (as project) each transition vob in the transitions folder. You needn't capture any bitmaps from these, simply treat them as any other normal video that you are frameserving through DVD2AVI. Once again, naming the .d2v files according to the transition you are serving will be a huge headache reducer later on. Something to the order of "Main_to_Sceneselect.d2v" would be appropriate.




Time to edit and encode the motion menus. Create a new avisynth script in the Motion Menus folder named according to your first .d2v file. i.e. Main1.avs for editing Main1.d2v. Once again, this will help us incredibly come time to author.

Now we need to add numbers to the menus for use as numerical SVCD selections, since SVCD dosen't support the same kind of selections that DVD does. Basically, every button that was selectable in the DVD is going to have a number next to it when we're done.

Open up notepad and get ready to write down a few values. Open the capture of your first motion menu in paint (these caps should still be in DVD2AVI's folder). Here you should be able to get a good idea of how many selections exist on the menu and such. This is how we use that info; move your mouse over the area where the number "1" will go (the first selection). You should see the coordinates in the bottom left corner of your paint program.



For simplicity's sake, it's a good idea to write down in notepad;

1. Set Up = 64,375

Find the values for the rest of the buttons in the same way, and write them down. Eventually notepad for this menu should look like this;

1. Set Up = 64,375
2. Extras = 64,420
3. Play Video = 650,375
4. Scene Access = 650,420

Good, now do that with the rest of your menu captures.

Save that info, right now we need to learn a bit about avisynth's subtitle filter.
Here is an example of a complete subtitle script for adding the number 1 to the pictured menu.

Subtitle("1.",64,375,0,9999,"Smudger LET",36,$2B2567,$73789B)

Right, and what does that mean to you? Here's the breakdown in order.

Subtitle() obviously, is the main command.

"1." is the character to be subtitled in. In this case, we're using 1s, 2s, 3s, etc.

64,375 is the horizontal and vertical position of the subtitle.

0,9999 is the frames on which to insert the sub. This is useful if your buttons arent always in view throughout the motion menu. Normally, though, 0-9999 is the way to go, since this will insert the sub over the entire playing time of the menu (unless of course it is longer than 9999 frames, but that will only happen if the menu is longer than 5 minutes)

"Smudger LET" is the font name. Its more aesthetically correct to try to make the font as close as possible to the text on the button, but this part is totally up to you.

36 is the font size, again, this depends on how big you want the numbers.

$2B2567,$73789B - these are the halo color and main subtitle color, respectively. They are hexadecimal colors, just like in html, but instead of # you must place a $ sign at the beginning. Once again, it is nice to come close to the color of the text on the button, but this is up to you.

So in other words;

Subtitle("number",x-pos,y-pos,start-frame,end-frame,"font",font-size,$halo-color,$body-color)

This is where we will use the coords in our notepad file to insert the selections. In your Main1.avs or whatever you named it, type the regular mpeg2dec lines and then right after insert your sub scripts. For each number/button/selection, you will need a separate subtitle command, so for the example menu pictured above, the script now looks like this;

LoadPlugin("C:\MPEG2DEC.DLL")
mpeg2source("main1.d2v")
Subtitle("1.",64,375,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("2.",64,420,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("3.",650,375,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("4.",650,420,0,9999,"Smudger LET",36,$2B2567,$73789B)

Preview that in Vdub, and it will look like this;



So as you can see, we've just inserted the needed selections. Do that process with your remaining few motion menus and you'll be done editing completely.

Now, naturally you should resize to 480x480 in avisynth as well, but since we wont be giving these a whole lot of bits, we should really crop overscan. So the completed script for main1 will be;

LoadPlugin("C:\MPEG2DEC.DLL")
mpeg2source("main1.d2v")
Subtitle("1.",64,375,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("2.",64,420,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("3.",650,375,0,9999,"Smudger LET",36,$2B2567,$73789B)
Subtitle("4.",650,420,0,9999,"Smudger LET",36,$2B2567,$73789B)
Crop(24,16,672,448)
BicubicResize(448,448)
AddBorders(16,16,16,16)

Thats it. Do that with the rest of your motion menus and you're halfway there. By the time your done, there should be 1 .avs for each .d2v and each should be named appropriately, e.g. Main1.avs, Main2.avs, Extra1.avs, Extra2.avs.




Start up CCE or TMPG, whichever works for you, and load up each .avs (a batch encode is in order if you have a lot of scripts to encode). Set the max bitrate to 2500, min to 300, and average to 1400 (those are just suggested values, feel free to mess with them all you want. If you have lotsa room, go for avg 2500, but mostly you may want to go lower and maybe even sub-1000). Encode.

If you're familiar with the basics of creating SVCDs, then the next two steps are definately familiar to you, simply use BeSweet to extract and re-encode the audio from each of your VOBs. Then, mux in BBmpeg as a regular SVCD stream.

Ta-dah, you've totally completed your motion menus! We still have to author them, but that comes much later.




Okay, to procrastinate the hard work, we'll do the transitions next (if you have any). Simply do these like any other movie file, frameserve through avisynth (cropped overscan is again a good idea) encode in TMPG or CCE (at a low bitrate) transcode the audio in besweet, and mux in BBmpeg. If the transition dosen't have audio, simply skip BeSweet and mux only the m2v in BBmpeg. To do this uncheck "Multiplex audio" in the General Settings tab and load only your m2v into the input and output files tab. Once all of your transitions are converted, we can move on to stills.

Open your first still menu out of your "stills\caps" folder in paint. All you're going to do here is put the selection numbers in manually in paint instead of in avisynth, so go around your menu with the text tool placing selection numbers next to each button. Once you're done, the menu should look something like this;



This scene select menu already had numbers embedded in it, but to keep the navigation simple, we used the same top to bottom, left to right numbering system to identify the selections.

So, again, repeat that process for all of your still menus, saving each of them in the stills\Done folder under their proper name (sceneselect1.bmp in this case) there is no need to resize these either, VCDEasy will do that for us.

Note: At some point you'll probably come across a bunch of language select stills, each with a different language highlighted. Since SVCD can't really use these types of menus, we'll only leave them in for aesthetic purposes or if your SVCD does have all the languages from the DVD at least the viewer can see what languages are available. At any rate you only want one of the language menus (once again, there will be several all with different languages selected) so pick your favorite and save that. On menus like these where no real selection can be made, there should only be a "1." subtitle, next to the "Back to Main" or "main" button.

Start up VCDEasy.
Go to "Tools" and then "Mpeg Stills"
Make it to look exactly like this



Do not, I repeat, DO NOT select 4/3 under TV Aspect Ratio Correction. For some reason this will really screw our stills up and make them look stretched, in addition to not fitting on the TV screen. We can't deselect "Apply Correction" for some reason, but selecting 16/9 will keep our stills in perfect proportion. I dunno why VCDEasy does this, but it does and this is the only workaround I've found.

Anyway now you'll want to drag all of your bitmaps in the stills\done folder into VCDEasy and let it generate the still menus for you. Make sure the output is in the stills\done folder as well. If you're tight on space, you can lower the Mpeg Size slider, but this will only have a big effect if there are a lot of stills.

Thats it. I mean, you're done editing and encoding the menus. Only one step left, authoring. Unfortunately, if your DVD was real complex, this won't exactly be a breeze. Go have some tea and relax for awhile. Encode your extras and then do your main movie with DVD2SVCD. Come back a few hours later and get ready to finish the job.




Back already? Okay well here we go.
Start VCDEasy. Drag all of your completed motion menus, transitions, and stills into the main window. Then drag your extras and the main movie. In "Options" make the "Time to wait after each Sequence/Segment by default" 0. Then on to Chapters. Start ChapterXtractor and open your IFO. Save the chapter timecodes and then enter them into VCDEasy with the "Create chapter at" function. Don't forget to select the main movie in the dropdown list before entering the chapters of course.

Now for the fun part, "Interactivity". This requires that you know basically how the specific DVD's menu system operates.

Usually, if you have a motion menu, it will play infinitely, so you should select "Play Forever" still menus will usually stay on the screen forever too, in which case you would select "Wait Infinite"
Now, for the numerical and previous/next selections, you basically want to imitate the DVD's selections. Since we edited in the numbers to the menus, this is a mental synch (thats sinch.. not sync). Unfortunately, if there are a lot of menus, you'll have to do a lot of "numeric key" editing. It isnt hard though to get lost in this phaze of editing, so I threw together a VCDImager.org esque chart to show an example of a basic DVD structure redone on SVCD.



So in other words, if your main menu has 4 selections on it and the first is "Play Movie", then you're going to link the numerical selection "1" to your main movie file. If selection 2 is a scene select menu, then you link the numerical selection "2" to the scene select menu or if there is a transition in between, you link "2" to the transition and then program the transition to go to the real scene select menu on timeout. For a more in-depth understanding of all this than I can offer at 3:08 AM on sunday morning, I suggest reading the menu guides on VCDImager.org, they are excellent for understanding complicated menu structures like the ones we are creating.

So, once you have authored all of your menus, transitions, previews, and movies in correctly, you are free to create the image and then burn it. Go try it out on your standalone, and enjoy menus copied in near-absolute perfection.

Note - If you are using 2 CDs then some of your chapters or extras may not be on the same CD as the menu would indicate. In this case, it'd be appropriate to create a simple "Insert next CD" or "This chapter on next disc" image that you could then convert to MPEG still as we did earlier and connect it to all the chapters or extras not available on one disc or the other.

There you have it. There are some extra things to play around with such as IVTCing menus which have been telecined, adding extra seconds to the end of a motion menu to prevent premature stopping on standalones, yaddayaddayadda. Those are topics for a 2.0 version of the guide. Right now, its 3:15 AM, several weeks after I set out to create this blasted guide, and I'm tired as hell. I hope this was useful to all of you and look forward to new developments on the program front and in simplifying the guide and proccess further. Signing out, this has been a guide on copying menus from DVD to SVCD, by Taberis (CyberTab17@aol.com), goodnight everyone.




Go Back to the main site.