Explorar o código

SVGRenderer: support LineDashedMaterial

Sergey Linev %!s(int64=8) %!d(string=hai) anos
pai
achega
aff695d020
Modificáronse 1 ficheiros con 6 adicións e 0 borrados
  1. 6 0
      examples/js/renderers/SVGRenderer.js

+ 6 - 0
examples/js/renderers/SVGRenderer.js

@@ -384,6 +384,12 @@ THREE.SVGRenderer = function () {
 
 
 			addPath( style, path );
 			addPath( style, path );
 
 
+		} else if ( material.isLineDashedMaterial ) {
+
+			var style = 'fill:none;stroke:' + getSvgColor( material.color, material.opacity ) + ';stroke-width:' + material.linewidth + ';stroke-dasharray:' + material.dashSize + "," + material.gapSize;
+
+			addPath( style, path );
+
 		}
 		}
 
 
 	}
 	}