diff options
author | Kae <80987908+Novaenia@users.noreply.github.com> | 2023-06-25 18:12:54 +1000 |
---|---|---|
committer | Kae <80987908+Novaenia@users.noreply.github.com> | 2023-06-25 18:12:54 +1000 |
commit | 7d205330dbf1c2fd44d9d58393ab46434ac8bb5e (patch) | |
tree | e73db06236120e2399f0b4863257477eec528295 /source/core/StarImageProcessing.cpp | |
parent | e2424b7dcf60d18b277b092eb7f2a947fff27415 (diff) |
More directives optimization
Diffstat (limited to 'source/core/StarImageProcessing.cpp')
-rw-r--r-- | source/core/StarImageProcessing.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/source/core/StarImageProcessing.cpp b/source/core/StarImageProcessing.cpp index c2f980e..56ac130 100644 --- a/source/core/StarImageProcessing.cpp +++ b/source/core/StarImageProcessing.cpp @@ -173,7 +173,7 @@ ImageOperation imageOperationFromString(String const& string) { } else if (type == "replace") { ColorReplaceImageOperation operation; for (size_t i = 0; i < (bits.size() - 1) / 2; ++i) - operation.colorReplaceMap[Color::fromHex(bits[i * 2 + 1]).toRgba()] = Color::fromHex(bits[i * 2 + 2]).toRgba(); + operation.colorReplaceMap[Color::hexToVec4B(bits[i * 2 + 1])] = Color::hexToVec4B(bits[i * 2 + 2]); return operation; @@ -259,7 +259,7 @@ ImageOperation imageOperationFromString(String const& string) { return FlipImageOperation{FlipImageOperation::FlipXY}; } else { - throw ImageOperationException(strf("Could not recognize ImageOperation type %s", type)); + throw ImageOperationException(strf("Could not recognize ImageOperation type %s", type), false); } } catch (OutOfRangeException const& e) { throw ImageOperationException("Error reading ImageOperation", e); |