C/Visual C - rasterop

 
Vista:

rasterop

Publicado por isidro (1 intervención) el 26/05/2013 20:05:54
puden darme un ejemplo donde se este implementando rasterop en c...........no importa cualquier ejemplo
Valora esta pregunta
Me gusta: Está pregunta es útil y esta claraNo me gusta: Está pregunta no esta clara o no es útil
0
Responder

rasterop

Publicado por Andreina (2 intervenciones) el 01/06/2013 04:31:32
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
/* Declaracion de Librerias a Utilizar*/
#include <stdio.h>
#include <conio.h>
#include <dos.h>
#include <math.h>
#include <graphics.h>
#include <alloc.h>
 
void main(void)
{
 
int imagentam;
void *imagen;
 
int adap=DETECT, modo;
initgraph(&adap,&modo,"C:\\tc20\\bin");
cleardevice();
 
setfillstyle(SLASH_FILL,5);
 
bar(50,50,100,100);
imagentam = imagesize(50,50,100,100);   /*se guarda la imagen*/
imagen=malloc(imagentam);
 
getimage(50,50,100,100,imagen);
putimage(400,50,imagen, COPY_PUT);
getch();
 
putimage(400,110,imagen, COPY_PUT);
 
getch();
 
free(imagen);
closegraph();
 
getch();
 
}
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar

rasterop

Publicado por Andreina (2 intervenciones) el 01/06/2013 05:01:39
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
# include <conio.h>
# include <graphics.h>
# include <math.h>
# include <dos.h>
void inicializar(void);
void cuerpo(void);
void main(void)
{
inicializar();
cuerpo();
}
void inicializar(void)
{
int drive=DETECT,modo;
initgraph(&drive,&modo,"c:\\tc20\\bin");
}
 
void cuerpo()
{
double x,y;
while(!kbhit())
	{
x=-180;
	while(x<=180 && !kbhit())
	{
	y=sqrt(15000*(1-((x*x)/32400)));
	circle(x+310,240-y,20);
	delay(15000);
	x+=1;
	cleardevice();
	}
	x=180;
	while(x>=-180 && !kbhit())
	{
	y=-1*sqrt(15000*(1-((x*x)/32400)));
	circle(x+310,240-y,20);
	delay(15000);
	x-=1;
cleardevice();
	}
	}
 
getch();
}
Valora esta respuesta
Me gusta: Está respuesta es útil y esta claraNo me gusta: Está respuesta no esta clara o no es útil
0
Comentar