PGMA_TO_PGMB\
convert ASCII PGM to binary PGM graphics file {#pgma_to_pgmb-convert-ascii-pgm-to-binary-pgm-graphics-file align=”center”}
=============================================
PGMA_TO_PGMB is a C++ program which converts ASCII PGM files to
binary PGM format.
Usage: {#usage align=”center”}
pgma_to_pgmb file1 file2
where
- file1 is the name of an existing PGM file in ASCII format;
- file2 is the name of the PGM file in binary format to be created.
Licensing: {#licensing align=”center”}
The computer code and data files described and made available on this
web page are distributed under the GNU LGPL
license.
Languages: {#languages align=”center”}
PGMA_TO_PGMB is available in a C++
version.
PGMA, a data directory which contains
sample ASCII PGM files.
PGMA_IO, a C++ library which is
used by PGMA_TO_PGMB to read in the ASCII PGM file.
PGMB, a data directory which contains
sample binary PGM files.
PGMB_IO, a C++ library which is
used by PGMA_TO_PGMB to write out the binary PGM file.
PGMB_TO_PGMA, a C++
program which converts a binary PGM file to ASCII PGM format.
Reference: {#reference align=”center”}
- the NETPBM homepage.
Source Code: {#source-code align=”center”}
List of Routines: {#list-of-routines align=”center”}
- MAIN is the main program for PGMA_TO_PGMB.
- I4VEC_TO_UCVEC converts an I4VEC into UNSIGNED CHAR’s.
- PGMA_CHECK_DATA checks the data for an ASCII PGM file.
- PGMA_READ reads the header and data from an ASCII PGM file.
- PGMA_READ_DATA reads the data in an ASCII PGM file.
- PGMA_READ_HEADER reads the header of an ASCII PGM file.
- PGMA_TO_PGMB converts an ASCII PGM file to binary PGM format.
- PGMB_WRITE writes the header and data for a binary portable
gray map file.
- PGMB_WRITE_DATA writes the data for a binary portable gray map
file.
- PGMB_WRITE_HEADER writes the header of a binary portable gray
map file.
- S_LEN_TRIM2 returns the length of a string to the last
nonblank.
- S_WORD_EXTRACT_FIRST2 extracts the first word from a string.
- TIMESTAMP prints the current YMDHMS date as a time stamp.
You can go up one level to the C++ source codes.
Last revised on 30 March 2011.