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 Development
Register FAQ Calendar Today's Posts Search

Reply
 
Thread Tools Search this Thread Display Modes
Old 19th October 2006, 03:17   #1  |  Link
pandy
Registered User
 
Join Date: Mar 2006
Posts: 1,049
Ordered Dither plugin for Avisynth?

Hi, is there any chance to make some kind of regular pattern dither for reducing banding effect?
I think that this kind of dither can be properly encoded by MPEG-2 or MPEG-4 encoder.
I know that plugin named BlockBuster have this feature but i think on specialized plugin similar to GradFun2DB...
AFAIK there is also special kind of dithering - "Albie" optimized for interlace displays.
TIA
pandy is offline   Reply With Quote
Old 19th October 2006, 04:29   #2  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 209
Quote:
Originally Posted by pandy View Post
Hi, is there any chance to make some kind of regular pattern dither for reducing banding effect?
I think that this kind of dither can be properly encoded by MPEG-2 or MPEG-4 encoder.
No, your best bet is to let the encoder perform the dithering itself. CCE SP has this as an option ("Dithered Quantization"), and other encoders may have this as well. If you dither yourself before feeding it to the encoder, there will be severe consequences (such as screwing up the motion, or having the motion screw up the dither).
Trixter is offline   Reply With Quote
Old 19th October 2006, 04:34   #3  |  Link
Mug Funky
interlace this!
 
Mug Funky's Avatar
 
Join Date: Jun 2003
Location: i'm in ur transfers, addin noise
Posts: 4,555
1 bit dither should be fine... i second this request. perhaps gradfun could be modified to do this, too?

remember motion estimation in an encoder is done on quantized frames. the dither will be gone from the reference frame, and uniform dither on the current frame isn't really going to change ME decisions in a bad way.

besides, CCE's "dithered quantization" does just the same thing, only it probably does it in 10 bit yuv.
__________________
sucking the life out of your videos since 2004
Mug Funky is offline   Reply With Quote
Old 19th October 2006, 15:24   #4  |  Link
pandy
Registered User
 
Join Date: Mar 2006
Posts: 1,049
Quote:
Originally Posted by Trixter View Post
No, your best bet is to let the encoder perform the dithering itself. CCE SP has this as an option ("Dithered Quantization"), and other encoders may have this as well. If you dither yourself before feeding it to the encoder, there will be severe consequences (such as screwing up the motion, or having the motion screw up the dither).
I dont have encoder for HD signals with dither....
If dither is stationary (from energy point of view) there no motion problem. Sa not random but stationary dither with tightly concentrated energy from DCT point of view.
I tested few methods and seem that stationary dithering can be compressed by freeware encoders, i also reduce number of colors on planes Cb and Cr with ordered ditehr (lack of tool to add ordered dither wihtout reducing numbers of colors) and results from eye point of view was nice - (FFT of this pictures was clear, dither energy tightly concentrated on few points thus no reducing in DCT)
pandy is offline   Reply With Quote
Old 19th October 2006, 15:30   #5  |  Link
pandy
Registered User
 
Join Date: Mar 2006
Posts: 1,049
Quote:
Originally Posted by Mug Funky View Post
1 bit dither should be fine... i second this request. perhaps gradfun could be modified to do this, too?

remember motion estimation in an encoder is done on quantized frames. the dither will be gone from the reference frame, and uniform dither on the current frame isn't really going to change ME decisions in a bad way.

besides, CCE's "dithered quantization" does just the same thing, only it probably does it in 10 bit yuv.
So probably kind of gradfun + new dither which stationary (grid?) + maybe modified QM and... regularity of dither should be good compressible...
Main problem is recognize banding area, recreate lost bits (10/8.2 vs 8 bits) and stationary dither/noiseshape.
pandy is offline   Reply With Quote
Old 19th October 2006, 15:35   #6  |  Link
Trixter
Registered User
 
Join Date: Oct 2003
Posts: 209
Quote:
Originally Posted by Mug Funky View Post
besides, CCE's "dithered quantization" does just the same thing, only it probably does it in 10 bit yuv.
Which is really where it should be done, IMO. Doing so with a 10-bit DCT means you remove the posturization without touching the quality of the image too much.
Trixter is offline   Reply With Quote
Old 19th October 2006, 18:24   #7  |  Link
pandy
Registered User
 
Join Date: Mar 2006
Posts: 1,049
Quote:
Originally Posted by Trixter View Post
Which is really where it should be done, IMO. Doing so with a 10-bit DCT means you remove the posturization without touching the quality of the image too much.
Can You recomend similar in functionality encoders for h.264 HP@L4.1 and h.262 MP@HL (with price less than 1k$ or even beter freeware)?
pandy is offline   Reply With Quote
Old 19th October 2006, 18:38   #8  |  Link
foxyshadis
Angel of Night
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Tangled in the silks
Posts: 9,559
Quote:
Originally Posted by pandy View Post
So probably kind of gradfun + new dither which stationary (grid?) + maybe modified QM and... regularity of dither should be good compressible...
Main problem is recognize banding area, recreate lost bits (10/8.2 vs 8 bits) and stationary dither/noiseshape.
What kind of dither are we talking about? Encoding eats debanding for lunch. Even if you ran it in a dither pattern, it still gets eaten because it's extremely low amplitude+high frequency. BlockBuster works through encoding because it's a much higher amplitude noise, and even then it's usually smeared unless you're making very high birate encodes.

The only way it won't be is if you use a flatter matrix and steal from the more important lower frequencies; ie, introduce a lot of ringing and possibly blocking.

Question is, what are you trying to do? Encode files for standalone playback, for friends, for business distribution?
Quote:
Originally Posted by pandy View Post
Can You recomend similar in functionality encoders for h.264 HP@L4.1 and h.262 MP@HL (with price less than 1k$ or even beter freeware)?
Akupenguin has indicated that he may do this for x264 in the future. Otherwise, the options are mainconcept and ateme, afaik. (Nero removed the feature from its implementation of Ateme's.)
foxyshadis is offline   Reply With Quote
Old 20th October 2006, 02:43   #9  |  Link
pandy
Registered User
 
Join Date: Mar 2006
Posts: 1,049
Quote:
Originally Posted by foxyshadis View Post
The only way it won't be is if you use a flatter matrix and steal from the more important lower frequencies; ie, introduce a lot of ringing and possibly blocking.
Yes, i know it... but with regular pattern which should be very well compressible this should be no problem...

Maybe some qm with "hole" for some freq?

Quote:
Originally Posted by foxyshadis View Post
Question is, what are you trying to do? Encode files for standalone playback, for friends, for business distribution?
some private use... some testing areas...

Quote:
Originally Posted by foxyshadis View Post
Akupenguin has indicated that he may do this for x264 in the future. Otherwise, the options are mainconcept and ateme, afaik. (Nero removed the feature from its implementation of Ateme's.)
Hm... mainconcept don't work, have it, use it, swear it...
pandy is offline   Reply With Quote
Old 20th October 2006, 06:03   #10  |  Link
Mug Funky
interlace this!
 
Mug Funky's Avatar
 
Join Date: Jun 2003
Location: i'm in ur transfers, addin noise
Posts: 4,555
hmm... i wonder how useful a noiseshaped dither would be if it did it's noise shaping based on a CQM the user inputs? ie put the dither in the higher numbers.
__________________
sucking the life out of your videos since 2004
Mug Funky is offline   Reply With Quote
Reply


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 02:22.


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