LinuxQuestions.org
Review your favorite Linux distribution.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxAnswers Discussion
User Name
Password
LinuxAnswers Discussion This forum is to discuss articles posted to LinuxAnswers.

Notices


Reply
  Search this Thread
Old 11-03-2004, 05:29 PM   #121
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48

Version 0.14 has been released. Get it here.

The homepage has also been updated with new documentation. Follow the directions there for installation.

Please let me know if you have any problems; there are a lot of new features in this release, and new features usually means new bugs. Also, if some of you would be so kind as to email me a copy of your ~/.tovid/stats file after you have encoded some videos, that would be great - it'll help me to figure out more accurate estimates of disk space requirements. You can send email to wapcaplet99 at yahoo dot com.

Enjoy!
 
Old 11-03-2004, 05:44 PM   #122
Mysil2
LQ Newbie
 
Registered: Oct 2004
Location: Norway
Distribution: Fedora Core 2
Posts: 22

Rep: Reputation: 15
Wohoo

Good job

I have begun encoding a 1,5 hour movie now. Have to go to bed now, so I will see how it went out in about 6,5 hours...

I see you sat the parameter "-M 2" in mpeg2enc. Tomorrow I will try to compare if "-M 3" is faster. It may be, because at the moment the CPUs uses between 50-60% load.
 
Old 11-03-2004, 06:44 PM   #123
sk545
Member
 
Registered: Aug 2002
Posts: 312

Rep: Reputation: 30
Very cool, here are some first impressions:

-The idvid script is really cool, however its missing one important thing: Identification of the codec that the video has.

- I see now that there is a -ntsc and -pal option, what does the script do as defualt if those are not specified?

- The estimate of disk space is way cool. However it is easy to miss. Maybe it could be in bold or at the bottom? Plus it would be nice to have it report in megabytes rathers than K. Dunno if thats possible, but ' ls -h' does that on the command line.

- Any way to have it so it doesn't crash if one forgets to put in a output file? It could just use a default output name or something..

-Does the ~/.tovid directory get made after we encode at least one movie? Because i don't see it after just installing tovid.

- The biggest 'problem' for me would be that it takes very long to encode. A 700mb avi (codec=DX50) is taking me around and estimated 13hrs on a 1gz computer as reported by the script. Is this because of that ' -nice' option passed to mplayer? Or is it the options that i used:

$ tovid -ntsc -svcd -full -normalize super.avi supertovid

I will post more later on, but thats just the first impression. Overall its much cleaner than the previous version. Great job.

Last edited by sk545; 11-03-2004 at 06:48 PM.
 
Old 11-03-2004, 07:25 PM   #124
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48
Quote:
Originally posted by sk545
The idvid script is really cool, however its missing one important thing: Identification of the codec that the video has.
Yeah, I'll try to get that in the future. Mplayer doesn't always report anything useful for this; for MPEGs, it usually gives a video format of "0x100000002" or something.

Quote:
I see now that there is a -ntsc and -pal option, what does the script do as defualt if those are not specified?
NTSC is default. Those were actually there in the last release also.

Quote:
The estimate of disk space is way cool. However it is easy to miss. Maybe it could be in bold or at the bottom? Plus it would be nice to have it report in megabytes rathers than K. Dunno if thats possible, but ' ls -h' does that on the command line.
Yeah, I'll see about making it more prominent. Megabytes wouldn't be too hard either.

Quote:
Any way to have it so it doesn't crash if one forgets to put in a output file? It could just use a default output name or something..
I'll try to. Now that the other options are preceded by "-" it shouldn't be hard to find out which arguments are the infile and outfile, and it'd be easy to notice if one's missing.

Quote:
Does the ~/.tovid directory get made after we encode at least one movie? Because i don't see it after just installing tovid.
After encoding. The stats file is currently the only thing that will go in there.

Quote:
The biggest 'problem' for me would be that it takes very long to encode. A 700mb avi (codec=DX50) is taking me around and estimated 13hrs on a 1gz computer as reported by the script. Is this because of that ' -nice' option passed to mplayer?
If it's a movie-length video (~2 hours) then 13 hours for encoding sounds about right, for 1Ghz at SVCD resolution. The 'nice' option mostly makes it possible to be doing other things while it's encoding; without it, most computers, especially 1Ghz ones, would get very sluggish during encoding. If you aren't burdening the CPU with a lot of other stuff, the 'nice' part doesn't have much effect on encoding time as far as I can tell. Once we get some stats collected, we'll have a better idea about this - that's the main reason I included the ~/.tovid/stats output, since to date I've only had very vague ideas about how long encoding should take.
 
Old 11-03-2004, 08:19 PM   #125
sk545
Member
 
Registered: Aug 2002
Posts: 312

Rep: Reputation: 30
Thx for replying.

