History

avcodec/exr: remove wrong scaling for 32bit DWA compression

Paul B Mahol committed 3 years ago

Commit 024c30a1 parent b7e79ba1 file · +3 −4Browse files

Unified · Split

libavcodec/exr.c+3−4
@@ -1119,7 +1119,6 @@ static int dwa_uncompress(const EXRContext *s, const uint8_t *src, int compresse · 1118 unmodified lines
11191119 }
11201120
11211121 {
1122− const float scale = s->pixel_type == EXR_FLOAT ? 2.f : 1.f;
11231122 const int o = s->nb_channels == 4;
11241123 float *bo = ((float *)td->uncompressed_data) +
11251124 y * td->xsize * s->nb_channels + td->xsize * (o + 0) + x;
@@ -1137,9 +1136,9 @@ static int dwa_uncompress(const EXRContext *s, const uint8_t *src, int compresse · 11 unmodified lines
11371136
11381137 convert(yb[idx], ub[idx], vb[idx], &bo[xx], &go[xx], &ro[xx]);
11391138
1140− bo[xx] = to_linear(bo[xx], scale);
1141− go[xx] = to_linear(go[xx], scale);
1142− ro[xx] = to_linear(ro[xx], scale);
1139+ bo[xx] = to_linear(bo[xx], 1.f);
1140+ go[xx] = to_linear(go[xx], 1.f);
1141+ ro[xx] = to_linear(ro[xx], 1.f);
11431142 }
11441143
11451144 bo += td->xsize * s->nb_channels;

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t