More manual translations, to make the bulk process easier
git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@683 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
92
pxwide.c
92
pxwide.c
@@ -57,10 +57,10 @@ void Afficher_partie_de_l_ecran_Wide (word Largeur,word Hauteur,word Largeur_ima
|
||||
{
|
||||
byte* Dest=Ecran; //On va se mettre en 0,0 dans l'écran (Dest)
|
||||
byte* Src=Principal_Decalage_Y*Largeur_image+Principal_Decalage_X+Principal_Ecran; //Coords de départ ds la source (Src)
|
||||
int dx;
|
||||
int y;
|
||||
int dy;
|
||||
|
||||
for(dx=Hauteur;dx!=0;dx--)
|
||||
for(y=Hauteur;y!=0;y--)
|
||||
// Pour chaque ligne
|
||||
{
|
||||
// On fait une copie de la ligne
|
||||
@@ -129,13 +129,13 @@ void Ligne_horizontale_XOR_Wide(word Pos_X,word Pos_Y,word Largeur)
|
||||
void Ligne_verticale_XOR_Wide(word Pos_X,word Pos_Y,word Hauteur)
|
||||
{
|
||||
int i;
|
||||
byte Color;
|
||||
byte color;
|
||||
byte *Dest=Ecran+Pos_X*2+Pos_Y*Largeur_ecran*2;
|
||||
for (i=Hauteur;i>0;i--)
|
||||
{
|
||||
Color=~*Dest;
|
||||
*Dest=Color;
|
||||
*(Dest+1)=Color;
|
||||
color=~*Dest;
|
||||
*Dest=color;
|
||||
*(Dest+1)=color;
|
||||
Dest+=Largeur_ecran*2;
|
||||
}
|
||||
}
|
||||
@@ -147,13 +147,13 @@ void Display_brush_Color_Wide(word Pos_X,word Pos_Y,word Decalage_X,word Decalag
|
||||
// Src = Position dans la brosse
|
||||
byte* Src = Brosse + Decalage_Y * Largeur_brosse + Decalage_X;
|
||||
|
||||
word DX,CX;
|
||||
word x,y;
|
||||
|
||||
// Pour chaque ligne
|
||||
for(DX = Hauteur;DX > 0; DX--)
|
||||
for(y = Hauteur;y > 0; y--)
|
||||
{
|
||||
// Pour chaque pixel
|
||||
for(CX = Largeur;CX > 0; CX--)
|
||||
for(x = Largeur;x > 0; x--)
|
||||
{
|
||||
// On vérifie que ce n'est pas la transparence
|
||||
if(*Src != Couleur_de_transparence)
|
||||
@@ -182,12 +182,12 @@ void Display_brush_Mono_Wide(word Pos_X, word Pos_Y,
|
||||
// l'écran
|
||||
byte* Src=Largeur_brosse*Decalage_Y+Decalage_X+Brosse; // Src = adr ds
|
||||
// la brosse
|
||||
int dx,cx;
|
||||
int x,y;
|
||||
|
||||
for(dx=Hauteur;dx!=0;dx--)
|
||||
for(y=Hauteur;y!=0;y--)
|
||||
//Pour chaque ligne
|
||||
{
|
||||
for(cx=Largeur;cx!=0;cx--)
|
||||
for(x=Largeur;x!=0;x--)
|
||||
//Pour chaque pixel
|
||||
{
|
||||
if (*Src!=Couleur_de_transparence)
|
||||
@@ -209,13 +209,13 @@ void Clear_brush_Wide(word Pos_X,word Pos_Y,__attribute__((unused)) word Decalag
|
||||
{
|
||||
byte* Dest=Ecran+Pos_X*2+Pos_Y*2*Largeur_ecran; //On va se mettre en 0,0 dans l'écran (Dest)
|
||||
byte* Src = ( Pos_Y + Principal_Decalage_Y ) * Largeur_image + Pos_X + Principal_Decalage_X + Principal_Ecran; //Coords de départ ds la source (Src)
|
||||
int dx;
|
||||
int cx;
|
||||
int y;
|
||||
int x;
|
||||
|
||||
for(dx=Hauteur;dx!=0;dx--)
|
||||
for(y=Hauteur;y!=0;y--)
|
||||
// Pour chaque ligne
|
||||
{
|
||||
for(cx=Largeur;cx!=0;cx--)
|
||||
for(x=Largeur;x!=0;x--)
|
||||
//Pour chaque pixel
|
||||
{
|
||||
*(Dest+1)=*Dest=*Src;
|
||||
@@ -233,20 +233,20 @@ void Clear_brush_Wide(word Pos_X,word Pos_Y,__attribute__((unused)) word Decalag
|
||||
}
|
||||
|
||||
// Affiche une brosse (arbitraire) à l'écran
|
||||
void Affiche_brosse_Wide(byte * B, word Pos_X,word Pos_Y,word Decalage_X,word Decalage_Y,word Largeur,word Hauteur,byte Couleur_de_transparence,word Largeur_brosse)
|
||||
void Affiche_brosse_Wide(byte * brush, word Pos_X,word Pos_Y,word Decalage_X,word Decalage_Y,word Largeur,word Hauteur,byte Couleur_de_transparence,word Largeur_brosse)
|
||||
{
|
||||
// Dest = Position à l'écran
|
||||
byte* Dest = Ecran + Pos_Y * 2 * Largeur_ecran + Pos_X * 2;
|
||||
// Src = Position dans la brosse
|
||||
byte* Src = B + Decalage_Y * Largeur_brosse + Decalage_X;
|
||||
byte* Src = brush + Decalage_Y * Largeur_brosse + Decalage_X;
|
||||
|
||||
word DX,CX;
|
||||
word x,y;
|
||||
|
||||
// Pour chaque ligne
|
||||
for(DX = Hauteur;DX > 0; DX--)
|
||||
for(y = Hauteur;y > 0; y--)
|
||||
{
|
||||
// Pour chaque pixel
|
||||
for(CX = Largeur;CX > 0; CX--)
|
||||
for(x = Largeur;x > 0; x--)
|
||||
{
|
||||
// On vérifie que ce n'est pas la transparence
|
||||
if(*Src != Couleur_de_transparence)
|
||||
@@ -268,13 +268,13 @@ void Remap_screen_Wide(word Pos_X,word Pos_Y,word Largeur,word Hauteur,byte * Ta
|
||||
{
|
||||
// Dest = coords a l'écran
|
||||
byte* Dest = Ecran + Pos_Y * 2 * Largeur_ecran + Pos_X * 2;
|
||||
int dx,cx;
|
||||
int x,y;
|
||||
|
||||
// Pour chaque ligne
|
||||
for(dx=Hauteur;dx>0;dx--)
|
||||
for(y=Hauteur;y>0;y--)
|
||||
{
|
||||
// Pour chaque pixel
|
||||
for(cx=Largeur;cx>0;cx--)
|
||||
for(x=Largeur;x>0;x--)
|
||||
{
|
||||
*(Dest+1) = *Dest = Table_de_conversion[*Dest];
|
||||
Dest +=2;
|
||||
@@ -296,10 +296,10 @@ void Afficher_une_ligne_ecran_fast_Wide(word Pos_X,word Pos_Y,word Largeur,byte
|
||||
void Afficher_une_ligne_ecran_Wide(word Pos_X,word Pos_Y,word Largeur,byte * Ligne)
|
||||
/* On affiche une ligne de pixels en les doublant. */
|
||||
{
|
||||
int dx;
|
||||
int x;
|
||||
byte *Dest;
|
||||
Dest=Ecran+Pos_X*2+Pos_Y*2*Largeur_ecran;
|
||||
for(dx=Largeur;dx>0;dx--)
|
||||
for(x=Largeur;x>0;x--)
|
||||
{
|
||||
*Dest=*Ligne;
|
||||
Dest++;
|
||||
@@ -315,9 +315,9 @@ void Afficher_une_ligne_transparente_mono_a_l_ecran_Wide(
|
||||
// Utilisé par les brosses en mode zoom
|
||||
{
|
||||
byte* Dest = Ecran+ Pos_Y*2 * Largeur_ecran + Pos_X*2;
|
||||
int Compteur;
|
||||
int x;
|
||||
// Pour chaque pixel
|
||||
for(Compteur=0;Compteur<Largeur;Compteur++)
|
||||
for(x=0;x<Largeur;x++)
|
||||
{
|
||||
if (Couleur_transparence!=*Ligne)
|
||||
{
|
||||
@@ -346,12 +346,12 @@ void Afficher_partie_de_l_ecran_zoomee_Wide(
|
||||
// Pour chaque ligne à zoomer
|
||||
while(1)
|
||||
{
|
||||
int CX;
|
||||
int x;
|
||||
|
||||
// On éclate la ligne
|
||||
Zoomer_une_ligne(Src,Buffer,Loupe_Facteur*2,Largeur);
|
||||
// On l'affiche Facteur fois, sur des lignes consécutives
|
||||
CX = Loupe_Facteur;
|
||||
x = Loupe_Facteur;
|
||||
// Pour chaque ligne
|
||||
do{
|
||||
// On affiche la ligne zoomée
|
||||
@@ -367,8 +367,8 @@ void Afficher_partie_de_l_ecran_zoomee_Wide(
|
||||
Largeur*Loupe_Facteur,Hauteur);
|
||||
return;
|
||||
}
|
||||
CX--;
|
||||
}while (CX > 0);
|
||||
x--;
|
||||
}while (x > 0);
|
||||
Src += Largeur_image;
|
||||
}
|
||||
// ATTENTION on n'arrive jamais ici !
|
||||
@@ -379,10 +379,10 @@ void Afficher_une_ligne_transparente_a_l_ecran_Wide(word Pos_X,word Pos_Y,word L
|
||||
byte* Src = Ligne;
|
||||
byte* Dest = Ecran + Pos_Y * 2 * Largeur_ecran + Pos_X * 2;
|
||||
|
||||
word cx;
|
||||
word x;
|
||||
|
||||
// Pour chaque pixel de la ligne
|
||||
for(cx = Largeur;cx > 0;cx--)
|
||||
for(x = Largeur;x > 0;x--)
|
||||
{
|
||||
if(*Src!=Couleur_transparence)
|
||||
{
|
||||
@@ -403,7 +403,7 @@ void Display_brush_Color_zoom_Wide(word Pos_X,word Pos_Y,
|
||||
byte * Buffer)
|
||||
{
|
||||
byte* Src = Brosse+Decalage_Y*Largeur_brosse + Decalage_X;
|
||||
word DX = Pos_Y;
|
||||
word y = Pos_Y;
|
||||
byte bx;
|
||||
|
||||
// Pour chaque ligne
|
||||
@@ -413,9 +413,9 @@ void Display_brush_Color_zoom_Wide(word Pos_X,word Pos_Y,
|
||||
// On affiche facteur fois la ligne zoomée
|
||||
for(bx=Loupe_Facteur;bx>0;bx--)
|
||||
{
|
||||
Afficher_une_ligne_transparente_a_l_ecran_Wide(Pos_X,DX,Largeur*Loupe_Facteur,Buffer,Couleur_de_transparence);
|
||||
DX++;
|
||||
if(DX==Pos_Y_Fin)
|
||||
Afficher_une_ligne_transparente_a_l_ecran_Wide(Pos_X,y,Largeur*Loupe_Facteur,Buffer,Couleur_de_transparence);
|
||||
y++;
|
||||
if(y==Pos_Y_Fin)
|
||||
{
|
||||
return;
|
||||
}
|
||||
@@ -436,7 +436,7 @@ void Display_brush_Mono_zoom_Wide(word Pos_X, word Pos_Y,
|
||||
|
||||
{
|
||||
byte* Src = Brosse + Decalage_Y * Largeur_brosse + Decalage_X;
|
||||
int DX=Pos_Y;
|
||||
int y=Pos_Y;
|
||||
|
||||
//Pour chaque ligne à zoomer :
|
||||
while(1)
|
||||
@@ -455,13 +455,13 @@ void Display_brush_Mono_zoom_Wide(word Pos_X, word Pos_Y,
|
||||
{
|
||||
// On affiche la ligne zoomée
|
||||
Afficher_une_ligne_transparente_mono_a_l_ecran_Wide(
|
||||
Pos_X, DX, Largeur * Loupe_Facteur,
|
||||
Pos_X, y, Largeur * Loupe_Facteur,
|
||||
Buffer, Couleur_de_transparence, Couleur
|
||||
);
|
||||
// On passe à la ligne suivante
|
||||
DX++;
|
||||
y++;
|
||||
// On vérifie qu'on est pas à la ligne finale
|
||||
if(DX == Pos_Y_Fin)
|
||||
if(y == Pos_Y_Fin)
|
||||
{
|
||||
UpdateRect( Pos_X, Pos_Y,
|
||||
Largeur * Loupe_Facteur, Pos_Y_Fin - Pos_Y );
|
||||
@@ -480,7 +480,7 @@ void Clear_brush_zoom_Wide(word Pos_X,word Pos_Y,word Decalage_X,word Decalage_Y
|
||||
{
|
||||
// En fait on va recopier l'image non zoomée dans la partie zoomée !
|
||||
byte* Src = Principal_Ecran + Decalage_Y * Largeur_image + Decalage_X;
|
||||
int DX = Pos_Y;
|
||||
int y = Pos_Y;
|
||||
int bx;
|
||||
|
||||
// Pour chaque ligne à zoomer
|
||||
@@ -491,12 +491,12 @@ void Clear_brush_zoom_Wide(word Pos_X,word Pos_Y,word Decalage_X,word Decalage_Y
|
||||
|
||||
// Pour chaque ligne
|
||||
do{
|
||||
Afficher_une_ligne_ecran_fast_Wide(Pos_X,DX,
|
||||
Afficher_une_ligne_ecran_fast_Wide(Pos_X,y,
|
||||
Largeur * Loupe_Facteur,Buffer);
|
||||
|
||||
// Ligne suivante
|
||||
DX++;
|
||||
if(DX==Pos_Y_Fin)
|
||||
y++;
|
||||
if(y==Pos_Y_Fin)
|
||||
{
|
||||
UpdateRect(Pos_X,Pos_Y,
|
||||
Largeur*Loupe_Facteur,Pos_Y_Fin-Pos_Y);
|
||||
|
||||
Reference in New Issue
Block a user