Skip to content

Commit eb91d4c

Browse files
committed
Explain the purpose of introducing dt_imageio_png_read_header and dt_imageio_png_read_image
1 parent 3decb94 commit eb91d4c

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

src/imageio/imageio_png.c

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,12 @@
3131
#include "imageio_common.h"
3232
#include "imageio_png.h"
3333

34+
35+
// Reading of PNG files also takes place in the LUT 3D module in order to obtain
36+
// LUTs encoded in this format. To minimize code duplication, we put the code
37+
// common to both uses (reading the header and reading the image itself) into
38+
// two functions, dt_imageio_png_read_header and dt_imageio_png_read_image.
39+
3440
gboolean dt_imageio_png_read_header(const char *filename, dt_imageio_png_t *png)
3541
{
3642
png->f = g_fopen(filename, "rb");

0 commit comments

Comments
 (0)