@robert.beck12569 wrote:
Hello,
I am working on creating a C++ plugin that allows a user to manipulate surfaces indirectly using a control mesh. The idea is that the user will move mesh vertices around, and as the vertices move, the underlying surfaces should update. Below are a few images demonstrating this:
Here is the start:
This is what it looks like when the user selects a point:
This is how it looks after the user drags the point (imagine the surfaces moving with the point):
The reason for this post is that I want to figure out how to apply zebra stripes to the surfaces while I move the point around. I understand Rhino has a Zebra command, but I don’t know how I would be able to use it in my case.
Here is how I am drawing the surfaces:
void CRhinoGetTranslationPoint::DynamicDraw(CRhinoDisplayPipeline& dp, const ON_3dPoint& point) { if (draw) { const CDisplayPipelineAttributes* attrs = dp.DisplayAttrs(); CDisplayPipelineMaterial dpm = *attrs->m_pMaterial; dp.SetupDisplayMaterial(dpm, &m_doc, nullptr); for (size_t i = 0; i < patches.size(); i++) { ON_Brep* b = patches.at(i).BrepForm(); dp.DrawShadedBrep(b, &dpm, nullptr); delete b; } } CRhinoGetXform::DynamicDraw(dp, point); }
Posts: 1
Participants: 1