Coin3d --> Object turning black while moving camera

Here's the place for discussion related to coding in FreeCAD, C++ or Python. Design, interfaces and structures.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
User avatar
apeltauer
Posts: 399
Joined: Fri Aug 11, 2017 2:19 pm

Coin3d --> Object turning black while moving camera

Post by apeltauer »

hi all,

has anyone seen this behaviour when creating a coin3d object (here a line and a cone) and showing it in the scene grapgh, that the object is turning black when moving the camera?
Capture2.png
Capture2.png (9.4 KiB) Viewed 500 times
Capture.png
Capture.png (7.81 KiB) Viewed 500 times
It seems that it may has something to do that the object is somehow behind the cube?!

my sample code:

Code: Select all

  PartGui::ViewProviderPartExt* vp = dynamic_cast<PartGui::ViewProviderPartExt*>(Gui::Application::Instance->getViewProvider(object));
  if (!vp) return;
  auto currentRoot = vp->getRoot();
  auto pRoot = new SoSeparator();
  .....
   pRoot->addChild(static_cast<SoCone*>(aDir));
  currentRoot->addChild(pRoot);

wmayer
Founder
Posts: 20319
Joined: Thu Feb 19, 2009 10:32 am
Contact:

Re: Coin3d --> Object turning black while moving camera

Post by wmayer »

It seems that it may has something to do that the object is somehow behind the cube?!
Or it's a driver bug.

In some other scenario I also have the issue that the content turns black. For me this is the case when editing a sketch and with the rubber band selection of the Edit menu (not that of the sketcher) the whole content becomes black.
User avatar
apeltauer
Posts: 399
Joined: Fri Aug 11, 2017 2:19 pm

Re: Coin3d --> Object turning black while moving camera

Post by apeltauer »

hmmm... this could be true :(
Post Reply