Browse Source

Ink colors set as program intended them to be, helps recognize dots and grid

refactor
suhrke 3 years ago
parent
commit
343feef5f3
2 changed files with 6 additions and 6 deletions
  1. 4
    4
      source/Global.h
  2. 2
    2
      source/Printer.cpp

+ 4
- 4
source/Global.h View File

@@ -67,7 +67,7 @@ typedef struct t_data { // Block on paper
ushort crc; // Cyclic redundancy of addr and data
uchar ecc[32]; // Reed-Solomon's error correction code
} t_data;
//static_assert(sizeof(t_data)==128);
static_assert(sizeof(t_data)==128);

#define PBM_COMPRESSED 0x01 // Paper backup is compressed
#define PBM_ENCRYPTED 0x02 // Paper backup is encrypted
@@ -93,7 +93,7 @@ typedef struct t_superdata { // Identification block on paper
ushort crc; // Cyclic redundancy of previous fields
uchar ecc[32]; // Reed-Solomon's error correction code
} t_superdata;
//static_assert(sizeof(t_superdata)==sizeof(t_data));
static_assert(sizeof(t_superdata)==sizeof(t_data));

typedef struct t_block { // Block in memory
ulong addr; // Offset of the block
@@ -191,7 +191,7 @@ inline void print_superblock(t_superblock &x) {
<< " origsize: " << x.origsize
<< " mode: " << x.mode
<< " page: " << x.page
// << "modified: " << x.modified
<< " modified: " << x.modified
<< " attributes: " << x.attributes
<< " filecrc: " << x.filecrc
<< " name: " << x.name
@@ -208,7 +208,7 @@ inline void print_superdata(t_superdata &x) {
<< " mode: " << x.mode
<< " attributes: " << x.attributes
<< " page: " << x.page
// << "modified: " << x.modified
<< " modified: " << x.modified
<< " filecrc: " << x.filecrc
<< " name: " << x.name
<< " crc: " << x.crc

+ 2
- 2
source/Printer.cpp View File

@@ -362,7 +362,7 @@ int Initializeprinting(t_printdata *print, uint pageWidth, uint pageHeight) {

// // Dots on paper are black (palette index 0 in the memory bitmap that will
// // be created later in this subroutine).
// print->black=0; }
print->black=0; //}
// I treat printing to bitmap as a debugging feature and set some more or
// less sound defaults.

@@ -389,7 +389,7 @@ int Initializeprinting(t_printdata *print, uint pageWidth, uint pageHeight) {
// print->extratop=print->extrabottom=0;
// // To simplify recognition of grid on high-contrast bitmap, dots on the
// // bitmap are dark gray.
// print->black=64;
print->black=64;




Loading…
Cancel
Save