View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 30 posts ] 
Go to page 1, 2  Next

Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Sun Apr 13, 2008 10:39 am 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
About 80% of the shows I record are HDTV programs and I would like to be able to compress them down with a codec that can handle HDTV resolutions.

Can the myth2xvid or myth2xvid3 scripts be used to start with a 1920x1080 HDTV recorded program, compress it with xvid (to save hard drive space) and produce a full 1920x1080 HDTV output file? Or is xvid limited to standard definition (720x480)?

If xvid can't handle HDTV, can the script easily be modified to produce an h.264 1920x1080 HDTV file?
If an h.264 version could be created, we could call it myth2h264! :D

Eric

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 13, 2008 6:52 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Here is my myth2xvid that converts video to 960x540 using a bitrate of 1900 and copies the ac3 audio so you don't loose the full 5.1. The resolution and bitrate can be changed to whatever you want.

Britney


Top
 Profile  
 
 Post subject: 960x540?
PostPosted: Mon Apr 14, 2008 9:01 am 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
Thanks for the response.

960x540? Is that a PAL resolution?
Are you saying that all I have to do with the myth2xvid script is change the resolution of the raster to 1920x1080?

The goal is to output a compressed file with the same resolution as the input file - to maintain HDTV resolution but drop the size of the output file.

I wonder what to do about the other HDTV standard - 1280x720 (aka 720p)? That complicates things a bit. The script would have to be able to determine what the resolution of the recording is and then set the appropriate output resolution to match.

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 14, 2008 11:11 am 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
960x540 is just half of 1920x1080 and 75% of 1280x720 and is a decent compromise between size a quality for what I use it for. It still looks quite good on my 50" 1080p set. HD encoded using this still looks slightly better than DVD to my eyes.

Here is a version that will not do any scaling of the source file. I haven't tested it but it should do what you want. You may need to increase the bitrate to get the quality you are after but that will also increase the file size.

I would be curious as to what kind of file size savings you see with this.

Britney


Top
 Profile  
 
 Post subject: will try!
PostPosted: Mon Apr 14, 2008 9:17 pm 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
Thanks Britney. I will try it.

Even though I've been using Knoppmyth for 2 years, this will be the FIRST time I've tried to create/use a User job!

I put this file in the /usr/local/bin directory, correct?
To call this, I put this in User Job #1, correct?
The User Job #1 Command line should be "myth2xvid -cut "%DIR%" "%FILE%"?

I don't want to cut commercials at this time so I didn't put the "-cut" in the command line. Is that the right way to eliminate commercial cutting?

Thanks!
Eric

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 14, 2008 10:19 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Copy it to /usr/local/bin

You can change the name of User Job #1 to something like "Encode to xvid"
The command line should be /usr/local/bin/myth2xvid "%FILE%" "%TITLE% - %SUBTITLE%" "%CHANID%" "%STARTTIME%"

If you don't want to use the cut list you will need to change the USECUTLIST option in the script.

You might also need to make the script executable.

Britney


Top
 Profile  
 
 Post subject: user job didn't go
PostPosted: Tue Apr 15, 2008 7:55 am 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
Hi,

I set up the user job command scirpt as I noted in my previous post and scheduled an overnight recording-transcode of American Experience from PBS last night. The transcode part didn't produce a file in /myth/video, so I guess it didn't run. Perhaps it was the "make the script executable" requirement?

I just searched for how to make a script executable. I found this:
Make the scripts executable using command 'chmod +x *.sh'

So, I guess I just need to type "chmod +x /usr/local/bin/myth2xvid.sh"?
I would guess that I need to be logged in as root to make this chmod change?

Eric

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject: Re: user job didn't go
PostPosted: Tue Apr 15, 2008 1:24 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
neutron68 wrote:
So, I guess I just need to type "chmod +x /usr/local/bin/myth2xvid.sh"?
I would guess that I need to be logged in as root to make this chmod change?
Eric


Yes that it it.

Britney


Top
 Profile  
 
PostPosted: Tue Apr 15, 2008 9:26 pm 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
Ugh. Another transcode to xvid job failed. The mythweb page shows the status of the job as failed and gives the following comment: "ERROR: Unable to find executable, check backend logs"

I made all the suggested changes
1.) chmod command,
2.) replaced the command line with "/usr/local/bin/myth2xvid "%FILE%" "%TITLE% - %SUBTITLE%" "%CHANID%" "%STARTTIME%""

Here's what the mythbackend.log file shows:
Code:
2008-04-15 22:00:11.913 JobQueue: Started "Transcode to XviD" for "Frontline" recorded from channel 1202 at Tue Apr 15 21:00:00 2008
sh: /usr/local/bin/myth2xvid: No such file or directory
2008-04-15 22:00:11.944 JobQueue Error: User Job '/usr/local/bin/myth2xvid "1202_20080415210000.mpg" "Frontline - SUBTITLE%" "1202" "20080415210000" ' failed, unable to find executable, check your PATH and backend logs.
2008-04-15 22:00:11.945 JobQueue: Current PATH: '/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin'


The script file I made is called myth2xvid.sh. Is the mismatch between the command line in the job list and the actual file name the problem?

I decided to change the name of the file to myth2xvid, so it matches the other myth2bla scripts in that directory.