I started encoding a smaller video, since 13hrs is quite a bit. Will let you know how that goes.

Right now, the obvious 'bug' seems to be the percentage done, which is over 100%, more like 294%.

/edit: Got one video done, here are the stats:

samtovid.mpg 224560 k, 1369 secs svcd ntsc, 3600 KB/sec max -> 163 KB/sec. Took 1:38:54 to encode.

The original movie was (160 MB):

$ tcprobe -i samtovid.avi
[tcprobe] RIFF data, AVI video
[avilib] V: 29.970 fps, codec=DIV3, frames=41056, width=352, height=240
[avilib] A: 48000 Hz, format=0x55, bits=0, channels=2, bitrate=96 kbps,
[avilib] 41042 chunks, 16439040 bytes, CBR
[tcprobe] summary for samtovid.avi, (*) = not default, 0 = not detected
import frame size: -g 352x240 [720x576] (*)
frame rate: -f 29.970 [25.000] frc=4 (*)
audio track: -a 0 [0] -e 48000,0,2 [48000,16,2] -n 0x55 [0x2000] (*)
bitrate=96 kbps
length: 41056 frames, frame_time=33 msec, duration=0:22:49.903


Also, the script ends with the following for some reason:

/usr/local/bin/tovid: line 678: [: -v: unary operator expected
Done. Thanks for using tovid!

Last edited by sk545; 11-03-2004 at 08:36 PM.
 
Old 11-03-2004, 09:14 PM   #126
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48
Line 678 is a quick thing I threw in at the last minute; must have gotten the syntax wrong. You can just change the line to:

Code:
rm "$LOG_FILE"
which will cause the log file to always be deleted. Or, you can comment out the line (put a # at the front) to always leave the log file there when encoding finishes (probably a better idea for now, in case you want to check it for errors after encoding is done - then you can manually delete it). The log file is named with the same name as the output file, with a .log extension. It'll usually be fairly short, unless you specified the -debug option, in which case it'll be fairly large (~1MB or more, depending on what you're encoding).

When the encoding started, was a message printed like: "Reported running time is 0 seconds. Progress report will be inaccurate"? If not, it's probably just an all-too-common case of the reported running time being wrong, which will cause the progress report to be wrong also. Until I can find a way to get reliable running time reports, that'll remain a problem.
 
Old 11-03-2004, 09:47 PM   #127
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48
Another quick fix for a line that worked before, but seems to have stopped working in this version: line 389, change this part:

Code:
-e \"$OUT_PREFIX.$SUF\" || -e \"$OUT_PREFIX.mpg\" || -e \"$OUT_PREFIX.mpa\"
to read:

Code:
-e "$OUT_PREFIX.$SUF" || -e "$OUT_PREFIX.mpg" || -e "$OUT_PREFIX.mpa" || -e "$BASE_PREFIX.mpg"
(The full line is not shown here, since left and right square brackets are converted into some wiki-syntax when I post it)

Note that the backslashes have been taken out, and a new condition added. If you don't feel like fixing it, it's no big deal - but you will probably not be warned about overwriting existing files.

Last edited by wapcaplet; 11-03-2004 at 09:51 PM.
 
Old 11-04-2004, 03:52 AM   #128
Steel_J
Member
 
Registered: Oct 2004
Location: Montreal, Canada
Distribution: Ubuntu 16.04 LTS
Posts: 359
Blog Entries: 1

Rep: Reputation: 31
I am still here!

Hi wapcaplet,

Sorry if I did not post in a while.

Between work, all those things I do on computers and taking out the garbage there is much to do. Ho and there's the girlfriend that requires attention once in a while.

Kidding aside, actually what I have been doing is reading all of this thread with great attention. Then I went trough your website's documentation. I have been studying and experimenting Linux bash scripting with succes and wrote few scripts to warm me up.

Also continued a lot more research and testing in all the Linux audio video tools and I have been writing and organizing notes like crazy.

I played Doom3 also for fun!

All this just so you know I said I was going to write a script based on my DVD9toDVD5 guide and I am working on it.

Figure I would call it: DeeVRequant. Like it???

For now what I have takes the main title of an already ripped (with DVD::Rip) DVD video disc and one audio track and makes it all fit on one DVD-R 4.7. No ripping,No menu, no authoring.

Now that is temporary but I am working on one thing a a time.

My end objective would be to have the script take the whole DVD, process it and spit out a shrinked clone of itself, menus and all audio but for now I will be content if I get it to :

1) rip the main tilte and all it's audio tracks automatically
2) requant all of it
3) create a new DVD structure
4) author automatically with chapters at a fixed interval and a simple menu composed of a pre determined background image and a Play button.

Dreaming aside I have many Ideas but I would appreciate suggestions for the script portion to rip the DVD to disk (Main tille and all audio tracks) without the help of other software like DVD::Rip.

