This commit is contained in:
Ingy döt Net 2013-04-10 16:19:29 -07:00
parent e5e8880e41
commit 518da4a923
1019 changed files with 15877 additions and 0 deletions

View file

@ -0,0 +1,17 @@
/*REXX program to write a PPM formatted image file, P6 (binary). */
oFID = 'IMAGE.PPM' /*name of the output file. */
green = '00 ff 00'x
image. = green /*define all IMAGE RGB's to green*/
width = 20 /*define the width of IMAGE. */
height = 20 /* " " height " " */
sep = '9'x
call put 'P6'width||sep||height||sep||255||sep /*write header info.*/
do j =1 for width
do k=1 for height
call put image.j.k /*write IMAGE, 3 bytes at a time.*/
end /*k*/
end /*j*/
exit /*stick a fork in it, we're done.*/
/*─────────────────────────────────────subroutines──────────────────────*/
put: call charout oFID,arg(1); return /*write out character(s) to file.*/