Set a black frame when not using direct-DD access

This commit is contained in:
Lephenixnoir 2021-08-04 15:11:03 +02:00
parent 57624763e3
commit db01fa04f2
Signed by: Lephenixnoir
GPG Key ID: 1BBA026E13FC0495
2 changed files with 13 additions and 1 deletions

View File

@ -609,6 +609,8 @@ int main(void){
#else
EnableColor(1);
EnableStatusArea(3);
Bdisp_FrameAndColor(3, 16);
Bdisp_FrameAndColor(1, 0);
WADFileInfo wads[16];
int wad_count = FindWADs(wads, 16);
@ -689,9 +691,12 @@ int main(void){
}
}
memset(VRAM,0,WIDTH*HEIGHT*2);
memset(VRAM, 0, WIDTH*HEIGHT*2);
D_DoomMain();
Bdisp_FrameAndColor(3, 16);
Bdisp_FrameAndColor(1, 0);
if(gWADfd >= 0)
Bfile_CloseFile_OS(gWADfd);

View File

@ -159,6 +159,13 @@ void I_ShutdownGraphics(void)
void I_Flip (void)
{
/* Set a black frame if the current one is white */
if ((Bdisp_FrameAndColor(0, 0) & 1) == 0)
{
Bdisp_FrameAndColor(3, 17);
Bdisp_FrameAndColor(1, 0);
}
int x,y;
for(y=0;y<SCREENHEIGHT;y++)
{