GD-Chart

 view release on metacpan or  search on metacpan

examples/3d_bar_1.pl  view on Meta::CPAN

#!/usr/bin/perl

use strict;
use GD::Chart;

## Data on Oceans
## - Need to add legend afterwards

my(@data) = (
[180, 106, 75],
[724, 355, 292]
);
my(@labels) = ("Pacific Ocean", "Atlantic Ocean", "Indian Ocean");
my(@colours) = (hex 'bbccdd', hex 'aaffcc', hex 'ddaabb');

my(%opts) = (
	data	=> \@data,

examples/3d_bar_ttf_1.pl  view on Meta::CPAN

#!/usr/bin/perl

use strict;
use GD::Chart;

## Needs truetype support compiled in to work...

## Data on Oceans
## - Need to add legend afterwards

my(@data) = (
[180, 106, 75],
[724, 355, 292]
);
my(@labels) = ("Pacific Ocean", "Atlantic Ocean", "Indian Ocean");
my(@colours) = (hex 'bbccdd', hex 'aaffcc', hex 'ddaabb');

my(%opts) = (
	data	=> \@data,

gdchart0.11.4dev/gdchart.c  view on Meta::CPAN

						}
				}
			break;
		}
		setno = 0;

	/* ---------- scatter points  over all other plots ---------- */
	/* scatters, by their very nature, don't lend themselves to standard array of points */
	/* also, this affords the opportunity to include scatter points onto any type of chart */
	/* drawing of the scatter point should be an exposed function, so the user can */
	/*  use it to draw a legend, and/or add their own */
	if( GDC_scatter )
		{
		CREATE_ARRAY1( scatter_clr, int, GDC_num_scatter_pts );
		gdPoint	ct[3];

		for( i=0; i<GDC_num_scatter_pts; ++i )
			{
			int		hlf_scatterwdth = (int)( (float)(PX(2)-PX(1))
											 * (((float)((GDC_scatter+i)->width)/100.0)/2.0) );
			int	scat_x = PX( (GDC_scatter+i)->point + (do_bar?1:0) ),

gdchart0.11.4dev/gdchart.h  view on Meta::CPAN

EXTERND unsigned long		GDC_YLabelColor		DEFAULTO( GDC_DFLTCOLOR );
EXTERND unsigned long		GDC_YLabel2Color	DEFAULTO( GDC_DFLTCOLOR );
							/* supercedes VolColor	ulong_color[num_points] */
EXTERND unsigned long		*GDC_ExtVolColor	DEFAULTO( (unsigned long*)NULL );
							/* supercedes LineColor	ulong_color[num_sets] */
EXTERND unsigned long		*GDC_SetColor		DEFAULTO( (unsigned long*)NULL );
							/* supercedes SetColor	ulong_color[num_sets][num_points] */
EXTERND unsigned long		*GDC_ExtColor		DEFAULTO( (unsigned long*)NULL );
EXTERND char				GDC_transparent_bg	DEFAULTO( FALSE );
EXTERND char				*GDC_BGImage		DEFAULTO( (char*)NULL );
/* legends?  separate img? */
/* auto-size fonts, based on image size? */

/* ----- following options are for expert users only ----- */
												/* for alignment of multiple charts */
												/* USE WITH CAUTION! */
EXTERND char				GDC_hard_size		DEFAULTO( FALSE );
EXTERND int					GDC_hard_xorig		DEFAULTO( 0 );				/* in/out */
EXTERND int					GDC_hard_graphwidth	DEFAULTO( 0 );				/* in/out */
EXTERND int					GDC_hard_yorig		DEFAULTO( 0 );				/* in/out */
EXTERND int					GDC_hard_grapheight	DEFAULTO( 0 );				/* in/out */



( run in 0.567 second using v1.01-cache-2.11-cpan-49f99fa48dc )