summaryrefslogtreecommitdiff
path: root/example.c
diff options
context:
space:
mode:
authorGlenn Randers-Pehrson <glennrp@shaggy.simplesystems.org>2009-05-13 07:42:05 -0500
committerGlenn Randers-Pehrson <glennrp@shaggy.simplesystems.org>2009-05-13 07:42:05 -0500
commit1296329f028ca9aa5fb2e504d9db8b06804b49b1 (patch)
treef941ce1fcaf506eba46b8ae0166dedc0c10b0745 /example.c
parente38b432846ab971aae1e367bae23c761be491f43 (diff)
downloadlibpng-1296329f028ca9aa5fb2e504d9db8b06804b49b1.tar.gz
Revised commentary in example.c
Diffstat (limited to 'example.c')
-rw-r--r--example.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/example.c b/example.c
index e37f5009b..ee968bd4c 100644
--- a/example.c
+++ b/example.c
@@ -244,7 +244,7 @@ void read_png(FILE *fp, unsigned int sig_read) /* file is already open */
/* If we don't have another value */
else
{
- screen_gamma = 2.2; /* A good guess for a PC monitors in a dimly
+ screen_gamma = 2.2; /* A good guess for a PC monitor in a dimly
lit room */
screen_gamma = 1.7 or 1.0; /* A good guess for Mac systems */
}
@@ -681,9 +681,11 @@ void write_png(char *file_name /* , ... other image information ... */)
#endif
png_set_text(png_ptr, info_ptr, text_ptr, 3);
- /* other optional chunks like cHRM, bKGD, tRNS, tIME, oFFs, pHYs, */
+ /* other optional chunks like cHRM, bKGD, tRNS, tIME, oFFs, pHYs */
+
/* note that if sRGB is present the gAMA and cHRM chunks must be ignored
- * on read and must be written in accordance with the sRGB profile */
+ * on read and, if your application chooses to write them, they must
+ * be written in accordance with the sRGB profile */
/* Write the file header information. REQUIRED */
png_write_info(png_ptr, info_ptr);
@@ -779,7 +781,7 @@ void write_png(char *file_name /* , ... other image information ... */)
#endif no_entire /* use only one output method */
/* You can write optional chunks like tEXt, zTXt, and tIME at the end
- * as well. Shouldn't be necessary in 1.1.0 and up as all the public
+ * as well. Shouldn't be necessary in 1.2.0 and up as all the public
* chunks are supported and you can use png_set_unknown_chunks() to
* register unknown chunks into the info structure to be written out.
*/