Commit: 0606829850a169e1be5d268674f77c016f5640eb Author: Gaia Clary Date: Sat Dec 1 14:18:11 2018 +0100 Branches: blender2.8 https://developer.blender.org/rB0606829850a169e1be5d268674f77c016f5640eb
fix T58293 Collada: Does not export Texture coordinates when option 'only selected UV Map' is enabled =================================================================== M source/blender/collada/GeometryExporter.cpp =================================================================== diff --git a/source/blender/collada/GeometryExporter.cpp b/source/blender/collada/GeometryExporter.cpp index a82d07d53dd..bb69c3fc653 100644 --- a/source/blender/collada/GeometryExporter.cpp +++ b/source/blender/collada/GeometryExporter.cpp @@ -349,13 +349,14 @@ void GeometryExporter::createPolylist(short material_index, int num_layers = CustomData_number_of_layers(&me->ldata, CD_MLOOPUV); int active_uv_index = CustomData_get_active_layer_index(&me->ldata, CD_MLOOPUV); for (i = 0; i < num_layers; i++) { - if (!this->export_settings->active_uv_only || i == active_uv_index) { + int layer_index = CustomData_get_layer_index_n(&me->ldata, CD_MLOOPUV, i); + if (!this->export_settings->active_uv_only || layer_index == active_uv_index) { // char *name = CustomData_get_layer_name(&me->ldata, CD_MLOOPUV, i); COLLADASW::Input input3(COLLADASW::InputSemantic::TEXCOORD, makeUrl(makeTexcoordSourceId(geom_id, i, this->export_settings->active_uv_only)), 2, // this is only until we have optimized UV sets - (this->export_settings->active_uv_only) ? 0 : i // only_active_uv exported -> we have only one set + (this->export_settings->active_uv_only) ? 0 : layer_index // only_active_uv exported -> we have only one set ); til.push_back(input3); } _______________________________________________ Bf-blender-cvs mailing list Bf-blender-cvs@blender.org https://lists.blender.org/mailman/listinfo/bf-blender-cvs