Visual3d_Layer - LocalContext::MoveTo - Flickering

Hi

I've been using Visual3d_Layer to show some 2D data in my 3D viewer. The problem appears when I turn on automatic selection and hilighting. When mouse is moved over some entity (point, edge, etc...), the entity is hilighted automatically (LocalContext::MoveTo method takes care of that), but my Visual3D_Layer content is erased. Then I redraw the layer, but at this point flickering is visible when mouse is moved, because one frame is redrawn without Visual3D_Layer. I think this is because MoveTo method redraws view automatically, but it doesn't, of course, redraw my Visual3D_Layer.

Thanks for any help.

Paul Jimenez's picture

I just started using Visual3d_Layer and found the same problem. It's been more than a year now since you posted that problem, and it's not really surprising not seeing any comments about it, neither a fix in the newer version. I wonder if OCC developers are actually paying attention to these issues, or they are just waiting for people to pay them to fix bugs (do NOT consider this to be offensive, but DO reconsider paying more attention to the community... it's also for the good of OCC). I'll check the code and try to see if I can do something about it.

Paul Jimenez's picture

I just wasted some time trying to figure out what's wrong, but the code is not that easy to follow neither I was able to find a way to solve this problem.

It also happens when using ConvertToGrid. Everything that draws a "primitive" on top of the current view forgets to draw the layers, and I'm clueless as how to correctly incorporate the code to do that.

Paul Jimenez's picture