未验证 提交 0d7fe1e8 编写于 作者: M Mr.doob 提交者: GitHub

Merge pull request #19013 from rogangriffin/patch-1

Update Collada Exporter to export lightmap uvs
......@@ -264,6 +264,13 @@ ColladaExporter.prototype = {
triangleInputs += `<input semantic="TEXCOORD" source="#${ uvName }" offset="0" set="0" />`;
}
// serialize lightmap uvs
if ( 'uv2' in bufferGeometry.attributes ) {
var uvName = `${ meshid }-texcoord2`;
gnode += getAttribute( bufferGeometry.attributes.uv2, uvName, [ 'S', 'T' ], 'float' );
triangleInputs += `<input semantic="TEXCOORD" source="#${ uvName }" offset="0" set="1" />`;
}
// serialize colors
if ( 'color' in bufferGeometry.attributes ) {
......@@ -273,7 +280,7 @@ ColladaExporter.prototype = {
triangleInputs += `<input semantic="COLOR" source="#${ colName }" offset="0" />`;
}
var indexArray = null;
if ( bufferGeometry.index ) {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册