After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 778174 - raw: Fix the chromatic aberration and gamma curve setting
raw: Fix the chromatic aberration and gamma curve setting
Status: RESOLVED FIXED
Product: shotwell
Classification: Other
Component: raw
unspecified
Other All
: Normal normal
: ---
Assigned To: Shotwell Maintainers
Shotwell Maintainers
Depends on:
Blocks:
 
 
Reported: 2017-02-04 15:36 UTC by Debarshi Ray
Modified: 2017-02-06 18:54 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
libraw.vapi: Set the correct power value for the gamma curve (883 bytes, patch)
2017-02-04 15:37 UTC, Debarshi Ray
committed Details | Review
graw, libraw.vapi: Use the correct type for use_camera_matrix (1.96 KB, patch)
2017-02-04 15:53 UTC, Debarshi Ray
committed Details | Review
libraw.vapi: Fix setting of parameters on OutputParams (1.99 KB, patch)
2017-02-06 18:53 UTC, Jens Georg
committed Details | Review

Description Debarshi Ray 2017-02-04 15:36:06 UTC
I see two problems in the way LibRaw is set up in configure_for_rgb_display.

One, libraw_output_params_t.gamm[0] is meant to have the inverted gamma or power value. See: http://www.libraw.org/docs/API-datastruct-eng.html#libraw_output_params_t

Second, looking at the generated C code, the way set_chromatic_aberrations and set_gamma_curve are called seems wrong. We are passing libraw_output_params_t by value, instead of by reference / pointer. However my familiarity with Vala is limited, so I don't know how to fix it.
Comment 1 Debarshi Ray 2017-02-04 15:37:08 UTC
Created attachment 344930 [details] [review]
libraw.vapi: Set the correct power value for the gamma curve
Comment 2 Debarshi Ray 2017-02-04 15:53:21 UTC
Created attachment 344934 [details] [review]
graw, libraw.vapi: Use the correct type for use_camera_matrix

Found a third problem.
Comment 3 Jens Georg 2017-02-05 10:25:09 UTC
Attachment 344930 [details] pushed as e045b9b - libraw.vapi: Set the correct power value for the gamma curve
Attachment 344934 [details] pushed as 6c6182f - graw, libraw.vapi: Use the correct type for use_camera_matrix
Comment 4 Jens Georg 2017-02-06 18:53:29 UTC
Created attachment 345049 [details] [review]
libraw.vapi: Fix setting of parameters on OutputParams

Signed-off-by: Jens Georg <mail@jensge.org>
Comment 5 Jens Georg 2017-02-06 18:54:25 UTC
Comment on attachment 345049 [details] [review]
libraw.vapi: Fix setting of parameters on OutputParams

Attachment 345049 [details] pushed as c73d7b5 - libraw.vapi: Fix setting of parameters on OutputParams

This should fix the wrong C code.