Re-integrated anim in trunk, fixing the 999-layer limit at the same time

git-svn-id: svn://pulkomandy.tk/GrafX2/trunk@1841 416bcca6-2ee7-4201-b75f-2eb2f807beb1
This commit is contained in:
Yves Rizoud
2011-10-19 23:35:56 +00:00
parent 775ee56ed0
commit 8fb16e7089
28 changed files with 753 additions and 174 deletions

View File

@@ -299,9 +299,9 @@ int L_SetPictureSize(lua_State* L)
for (i=0; i<Main_backups->Pages->Nb_layers; i++)
{
Copy_part_of_image_to_another(
Main_backups->Pages->Next->Image[i],0,0,Min(Main_backups->Pages->Next->Width,Main_image_width),
Main_backups->Pages->Next->Image[i].Pixels,0,0,Min(Main_backups->Pages->Next->Width,Main_image_width),
Min(Main_backups->Pages->Next->Height,Main_image_height),Main_backups->Pages->Next->Width,
Main_backups->Pages->Image[i],0,0,Main_image_width);
Main_backups->Pages->Image[i].Pixels,0,0,Main_image_width);
}
Redraw_layered_image();
@@ -326,9 +326,9 @@ int L_SetSparePictureSize(lua_State* L)
for (i=0; i<Spare_backups->Pages->Nb_layers; i++)
{
Copy_part_of_image_to_another(
Spare_backups->Pages->Next->Image[i],0,0,Min(Spare_backups->Pages->Next->Width,Spare_image_width),
Spare_backups->Pages->Next->Image[i].Pixels,0,0,Min(Spare_backups->Pages->Next->Width,Spare_image_width),
Min(Spare_backups->Pages->Next->Height,Spare_image_height),Spare_backups->Pages->Next->Width,
Spare_backups->Pages->Image[i],0,0,Spare_image_width);
Spare_backups->Pages->Image[i].Pixels,0,0,Spare_image_width);
}
Redraw_spare_image();
@@ -637,7 +637,7 @@ int L_GetSpareLayerPixel(lua_State* L)
lua_pushinteger(L, Spare_backups->Pages->Transparent_color);
return 1;
}
lua_pushinteger(L, *(Spare_backups->Pages->Image[Spare_current_layer] + y*Spare_image_width + x));
lua_pushinteger(L, *(Spare_backups->Pages->Image[Spare_current_layer].Pixels + y*Spare_image_width + x));
return 1;
}