Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > Avisynth Usage

Reply
 
Thread Tools Search this Thread Display Modes
Old 28th April 2006, 15:50   #1  |  Link
Prysme
Registered User
 
Join Date: Mar 2003
Posts: 15
How to 1080i to XVID 720p ?

Hello,

I'm trying to find a way to resolve two issues in the same time
- reduce size of a 1080i stream
- deinterlace the "i" into a "p" offline in order to not have a overhead during the playback

My goal is to read the result on a HITACHI projector with a 720p matrix what ever the original fps, but I don't want to deinterlace at runtime during the playback.

After many tries with mencoder and plenty command lines, I am giving up ... I am really confused about those thing telecine, IVTC, deinterlace, decimate and so on ...
Each try gives me a jerky video (bad fps) or a ugly one (bad deinterlacing) ...

Let's take this example
ftp://ftp.heise.de/pub/ct/spezial/emotion.mpg

Could someone help me with this sample : 1080i to xvid 720p ?

Cheers,
Prysme.
Prysme is offline   Reply With Quote
Old 28th April 2006, 16:29   #2  |  Link
MrTroy
Registered User
 
Join Date: Apr 2005
Posts: 224
Search the AviSynth subforum, there are numerous threads about this.
MrTroy is offline   Reply With Quote
Old 28th April 2006, 17:17   #3  |  Link
Prysme
Registered User
 
Join Date: Mar 2003
Posts: 15
Quote:
Originally Posted by MrTroy
Search the AviSynth subforum,
I did it of course
But I don't have found a solution to my issues, that's why I am asking for an example with this sample.

Quote:
Originally Posted by MrTroy
there are numerous threads about this.
Perhaps my topic has to be moved to the avisynth section, is there a moderator to do it?
Prysme is offline   Reply With Quote
Old 28th April 2006, 19:14   #4  |  Link
MrTroy
Registered User
 
Join Date: Apr 2005
Posts: 224
OK, here you go.
First, make a .d2v out of your stream with DGIndex (there really ARE dozens of threads about that).

Then use this AviSynth script with your favourite encoder.

Code:
LoadPlugin("C:\Program Files\DGIndex\DGDecode.dll")
video=MPEG2Source("YourFile.avs")
ac3=NicAC3Source("YourAC3File DELAY -xxxms.ac3",channels=6).DelayAudio(-0.xxx)
wav=GetChannel(ac3,1,3,2,6,4,5)
AudioDub(video,wav)
DoubleWeave()
PullDown(0,3)
AssumeFPS(24,sync_audio=true)
SSRC(48000)
Crop(0,0,0,-8)
Spline36Resize(1280,720)
MrTroy is offline   Reply With Quote
Old 28th April 2006, 20:02   #5  |  Link
blubberbirne
Registered User
 
Join Date: Sep 2004
Location: Germany, Hamm
Posts: 161
I used this script

Code:
LoadPlugin("D:\DVDSoft\dgmpgdec\dgdecode.dll")
LoadPlugin("C:\Programme\AviSynth 2.5\plugins\TIVTC.dll")

MPEG2Source("file.d2v")
tfm().tdecimate()
Lanczos4Resize(1280,720,0,0,1920,1080)
Works perfect for me

Last edited by blubberbirne; 28th April 2006 at 20:08.
blubberbirne is offline   Reply With Quote
Old 28th April 2006, 23:03   #6  |  Link
MrTroy
Registered User
 
Join Date: Apr 2005
Posts: 224
Quote:
Originally Posted by blubberbirne
I used this script

...

Works perfect for me
That script doesn't handle the audio, doesn't take care of the redundant 8px in 1080i streams and uses a resize method that's actually meant for upscaling instead of downscaling.

Needless to say, I think Prysme would do better using my script.
MrTroy is offline   Reply With Quote
Old 29th April 2006, 00:45   #7  |  Link
dukey
Registered User
 
