5 #ifndef PDFTRON_H_CPPPDFPDFDraw
6 #define PDFTRON_H_CPPPDFPDFDraw
9 #include <C/PDF/TRN_PDFDraw.h>
19 namespace Gdiplus {
class Bitmap; };
34 std::vector<unsigned char> buf;
43 memcpy(&buf[0], b, h*s);
56 std::vector<unsigned char> temp(b.
GetBuffer());
135 void SetImageSize(
int width,
int height,
bool preserve_aspect_ratio =
true);
252 void SetImageSmoothing(
bool smoothing_enabled =
true,
bool hq_image_resampling =
false);
462 #if defined(_WIN32) && !defined(__WINRT__)
534 const UChar*
GetBitmap(
Page page,
int& out_width,
int& out_height,
int& out_stride,
double& out_dpi,
579 #include <Impl/PDFDraw.inl>
585 #endif // PDFTRON_H_CPPPDFPDFDraw
void SetGamma(double exp)
void SetPathHinting(bool enable_hinting)
void SetClipRect(Rect clip_rect)
void SetPrintMode(bool is_printing)
void SetImageSmoothing(bool smoothing_enabled=true, bool hq_image_resampling=false)
void SetPageBox(Page::Box region)
void SetThinLineScaling(double scaling)
BitmapInfo(const BitmapInfo &b)
void(* ErrorReportProc)(const char *message, void *data)
void SetPageTransparent(bool is_transparent)
void SetImageSize(int width, int height, bool preserve_aspect_ratio=true)
BitmapInfo(int w, int h, int s, double d, char *b)
std::vector< Separation > GetSeparationBitmaps(Page page)
void SetRotate(Page::Rotate r)
void SetDefaultPageColor(UInt8 r, UInt8 g, UInt8 b)
void SetFlipYAxis(bool flip_y)
void SetErrorReportProc(PDFRasterizer::ErrorReportProc error_proc, void *data)
std::vector< unsigned char > GetBuffer() const
void Export(Page page, const UString &filename, const char *format="PNG", SDF::Obj encoder_params=0)
void SetRasterizerType(PDFRasterizer::Type type)
void SetCaching(bool enabled=true)
const BitmapInfo GetBitmap(Page page, PixelFormat pix_fmt=e_bgra, bool demult=false)
void SetDrawUIElements(bool draw_ui_elements)
void SetDrawAnnotations(bool render_annots)
void SetOCGContext(OCG::Context *ctx)
void SetColorPostProcessMode(PDFRasterizer::ColorPostProcessMode mode)
void SetHighlightFields(bool highlight_fields)
void SetAntiAliasing(bool enable_aa)
void SetThinLineAdjustment(bool pixel_grid_fit, bool stroke_adjust)
void SetOverprint(PDFRasterizer::OverprintPreviewMode op)
void DrawInRect(Page &page, void *hdc, const Rect &rect)