When I look at the directory listing, I see that my script has the word staff in it's details. Is that ok?
Code:
root@mythtv:/usr/local/bin# ls -l myt*
-rwxr-xr-x 1 root staff 11118 Apr  3 22:40 myt2xvid3
-rwxr-xr-x 1 root root  14186 Dec  6  2006 myth.rebuilddatabase.pl
-rwxr-xr-x 1 root root  10650 Mar  5  2006 myth2ipod
-rwxr-xr-x 1 root staff  1959 Apr 14 22:20 myth2xvid
-rwxr-xr-x 1 root root   3116 Dec  6  2006 myth_archive_job.pl
-rwxr-xr-x 1 root root   1908 Mar  5  2007 mythbackup
-rwxr-xr-x 1 root root   1754 Feb  1  2006 mythbackup.old
-rwxr-xr-x 1 root root   6220 Dec  6  2006 mythencode.pl
-rwxr-xr-x 1 root root     66 Dec 14  2006 mythlink.sh
-rwxr-xr-x 1 root root   3562 Dec  6  2006 mythmaillog.pl
-rwxr-xr-x 1 root root   6511 Dec  6  2006 mythname.pl
-rwxr-xr-x 1 root root  16256 Dec  6  2006 mythrename.pl
-rwxr-xr-x 1 root root   2325 Mar  5  2007 mythrestore
-rwxr-xr-x 1 root root   1486 Dec 30  2006 mythrestore.old

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Last edited by neutron68 on Tue Apr 15, 2008 9:30 pm, edited 1 time in total.


Top
 Profile  
 
PostPosted: Tue Apr 15, 2008 9:30 pm 
Offline
Joined: Thu Mar 25, 2004 11:00 am
Posts: 9551
Location: Arlington, MA
neutron68 wrote:
The script file I made is called myth2xvid.sh. Is the mismatch between the command line in the job list and the actual file name the problem?

Yes. Correct the command line.

Unlike MS-Windows executable names in Unix are exact. If the name is xyz.sh, or xyz.pl, or xyz.py that is what you use.


Top
 Profile  
 
 Post subject: overnight test worked
PostPosted: Wed Apr 16, 2008 8:05 am 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
I made the noted changes and an overnight recording was successfully transcoded into an xvid avi file. The transcode started at 4am and finished at 8am. I was not able to see what the resulting file looks like yet. I'll do that tonight.

In the myth2xvid script, I set the bitrate at 5000. The original mpeg2 recording from PBS was a 6GB file. The transcoded xvid file is a 12GB file. The goal is to end up with a smaller file than the original, so I'll have to see if I can make adjustments to this process!

Eric

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject:
PostPosted: Wed Apr 16, 2008 8:47 am 
Offline
Joined: Mon Jul 31, 2006 10:41 pm
Posts: 149
If there is no subtitle then a previous re-encoded file will be overwritten.


Top
 Profile  
 
 Post subject: how to fix?
PostPosted: Wed Apr 16, 2008 9:15 am 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
mythedoff wrote:
If there is no subtitle then a previous re-encoded file will be overwritten.

I think the show does have a subtitle to it. The original file in the /myth/pretty directory is "Frontline - 2008-04-16, 3-00 AM - Sick Around the World.mpg".
It looks like the subtitle of this one is "Sick Around the World".

There is an AVI file in the /myth/video folder from the transcode. It's called "Frontline - SUBTITLE%.avi".
Are you saying that there was another file and it got deleted? Please elaborate.

So what part of the process needs to be fixed? The script? The command Line?

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 
 Post subject: Re: how to fix?
PostPosted: Wed Apr 16, 2008 12:39 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
neutron68 wrote:
There is an AVI file in the /myth/video folder from the transcode. It's called "Frontline - SUBTITLE%.avi".

Check your command line. I think there is a quote missing or there is an extra quote because the SUBTITLE should be the subtitle of the show it is encoding.
Code:
/usr/local/bin/myth2xvid "%FILE%" "%TITLE% - %SUBTITLE%" "%CHANID%" "%STARTTIME%"


Quote:
Are you saying that there was another file and it got deleted? Please elaborate.

He is saying that if there is a file in the /myth/video already named the same as the new file being encoded it will be overwritten. I really need to have the script do a check and not overwrite the existing file. In the meantime if you use this command it should reduce the chance of having the same name.
Code:
/usr/local/bin/myth2xvid "%FILE%" "%TITLE% - %SUBTITLE% - %STARTTIME%" "%CHANID%" "%STARTTIME%"


Britney


Top
 Profile  
 
 Post subject: Re: how to fix?
PostPosted: Wed Apr 16, 2008 1:16 pm 
Offline
Joined: Tue Mar 28, 2006 8:26 pm
Posts: 804
Location: Minneapolis, MN
Thanks all for your advice and assistance thus far! :)

brfransen wrote:
Check your command line. I think there is a quote missing or there is an extra quote because the SUBTITLE should be the subtitle of the show it is encoding.
Code:
/usr/local/bin/myth2xvid "%FILE%" "%TITLE% - %SUBTITLE%" "%CHANID%" "%STARTTIME%"

Britney

Yes, I'll recheck the command line. I hope its not a silly mistake like that. :oops:

Any thoughts about the xvid file being 2 times the size of the original HDTV mpeg2 file (which has a bitrate of about 14 mb/s, by the way)?
I expected an xvid file with a bitrate of 5 mb/s (script set for 5000) would be considerably smaller, but it wasn't.

Eric

_________________
KnoppMyth R5.5, Asus A8N-VM CSM (nvidia 6150 onboard video), AMD Athlon 64 dual-core 4200+, two 1GB sticks DDR 400, HD-3000 HDTV card, PVR-150 card, Iguanaworks RS-232 IR receiver/transmitter, Pioneer DVR-110 DVD burner


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 30 posts ] 
Go to page 1, 2  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 23 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu