/usr/share/doc/gri/html/example6.html is in gri-html-doc 2.12.23-9build2.
This file is owned by root:root, with mode 0o644.
The actual contents of the file can be viewed below.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 | <html>
<head>
<title>example6.gri</title>
</head>
<body bgcolor="#FFFFFF">
<i># This html document was prepared by gri2html based on the Gri script named</i>
<br><i># <a href="example6.gri">example6.gri</a></i>
<br># <i>Gri is available for free at <a href="http://gri.sourceforge.net">http://gri.sourceforge.net</a></i>
<pre>
<font color=#B22222># Example 6 -- Plot IR image of Gulf of Maine</font>
<font color=#B22222># Define characteristics of norda images</font>
<font color=#B22222># Note that the pixel to temperature conversion formula is</font>
<font color=#B22222>#</font>
<font color=#B22222># Temperature = 5C + pixel_value / 10</font>
<font color=#B22222>#</font>
<font color=#B22222># where pixel_value ranges from 0 to 255. Thus, a pixel</font>
<font color=#B22222># value of 0 corresponds to a temperatuer of 5C, and</font>
<font color=#B22222># 255 corresponds to 30.5C; this is why the limits</font>
<font color=#B22222># \0val and \255val, for use by the `set image</font>
<font color=#B22222># range' command, take on these values.</font>
<font color=#0000EE>\0val =</font> <font color=#2F4F4F>"5"</font> <font color=#B22222># 0 in image</font>
<font color=#0000EE>\255val =</font> <font color=#2F4F4F>"30.5"</font> <font color=#B22222># 255 in image</font>
<font color=#0000EE>.rows. =</font> 128
<font color=#0000EE>.cols. =</font> 128
<font color=#0000EE>.pixel_width. =</font> 2
<font color=#0000EE>.km. =</font> {<font color=#9400D3>rpn</font><font color=#CDAD00> .cols.</font><font color=#CDAD00> .pixel_width.</font> *}
<font color=#B22222># get filenames</font>
query<font color=#0000EE> \filename</font> <font color=#2F4F4F>"Name image file" ("example6image.dat"</font>)
query<font color=#0000EE> \maskname</font> <font color=#2F4F4F>"Name mask file" ("example6mask.dat"</font>)
<font color=#B22222># get data</font>
open<font color=#0000EE> \filename</font> binary uchar
set image range<font color=#0000EE> \0val</font><font color=#0000EE> \255val
</font>read image<font color=#CDAD00> .rows.</font><font color=#CDAD00> .cols.</font> box 0 0<font color=#CDAD00> .km.</font><font color=#CDAD00> .km.</font>
close
open<font color=#0000EE> \maskname</font> binary uchar
read image mask<font color=#CDAD00> .rows.</font><font color=#CDAD00> .cols.</font>
close
<font color=#B22222># find out what grayscale method to use</font>
query<font color=#0000EE> \histo</font> <font color=#2F4F4F>"Do histogram enhancement? (yes|no)" ("no"</font>)
query<font color=#0000EE> \minT</font> <font color=#2F4F4F>"T/deg for white on page? " ("10"</font>)
query<font color=#0000EE> \maxT</font> <font color=#2F4F4F>"T/deg for black on page? " ("15"</font>)
<font color=#0000EE>\incT =</font> <font color=#2F4F4F>"1"</font>
<font color=#B22222># set up scales. </font>
set x size 12.8
set y size 12.8
set x name <font color=#2F4F4F>"km"</font>
set y name <font color=#2F4F4F>"km"</font>
set x axis 0<font color=#CDAD00> .km.</font> 32
set y axis 0<font color=#CDAD00> .km.</font> 32
<font color=#B22222># plot image, grayscale, and histogram</font>
<font color=#9400D3>if</font> {<font color=#2F4F4F>"<font color=#0000EE>\histo" =</font>= "yes"</font>}
set image grayscale using histogram black<font color=#0000EE> \maxT</font> white<font color=#0000EE> \minT
</font><font color=#9400D3>else</font>
set image grayscale black<font color=#0000EE> \maxT</font> white<font color=#0000EE> \minT
</font><font color=#9400D3>end if</font>
draw image
draw image palette left<font color=#0000EE> \minT</font> right<font color=#0000EE> \maxT</font> increment<font color=#0000EE> \incT
</font>draw image histogram
<font color=#9400D3>if</font> {<font color=#2F4F4F>"<font color=#0000EE>\histo" =</font>= "yes"</font>}
draw title <font color=#2F4F4F>"Example 6: grayscale histogram enhanced"</font>
<font color=#9400D3>else</font>
draw title <font color=#2F4F4F>"Example 6: grayscale linear<font color=#0000EE> \minT</font> to<font color=#0000EE> \maxT"</font>
</font><font color=#9400D3>end if</font>
</pre>
</body>
</html>
|