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

`#include "il_internal.h"`
`#include "il_pnm.h"`
`#include <limits.h>`
`#include <ctype.h>`
`#include "il_manip.h"`
`#include "il_bits.h"`

## Defines

#define | MAX_BUFFER 180

## Functions

ILboolean | ilIsValidPnm (ILconst_string FileName)
| Checks if the file specified in FileName is a valid .pnm file.
ILboolean | ilIsValidPnmF (ILHANDLE File)
| Checks if the ILHANDLE contains a valid .pnm file at the current position.
ILboolean | ilIsValidPnmL (const void *Lump, ILuint Size)
| Checks if Lump is a valid .pnm lump.
ILboolean | iIsValidPnm ()
ILboolean | iCheckPnm (char Header[2])
ILboolean | ilLoadPnm (ILconst_string FileName)
ILboolean | ilLoadPnmF (ILHANDLE File)
ILboolean | ilLoadPnmL (const void *Lump, ILuint Size)
ILboolean | iLoadPnmInternal ()
ILimage * | ilReadAsciiPpm (PPMINFO *Info)
ILimage * | ilReadBinaryPpm (PPMINFO *Info)
ILimage * | ilReadBitPbm (PPMINFO *Info)
ILboolean | iGetWord (ILboolean final)
ILboolean | ilSavePnm (const ILstring FileName)
| Writes a Pnm file.
ILuint | ilSavePnmF (ILHANDLE File)
| Writes a Pnm to an already-opened file.
ILuint | ilSavePnmL (void *Lump, ILuint Size)
| Writes a Pnm to a memory "lump".
ILboolean | iSavePnmInternal ()
void | PbmMaximize (ILimage *Image)

## Variables

ILboolean | IsLump = IL_FALSE
ILstring | FName = NULL

## Define Documentation

#define MAX_BUFFER 180

Referenced by iGetWord(), and ilReadAsciiPpm().

## Function Documentation

ILboolean iCheckPnm | ( | char | Header[2] | ) |

Referenced by iIsValidPnm().

ILboolean iGetWord | ( | ILboolean | final | ) |

Referenced by iLoadPnmInternal().

ILboolean iIsValidPnm | ( | void |  | ) |

Referenced by ilIsValidPnmF(), and ilIsValidPnmL().

ILboolean ilIsValidPnm | ( | ILconst_string | FileName | ) |

Checks if the file specified in FileName is a valid .pnm file.

Referenced by ilIsValid().

ILboolean ilIsValidPnmF | ( | ILHANDLE | File | ) |

Checks if the ILHANDLE contains a valid .pnm file at the current position.

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

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

Checks if Lump is a valid .pnm lump.

Referenced by ilDetermineTypeL(), and ilIsValidL().

ILboolean ilLoadPnm | ( | ILconst_string | FileName | ) |

Referenced by ilLoad(), and ilLoadImage().

ILboolean ilLoadPnmF | ( | ILHANDLE | File | ) |

Referenced by ilLoadF(), and ilLoadPnm().

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

Referenced by ilLoadL().

ILboolean iLoadPnmInternal | ( | void |  | ) |

Referenced by ilLoadPnmF(), and ilLoadPnmL().

ILimage* ilReadAsciiPpm | ( | PPMINFO * | Info | ) |

Referenced by iLoadPnmInternal().

ILimage* ilReadBinaryPpm | ( | PPMINFO * | Info | ) |

Referenced by iLoadPnmInternal().

ILimage* ilReadBitPbm | ( | PPMINFO * | Info | ) |

Referenced by iLoadPnmInternal().

ILboolean ilSavePnm | ( | const ILstring | FileName | ) |

Writes a Pnm file.

Referenced by ilSave(), and ilSaveImage().

ILuint ilSavePnmF | ( | ILHANDLE | File | ) |

Writes a Pnm to an already-opened file.

Referenced by ilSaveF(), and ilSavePnm().

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

Writes a Pnm to a memory "lump".

Referenced by ilDetermineSize(), and ilSaveL().

ILboolean iSavePnmInternal | ( | void |  | ) |

Referenced by ilSavePnmF(), and ilSavePnmL().

void PbmMaximize | ( | ILimage * | Image | ) |

Referenced by iLoadPnmInternal().

## Variable Documentation

ILstring FName = NULL

Referenced by ilIsValidSgi(), ilIsValidSgiL(), ilSavePnmL(), iSavePnmInternal(), and iSaveSgiInternal().

ILboolean IsLump = IL_FALSE

Referenced by iLoadPnmInternal().