Broken pipe error
-
- Posts: 4
- Joined: 2015-04-08T10:35:14-07:00
- Authentication code: 6789
Broken pipe error
Hello hello,
New user to IM, I try to compare 2 images and showing the resulting in IMDisplay directly (without creating a file)
After searches I still cannot understand the reason of below error:
D:\DATA>compare.exe "image1.bmp" "image2.bmp" miff:- | imdisplay.exe
This just show IMdisplay with not content then, after I closes it, shows the error message:
compare.exe: unable to write blob `-': Broken pipe @ error/blob.c/ImageToFile/1730.
I'm running IM 6.9.0 Q16 64 bits on a dos command box on win 7 pro 64bits.
Are there some setup to allow pipe ? or any other trick ?
Thanks for any help
ALeX
New user to IM, I try to compare 2 images and showing the resulting in IMDisplay directly (without creating a file)
After searches I still cannot understand the reason of below error:
D:\DATA>compare.exe "image1.bmp" "image2.bmp" miff:- | imdisplay.exe
This just show IMdisplay with not content then, after I closes it, shows the error message:
compare.exe: unable to write blob `-': Broken pipe @ error/blob.c/ImageToFile/1730.
I'm running IM 6.9.0 Q16 64 bits on a dos command box on win 7 pro 64bits.
Are there some setup to allow pipe ? or any other trick ?
Thanks for any help
ALeX
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Broken pipe error
I confirm your command doesn't work, on IM v6.9.1-0. Both of the following alternatives do, using imdisplay:
Code: Select all
compare rose: rose: show:
compare rose: rose: miff:- |convert - show:
snibgo's IM pages: im.snibgo.com
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Broken pipe error
I do not know much about windows nor imdisplay.exe, but do you not need a - for standard in when using a pipe to some display command to tell it to retrieve the standard out from the miff:-. So something like
Code: Select all
compare.exe "image1.bmp" "image2.bmp" miff:- | imdisplay.exe -
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Broken pipe error
I should have mentioned: I tried ...
... but it doesn't work. imdisplay runs, but with no image, and we get the message:
These two also don't work:
The workaround, as in my first post, is to use "show:", or use convert on the right side of the pipe.
Code: Select all
compare rose: rose: miff:- |imdisplay -
Code: Select all
compare.exe: unable to write blob `-': Broken pipe @ error/blob.c/ImageToFile/1730.
Code: Select all
f:\web\im>%IM%convert rose: miff:- |%IM%imdisplay -
convert.exe: unable to write blob `-': Broken pipe @ error/blob.c/ImageToFile/1730.
f:\web\im>%IM%convert rose: miff:- |%IM%imdisplay
convert.exe: unable to write blob `-': Broken pipe @ error/blob.c/ImageToFile/1730.
snibgo's IM pages: im.snibgo.com
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Broken pipe error
Try png:- or or tiff:- and see if they work. It could be a miff: issue
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Broken pipe error
Just curious, but I thought show: was a unix only tool. But perhaps I am wrong. Perhaps you can configure the delegates.xml file to use imdisplay or some windows tool to display the image when show: is used. If so, it might be useful to others to know how you did the configuration. I presume you are using show: outside Cygwin. But does it work in Cygwin along with x: if X11 delegate is installed. It might be nice to add something to the docs at http://www.imagemagick.org/Usage/windows/
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Broken pipe error
Tiff:- and png:- don't work here. I suspect imdisplay isn't reading from stdin.
I don't use or know X.
show: and win: both work in pre-built binaries of recent IM versions, under Windows, with no changes required.
I don't use or know X.
show: and win: both work in pre-built binaries of recent IM versions, under Windows, with no changes required.
snibgo's IM pages: im.snibgo.com
- fmw42
- Posts: 25562
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
Re: Broken pipe error
Nice to know. Perhap Dirk fixed them. I never thought that show: would work with Windows.snibgo wrote: show: and win: both work in recent IM versions, under Windows, with no changes required.
Thanks
Re: Broken pipe error
Magick enabled this two years ago, he should get the credits. IMDisplay can only read from a file and has no support for reading from stdin at the moment. I will bookmark this topic and see if I can add support for this at some point
-
- Posts: 4
- Joined: 2015-04-08T10:35:14-07:00
- Authentication code: 6789
Re: Broken pipe error
Thanks all for all these feedbacks
I have no problem with show: indeed, that's my current workaround. But I need to use IMDisplay (or maybe something else) in order to control better the displayed picture (eg show full screen or window sized properly to fit the full content (no need to scroll))...
Cannot try yet your tips, I'll do later today and let you know my findings, if any.
Thanks again
I have no problem with show: indeed, that's my current workaround. But I need to use IMDisplay (or maybe something else) in order to control better the displayed picture (eg show full screen or window sized properly to fit the full content (no need to scroll))...
Cannot try yet your tips, I'll do later today and let you know my findings, if any.
Thanks again
-
- Posts: 4
- Joined: 2015-04-08T10:35:14-07:00
- Authentication code: 6789
Re: Broken pipe error
Dear All,
Well, it's ok with convert instead of IMdisplay. Seems to confirm the pipe is not possible with it.
But I still don't know yet how to open the window in IMdisplay so that it is maximized and the size of the IMdisplay window itself is large enough to contain the full picture without any need of scrollbars...
Any idea is welcome - I'd like to avoid playing with delegate for now... if possible.
Thx
ALeX
Well, it's ok with convert instead of IMdisplay. Seems to confirm the pipe is not possible with it.
But I still don't know yet how to open the window in IMdisplay so that it is maximized and the size of the IMdisplay window itself is large enough to contain the full picture without any need of scrollbars...
Any idea is welcome - I'd like to avoid playing with delegate for now... if possible.
Thx
ALeX
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Broken pipe error
I don't think that is possible with IMdisplay.Salsalex2011 wrote:But I still don't know yet how to open the window in IMdisplay so that it is maximized and the size of the IMdisplay window itself is large enough to contain the full picture without any need of scrollbars...
I have set up IM so converting to "msph:" uses Microsoft Photo Viewer, which by default reduces an image to fit in the window.
Code: Select all
convert wizard: msph:
msph.bat is in a directory in my %PATH%. It contains a single line:
Code: Select all
rundll32.exe "C:\Program Files\Windows Photo Viewer\PhotoViewer.dll", ImageView_Fullscreen %~dpnx1
Code: Select all
<delegate decode="png" encode="msph" command="msph.bat %i"/>
snibgo's IM pages: im.snibgo.com
-
- Posts: 4
- Joined: 2015-04-08T10:35:14-07:00
- Authentication code: 6789
Re: Broken pipe error
Thanks fro the idea, I'll try it
-
- Posts: 1
- Joined: 2016-05-10T23:39:48-07:00
- Authentication code: 1151
Re: Broken pipe error
Personally, I'm still experiencing "Broken pipe error" on Linux with IM 6.7 whil converting in tif format from the CLI
-
- Posts: 12159
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
Re: Broken pipe error
@marcomarsala: I don't know if your post is serious. Unless you tell us the version of IM you use, and what command you use, and what happens instead, no advice is possible.
snibgo's IM pages: im.snibgo.com