Skip to content

Commit 5113cd6

Browse files
committed
print smoothing group id.
1 parent 65df7c4 commit 5113cd6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

loader_example.cc

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,6 +145,9 @@ static void PrintInfo(const tinyobj::attrib_t& attrib,
145145
assert(shapes[i].mesh.num_face_vertices.size() ==
146146
shapes[i].mesh.material_ids.size());
147147

148+
assert(shapes[i].mesh.num_face_vertices.size() ==
149+
shapes[i].mesh.smoothing_group_ids.size());
150+
148151
printf("shape[%ld].num_faces: %lu\n", static_cast<long>(i),
149152
static_cast<unsigned long>(shapes[i].mesh.num_face_vertices.size()));
150153

@@ -165,6 +168,8 @@ static void PrintInfo(const tinyobj::attrib_t& attrib,
165168

166169
printf(" face[%ld].material_id = %d\n", static_cast<long>(f),
167170
shapes[i].mesh.material_ids[f]);
171+
printf(" face[%ld].smoothing_group_id = %d\n", static_cast<long>(f),
172+
shapes[i].mesh.smoothing_group_ids[f]);
168173

169174
index_offset += fnum;
170175
}

0 commit comments

Comments
 (0)