I will repost with new as soon as I can.

I installed your script, the latest version. Great installer, I like it. Flawless.

Now maybe I missed something but I have a question: If I want to make a DVD out of an AVI how exactly am I going to specify to tovid that I wannt the output to fit on a single DVD-R 4.7Gig. Is it done automatically.

For VCD or SVCD's it's mostly a non issue since they get splitted in 700mb chunks, but I dont want my DVD movies to use more than one DVD disc.
 
Old 11-04-2004, 04:25 AM   #129
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48
Steel_J - great to hear that you are getting the hang of scripting (and still leaving time for the more exciting things in life ). Start with small goals; don't try to write a script to do everything at once. Focus on each of the things in order, and get one of them working before moving to the next, and I think you'll be successful.

I'm glad you like the new version of tovid!

Quote:
Now maybe I missed something but I have a question: If I want to make a DVD out of an AVI how exactly am I going to specify to tovid that I wannt the output to fit on a single DVD-R 4.7Gig. Is it done automatically
Excellent question. I've ignored this possibility so far, under the assumption that practically all movies will fit on a 4.7G DVD. So far, experience has borne me out - most of the 2-hour movies I've encoded end up being around 2G. So even for a nearly four-hour movie like, say, Ben Hur, you should have no trouble getting it to fit on a single DVD.

However, now that denoising is always done, there's a chance that quality will be improved enough that 4.7G isn't enough for some movies. There may be a way to get mplex to split the output (like it does with VCD/SVCD), but somehow I doubt it. I guess the best I can offer is: if it happens, let me know!
 
Old 11-04-2004, 10:43 AM   #130
sk545
Member
 
Registered: Aug 2002
Posts: 312

Rep: Reputation: 30
Quote:
All this just so you know I said I was going to write a script based on my DVD9toDVD5 guide and I am working on it.
What exactly does dvd9 to dvd5 mean?
Quote:
I installed your script, the latest version. Great installer, I like it. Flawless.
Yeah, the installer is great, but i would tweak it like so:

1) Change the installer script's name from 'configure' to something like 'install.sh'. I think it would be better since 'configure' is pretty much something thats done to a source, then you do make and make install. It would just be less confusing since people are so used to doing ./configure, make, make install.

2) I don't know how hard this would be, but it would be nice for the install script to check for the versions of mplayer, mjpegtools, etc binaries and tell one if they are too old or not. This would at least have people installing the updated versions before reporting any bugs due to outdated binaries.

/edit: Here some more info on kvcd and such:

http://dvdripping-guid.berlios.de/

http://dvdripping-guid.berlios.de/forum/index.php

There isn't much activity going on there though, and most of their scripts haven't worked for me. Still i think its just good for knowlege.

Another one:

http://www.kvcd.net/forum/

Last edited by sk545; 11-04-2004 at 11:14 AM.
 
Old 11-04-2004, 01:56 PM   #131
Steel_J
Member
 
Registered: Oct 2004
Location: Montreal, Canada
Distribution: Ubuntu 16.04 LTS
Posts: 359
Blog Entries: 1

Rep: Reputation: 31
Many answers

Quote:
What exactly does dvd9 to dvd5 mean?
I was referring to a guide that I wrote that can be found here : http://www.linuxquestions.org/questi...t=dvd9+to+dvd5

It's purpose is to backup your DVD movies on DVD-R's.

DVD9 TO DVD5 is an expression to describe the process of backing up a commercial DVD (9 gigabytes of space on it by design) to a DVD-R witch as only 4.7 gigs on it. So basically you have to shrink the video stream to fit on a smaller medium.

The shrinking is done via a process called requantization and involves processing the mpeg2 stream matrix so that data is removed up to a certain ratio and a new matrix is rewritten.

The result is a smaller mpeg2 elementary stream (M2V) of a very nice quality all done very fast (around 15 minutes for a 2 hours movie) and without any kind of re-encoding.

On Windows many programs do this, DVDShrink being a very popular one, but it's source is not public.

wapcaplet and me had a conversation in another thread about my guide because he was interested in using it as a part of his Tovid Suite of utilities. I agreed to turn it into a working script to help him out and all of you Linux lovers out there.

Quote:
Change the installer script's name from 'configure' to something like 'install.sh'.
I agree, hahahaha! Imagine my surprise when I used the ./configure and got greeted with a welcome message and a simple step by step install instead of the ususal mile long ./configure outputs. It would make sense to give it a different name / procedure. Never the less, wapcaplet does great work and he works fast!

As for the version number indications. It would let the users prevent the earlier problems reported with all the different versions earlier in the thread.
 
Old 11-04-2004, 02:14 PM   #132
sk545
Member
 
Registered: Aug 2002
Posts: 312

