MantisBT
Mantis Bug Tracker Workflow

View Revisions: Issue #24050 All Revisions ] Back to Issue ]
Summary 0024050: Voxel_FastConverter::Convert / ConvertUsingSAT - problems in multithreaded scenario
Revision 2013-06-28 11:27 by Pawel
Description Both methods mentioned above use the following code to judge which triangles to process in the specified thread:

start_thread_triangle = (ithread - 1) * (myNbTriangles / myNbThreads) + 1;
end_thread_triangle = (ithread - 0) * (myNbTriangles / myNbThreads);

That code gives incorrect results for some cases due to the fact that the computation is carried out on integer numbers, e.g.:

myNbTriangles = 12; //Box
myNbThreads = 8;

(myNbTriangles / myNbThreads) always yields 1 and so the triangle 9 to 12 are never processed.
Revision 2013-06-27 15:48 by Pawel
Description Both methods mentioned above use the following code to judge which triangles to process in the specified thread:

start_thread_triangle = (ithread - 1) * (myNbTriangles / myNbThreads) + 1;
end_thread_triangle = (ithread - 0) * (myNbTriangles / myNbThreads);

That code gives incorrect results for some cases due to the fact that the computation is carried out on integer numbers, e.g.:

myNbTriangles = 12; //Box
myNbThreads = 8;

(myNbTriangles / myNbThreads) always yields and so the triangle 9 to 12 are never processed.


Copyright © 2000 - 2020 MantisBT Team
Powered by Mantis Bugtracker