Quantcast FFmpeg: KVCD/DVD with FFmpeg - digitalFAQ.com Forums [Archives]
  #1  
02-07-2010, 02:07 PM
patchworks patchworks is offline
Free Member
 
Join Date: Feb 2004
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
Hi guyz, I *need* to encode KVCD/DVDs with MediaCoder but I can't understand how to force FFmpeg (that is the encoder) to use - this ? - matrices.

Can anyone help ?

Thanks in advice !!!
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
  #2  
02-07-2010, 09:08 PM
Dialhot Dialhot is offline
Free Member
 
Join Date: May 2003
Posts: 10,463
Thanks: 0
Thanked 0 Times in 0 Posts
Never used it, but I've fixed the snapshots in the topic you are mentionning, it may help you.
Reply With Quote
  #3  
02-10-2010, 05:25 AM
patchworks patchworks is offline
Free Member
 
Join Date: Feb 2004
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
Well, then, buzzqw (the HDConvertToX, MicroX264 and AutoMen author) suggested me to use these FFmpeg parameters (even if he don't know HOW):

-intra_matrix matrix specify intra matrix coeffs
-inter_matrix matrix specify inter matrix coeffs

Hope that helps !
Reply With Quote
  #4  
02-10-2010, 05:34 AM
patchworks patchworks is offline
Free Member
 
Join Date: Feb 2004
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
Hey ! I just found a possible solution in Mencoder's manual !
Quote:
Originally Posted by 11.3. Encoding with the libavcodec codec family
11.3.5. Custom inter/intra matrices

With this feature of libavcodec you are able to set custom inter (I-frames/keyframes) and intra (P-frames/predicted frames) matrices. It is supported by many of the codecs: mpeg1video and mpeg2video are reported as working.

A typical usage of this feature is to set the matrices preferred by the KVCD specifications.

The KVCD "Notch" Quantization Matrix:

Intra:

8 9 12 22 26 27 29 34
9 10 14 26 27 29 34 37
12 14 18 27 29 34 37 38
22 26 27 31 36 37 38 40
26 27 29 36 39 38 40 48
27 29 34 37 38 40 48 58
29 34 37 38 40 48 58 69
34 37 38 40 48 58 69 79

Inter:

16 18 20 22 24 26 28 30
18 20 22 24 26 28 30 32
20 22 24 26 28 30 32 34
22 24 26 30 32 32 34 36
24 26 28 32 34 34 36 38
26 28 30 32 34 36 38 40
28 30 32 34 36 38 42 42
30 32 34 36 38 40 42 44

Usage:

mencoder input.avi -o output.avi -oac copy -ovc lavc \
-lavcopts inter_matrix=...:intra_matrix=...

mencoder input.avi -ovc lavc -lavcopts \
vcodec=mpeg2video:intra_matrix=8,9,12,22,26,27,29, 34,9,10,14,26,27,29,34,37,\
12,14,18,27,29,34,37,38,22,26,27,31,36,37,38,40,26 ,27,29,36,39,38,40,48,27,\
29,34,37,38,40,48,58,29,34,37,38,40,48,58,69,34,37 ,38,40,48,58,69,79\
:inter_matrix=16,18,20,22,24,26,28,30,18,20,22,24, 26,28,30,32,20,22,24,26,\
28,30,32,34,22,24,26,30,32,32,34,36,24,26,28,32,34 ,34,36,38,26,28,30,32,34,\
36,38,40,28,30,32,34,36,38,42,42,30,32,34,36,38,40 ,42,44 -oac copy -o svcd.mpg
Hope that inspires !
Reply With Quote
  #5  
02-10-2010, 05:40 AM
patchworks patchworks is offline
Free Member
 
Join Date: Feb 2004
Posts: 38
Thanks: 0
Thanked 0 Times in 0 Posts
Here we go (KSVCD) !!!

Quote:
Quality is awesome. It can reach quant 2 for 400kb/s on low motion.

ffmpeg -hq -i d:\sample.vob -target svcd -bufsize 224 -b 600 -mbd 2 -g 240 -bt 1024 -trell -bf 2 -alt -y -intra_matrix "8,9,12,22,26,27,29,34,9,10,14,26,27,29,34,37,12,1 4,18,27,29,34,37,38,22,26,27,31,36,37,38,40,26
,27,31,36,37,38,40,48,27,29,34,37,38,40,48,58,29,3 4,37,38,40,48,58,69,34,37,38,40,48,58,69,79" -inter_matrix "16,18,20,22,24,26,28,30,18,20,22,24,26,28,30,32,2 0,22,24,26,28,30,32,34,22,24,26,30,32,32,34,36
,24,26,28,32,34,34,36,38,26,28,30,32,34,36,38,40,2 8,30,32,34,36,38,42,42,30,32,34,36,38,40,42,44" test.mpg

Very good quality for 1CD SVCD encode
...what about KVCD ? How to change parameters before "-intra_matrix" ? What about 2-pass ?
Reply With Quote
Reply




Similar Threads
Thread Thread Starter Forum Replies Last Post
FFMPEG: Do ffvfw and mencoder/ffmpeg give the same results? Razorblade2000 Video Encoding and Conversion 4 02-06-2004 04:23 PM
FFMPEG: My preliminary test. ffmpeg 0.4.7 vs. TMPEG 2.520 kwag Video Encoding and Conversion 23 10-21-2003 05:13 PM
FFMPEG: Encoding Audio: toolame,mp2enc or ffmpeg Razorblade2000 Video Encoding and Conversion 0 10-18-2003 03:04 PM
FFMPEG: Letterboxing with ffmpeg (aspect ratio) el_mozo Video Encoding and Conversion 16 10-14-2003 03:53 PM
FFMPEG: Guide for avi to kvcd using ffmpeg Big2hd Video Encoding and Conversion 15 09-15-2003 03:04 AM

Thread Tools



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