mirror of
				https://github.com/PabloMK7/citra.git
				synced 2025-10-31 05:40:04 +00:00 
			
		
		
		
	Fix broken surface validation logic since removal of the reinterpret hack
This commit is contained in:
		
							parent
							
								
									f893daa4a2
								
							
						
					
					
						commit
						9a6a452857
					
				
					 1 changed files with 3 additions and 5 deletions
				
			
		|  | @ -1271,10 +1271,8 @@ void RasterizerCacheOpenGL::ValidateSurface(const Surface& surface, PAddr addr, | ||||||
|         return; |         return; | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     auto validate_regions = surface->invalid_regions & validate_interval; |  | ||||||
| 
 |  | ||||||
|     for (;;) { |     for (;;) { | ||||||
|         const auto it = validate_regions.begin(); |         const auto it = surface->invalid_regions.find(validate_interval); | ||||||
|         if (it == surface->invalid_regions.end()) |         if (it == surface->invalid_regions.end()) | ||||||
|             break; |             break; | ||||||
| 
 | 
 | ||||||
|  | @ -1287,7 +1285,7 @@ void RasterizerCacheOpenGL::ValidateSurface(const Surface& surface, PAddr addr, | ||||||
|         if (copy_surface != nullptr) { |         if (copy_surface != nullptr) { | ||||||
|             SurfaceInterval copy_interval = params.GetCopyableInterval(copy_surface); |             SurfaceInterval copy_interval = params.GetCopyableInterval(copy_surface); | ||||||
|             CopySurface(copy_surface, surface, copy_interval); |             CopySurface(copy_surface, surface, copy_interval); | ||||||
|             validate_regions.erase(interval); |             surface->invalid_regions.erase(interval); | ||||||
|             continue; |             continue; | ||||||
|         } |         } | ||||||
| 
 | 
 | ||||||
|  | @ -1295,7 +1293,7 @@ void RasterizerCacheOpenGL::ValidateSurface(const Surface& surface, PAddr addr, | ||||||
|         FlushRegion(params.addr, params.size); |         FlushRegion(params.addr, params.size); | ||||||
|         surface->LoadGLBuffer(params.addr, params.end); |         surface->LoadGLBuffer(params.addr, params.end); | ||||||
|         surface->UploadGLTexture(surface->GetSubRect(params)); |         surface->UploadGLTexture(surface->GetSubRect(params)); | ||||||
|         validate_regions.erase(interval); |         surface->invalid_regions.erase(interval); | ||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue