diff options
author | Pin <wf6DJd8a3xSSCZbn@protonmail.com> | 2021-12-03 18:45:05 -0500 |
---|---|---|
committer | Pin <wf6DJd8a3xSSCZbn@protonmail.com> | 2021-12-03 18:45:05 -0500 |
commit | 9afed448df20c9bc1681369267dd240fe2f3465b (patch) | |
tree | 7d67c31538a853828642b2fbb08c126f6f2aaee8 | |
parent | 5b45337d98ad1930059c9c7e77cab63442249a86 (diff) |
Updatewip
-rw-r--r-- | README.md | 2 | ||||
-rw-r--r-- | cmd/pspng.c | 3 |
2 files changed, 4 insertions, 1 deletions
@@ -4,6 +4,8 @@ Sample program to embed messages into PNG images ## Install +**NOTE:** Set the core_count variable to one value lower than maximum cores on the host in cmd/pspng.c + Requires zlib, pthread, and sodium header files to compile (These will be distro specific packages) Build: diff --git a/cmd/pspng.c b/cmd/pspng.c index 2bf9d7a..8a99a31 100644 --- a/cmd/pspng.c +++ b/cmd/pspng.c @@ -265,7 +265,8 @@ static int crc_embed_data(unsigned char *data, unsigned int data_length, int bit raw_data = create_raw_pixel_values(data, bit_width, color_range, sliding_window); random_window_bit_change(data, raw_data, bit_width, 2, color_range, sliding_window, offset); - if(offset > 500000) { + //if(offset > 500000) { + if(offset == -1) { new_data = calloc(300000, sizeof(unsigned char)); for(int k = 0; k < 300000; k++) { new_data[k] = data[offset-(offset-prior_offset-1)+k]; |