# E:/DevIL/src-IL/src/il_png.c File Reference

`#include "il_internal.h"`
`#include <png.h>`
`#include "il_manip.h"`
`#include <stdlib.h>`

## Defines

#define | GAMMA_CORRECTION 1.0

## Functions

ILboolean | iIsValidPng (void)
ILboolean | iLoadPngInternal (void)
ILboolean | iSavePngInternal (void)
ILint | readpng_init (void)
ILboolean | readpng_get_image (ILdouble display_exponent)
void | readpng_cleanup (void)
ILboolean | ilIsValidPng (ILconst_string FileName)
ILboolean | ilIsValidPngF (ILHANDLE File)
ILboolean | ilIsValidPngL (const void *Lump, ILuint Size)
ILboolean | ilLoadPng (ILconst_string FileName)
ILboolean | ilLoadPngF (ILHANDLE File)
ILboolean | ilLoadPngL (const void *Lump, ILuint Size)
ILboolean | ilSavePng (const ILstring FileName)
| Writes a Png file.
ILuint | ilSavePngF (ILHANDLE File)
| Writes a Png to an already-opened file.
ILuint | ilSavePngL (void *Lump, ILuint Size)
| Writes a Png to a memory "lump".
void | png_write (png_structp png_ptr, png_bytep data, png_size_t length)
void | flush_data (png_structp png_ptr)

## Variables

png_structp | png_ptr = NULL
png_infop | info_ptr = NULL
ILint | png_color_type

## Define Documentation

#define GAMMA_CORRECTION 1.0

## Function Documentation

void flush_data | ( | png_structp | png_ptr | ) |

Referenced by iSavePngInternal().

ILboolean iIsValidPng | ( | void |  | ) |

Referenced by ilIsValidPngF(), ilIsValidPngL(), and iLoadPngInternal().

ILboolean ilIsValidPng | ( | ILconst_string | FileName | ) |

Referenced by ilIsValid().

ILboolean ilIsValidPngF | ( | ILHANDLE | File | ) |

Referenced by ilDetermineTypeF(), ilIsValidF(), and ilIsValidPng().

ILboolean ilIsValidPngL | ( | const void * | Lump,
|  | ILuint | Size |
| ) |  |  |

Referenced by ilDetermineTypeL(), and ilIsValidL().

ILboolean ilLoadPng | ( | ILconst_string | FileName | ) |

Referenced by ilLoad(), and ilLoadImage().

ILboolean ilLoadPngF | ( | ILHANDLE | File | ) |

Referenced by ilLoadF(), and ilLoadPng().

ILboolean ilLoadPngL | ( | const void * | Lump,
|  | ILuint | Size |
| ) |  |  |

Referenced by ilLoadL().

ILboolean iLoadPngInternal | ( | void |  | ) |

Referenced by ilLoadPngF(), and ilLoadPngL().

ILboolean ilSavePng | ( | const ILstring | FileName | ) |

Writes a Png file.

Referenced by ilSave(), and ilSaveImage().

ILuint ilSavePngF | ( | ILHANDLE | File | ) |

Writes a Png to an already-opened file.

Referenced by ilSaveF(), and ilSavePng().

ILuint ilSavePngL | ( | void * | Lump,
|  | ILuint | Size |
| ) |  |  |

Writes a Png to a memory "lump".

Referenced by ilDetermineSize(), and ilSaveL().

ILboolean iSavePngInternal | ( | void |  | ) |

Referenced by ilSavePngF(), and ilSavePngL().

void png_write | ( | png_structp | png_ptr,
|  | png_bytep | data,
|  | png_size_t | length |
| ) |  |  |

Referenced by iSavePngInternal().

void readpng_cleanup | ( | void |  | ) |

Referenced by iLoadPngInternal().

ILboolean readpng_get_image | ( | ILdouble | display_exponent | ) |

Referenced by iLoadPngInternal().

ILint readpng_init | ( | void |  | ) |

Referenced by iLoadPngInternal().

## Variable Documentation

png_infop info_ptr = NULL

Referenced by iLoadPngInternal(), iSavePngInternal(), readpng_cleanup(), readpng_get_image(), and readpng_init().

ILint png_color_type

Referenced by readpng_get_image().

png_structp png_ptr = NULL

Referenced by iLoadPngInternal().