src/platform/imagemagick/imagemagick-gif-encoder.h (view raw)
1/* Copyright (c) 2013-2015 Jeffrey Pfau
2 *
3 * This Source Code Form is subject to the terms of the Mozilla Public
4 * License, v. 2.0. If a copy of the MPL was not distributed with this
5 * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
6#ifndef IMAGEMAGICK_GIF_ENCODER
7#define IMAGEMAGICK_GIF_ENCODER
8
9#include "gba/gba.h"
10
11#define MAGICKCORE_HDRI_ENABLE 0
12#define MAGICKCORE_QUANTUM_DEPTH 8
13
14#include <wand/MagickWand.h>
15
16struct ImageMagickGIFEncoder {
17 struct GBAAVStream d;
18 MagickWand* wand;
19 char* outfile;
20 uint32_t* frame;
21
22 unsigned currentFrame;
23 int frameskip;
24 int delayMs;
25};
26
27void ImageMagickGIFEncoderInit(struct ImageMagickGIFEncoder*);
28void ImageMagickGIFEncoderSetParams(struct ImageMagickGIFEncoder* encoder, int frameskip, int delayMs);
29bool ImageMagickGIFEncoderOpen(struct ImageMagickGIFEncoder*, const char* outfile);
30bool ImageMagickGIFEncoderClose(struct ImageMagickGIFEncoder*);
31bool ImageMagickGIFEncoderIsOpen(struct ImageMagickGIFEncoder*);
32
33#endif