Skip to content

Commit e830eea

Browse files
authored
[fix] remove breaking const qualifier on hints in configure (#219)
Signed-off-by: Anton Dukhovnikov <antond@wetafx.co.nz>
1 parent 79c91eb commit e830eea

File tree

2 files changed

+6
-8
lines changed

2 files changed

+6
-8
lines changed

include/rawtoaces/image_converter.h

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,29 +160,29 @@ class ImageConverter
160160
/// decode the pixels.
161161
/// @param input_filename
162162
/// A file name of the raw image file to read the metadata from.
163-
/// @param hints
163+
/// @param options
164164
/// Conversion hints to be passed to OIIO when reading an image file.
165165
/// The list can be pre- or post- updated with other hints, unrelated to
166166
/// the rawtoaces conversion.
167167
/// @result
168168
/// `true` if configured successfully.
169169
bool configure(
170-
const std::string &input_filename, const OIIO::ParamValueList &hints );
170+
const std::string &input_filename, OIIO::ParamValueList &options );
171171

172172
/// Configures the converter using the requested white balance and colour
173173
/// matrix method, and the metadata of the given OIIO::ImageSpec object.
174174
/// Use this method if you already have an image read from file to save
175175
/// on disk operations.
176176
/// @param imageSpec
177177
/// An image spec obtained from OIIO::ImageInput or OIIO::ImageBuf.
178-
/// @param hints
178+
/// @param options
179179
/// Conversion hints to be passed to OIIO when reading an image file.
180180
/// The list can be pre- or post- updated with other hints, unrelated to
181181
/// the rawtoaces conversion.
182182
/// @result
183183
/// `true` if configured successfully.
184184
bool configure(
185-
const OIIO::ImageSpec &imageSpec, const OIIO::ParamValueList &hints );
185+
const OIIO::ImageSpec &imageSpec, OIIO::ParamValueList &options );
186186

187187
/// Load an image from a given `path` into a `buffer` using the `hints`
188188
/// calculated by the `configure` method. The hints can be manually

src/rawtoaces_util/image_converter.cpp

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1239,9 +1239,8 @@ void fix_metadata( OIIO::ImageSpec &spec )
12391239
}
12401240

12411241
bool ImageConverter::configure(
1242-
const std::string &input_filename, const OIIO::ParamValueList &hints = {} )
1242+
const std::string &input_filename, OIIO::ParamValueList &options )
12431243
{
1244-
OIIO::ParamValueList options = hints;
12451244
options["raw:ColorSpace"] = "XYZ";
12461245
options["raw:use_camera_wb"] = 0;
12471246
options["raw:use_auto_wb"] = 0;
@@ -1275,9 +1274,8 @@ bool ImageConverter::configure(
12751274
// -G - green_matching() filter
12761275

12771276
bool ImageConverter::configure(
1278-
const OIIO::ImageSpec &image_spec, const OIIO::ParamValueList &hints = {} )
1277+
const OIIO::ImageSpec &image_spec, OIIO::ParamValueList &options )
12791278
{
1280-
OIIO::ParamValueList options = hints;
12811279
options["raw:use_camera_wb"] = 0;
12821280
options["raw:use_auto_wb"] = 0;
12831281

0 commit comments

Comments
 (0)