pull/32112/head
Comma Device 1 year ago
parent 192c1e5c55
commit 18cd498b13
  1. 4
      system/camerad/sensors/os04c10_cl.h

@ -9,7 +9,7 @@
#define VIGNETTE_RSZ 2.2545f #define VIGNETTE_RSZ 2.2545f
float combine_dual_pvs(float lv, float sv, int expo_time) { float combine_dual_pvs(float lv, float sv, int expo_time) {
float svc = fmax(sv * expo_time, 61376.0); float svc = fmax(sv * expo_time, (float)(64 * (PV_MAX10 - BLACK_LVL)));
float svd = sv * fmin(expo_time, 8.0) / 8; float svd = sv * fmin(expo_time, 8.0) / 8;
if (expo_time > 64) { if (expo_time > 64) {
@ -52,4 +52,4 @@ float3 apply_gamma(float3 rgb, int expo_time) {
return clamp(log(1 + rgb*(PV_MAX16 - BLACK_LVL)) * (0.48*s*s - 12.92*s + 115.0) - (1.08*s*s - 29.2*s + 260.0), 0.0, 255.0) / 255.0; return clamp(log(1 + rgb*(PV_MAX16 - BLACK_LVL)) * (0.48*s*s - 12.92*s + 115.0) - (1.08*s*s - 29.2*s + 260.0), 0.0, 255.0) / 255.0;
} }
#endif #endif

Loading…
Cancel
Save