Join Date: Dec 2005
Posts: 560
do reduceby2 or whatever it is
and encode it at 960x544
That will do a perfect deinterlace, although will be a bit lower resolution than 1280x720 .. but you wont notice much diff tbh
dukey is offline   Reply With Quote
Old 29th April 2006, 02:29   #8  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
MrTroy: your script is not adaptive to floating pulldown patterns. It involves a 23.976 -> 24.000 fps audio speedup with audio recoding (which is always sub-optimal! especially with AC3). Spline32Resize() is not my favourite resizer. Lanczos does a pretty well job one downscaling IMO.

also blubberbirne's script takes care of the 1088 -> 1080 thing.

I'd prefer blubberbirnes script in the case of NTSC-Film, cause it leaves the audio as it is.

Of cause there are many other possibilitys how to deal with 1080i contents. The possibilities are the same like in the case of 480i or 576i.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 29th April 2006, 08:09   #9  |  Link
MrTroy
Registered User
 
Join Date: Apr 2005
Posts: 224
Quote:
Originally Posted by scharfis_brain
MrTroy: your script is not adaptive to floating pulldown patterns. It involves a 23.976 -> 24.000 fps audio speedup with audio recoding (which is always sub-optimal! especially with AC3). Spline32Resize() is not my favourite resizer. Lanczos does a pretty well job one downscaling IMO.
I have never come across a 1080i broadcast with floating pulldown. But you're correct of course: it IS possible.
As for the resizing: I did some comparative tests and I prefer Spline resizing for this job. Of course, that's just my preference.
You're correct that with this script, the audio has to be recoded. But myself I always recode the audio anyway: broadcast streams are 384kbps, not really suitable for making a reasonably small XviD.
Quote:
also blubberbirne's script takes care of the 1088 -> 1080 thing.
Heh, stupid of me, I didn't see it.
MrTroy is offline   Reply With Quote
Old 29th April 2006, 09:57   #10  |  Link
scharfis_brain
brainless
 
scharfis_brain's Avatar
 
Join Date: Mar 2003
Location: Germany
Posts: 3,605
Reencoding AC3 is nonsense if you want to make an HDTV AVI File, because why HD-Video and SD-Sound?

Also reencoding AC3 has some weird disadvatages like bit depth etc.
you need to decode AC3 with at least 24bit and then you need to encode with an encoder that accepts at least 24bits.
This is why AC3 can virtually store much higher bitdepths that 16bit.
SO with nicaudio you are loosing precision, with reencoding even more.
__________________
Don't forget the 'c'!

Don't PM me for technical support, please.
scharfis_brain is offline   Reply With Quote
Old 29th April 2006, 13:26   #11  |  Link
MrTroy
Registered User
 
Join Date: Apr 2005
Posts: 224
Quote:
Originally Posted by scharfis_brain
Reencoding AC3 is nonsense if you want to make an HDTV AVI File, because why HD-Video and SD-Sound?
In that case you could also say: reencoding to XviD is nonsense, why convert a perfectly good TS to XviD?

Truth is, encoding to XviD is to save harddisk space, and if you're going to do that, you might as well give the audio a somewhat lower bitrate.
MrTroy is offline   Reply With Quote
Old 29th April 2006, 13:49   #12  |  Link
Prysme
Registered User
 
Join Date: Mar 2003
Posts: 15
Quote:
Originally Posted by blubberbirne
I used this script

Code:
LoadPlugin("D:\DVDSoft\dgmpgdec\dgdecode.dll")
LoadPlugin("C:\Programme\AviSynth 2.5\plugins\TIVTC.dll")

MPEG2Source("file.d2v")
tfm().tdecimate()
Lanczos4Resize(1280,720,0,0,1920,1080)
Works perfect for me
I've try it, it works perfectly !! thank you, could you explain me what is doing tfm and tdecimate exactly ?
Prysme is offline   Reply With Quote
Old 2nd May 2006, 00:45   #13  |  Link
mrkazador
Registered User
 
Join Date: Apr 2006
Posts: 53
http://www.samek.neostrada.pl/hdtv/hdtv2xvid.htm
A little old but should get you started.

http://nwgat.net/
A better up to date guide using x264.

http://www.chade.org/HDTV/software/index.htm
A guide using Gordian Knot.

http://www.abhdtv.net/forum/showthread.php?t=114
Ts to wmv9.
mrkazador is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

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 On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 17:10.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2017, vBulletin Solutions Inc.