Code base obscuration (for images) 1.0
It implements different obscuration methods on portable images (.pgm and .ppm)
|
This file contains the main function for the PPM image obscuration program, which applies various image obscuration techniques to PPM images using the Paillier cryptosystem. More...
#include "../../../include/model/filesystem/filesystemCommon.hpp"
#include "../../../include/model/image/ImageBase.hpp"
#include "../../../include/model/image/image_ppm.hpp"
#include "../../../include/model/obscuration/obscurationCommon.hpp"
#include "../../../include/model/obscuration/obscurationPPM.hpp"
#include <cstdio>
#include <cstring>
#include <filesystem>
#include <string>
#include <vector>
Functions | |
bool | is_ppm (const std::string &extension) |
Checks if a given file extension is PPM. | |
void | getFilePathsOfPPMFilesFromFolder (std::vector< std::string > &imagePaths, std::string folderPath) |
Gets the file paths of all PPM images in a given folder. | |
void | string2char (std::string str, char *charArray) |
Converts a std::string to a char array. | |
int | main (int argc, char **argv) |
Main function for the PPM image obscuration program. | |
This file contains the main function for the PPM image obscuration program, which applies various image obscuration techniques to PPM images using the Paillier cryptosystem.
The techniques include blurring, scrambling, pixelation, and selective encryption. The program takes a directory as input and applies the obscuration techniques to all PPM images in the directory. The obscured images are then saved to separate directories based on the technique used. Source files main.cpp and Functions.h by Norman Hutte.
void getFilePathsOfPPMFilesFromFolder | ( | std::vector< std::string > & | imagePaths, |
std::string | folderPath ) |
Gets the file paths of all PPM images in a given folder.
imagePaths | The vector to store the file paths in. |
folderPath | The path to the folder to search in. |
bool is_ppm | ( | const std::string & | extension | ) |
Checks if a given file extension is PPM.
extension | The file extension to check. |
int main | ( | int | argc, |
char ** | argv ) |
Main function for the PPM image obscuration program.
argc | The number of command-line arguments. |
argv | The command-line arguments. |
void string2char | ( | std::string | str, |
char * | charArray ) |
Converts a std::string to a char array.
str | The string to convert. |
charArray | The char array to store the result in. |