What different between patch_bad_pixels and patch_bad_pixels_b ? - RAW Shooting and Processing - CHDK Forum  

What different between patch_bad_pixels and patch_bad_pixels_b ?

  • 4 Replies
  • 3414 Views
*

Offline Lebeau

  • ***
  • 187
What different between patch_bad_pixels and patch_bad_pixels_b ?
« on: 21 / December / 2010, 20:12:30 »
Advertisements
In gui_init (gui.c), you have:
2010     load_bad_pixels_list("A/CHDK/badpixel");
2011     load_bad_pixels_list("A/CHDK/badpixel.txt");

In conf_change_dng (conf.c), you have:
 455   if (!badpixel_list_loaded_b()) load_bad_pixels_list_b("A/CHDK/badpixel.bin");

In raw_savefile (raw.c), you have:
00127     if (conf.bad_pixel_removal) patch_bad_pixels();
and just before writing to the DNG file:
00175                patch_bad_pixels_b();

Is that means that my column of new hot pixels shall be textually entered into the "badpixel.txt" file?

If I understand correctly,
 - "badpixel.txt" (user edited) will correct my user-defined bad pixels and
 - "badpixel.bin" (generated via OSD menu) will correct Canon-defined bad pixels
Am I right?

If I am right, the "badpixel.txt" shall be shorter than PIXELS_BUF_SIZE = 8192 bytes. How am I inserting a column of 3000 bad pixels? Change the value and compile ?

*

Offline Lebeau

  • ***
  • 187
Re: What different between patch_bad_pixels and patch_bad_pixels_b ?
« Reply #1 on: 25 / December / 2010, 11:09:26 »
I red source code and find by myself, thank you :)

In fact, badpixel.txt contains column and row, comma separated and not tab nor space.

I patch "patch_bad_pixels" to loop in the column since "patch_bad_pixel" average around, nor left-right only.

*

Offline fe50

  • ******
  • 3152
  • IXUS50 & 860, SX10 Star WARs-Star RAWs
    • fe50
Re: What different between patch_bad_pixels and patch_bad_pixels_b ?
« Reply #2 on: 25 / December / 2010, 16:52:13 »
If I understand correctly,
 - "badpixel.txt" (user edited) will correct my user-defined bad pixels and
 - "badpixel.bin" (generated via OSD menu) will correct Canon-defined bad pixels
Am I right?
There are two CHDK functions/features:

1) Badpixel removal - to "remove" defective (bad) pixels which are normally visible in the image
The file "badpixel" (without filename extension) is used for this; CHDK also looks for the filename "badpixel.txt"

2) The DNG badpixel mechanism - only used for DNG file creation.
This "extracts" the pixels which were marked as bad already by the Canon firmware.
The file "badpixel.bin" isn't a direct editable text file; this file can be created either with the help of a little lua script (like badpixel.lua from the CHDK full package; the command set_raw(255) turns on the special "bad pixel mode") or outside the camera with a small tool like ewavr's "show_bad_b.exe"...

Read more about those two things here:
* http://chdk.wikia.com/wiki/Badpixel_removal
* http://chdk.setepontos.com/index.php?topic=4853.msg47173#msg47173 (badpixel.lua dissection)

*

Offline hoodsmom

  • *
  • 3
  • SD750 101B
Re: What different between patch_bad_pixels and patch_bad_pixels_b ?
« Reply #3 on: 14 / March / 2011, 23:26:51 »
I have an SD750 and an SX10.  So far I've only put CHDK on the SD750.  I would like to do in-camera DNG recording, but was stymied by the directions @ http://chdk.wikia.com/wiki/Badpixel_removal

In the complete download packages there's the script badpixel.lua (located in the folder \CHDK\SCRIPTS\TEST) to generate the badpixel.bin file on-the-fly in the camera.
The badpixel.lua (and the test folder) do not exist in the build for my SD750 and the wiki says the script is unsupported.

As of build 1039, badpixel.bin may be created in camera in the raw menu, using "Create badpixel.bin".

I could not find "create badpixel.bin" after a thorough search of the SD750 menus.

Is embedded DNG supported in the SD750?  Am I going to have similar issues with the SX10?



*

Offline fe50

  • ******
  • 3152
  • IXUS50 & 860, SX10 Star WARs-Star RAWs
    • fe50
Re: What different between patch_bad_pixels and patch_bad_pixels_b ?
« Reply #4 on: 15 / March / 2011, 01:52:55 »
The badpixel.lua (and the test folder) do not exist in the build for my SD750 and the wiki says the script is unsupported.

As of build 1039, badpixel.bin may be created in camera in the raw menu, using "Create badpixel.bin".
Quote
I could not find "create badpixel.bin" after a thorough search of the SD750 menus.
Is embedded DNG supported in the SD750?  Am I going to have similar issues with the SX10?
On current CHDK versions the menu item is in the RAW menu, the old .lua script is not included & not supported anymore.
The \CHDK\TEST folder is included in all FULL download packages, if you don't have that folder on your card i suggest to download a full package from the Autobuild Server & expand ALL files & folders to the root of your SD card...

--> http://chdk.wikia.com/wiki/Downloads

From a short look at the sources, DNG support for the SD750 should work; on the SX10 DNG support is available & fully functional for a long time now...

 

Related Topics


SimplePortal 2.3.6 © 2008-2014, SimplePortal