Browse Source

following PR #13787 removing extra commas and correction for g style being overriden by empty style on path tag, temp correction, more to come

Nicolas Debeissat 7 years ago
parent
commit
160f8a19b0
1 changed files with 5 additions and 3 deletions
  1. 5 3
      examples/js/loaders/SVGLoader.js

+ 5 - 3
examples/js/loaders/SVGLoader.js

@@ -149,7 +149,7 @@ THREE.SVGLoader.prototype = {
 							numbers[ 2 ],
 							numbers[ 2 ],
 							numbers[ 3 ],
 							numbers[ 3 ],
 							numbers[ 4 ],
 							numbers[ 4 ],
-							numbers[ 5 ],
+							numbers[ 5 ]
 						);
 						);
 						control.x = numbers[ 2 ];
 						control.x = numbers[ 2 ];
 						control.y = numbers[ 3 ];
 						control.y = numbers[ 3 ];
@@ -249,7 +249,7 @@ THREE.SVGLoader.prototype = {
 							point.x + numbers[ 2 ],
 							point.x + numbers[ 2 ],
 							point.y + numbers[ 3 ],
 							point.y + numbers[ 3 ],
 							point.x + numbers[ 4 ],
 							point.x + numbers[ 4 ],
-							point.y + numbers[ 5 ],
+							point.y + numbers[ 5 ]
 						);
 						);
 						point.x += numbers[ 4 ];
 						point.x += numbers[ 4 ];
 						point.y += numbers[ 5 ];
 						point.y += numbers[ 5 ];
@@ -459,7 +459,9 @@ THREE.SVGLoader.prototype = {
 
 
 		function parseStyle( node, style ) {
 		function parseStyle( node, style ) {
 
 
-			style.fill = node.style.fill;
+			if (node.style.fill != '') {
+				style.fill = node.style.fill;
+			}
 
 
 		}
 		}