Rep: Reputation: 30
thx for explaining, Steel_J. As for dvd9's, they are dual layered, but not dual-sided, correct? In other words, one side of dvd9 can hold ~9gb of data since its dual layerd?

Sorry, i always confuse dual layered with dual sided.

Yeah, i think the install script should just install tovid. But, it should put a 'uninstalltovid.sh' in /usr/local/bin separately. This way we could delete the untarred tar.gz directory of tovid, and still be able to uninstall tovid if necessary. Thats just how would do it anyways. Then again, having the option of installing/uninstalling in the main install script would be easier if one had downloaded a new version of tovid. They would just have to call the install script which would both uninstall the old version and install the new one. Meh, guess its better to have both. lol.

Last edited by sk545; 11-04-2004 at 02:21 PM.
 
Old 11-04-2004, 03:02 PM   #133
Steel_J
Member
 
Registered: Oct 2004
Location: Montreal, Canada
Distribution: Ubuntu 16.04 LTS
Posts: 359
Blog Entries: 1

Rep: Reputation: 31
Well actually there is a way to remember easily fo you.

DVD-10 --- 8.75 GB. They are Double Sided Single Layered.

DVD-9 --- 7.95 GB. They are Single Sided Dual Layered

So in essence you had it correct. DVD-9 are the most common disc you will find in your local video rental store. DVD-10 are met ocasionnaly, but these seem to be an older method of doing things. I have a few of them and you have to get up in the middle of the movie to flip over the disc in the player lol.
 
Old 11-04-2004, 04:09 PM   #134
sk545
Member
 
Registered: Aug 2002
Posts: 312

Rep: Reputation: 30
hrm..then i guess the next question is that what is a double-sided AND dual-layered dvd called...if it exists...

Last edited by sk545; 11-04-2004 at 04:18 PM.
 
Old 11-04-2004, 04:33 PM   #135
wapcaplet
LQ Guru
 
Registered: Feb 2003
Location: Colorado Springs, CO
Distribution: Gentoo
Posts: 2,018

Original Poster
Rep: Reputation: 48
Steel_J - A tovid user sent me his own script for doing DVD backup. Let me know if you're interested in seeing it - it might give you some ideas that you could build on.

I've submitted tovid to freshmeat, so it will now show up whenever anyone's searching for video conversion software, and will appear briefly on the main freshmeat page with each new release. Just for kicks, I tried a Google search for "tovid" - the tovid homepage is the first result. I hope that means nobody else is using the name! It'll be interesting to see whether the download statistics on sourceforge go up after being announced on freshmeat. I've already had one bug-report filed on sourceforge since the announcement.

Regarding the name of the 'configure' script - I named it that in anticipation that it may eventually be more of a configuration utility than an installer. 'install' may be better. I'll have to ponder on that.

Version-checking of the various utilities should certainly be enabled where it's needed. Right now, the only version dependencies that I know of are dvdauthor (>=0.6.0) and possibly ImageMagick (>=v6).

I've just tried another DVD-quality movie encoding using the -twopass option; once again, it failed with a broken pipe after working for a couple hours. I'm considering my options for ways to handle this. I'd like to eliminate both the -fps and -twopass options, and have the script automatically resolve the frame-rate issues that necessitate having them now. I'd simply love to find a one-size-fits-all encoding command - mencoder by itself can do almost everything, including frame-rate fixing, resizing, and denoising; I just need to find a rock-solid way to get MPEG video out of it. I'm thinking of trying ffmpeg, to see if it can handle any of mencoder's output formats (though I'd hate to introduce another dependency); ideally I'd have mencoder do all of the encoding. It'd probably be a lot faster and cleaner that way. That's my top priority at the moment - ironing out all the inconsistencies in video encoding.

Then, I think I want to see if I can convince Lowry Digital to release the proprietary (and patented) code they used to clean up Indiana Jones and the Star Wars trilogy as open source. Wouldn't it be cool if tovid could do this? Of course, you'd need to run tovid on a cluster of ~100 high-end machines with a few hundred TB of disk space... oh, and it would include an option to replace all guns with walkie-talkies. Maybe someday algorithms as good as that will make their way to open source. We can dream, right?
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Convert AVI to either DVD, VCD or SVCD format linux-rulz Linux - General 13 12-27-2011 01:29 PM
XVID, VCD, SVCD and so on. How to?? Thakowbbery SUSE / openSUSE 7 10-31-2005 03:39 PM
Encoding video for VCD and DVD wapcaplet LinuxQuestions.org Member Success Stories 3 08-01-2004 01:03 PM
SVCD, VCD, DVD editing asalford Linux - Software 19 07-16-2004 04:47 PM
converting *.avi file to *.vcd (or svcd) zstingx Linux - General 1 10-07-2003 06:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General > LinuxAnswers Discussion

All times are GMT -5. The time now is 10:42 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration