Skip to content

Commit 55dd846

Browse files
committed
Fixed invalid transform selection when setting primitive reference
1 parent 4cbe7ff commit 55dd846

File tree

1 file changed

+1
-1
lines changed
  • RadeonRays/src/accelerator

1 file changed

+1
-1
lines changed

RadeonRays/src/accelerator/bvh2.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -334,8 +334,8 @@ namespace RadeonRays
334334
{
335335
auto shape = ref.first;
336336
matrix worldmat, worldmatinv;
337+
shape->GetTransform(worldmat, worldmatinv);
337338
auto mesh = static_cast<const Mesh *>(static_cast<const ShapeImpl *>(shape)->is_instance() ? static_cast<const Instance *>(shape)->GetBaseShape() : shape);
338-
mesh->GetTransform(worldmat, worldmatinv);
339339
auto face = mesh->GetFaceData()[ref.second];
340340
auto v0 = transform_point(mesh->GetVertexData()[face.idx[0]], worldmat);
341341
auto v1 = transform_point(mesh->GetVertexData()[face.idx[1]], worldmat);

0 commit comments

Comments
 (0)