Quickest way to get an output image to show "structure" of the image
Posted: 2019-01-08T12:42:35-07:00
Magick version:
Version: ImageMagick 7.0.8-11 Q16 x64 2018-08-29 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2018 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Visual C++: 180040629
Features: Cipher DPC Modules OpenMP
Delegates (built-in): bzlib cairo flif freetype gslib heic jng jp2 jpeg lcms lqr lzma openexr pangocairo png ps raw rsvg tiff webp xml zlib
OS: Windows 10
Hey all, I'm trying to use ImageMagick to get the structure of pdf statements. Here is the input/output of what I'm talking about:
Input:
Output:
Right now, I am accomplishing this by first applying a blur to the image, and then after that making any non-white pixels black.
magick convert "input.png" -blur 0x08 "blur.png" &&
magick convert "blur.png" -fill -black +opaque white output.png
The only issue with this is that the blur command is very computational intensive, and takes much longer than I'd like it to. One consideration I had is keeping using the MPR format (memory persistent register) since the write of the blur image to disk is unneeded to me. However, I'd like to know if there's a faster way to do the operation I want without using blur at all. It may be worth noting that I'd like to parallelize multiple calls to this command in the future.
Thanks in advance!
Version: ImageMagick 7.0.8-11 Q16 x64 2018-08-29 http://www.imagemagick.org
Copyright: Copyright (C) 1999-2018 ImageMagick Studio LLC
License: http://www.imagemagick.org/script/license.php
Visual C++: 180040629
Features: Cipher DPC Modules OpenMP
Delegates (built-in): bzlib cairo flif freetype gslib heic jng jp2 jpeg lcms lqr lzma openexr pangocairo png ps raw rsvg tiff webp xml zlib
OS: Windows 10
Hey all, I'm trying to use ImageMagick to get the structure of pdf statements. Here is the input/output of what I'm talking about:
Input:
Output:
Right now, I am accomplishing this by first applying a blur to the image, and then after that making any non-white pixels black.
magick convert "input.png" -blur 0x08 "blur.png" &&
magick convert "blur.png" -fill -black +opaque white output.png
The only issue with this is that the blur command is very computational intensive, and takes much longer than I'd like it to. One consideration I had is keeping using the MPR format (memory persistent register) since the write of the blur image to disk is unneeded to me. However, I'd like to know if there's a faster way to do the operation I want without using blur at all. It may be worth noting that I'd like to parallelize multiple calls to this command in the future.
Thanks in advance!