Bitmap/PPM conversion through a pipe: Difference between revisions
Content added Content deleted
(→{{header|Tcl}}: Added zkl) |
(Added Mathematica) |
||
Line 108: | Line 108: | ||
} |
} |
||
}</lang> |
}</lang> |
||
=={{header|Mathematica}}== |
|||
{{untested|Mathematica}} |
|||
<lang Mathematica>convert[img_, out_] := |
|||
Module[{pipe = |
|||
StartProcess[{"WolframKernel", "-noinit", "-noprompt", "-run", |
|||
"Export[\"out.jpg\",ImportString[InputString[],\"PPM\"]]"}]}, |
|||
WriteString[pipe, ExportString[Image[Graphics[]], "PPM"]]; |
|||
Close[pipe];];</lang> |
|||
== {{Header|OCaml}} == |
== {{Header|OCaml}} == |