Browse Source

Merge pull request #11041 from gero3/CommentIncludes

Allow commenting out #includes
Mr.doob 8 năm trước cách đây
mục cha
commit
428935beb2
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      src/renderers/webgl/WebGLProgram.js

+ 1 - 1
src/renderers/webgl/WebGLProgram.js

@@ -152,7 +152,7 @@ function replaceLightNums( string, parameters ) {
 
 function parseIncludes( string ) {
 
-	var pattern = /#include +<([\w\d.]+)>/g;
+	var pattern = /^\s*#include +<([\w\d.]+)>/gm;
 
 	function replace( match, include ) {