Skip to content
Snippets Groups Projects
Commit 95d3dbe6 authored by tpylak's avatar tpylak
Browse files

fix: allow old serialized ConvertToolImageTransformer to deserialize

SVN: 22823
parent c59373ad
No related branches found
No related tags found
No related merge requests found
...@@ -92,9 +92,10 @@ public class ConvertToolImageTransformer implements IStreamingImageTransformer ...@@ -92,9 +92,10 @@ public class ConvertToolImageTransformer implements IStreamingImageTransformer
private final boolean useGraphicsMagic; private final boolean useGraphicsMagic;
ConvertToolImageTransformer(String arguments, ToolChoice choice) ConvertToolImageTransformer(String arguments, ToolChoice choiceOrNull)
{ {
this.convertCliArguments = parseCommandArguments(arguments); this.convertCliArguments = parseCommandArguments(arguments);
ToolChoice choice = (choiceOrNull == null ? ToolChoice.ENFORCE_IMAGEMAGICK : choiceOrNull);
switch (choice) switch (choice)
{ {
case ENFORCE_IMAGEMAGICK: case ENFORCE_IMAGEMAGICK:
...@@ -130,8 +131,9 @@ public class ConvertToolImageTransformer implements IStreamingImageTransformer ...@@ -130,8 +131,9 @@ public class ConvertToolImageTransformer implements IStreamingImageTransformer
{ {
try try
{ {
// TODO 2011-08-31, Franz-Josef Elmer: Uncomment when new fast method is working correctly for colored images // TODO 2011-08-31, Franz-Josef Elmer: Uncomment when new fast method is working
// byte[] input = ImageUtil.imageToPngFast(image); // correctly for colored images
// byte[] input = ImageUtil.imageToPngFast(image);
byte[] input = toByteArray(image); byte[] input = toByteArray(image);
byte[] output = transform(input); byte[] output = transform(input);
return toBufferedImage(output); return toBufferedImage(output);
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment