ciderpress/reformat/HiRes.h
Andy McFadden 8f61f84585 Use types with explicit sizes
Much of what the "reformat" code does involves processing data that is
8, 16, or 32 bits.  We want to use size-specific types from stdint.h
(e.g. uint16_t) rather than "unsigned short".

This was a quick pass to replace the various "unsigned" declarations.
More can be done here and elsewhere.
2014-11-20 18:10:18 -08:00

45 lines
1.0 KiB
C++

/*
* CiderPress
* Copyright (C) 2007 by faddenSoft, LLC. All Rights Reserved.
* See the file LICENSE for distribution terms.
*/
/*
* Reformat hi-res images.
*/
#ifndef REFORMAT_HIRES_H
#define REFORMAT_HIRES_H
#include "ReformatBase.h"
/*
* Reformat a HiRes graphic into a bitmap.
*/
class ReformatHiRes : public ReformatGraphics {
public:
ReformatHiRes(void) { fBlackWhite = false; }
virtual ~ReformatHiRes(void) {}
virtual void Examine(ReformatHolder* pHolder);
virtual int Process(const ReformatHolder* pHolder,
ReformatHolder::ReformatID id, ReformatHolder::ReformatPart part,
ReformatOutput* pOutput);
enum {
kPixelsPerLine = 280,
kNumLines = 192,
kOutputWidth = 560,
kOutputHeight = 384,
kExpectedSize = 8192,
};
static void InitLineOffset(int* pOffsetBuf);
MyDIBitmap* HiResScreenToBitmap(const uint8_t* buf);
int fLineOffset[kNumLines];
bool fBlackWhite;
};
#endif /*REFORMAT_HIRES_H*/