Hallo

>         I'm sure you've all see the blocks/splotches in dim/dark scenes - it's
>         especially noticeable when fades from or to black occur.
> 
>         No, I'm not hot on the trail of a new filter - but the visible blocks
>         during dark and fade scenes is very annoying and I'm not sure how to
>         reduce their obviousness.
> 
>         What seems like a good idea is a selective median/averaging filter
>         that would be more aggressive in dark scenes and gradually taper off
>         as the frames became brighter.  I'm not sure if treating regions within
>         a frame would be a good thing or not - might be, but might lead to
>         artifacts.
I had often wished that the filter would not be so aggresive in the
darker areas, and preserve more 

>         What's a good metric for determining the "brightness" of a frame?
>         Compute a histogram of the Y' values and see if there's a big cluster
>         below a specified threshold (such as 32)?  For example, this is a
>         histogram of Y' for a frame that's supposedly pure black (after Y=32
>         it's all 0):
> Y 15 11904
> Y 16 19854
> Y 17 28770
> Y 18 41353
> Y 19 54259
> Y 20 58347
> Y 21 47760
> Y 22 32121
> Y 23 19341
> Y 24 9487
> Y 25 3593

>         and finally with 8:
> Y 15 573
> Y 16 1691
> Y 17 13763
> Y 18 53222
> Y 19 93559
> Y 20 109834
> Y 21 58018
> Y 22 5464
> Y 23 619
> Y 24 298
> Y 25 125


>         It wouldn't be a good idea to use a "-t 8" over the entire movie.  But
>         if a frame is so dark that Y' is centered around 20 perhaps a "-t 8"
>         would be fine.
> 
>         Would it make sense to have several 'regions' or 'bands' that have
>         different thresholds?   If the majority of the frame has a Y' around
>         20 +/-4 use a "-t 8", if it's centered about 28 +/- 4 then a "-t 6",
>         32 +/-4  "-t 4", and so on.  After a certain point Y' will be high
>         enough (48 or so) that the scene will be bright enough to not need
>         median/averaging since the blocks/splotches won't be as noticeable to
>         the eye.
That sounds like a nice idea :)
Are you planing to add that feature to yuvmedianfilter ?

>         Or would that not make much difference or even worse cause visible
>         artifacts?
Test will prove this or that. 

>         The other idea is to quantize dim scenes less accurately.  For dim
>         frames (where the majority of the frame has Y' less than a specified
>         value) turning Y' values between 16...19 = 18, 18...22 = 20 and so on
>         up to a max (40 perhaps the default ceiling).   That would reduce the
>         blockiness quite a bit I'd think since the encoder wouldn't see
>         Y' jumping up and down by small amounts.
But if you make larger areas and goe than to the nex level, it is more
likely that you notice the "jump" to the next area. 

>From what I have read the human eye is able to determine
black/gray/white much better than colors. You can fool the eye with only
256 (8Bit) differnet numbers from white to black, but you have to use a
logaritmic scale. If you use a linar scale 8 bit are not enough. You
usually notice than missing colors when you get really dark. 

If you are interrested I search again the docu, but it is in German. 

>         Yet another idea (notice how easy they come when one isn't writing the
>         code :)) would be a filter than could be 'trained' - by that I mean
>         feed it a bunch of frames of what should be considered "black" - from
>         that it could would determine the appropriate median/quantizing
>         parameters to apply.   What'd be great would be the ability to
>         "subtract" the differences between "pure black" and the "reference
>         frame(s)" from the movie - but I'm not sure how one subtracts in the
>         "YUV" space ;)
Do you think the the area which you set to real black could be used for
that ? 

A area that is nearly always aviable and black on PAL full size images
are the first 10 pixles on the left edge and the last 10 on the right
edge. 

>         Any statistics or signal processing folks care to chime in with ideas,
>         suggestions, or even better working code? :) :)
I'll test anything that compiles on your machines ;)

auf hoffentlich bald,

Berni the Chaos of Woodquarter

Email: [EMAIL PROTECTED]
www: http://www.lysator.liu.se/~gz/bernhard


-------------------------------------------------------
This SF.Net email is sponsored by: Oracle 10g
Get certified on the hottest thing ever to hit the market... Oracle 10g. 
Take an Oracle 10g class now, and we'll give you the exam FREE.
http://ads.osdn.com/?ad_id=3149&alloc_id=8166&op=click
_______________________________________________
Mjpeg-users mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/mjpeg-users

Reply via email to