Log in

View Full Version : Differences between monitor and tv using DivX


Master Ki Adi Mundi
22nd September 2003, 06:49
I am sure this has been asked before.. I have searched around, but due to the two letter search limit, finding posts that contain "tv" is not that easy. Problem is simple to explain, but the answer is probably not so straight forward.

I recently purchased an EPIA and started toying with the HTPC idea, the EPIA uses a VT1622 standard definition digital set top chip for TV-out and does colour space conversion and scaling, by all reports its a great TV-out chip. I've performed a number of 24bit test images (PNG) using TV-out and I cannot see any banding or noticable colour artifacts, in actual fact it looks great.

Movies encoded using GK/DivX5 around 1.2Gb -> 1.8Gb with AC3 look and sound great on my PC monitor, however when viewed on the EPIA TV-out some clips suffer from what I would call colour intepolation, especially in grey/green scenes. I must stress that even with my monitor brightness and contrast full up, I do not see any of this color artifacting on the monitor. Putting the dark macroblock issue aside, I see definite descrete colour differences.

I am wondering whats going on here, my logic goes as follows;

Since my 24bit test images display fine using TV-out then I think I can rule out crappy TV-out hardware and/or driver related problems.

Since not all my clips suffer from this problem, and if they do, its not that noticable. Then maybe its a player issue or an encoding problem, but the offending clips look fine on the monitor, so my logic breaks down and I get confused. :(

Then I think about the YUV colour space and the fact that DivX uses 4:2:0 giving 12bpp, which is effectively 24bit RGB , right? So some colour reduction is to be expected, and this colour space conversion doesn't occur using a monitor??

I have played around with my player ( Mplayer ) until the cows come home and nothing much changes. I have tried encoding my DivX, making then larger, this does reduced the effect slightly, the main issue is that some movies suffer more than others. For example, Star Wars EP2 doesn't have even a hint of this problem. My theory is that the source colour space matches DivX colour space exactly. Does this make any sense?

What advice can you give on how to encode my rips to minimise this, and any technical explainations that might help me get this straight in my head.

Thanks

hakko504
22nd September 2003, 09:42
First, check the resolution of your encoded clips: If you intend to watch them on TV you should (if possible) try to match the output resolution of your TV-out unit. Myself, I have a Matrox G400 Marvel, and it always uses 704x576 (PAL) as output resolution when displaying video. Now, the matrox card is quite good at scaling the video, but still the best results are obtained if I use 704xYYY for widescreen movies, or (if I want to save space) limits the height to 288. I also use VCD resolution (352x288) for much 4:3 stuff, and plays it back using Zoomplayer (or a player capable of correcting aspect ratio on the fly) when I watch it on the monitor. Since I'm in PAL country, the quite popular 640x480 is useless when I want to watch something on the TV, as it would mean scaling the video in both directions with quite odd scaling factors. If you have to scale in both directions, them at least make sure that the height is half the output resoltion: that will give you a better result.

As I see it, the most useful resolutions if you want to watch the final result on a TV is:
tv-out 704x576 768x576 704x480 640x480
---- PAL PAL NTSC NTSC
AR
4:3 (small) 352x288+ 384x288 352x240+ 320x240
4:3 (large) 704x576+ 768x576 704x480+ 640x480
16:9 (small) 512x288 512x288 432x240* 432x240*
16:9 (large) 704x400* 768x432% 704x400* 640x352*
2.35:1 704x288& 768x320&% 704x288& 640x272&

+ Intentionally left at wrong aspect ratio: correct with SW player when displaying on monitor.
* rounded to nearest mod-16. Height fixed for small res, width fixed for large.
& use crop to make height mod-16.
% requires PAL 16:9 source.

SeeMoreDigital
22nd September 2003, 15:16
Nice one hakko504,

You may find these resolutions (image pixel frame sizes) useful too!


Info about... Pixel Ratios and Pixel Totals
--------------------------------------------------------------------------------
PAL DVD Player & DV Camcorders
Frame Aspect Ratio = 1.25:1 'Anamorphic Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.33:1 720 x 576 720 x 576 000,000 414,720 00.00
1.77:1 720 x 576 720 x 576 000,000 414,720 00.00
1.85:1 720 x 560 720 x 554 15,840 398,880 4.00
2.35:1 720 x 432 720 x 436 100,800 313,920 32.35
--------------------------------------------------------------------------------
PAL Standard (4:3) TV/PC Monitor
Frame Aspect Ratio = 1.33:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.33:1 768 x 576 768 x 576 000,000 442,368 00.00
1.77:1 768 x 432 768 x 432 110,592 331,776 33.33
1.85:1 768 x 416 768 x 416 122,880 319,488 38.70
2.35:1 768 x 320 768 x 326 192,000 250,368 76.50
--------------------------------------------------------------------------------
NTSC Standard (4:3) TV/PC Monitor
Frame Aspect Ratio = 1.33:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.33:1 640 x 480 640 x 480 000,000 307,200 00.00
1.77:1 640 x 368 640 x 360 76,800 230,400 33.33
1.85:1 640 x 352 640 x 344 87,040 220,160 38.70
2.35:1 640 x 272 640 x 272 133,120 174,080 76.50
--------------------------------------------------------------------------------
NTSC DVD Player & DV Camcorders
Frame Aspect Ratio = 1.50:1 'Anamorphic Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.33:1 720 x 480 720 x 480 000,000 345,600 00.00
1.77:1 720 x 480 720 x 480 000,000 345,600 00.00
1.85:1 720 x 464 720 x 462 12,960 332,640 4.00
2.35:1 720 x 368 720 x 362 84,960 260,640 32.35
--------------------------------------------------------------------------------
PAL Widescreen (16:9) TV/PC Monitor - 'Not a Recognized Standard'
Frame Aspect Ratio = 1.77:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.77:1 1024 x 576 1024 x 576 000,000 589,824 00.00
1.85:1 1024 x 560 1024 x 554 22,528 567,296 4.00
2.35:1 1024 x 432 1024 x 436 143,360 446,464 32.35
--------------------------------------------------------------------------------
NTSC Widescreen (16:9) TV/PC Monitor - 'Not a Recognized Standard'
Frame Aspect Ratio = 1.77:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.77:1 848 x 480 854 x 480 000,000 409,920 00.00
1.85:1 848 x 464 854 x 462 15,372 394,548 4.00
2.35:1 848 x 368 854 x 362 100,772 309,148 32.35
--------------------------------------------------------------------------------
High Definition (16:9) 720
Frame Aspect Ratio = 1.77:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.77:1 1280 x 720 1280 x 720 000,000 921,600 00.00
1.85:1 1280 x 688 1280 x 692 35,840 885,760 4.00
2.35:1 1280 x 544 1280 x 544 225,280 696,320 32.35
--------------------------------------------------------------------------------
High Definition (16:9) 816 - 'Not a Recognized Standard'
Frame Aspect Ratio = 1.77:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.77:1 1440 x 816 1440 x 816 000,000 1,175,040 00.00
1.85:1 1440 x 784 1440 x 784 46,080 1,128,960 4.00
2.35:1 1440 x 608 1440 x 616 288,000 887,040 32.35
--------------------------------------------------------------------------------
High Definition (16:9) 1080
Frame Aspect Ratio = 1.77:1 'Full Frame'
Image To Nearest Exact 'Even' Matte Image Matte %
AR 16th Pixel Pixel Size Pixel Qty Pixel Qty Of Frame
1.77:1 1920 x 1088 1920 x 1080 000,000 2,073,600 00.00
1.85:1 1920 x 1040 1920 x 1038 80,640 1,992,960 4.00
2.35:1 1920 x 816 1920 x 816 516,800 1,556,720 32.35
--------------------------------------------------------------------------------
The above is meant to be used as a guide only.....

Cheers

Master Ki Adi Mundi
23rd September 2003, 01:21
Thanks guys,

My clips are all mostly 704x288, My TV-out is set to 720x576 PAL, ( from my Amiga days, shouldn't this be 768x576 ? )

Using the player I can view them a 1:1 the original resolution, I'll check to see if this colour thing is still present.

I am going to do some further testing with various 24bit images especially in the darker grey/green area, I suspect the hardware colour space conversion might be the culprit.

hakko504
23rd September 2003, 07:43
Originally posted by Master Ki Adi Mundi
My TV-out is set to 720x576 PAL, ( from my Amiga days, shouldn't this be 768x576 ? )
Yes, and no. 768x576 is of course correct 4:3 aspect ratio, but as all DVD/VCD's are anamorphic anyway, and uses the resolution 720x576, it's much easier to make TV-out chips that sends 720x576 to the TV. There are 768x576 TV-outs too I think, but they are in a minority by far. (I know some TV-in uses 768x576.)

Master Ki Adi Mundi
24th September 2003, 01:05
Ok,the results of my 24bit image testing have proved that something is going on with the TV output and the way it interprets and converts 24bit RGB colours. I realise now that it is not a DivX issue and more likely related to my gfx drivers and or hardware. Though I don't suppose it will bother anyone if I explain my findings here, hopefully helping anyone else who notices this too.

My TV output is set to 720x576 ( 32bit colour depth )
I create some gradient images in gimp ( 24bit PNG )
on a monitor they look fine.

1/ #333333 -> #000000 - Dark Grey to Black
2/ #330000 -> #000000 - Dark Red to Black
3/ #003300 -> #000000 - Dark Green to Black
4/ #000033 -> #000000 - Dark Blue to Black

I noticed a little banding on (1) though this ended up being the best result. The others were quite bad, the gradient starts ok but as it moves to black it just stops and goes immediately to black. The red was quite bad as it moved to dark magenta before going to black. The point at which they go black for each colour varies, blue suffered the most. By the way, images that had gradients going to white were fine and look as I expected.

Is this a problem with YUV colour space conversion and the best I should expect?

I bloody hope not... My cheap ass DVD player outputs better colours.

I am hoping its a gfx driver problem, fingers crossed.

SeeMoreDigital
24th September 2003, 11:57
Master Ki Adi Mundi,

As a matter of interest......
What TV are you using. 4:3 or 16:9?
And what connection methods have you tried. Composite or S-VHS?

Cheers

Master Ki Adi Mundi
25th September 2003, 01:36
My TV only accepts composite In, though I have tried SVHS ( with a SVHS to Composite cable ).

After screwing around with it a bit and adjusting the colour and brightness on the tv, its bearable, a friend took a look and said that, while it was noticable, its really not that bad.

Thanks

SeeMoreDigital
25th September 2003, 09:56
Originally posted by Master Ki Adi Mundi
My TV only accepts composite In, though I have tried SVHS ( with a SVHS to Composite cable )... OK. I understand a bit more now!

Many leads that convert an S-VHS signal output to an composite signal output will shift the colours around slightly. You may have also noticed that there's a slight 'metalic' look to the images. This is because the 'lumninance' part of the signal is not being outputted properly.

If you search around, you can find a neat little 'gender' S-VHS to composite converter. Some of these are quite good because they incorporate resistors within the barrel of the converter.

Thankfully some video cards are not as bad as others at outputting an S-VHS/composite signal

Cheers