File:  [Repository ATC2] / QuadraticMandel / mypng.h
Revision 1.2: download - view: text, annotated - select for diffs
Tue Oct 18 09:02:34 2011 UTC (13 years ago) by cvsmgr
Branches: MAIN
CVS tags: HEAD
Quadratic fractal set generation.

/*******************************************************************************
+*  Fractal set generation for quadratic maps.
+*  Copyright (C) 2011, Raúl Durán Díaz, raul.duran@uah.es
+*
+*  This program is free software: you can redistribute it and/or modify
+*  it under the terms of the GNU General Public License as published by
+*  the Free Software Foundation, either version 3 of the License, or
+*  (at your option) any later version.
+*
+*  This program is distributed in the hope that it will be useful,
+*  but WITHOUT ANY WARRANTY; without even the implied warranty of
+*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+*  GNU General Public License for more details.
+*
+*  You should have received a copy of the GNU General Public License
+*  along with this program.  If not, see <http://www.gnu.org/licenses/>.
*******************************************************************************/
/*******************************************************************************
+* Soporte para librería png.
+*
+* 7.07.2005
+*
+* $Id: mypng.h,v 1.2 2011/10/18 09:02:34 cvsmgr Exp $
+* $Name:  $
*******************************************************************************/
# include "png.h"

# define ERROR 1
# define OK    0
# define NUM_COLS (768)
# define NUM_ROWS (576)
# define SIDE     10.0
# define INCR     (SIDE/NUM_COLS)
# define NUM_TEXT      7
# define TEXT_LENGTH 256

typedef int BOOL;

BOOL           ReadPNGText(char *file_name);
BOOL           WritePNG(char *file_name, png_colorpp pixels,
                        png_textp text_ptr, int num_text);
png_colorpp    AllocatePNG(png_uint_32 height, png_uint_32 width);
void           BuildTextPtr(png_textp info_text, double alpha, double beta, int itermax,
                            double side_len, double offset_x, double offset_y);
void           DeallocatePNG(png_colorpp p, png_uint_32 height, png_uint_32 width);
double         PixToCoordX(int x);
int            CoordXToPix(double x);
double         PixToCoordY(int y);
int            CoordYToPix(double y);
void           SetSide(double l);
void           SetImageSize(int rows, int columns);
void           SetOffsetX(double off_x);
void           SetOffsetY(double off_y);
void           DrawVertiLine(png_colorpp image, double coord_x, png_color p);
void           DrawHorizLine(png_colorpp image, double coord_y, png_color p);

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>