Difference between revisions of "Focus helper"

From ElphelWiki
Jump to: navigation, search
 
 
(3 intermediate revisions by the same user not shown)
Line 1: Line 1:
 
==Description==
 
==Description==
 
After the DCT transform of a 8x8 block the 64 frequency coefficients are aquired. Each coefficient is squared and multiplied by the value from the table of weights (it can be set) and a single value for a block is the result. For better focus the lower frequencies go with greater weights (more attention to details). Then the sum of the squared (one more time and this 'squaring' weakens 8x8 blocks in the calculation area that have more lower frequency components) values of all the blocks in the focus area is taken and it is the length of Green Horizontal Line.
 
After the DCT transform of a 8x8 block the 64 frequency coefficients are aquired. Each coefficient is squared and multiplied by the value from the table of weights (it can be set) and a single value for a block is the result. For better focus the lower frequencies go with greater weights (more attention to details). Then the sum of the squared (one more time and this 'squaring' weakens 8x8 blocks in the calculation area that have more lower frequency components) values of all the blocks in the focus area is taken and it is the length of Green Horizontal Line.
 +
 +
In the visual representation - the more white the better focus.
  
 
So, by setting the table of weights the higher/lower frequencies can be filtered.
 
So, by setting the table of weights the higher/lower frequencies can be filtered.
  
 
==Controls page==
 
==Controls page==
[[Image:Focusinghelper.jpg|thumb|900px|Fig.1 Interface]]
+
 
 +
[http://192.168.0.9/focus.html http://192.168.0.9/focus.html]
 +
 
 +
{|
 +
|[[Image:Focusinghelper.jpg|thumb|900px|Fig.1 Interface]]
 +
|}
 +
 
 
Each new single Green Horizontal Line is for a single image. As the new lines appear at the bottom the values for the old ones are replaced with their mean value.
 
Each new single Green Horizontal Line is for a single image. As the new lines appear at the bottom the values for the old ones are replaced with their mean value.
  
Line 12: Line 20:
 
''Left'', ''Width'', ''Top'', ''Height'' - calculation area.
 
''Left'', ''Width'', ''Top'', ''Height'' - calculation area.
  
[[Image:Focusinghelper_sample1.jpg|thumb|400px|Fig.2 Sample 1, Show='combine woi']]
+
{|
[[Image:Focusinghelper_sample2.jpg|thumb|400px|Fig.3 Sample 2, Show='focus']]
+
|[[Image:Focusinghelper_sample1.jpg|thumb|400px|Fig.2 Sample 1, Show='focus']]
 +
|[[Image:Focusinghelper_sample2.jpg|thumb|400px|Fig.3 Sample 2, Show='combine woi']]
 +
|}

Latest revision as of 11:08, 16 December 2009

Description

After the DCT transform of a 8x8 block the 64 frequency coefficients are aquired. Each coefficient is squared and multiplied by the value from the table of weights (it can be set) and a single value for a block is the result. For better focus the lower frequencies go with greater weights (more attention to details). Then the sum of the squared (one more time and this 'squaring' weakens 8x8 blocks in the calculation area that have more lower frequency components) values of all the blocks in the focus area is taken and it is the length of Green Horizontal Line.

In the visual representation - the more white the better focus.

So, by setting the table of weights the higher/lower frequencies can be filtered.

Controls page

http://192.168.0.9/focus.html

Fig.1 Interface

Each new single Green Horizontal Line is for a single image. As the new lines appear at the bottom the values for the old ones are replaced with their mean value.

Zoom, Show (area of calculation), Mode, Filter and Scale can be set.

Left, Width, Top, Height - calculation area.

Fig.2 Sample 1, Show='focus'
Fig.3 Sample 2, Show='combine woi'