WXP C++ Library Version 6.74.6
Loading...
Searching...
No Matches
PngFile.h
1#ifndef _WINC_PNG
2#define _WINC_PNG
3
4#include <WXP/File.h>
5#include <WXP/Image.h>
6
7namespace WXP {
8 class PngFile {
9 File file; /* The file */
10 bool opened;
11 int access;
12 int width; /* Width of image */
13 int height; /* Height of image */
14 int depth; /* Depth of image */
15 int index;
16 int use_inter;
17 char title[40];
18 char comment[1000];
19
20 public:
21 PngFile();
22 ~PngFile();
23 int init();
24
25 PngFile( const char *filename, int access );
26 int open( const char *filename, int access );
27 bool isOpen();
28 int close();
29 int setInterlace( int val );
30 int setTitle( const char *str );
31 int setComment( const char *str );
32 /*
33 Decode routines
34 */
35 int read( Image &image );
36 int read( const char *filename, Image &image );
37 /*
38 Encode routines
39 */
40 int write( Image &image );
41 int write( const char *filename, Image &image );
42 };
43}
44#endif
This class accesses files.
Definition: File.h:15
This class defines an image.
Definition: Image.h:19
This class reads and write PNG image files.
Definition: PngFile.h:8
int setTitle(const char *str)
Definition: PngFile.cc:108
int init()
Definition: PngFile.cc:55
int open(const char *filename, int access)
Definition: PngFile.cc:67
PngFile()
Definition: PngFile.cc:31
int read(Image &image)
Definition: PngFile.cc:126
int setComment(const char *str)
Definition: PngFile.cc:117
bool isOpen()
Definition: PngFile.cc:82
int write(Image &image)
Definition: PngFile.cc:382
int setInterlace(int val)
Definition: PngFile.cc:99
~PngFile()
Definition: PngFile.cc:48
int close()
Definition: PngFile.cc:89
All WXP classes fall under the WXP namespace.
Definition: Angle.h:4