Bitmap/Read an image through a pipe: Difference between revisions
Content added Content deleted
m (→{{header|Go}}: library path updates) |
(→{{header|C}}: {{improve}} on messy code) |
||
Line 70: | Line 70: | ||
=={{header|C}}== |
=={{header|C}}== |
||
{{improve|C|Too many dependencies, too complicated for a reader to set up.}} |
|||
{{works with|POSIX|.1-2001}} |
{{works with|POSIX|.1-2001}} |
||
Here I've used '''convert''' by ImageMagick. It is up to the program to ''understand'' the source file type; in this way, we can read theoretically any image format ImageMagick can handle. The <tt>get_ppm</tt> function defined in [[Read ppm file]] is used. |
Here I've used '''convert''' by ImageMagick. It is up to the program to ''understand'' the source file type; in this way, we can read theoretically any image format ImageMagick can handle. The <tt>get_ppm</tt> function defined in [[Read ppm file]] is used. |
||
Line 103: | Line 105: | ||
return NULL; |
return NULL; |
||
}</lang> |
}</lang> |
||
=={{header|Go}}== |
=={{header|Go}}== |
||
{{works with|Go weekly.2011-12-14}} |
{{works with|Go weekly.2011-12-14}} |