Bitmap/Write a PPM file: Difference between revisions
Content added Content deleted
m (→{{header|Rust}}: Rust `try` macros have been deprecated in stable rust as of 1.39.0, and have since been replaced by the ? operator) |
Thundergnat (talk | contribs) m (Regularize non-standard header markup) |
||
Line 1,311: | Line 1,311: | ||
END PPM.</lang> |
END PPM.</lang> |
||
== |
=={{Header|Nim}}== |
||
<lang nim>import bitmap |
<lang nim>import bitmap |
||
import streams |
import streams |
||
Line 1,349: | Line 1,349: | ||
image.writePPM("output.ppm")</lang> |
image.writePPM("output.ppm")</lang> |
||
== |
=={{Header|OCaml}}== |
||
<lang ocaml>let output_ppm ~oc ~img:(_, r_channel, g_channel, b_channel) = |
<lang ocaml>let output_ppm ~oc ~img:(_, r_channel, g_channel, b_channel) = |