synfig-core  1.0.3
trgt_magickpp.h
Go to the documentation of this file.
1 
20 /* === S T A R T =========================================================== */
21 
22 #ifndef __SYNFIG_TRGT_MAGICKPP_H
23 #define __SYNFIG_TRGT_MAGICKPP_H
24 
25 /* === H E A D E R S ======================================================= */
26 
27 #include <synfig/target_scanline.h>
28 #include <synfig/string.h>
29 #include <synfig/targetparam.h>
30 #include <cstdio>
31 
32 #include <vector>
33 #include <Magick++.h>
34 
35 /* === M A C R O S ========================================================= */
36 
37 /* === T Y P E D E F S ===================================================== */
38 
39 /* === C L A S S E S & S T R U C T S ======================================= */
40 
42 {
44 
45 private:
46 
47  int width, height;
48 
49  synfig::String filename;
50  unsigned char *buffer1, *start_pointer, *buffer_pointer;
51  unsigned char *buffer2, *previous_buffer_pointer;
52  bool transparent;
53  synfig::Color *color_buffer;
54  std::vector<Magick::Image> images;
55  synfig::String sequence_separator;
56 
57 public:
58 
59  magickpp_trgt(const char *filename, const synfig::TargetParam &params):
60  width(),
61  height(),
62  filename(filename),
63  buffer1(NULL),
64  start_pointer(NULL),
65  buffer_pointer(NULL),
66  buffer2(NULL),
67  previous_buffer_pointer(NULL),
68  transparent(),
69  color_buffer(NULL),
70  sequence_separator(params.sequence_separator)
71  { }
72  virtual ~magickpp_trgt();
73 
74  virtual bool set_rend_desc(synfig::RendDesc *desc);
75  virtual bool init(synfig::ProgressCallback *cb);
76 
77  virtual bool start_frame(synfig::ProgressCallback *cb);
78  virtual void end_frame();
79 
80  virtual synfig::Color* start_scanline(int scanline);
81  virtual bool end_scanline();
82 };
83 
84 /* === E N D =============================================================== */
85 
86 #endif