(ISSUE) SetVisible can hide but not show robot from API——打印Version +- RoboDK Forum (//www.sinclairbody.com/forum) +-- Forum: RoboDK (EN) (//www.sinclairbody.com/forum/Forum-RoboDK-EN) +--- Forum: RoboDK API (//www.sinclairbody.com/forum/Forum-RoboDK-API) +--- Thread: (ISSUE) SetVisible can hide but not show robot from API (/Thread-ISSUE-SetVisible-can-hide-but-not-show-robot-from-API) |
(ISSUE) SetVisible can hide but not show robot from API-thealenoid-05-03-2019
Code:
// Visibility
Using the C# code above, I can hide a robot (IItem) by setting its visibility to false, but when I set the visibility to true only the tool frame reappears. I tried to call RoboDK.Render(true), as well, but that had not effect. When I toggle visibility in the RoboDK window, it acts as expected. Has anybody else seen this error before? RE: (ISSUE) SetVisible can hide but not show robot from API-thealenoid-05-03-2019
Code:
// My visibility control functions in C#
Through experimentation, I found that you can set the visibility of specific joints in a mechanism. The joints to show are specified by a bit mask as the second argument to the .SetVisible(bool, mask) function. The first bit is always the tool frame, and then the bits alternate between joint visuals and joint frames. Note, the frames will not appear visible unless the corresponding joint is visible as well. |