-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathPBMImage.h
More file actions
31 lines (30 loc) · 944 Bytes
/
PBMImage.h
File metadata and controls
31 lines (30 loc) · 944 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
#pragma once
#include "Image.h"
class PBM : public Image
{
private:
int** pixel;
int** copyofPixel();
void deletecopyofPixel(int**);
public:
PBM(const char* mN = "" ,unsigned int w =0, unsigned int h =0, const char* n ="", unsigned int mC = 1);
PBM(std::string mN = "", unsigned int w = 0, unsigned int h = 0, std::string n = "", unsigned int mC = 1);
PBM(const PBM& other);
PBM& operator=(const PBM& other);
~PBM();
void createPixels(unsigned int , unsigned int);
void deletePixels();
void copyPixels(const PBM&);
void readPixels(std::istream& in);
void readPixels();
void printPixels(std::ostream& out);
void printPixels();
void rotate(std::string direction);
void grayscale();
void monochrome();
void negative();
Image* getCopy();
void save(std::ostream& out);
friend std::istream& operator>>(std::istream& in, PBM& pp);
friend std::ostream& operator<<(std::ostream& out, PBM& pp);
};