mirror of
				https://github.com/python-pillow/Pillow.git
				synced 2025-11-04 09:57:43 +03:00 
			
		
		
		
	Map buffer into (0, 0) image
This commit is contained in:
		
							parent
							
								
									24606216e1
								
							
						
					
					
						commit
						51a6d45566
					
				| 
						 | 
				
			
			@ -3000,7 +3000,7 @@ def frombuffer(mode, size, data, decoder_name="raw", *args):
 | 
			
		|||
        if args == ():
 | 
			
		||||
            args = mode, 0, 1
 | 
			
		||||
        if args[0] in _MAPMODES:
 | 
			
		||||
            im = new(mode, (1, 1))
 | 
			
		||||
            im = new(mode, (0, 0))
 | 
			
		||||
            im = im._new(core.map_buffer(data, size, decoder_name, 0, args))
 | 
			
		||||
            if mode == "P":
 | 
			
		||||
                from . import ImagePalette
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue
	
	Block a user