#include "pngwriter.h"
#include
#include
int main()
{
int i,j;
pngwriter one(300,300,0,"one.png");
pngwriter two(300,300,0,"two.png");
one.filledsquare(50,100,100,200,0,65535,0);
one.line(150,150,290,290,65535,0,0);
one.line(150,150,10,290,65535,0,0);
one.line(150,150,290,10,65535,0,0);
one.line(150,150,10,10,65535,0,0);
one.line(150,100,150,200,65535,0,0);//Dibuja la cruz roja
one.line(100,150,200,150,65535,0,0);
one.square(30,30,250,50,0,65535,65535);
one.filledcircle(100,100,50,65535,0,65535);
one.circle(210,220,10,20000,20000,50000);
one.close();
for(intiter = 1;iter< 300;iter++) //Dibuja el gradiente de la esquina inferior izquierda
{
two.line(1,300,iter,1,65535-65535*((double)iter)/300.0, 0,65535);
}
for(intiter2 = 0; iter2 < 8; iter2++) //Dibuja los circulos verdes
{
two.filledcircle(280-25*iter2,250,10,0,65535 - 65535*((double)iter2/7.0),0);
}
for(intiter3 = 120; iter3>0;iter3--)
{
two.filledsquare(70,70,70+iter3,70+iter3,0,0,65535 -65535*((double)iter3/120.0 ));
}
two.close();
return 0;
}
|