瀏覽代碼

HTMLMesh: Remove the +0.5 offset for image (#25930)

Vincent Fretin 2 年之前
父節點
當前提交
8be4325d6d
共有 1 個文件被更改,包括 2 次插入2 次删除
  1. 2 2
      examples/jsm/interactive/HTMLMesh.js

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

@@ -281,8 +281,8 @@ function html2canvas( element ) {
 
 			x = rect.left - offset.left - 0.5;
 			y = rect.top - offset.top - 0.5;
-			width = rect.width + 0.5;
-			height = rect.height + 0.5;
+			width = rect.width;
+			height = rect.height;
 
 			context.drawImage( element, x, y, width, height );