mirror of
				https://github.com/RGBCube/serenity
				synced 2025-10-31 16:22:43 +00:00 
			
		
		
		
	LibWeb: Add DOMMatrix toFloat32Array and toFloat64Array
This commit is contained in:
		
							parent
							
								
									7b4b5b735b
								
							
						
					
					
						commit
						2e122b16e4
					
				
					 6 changed files with 59 additions and 2 deletions
				
			
		|  | @ -0,0 +1,4 @@ | |||
| 1. {"0":10,"1":20,"2":0,"3":0,"4":30,"5":40,"6":0,"7":0,"8":0,"9":0,"10":1,"11":0,"12":50,"13":60,"14":0,"15":1} | ||||
| 2. {"0":10,"1":20,"2":30,"3":40,"4":50,"5":60,"6":70,"7":80,"8":90,"9":100,"10":110,"11":120,"12":130,"13":140,"14":150,"15":160} | ||||
| 3. {"0":10,"1":20,"2":0,"3":0,"4":30,"5":40,"6":0,"7":0,"8":0,"9":0,"10":1,"11":0,"12":50,"13":60,"14":0,"15":1} | ||||
| 4. {"0":10,"1":20,"2":30,"3":40,"4":50,"5":60,"6":70,"7":80,"8":90,"9":100,"10":110,"11":120,"12":130,"13":140,"14":150,"15":160} | ||||
							
								
								
									
										21
									
								
								Tests/LibWeb/Text/input/geometry/dommatrix-to-array.html
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										21
									
								
								Tests/LibWeb/Text/input/geometry/dommatrix-to-array.html
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,21 @@ | |||
| <script src="../include.js"></script> | ||||
| <script> | ||||
|     test(() => { | ||||
|         let testCounter = 1; | ||||
|         function testPart(part) { | ||||
|             println(`${testCounter++}. ${JSON.stringify(part())}`); | ||||
|         } | ||||
| 
 | ||||
|         // 1. DOMMatrix to Float32Array | ||||
|         testPart(() => new DOMMatrix([10, 20, 30, 40, 50, 60]).toFloat32Array()); | ||||
| 
 | ||||
|         // 2. DOMMatrix to Float32Array | ||||
|         testPart(() => new DOMMatrix([10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 110, 120, 130, 140, 150, 160]).toFloat32Array()); | ||||
| 
 | ||||
|         // 3. DOMMatrix to Float64Array | ||||
|         testPart(() => new DOMMatrix([10, 20, 30, 40, 50, 60]).toFloat64Array()); | ||||
| 
 | ||||
|         // 4. DOMMatrix to Float64Array | ||||
|         testPart(() => new DOMMatrix([10, 20, 30, 40, 50, 60, 70, 80, 90, 100, 110, 120, 130, 140, 150, 160]).toFloat64Array()); | ||||
|     }); | ||||
| </script> | ||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Bastiaan van der Plaat
						Bastiaan van der Plaat