#ifndef H_FRACTAL_ARGS
#define H_FRACTAL_ARGS
#include <stdbool.h>
#include <stdlib.h>
#include <stdio.h>
#include "optparse.h"
#define UNUSED __attribute__((unused))
#define ARG_UNDEFINED 0L
#define ARG_DEFAULT_WIDTH 1024
#define ARG_DEFAULT_HEIGHT 768
#define ARG_DEFAULT_ITERATIONS 50
#define ARG_DEFAULT_SAMPLES 1
#define ARG_DEFAULT_X -0.75
#define ARG_DEFAULT_Y 0.00
#define ARG_DEFAULT_ZOOM 300
#define ARG_DEFAULT_PALETTE "hsv(215.7,0.987,0.694)"
#define ARG_DEFAULT_DEBUG false
#define ARG_DEFAULT_VERBOSE false
#define ARG_DEFAULT_VERSION false
#define ARG_DEFAULT_HELP false
#define ARG_DEFAULT_THREADS ARG_UNDEFINED
#define ARG_DEFAULT_FILENAME "output.png"
#define xstr(x) #x
#define str(x) xstr(x)
#define opt(x,y) " ("str(x)y")"
extern struct optparse_long longopts[];
typedef struct global_args_t {
int width;
int height;
int iterations;
int samples;
double cx;
double cy;
double zoom;
char *palette;
char *filename;
int threads;
bool debug;
bool verbose;
bool version;
bool help;
} global_args;
void args_init( global_args *args );
void args_parse( char **v, global_args *args );
#endif