src/video/dga/SDL_dgavideo.c
changeset 202 401f0134f4f9
parent 105 2136ea8953f9
child 252 e8157fcb3114
equal deleted inserted replaced
201:ddee60057806 202:401f0134f4f9
   529 			flip_yoffset[1] = current->h;
   529 			flip_yoffset[1] = current->h;
   530 			flip_address[0] = memory_base;
   530 			flip_address[0] = memory_base;
   531 			flip_address[1] = memory_base+screen_len;
   531 			flip_address[1] = memory_base+screen_len;
   532 			surfaces_mem += screen_len;
   532 			surfaces_mem += screen_len;
   533 			surfaces_len -= screen_len;
   533 			surfaces_len -= screen_len;
   534 			DGA_FlipHWSurface(this, current);
       
   535 		}
   534 		}
   536 	}
   535 	}
   537 
   536 
   538 	/* Allocate memory tracking for hardware surfaces */
   537 	/* Allocate memory tracking for hardware surfaces */
   539 	DGA_FreeHWSurfaces(this);
   538 	DGA_FreeHWSurfaces(this);
   540 	if ( surfaces_len < 0 ) {
   539 	if ( surfaces_len < 0 ) {
   541 		surfaces_len = 0;
   540 		surfaces_len = 0;
   542 	}
   541 	}
   543 	DGA_InitHWSurfaces(this, current, surfaces_mem, surfaces_len);
   542 	DGA_InitHWSurfaces(this, current, surfaces_mem, surfaces_len);
       
   543 
       
   544 	/* Expose the back buffer as surface memory */
       
   545 	if ( current->flags & SDL_DOUBLEBUF ) {
       
   546 		this->screen = current;
       
   547 		DGA_FlipHWSurface(this, current);
       
   548 		this->screen = NULL;
       
   549 	}
   544 
   550 
   545 	/* Set the update rectangle function */
   551 	/* Set the update rectangle function */
   546 	this->UpdateRects = DGA_DirectUpdate;
   552 	this->UpdateRects = DGA_DirectUpdate;
   547 
   553 
   548 	/* Enable mouse and keyboard support */
   554 	/* Enable mouse and keyboard support */