Procházet zdrojové kódy

Clear the canvas before starting to draw (#27092)

Co-authored-by: Antonio Pisano <[email protected]>
Antonio Pisano před 1 rokem
rodič
revize
bb22d64298
1 změnil soubory, kde provedl 2 přidání a 0 odebrání
  1. 2 0
      examples/jsm/interactive/HTMLMesh.js

+ 2 - 0
examples/jsm/interactive/HTMLMesh.js

@@ -501,6 +501,8 @@ function html2canvas( element ) {
 
 	// console.time( 'drawElement' );
 
+	context.clearRect(0, 0, canvas.width, canvas.height);
+
 	drawElement( element );
 
 	// console.timeEnd( 'drawElement' );