| 1 | # Convert "arbitrary" image files to rgb files (SGI's image format).
|
|---|
| 2 | # Input may be compressed.
|
|---|
| 3 | # The uncompressed file type may be PBM, PGM, PPM, GIF, TIFF, or Sun raster.
|
|---|
| 4 | # An exception is raised if the file is not of a recognized type.
|
|---|
| 5 | # Returned filename is either the input filename or a temporary filename;
|
|---|
| 6 | # in the latter case the caller must ensure that it is removed.
|
|---|
| 7 | # Other temporary files used are removed by the function.
|
|---|
| 8 |
|
|---|
| 9 | import os
|
|---|
| 10 | import tempfile
|
|---|
| 11 | import pipes
|
|---|
| 12 | import imghdr
|
|---|
| 13 |
|
|---|
|
|---|