diff --git a/bazaar/Oce2Upp/OCECtrl_CPP b/bazaar/Oce2Upp/OCECtrl_CPP index f7fc81a75..f53e126fe 100755 --- a/bazaar/Oce2Upp/OCECtrl_CPP +++ b/bazaar/Oce2Upp/OCECtrl_CPP @@ -53,7 +53,7 @@ void OCECtrl::SetDocument(OCEDoc *doc) HWND windowHandle = GetHWND(); // Creates the view object - view = document->GetViewer()->CreateView(); + view = new NIS_View(document->GetViewer()); // Creates the OpenCascade window handle Aspect_Handle aWindowHandle = (Aspect_Handle)windowHandle; @@ -72,7 +72,7 @@ void OCECtrl::SetDocument(OCEDoc *doc) Window WindowHandle = GetWindow(); // Creates the view object - view = document->GetViewer()->CreateView(); + view = new NIS_View(document->GetViewer()); Aspect_Handle aWindowHandle = (Aspect_Handle)WindowHandle; Handle(Xw_Window) hWnd = new Xw_Window (document->GetGraphicDriver()->GetDisplayConnection(), aWindowHandle); @@ -201,7 +201,12 @@ void OCECtrl::InitView(void) view->SetTransparency(); - // Signals resize needed +// view->SetPlaneOff(); + view->SetDepth(10000); + + view->SetSurfaceDetail(V3d_TEX_ALL); + + // Signals resize needed view->MustBeResized(); } // END OCECtrl::InitView() diff --git a/bazaar/Oce2Upp/OCECtrl_H b/bazaar/Oce2Upp/OCECtrl_H index 370e8ebd8..39d2d68ef 100755 --- a/bazaar/Oce2Upp/OCECtrl_H +++ b/bazaar/Oce2Upp/OCECtrl_H @@ -11,10 +11,8 @@ class OCECtrl : public DHCtrl bool opened; - protected: - // The view object - Handle(V3d_View) view; + Handle(NIS_View) view; #ifdef PLATFORM_WIN32 // state handler, to catch init and terminate @@ -46,9 +44,14 @@ class OCECtrl : public DHCtrl // Paint function with context virtual void Paint(Draw &draw) ; + protected: + // get document OCEDoc *GetDocument(void) const { return document; } + // get the view handle + Handle(NIS_View) GetViewHandle(void) const { return view; } + //////////////////////////////////////////////////////////////////////////////////////////// public: diff --git a/bazaar/Oce2Upp/OCE_H b/bazaar/Oce2Upp/OCE_H index c31bd937a..abd82e9e4 100755 --- a/bazaar/Oce2Upp/OCE_H +++ b/bazaar/Oce2Upp/OCE_H @@ -2,6 +2,8 @@ #define _OCE_H #include +#undef Convex + #undef HAVE_CONFIG_H #ifdef PLATFORM_POSIX #define OCE_HAVE_FSTREAM @@ -11,7 +13,9 @@ #define OCE_HAVE_LIMITS_H #define HAVE_SYS_STAT_H #define HAVE_STRING_H +#ifndef HAVE_UNISTD_H #define HAVE_UNISTD_H +#endif #define HAVE_SIGNAL_H #define HAVE_SYS_SEM_H #define HAVE_STATFS\ @@ -64,6 +68,7 @@ #include #include #include +#include #include #include