Vous n'êtes pas identifié.
//**************Nombres de cycles des routines graphiques***************//
// Toutes les ft sont adaptÈes pour fonctionner avec casio2.h //
// Elles contiennent le calcul du seg video //
// Routines pour metre un pixel selon la couleur //routine pixel par bradn mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov ah,0xfe //2 rol ah,cl //3 and es:[si],ah //7 mov ah,al //2 rol ah,cl //3 or es:[si],ah //7 //total //55 cycles (soit 47 cycles sans la def de seg) //routine moi setpix mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov al,couleur //2 mov bl,es:[si] //4 db 0x0F,0x12,0x0C3 //2 rol al,cl //3 or bl,al //2 mov es:[si],bl //2 //total //48 cycles (soit 40 cycles sans la def de seg) // Routines pour mettre un pixel noir //Routine whyp set black pix mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 xor bl,bl //2 db 0x0F,0x14,0x0C3 //2 or es:[si],bl //7 //total //44 cycles (soit 38 cycles sans la def de seg) //routine moi setbpix mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov bl,es:[si] //4 db 0x0F,0x14,0x0C3 //2 mov es:[si],bl //2 //total //41 cycles (soit 35 cycles sans la def de seg) //Routines pour mettre un pixel blanc //routine white pix par whyp mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov bl,0xFF //2 db 0x0F,0x12,0x0C3 //2 and es:[si],bl //7 //total //44 cycles (soit 38 cycles sans la def de seg) //routine moi setwPix mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov bl,es:[si] //4 db 0x0F,0x12,0x0C3 //2 mov es:[si],bl //2 //total //41 cycles (soit 35 cycles sans la def de seg) // Routine pour inverser un pixel //routine invpixel (universelle) mov ax,page //2 shl ax,6 //2 add ax,0x1a20 //2 mov es,ax //2 mov cx,X //2 mov dx,Y //2 mov si,0x003f //2 sub si,dx //1 sub cx,0x80 //2 not cx //2 push cx //3 and cl,0xf8 //2 shl cx,0x03 //2 add si,cx //1 pop cx //4 and cl,0x07 //2 //33 mov bl,es:[si] //4 db 0x0F,0x016,0x0C3 //2 mov es:[si],bl //2 //total //41 cycles (soit 35 cycles sans la def de seg)
/* Donc on voit alors que pour mettre un pixel on a :
Pixel : Bradn 55(47) vs superna 48(40)
Pixel Noir : Whyp 44 ( 38 ) vs superna 41 ( 35 )
Pixel Blanc : Whyp 44 ( 38 ) vs superna 41 ( 35 )
d'ou l'utilitÈ d'utiliser les ft specifiques
Note : Je ne veut absolument pas etre le plus fort car je n'aurais jamais put faire
ces optimisations sans les routines de whyp et de BradN, donc d'abord :
Bravo Whyp et BradN !! */
Hors ligne
superna révolutionne le monde... j'ai rien capté mais je crois que c'est bien trouvé... bravo
Hors ligne
Et bravo a toi !
Hors ligne