camerad: recalibrate ox colors for HDR (#25874)

re
old-commit-hash: 4ed0abd197
taco
ZwX1616 3 years ago committed by GitHub
parent 4b50c653d6
commit 0bc78ce16b
  1. 6
      system/camerad/cameras/real_debayer.cl
  2. 16
      system/camerad/cameras/sensor2_i2c.h

@ -9,9 +9,9 @@
float3 color_correct(float3 rgb) { float3 color_correct(float3 rgb) {
// color correction // color correction
#if IS_OX #if IS_OX
float3 x = rgb.x * (float3)(1.81485125, -0.51650643, -0.06985117); float3 x = rgb.x * (float3)(1.5664815 , -0.29808738, -0.03973474);
x += rgb.y * (float3)(-0.51681964, 1.85935946, -0.49871889); x += rgb.y * (float3)(-0.48672447, 1.41914433, -0.40295248);
x += rgb.z * (float3)(-0.29803161, -0.34285304, 1.56857006); x += rgb.z * (float3)(-0.07975703, -0.12105695, 1.44268722);
#else #else
float3 x = rgb.x * (float3)(1.82717181, -0.31231438, 0.07307673); float3 x = rgb.x * (float3)(1.82717181, -0.31231438, 0.07307673);
x += rgb.y * (float3)(-0.5743977, 1.36858544, -0.53183455); x += rgb.y * (float3)(-0.5743977, 1.36858544, -0.53183455);

@ -727,10 +727,10 @@ struct i2c_random_wr_payload init_array_ox03c10[] = {
// color balance gains // color balance gains
// blue // blue
{0x5280, 0x06}, {0x5281, 0x4A}, // hcg {0x5280, 0x06}, {0x5281, 0xCB}, // hcg
{0x5480, 0x06}, {0x5481, 0x4A}, // lcg {0x5480, 0x06}, {0x5481, 0xCB}, // lcg
{0x5680, 0x07}, {0x5681, 0xDD}, // spd {0x5680, 0x06}, {0x5681, 0xCB}, // spd
{0x5880, 0x06}, {0x5881, 0x4A}, // vs {0x5880, 0x06}, {0x5881, 0xCB}, // vs
// green(blue) // green(blue)
{0x5282, 0x04}, {0x5283, 0x00}, {0x5282, 0x04}, {0x5283, 0x00},
@ -745,10 +745,10 @@ struct i2c_random_wr_payload init_array_ox03c10[] = {
{0x5884, 0x04}, {0x5885, 0x00}, {0x5884, 0x04}, {0x5885, 0x00},
// red // red
{0x5286, 0x08}, {0x5287, 0x6C}, {0x5286, 0x08}, {0x5287, 0xDE},
{0x5486, 0x08}, {0x5487, 0x6C}, {0x5486, 0x08}, {0x5487, 0xDE},
{0x5686, 0x08}, {0x5687, 0xAA}, {0x5686, 0x08}, {0x5687, 0xDE},
{0x5886, 0x08}, {0x5887, 0x6C}, {0x5886, 0x08}, {0x5887, 0xDE},
}; };
struct i2c_random_wr_payload init_array_ar0231[] = { struct i2c_random_wr_payload init_array_ar0231[] = {

Loading…
Cancel
Save