Open CASCADE, the 3D modelling kernel
3D modeling & numerical simulation

Search the Forums
See All Topics

Visualising Iges files with DRAWEXE

Visualising Iges files with DRAWEXE
Hugh Sorby 2009/04/23 23:53
I am trying to visualise some iges files using draw. I am having two problems. First I can't get the surfaces to display, only wireframes and Second DRAWEXE crashes when it tries to process mouse move events.

For the first I am running these commands in DRAWEXE:

pload ALL
NewDocument d XmlXCAF
ReadIges d file.igs
XShow d

For the second, I get this backtrace:

#0 0x00007f2577d5da05 in V3d_View::Viewer (this=0xfefdfefdfefd0000) at ../../../../src/V3d/V3d_View.cxx:2419
#1 0x00007f2577bf8976 in AIS_InteractiveContext::MoveTo (this=0x19db3e8, XPix=264, YPix=479, aView=@0x200f1ef8)
at ../../../../src/AIS/AIS_InteractiveContext_1.cxx:150
#2 0x00007f2575720267 in ViewerTest_EventManager::MoveTo (this=0x200f1ee0, XPix=264, YPix=479)
at ../../../../src/ViewerTest/ViewerTest_EventManager.cxx:34
#3 0x00007f25757408e8 in ProcessMotion () at ../../../../src/ViewerTest/ViewerTest_ViewerCommands.cxx:601
#4 0x00007f257574184e in ViewerMainLoop (argc=0, argv=0x0) at ../../../../src/ViewerTest/ViewerTest_ViewerCommands.cxx:1173
#5 0x00007f2575741930 in VProcessEvents () at ../../../../src/ViewerTest/ViewerTest_ViewerCommands.cxx:1196
#6 0x00007f257ba88f31 in ?? () from /usr/lib/
#7 0x00007f257ba6b2ee in Tcl_ServiceEvent () from /usr/lib/
#8 0x00007f257ba6b606 in Tcl_DoOneEvent () from /usr/lib/
#9 0x00007f257b73d699 in Tk_MainLoop () from /usr/lib/
#10 0x00007f257ed527e5 in Run_Appli (interprete=0x7f257ed2e712 <Draw_Interprete(char*)>) at ../../../../src/Draw/Draw_Window.cxx:1181
#11 0x00007f257ed2ed00 in Draw_Appli (argc=1, argv=0x7fff874b6ea8, Draw_InitAppli=0x400ace <Draw_InitAppli(Draw_Interpretor&)>)
at ../../../../src/Draw/Draw.cxx:300
#12 0x00007f257ed3df0f in _main_ (argc=1, argv=0x7fff874b6ea8, fDraw_InitAppli=0x400ace <Draw_InitAppli(Draw_Interpretor&)>)
at ../../../../src/Draw/Draw_Main.cxx:180
#13 0x0000000000400acc in main (argc=1, argv=0x7fff874b6ea8) at ../../../../src/DRAWEXE/DRAWEXE.cxx:23

As you can see V3d_View::Viewer is returning an invalid handle. I don't run windows so I can only say this is an issue under Linux.

Help with either of these two issues would be great, many thanks.
Roman Lygin 2009/04/24 07:13
Hi Hugh,

This crash is due to a regression introduced in 6.3.0 when DRAW's View3d was migrated to NIS_View. The API in ViewerTest has been re-tailored to it *too much* and did break a compatibility it could have kept given that NIS_View inherits V3d_View.

Here are the patches I have made to get it back to work. File VieweTest.cxx:

static void VwrTst_InitEventMgr(const Handle(V3d_View)& aView,
const Handle(AIS_InteractiveContext)& Ctx)
theEventMgrs.Prepend(new ViewerTest_EventManager(aView, Ctx));


void ViewerTest::ResetEventManager()
VwrTst_InitEventMgr(ViewerTest::CurrentView(), ViewerTest::GetAISContext());


Hope this helps.

--- - the Open CASCADE blog - CAD Exchanger, your 3D data translator
Hugh Sorby 2009/04/28 06:46
Thanks Roman,

That helped me solve issue 2, but issue 1 is still outstanding.

Is there something I am missing here?

Latest news
  • New features to enhance the development process
  • Open CASCADE Technology 6.7.1 is available for download!
  • Open CASCADE Technology 6.7.0 is available for download!

  • © OPEN CASCADE 2000 - 2014  |  Search  |  Contacts   |  Site map