Support transparent-bg QR codes
This commit is contained in:
		
							parent
							
								
									d8b037a15b
								
							
						
					
					
						commit
						4da495a8cc
					
				
					 1 changed files with 2 additions and 0 deletions
				
			
		|  | @ -48,6 +48,8 @@ class QrcodeDecoder { | |||
|     } | ||||
| 
 | ||||
|     this.gCtx!.clearRect(0, 0, width, height); | ||||
|     this.gCtx!.fillStyle = "#ffffff"; | ||||
|     this.gCtx!.fillRect(0, 0, width, height); | ||||
|     this.gCtx!.drawImage(target, 0, 0, width, height); | ||||
| 
 | ||||
|     const imageData = this.gCtx!.getImageData( | ||||
|  |  | |||
		Loading…
	
		Reference in a new issue