[vtkusers] Re: Windows 2000 - Resize

Meintjes Bekker Meintjes at IGS-NT.uovs.ac.za
Thu Jun 15 10:53:14 EDT 2000


Thanks Nigel for your reply. I've tried your suggestion but it doesn't work.
What is strange about the whole thing it works fine on Windows 98/NT.

Thanks again for your reply.

Regards
Meintjes

> A few variations of the MFC "sample" exist.  Each handles 
> interaction messages differently. 
> 
>   "Sample" is part of the self-installing precompiled ver 3.x.
>   "ugview2" still seems to ship with nightly download. (Why?)
> 
> "Sample" has this OnSize routine, which looks like it simply 
> reorders the calls you already make. 
> 
> 
> void vtkMFCRenderView::OnSize(UINT nType, int cx, int cy) 
> {
>   vtkMFCView::OnSize(nType, cx, cy);
> 	
>   // TODO: Add your message handler code here
>   if (this->Interactor->GetInitialized())
>   {
>     this->Interactor->SetSize(cx,cy);		
>   }
> }
> 
> 
> The "ugview2" version still seems to use the non-existant (??) 
> class, vtkWin32MappedInteractor, and its OnSize looks like this
> 
> void CVtkView::OnSize(UINT nType, int cx, int cy) 
> {
>   if (ren) iren->OnSize(this->m_hWnd,nType, cx, cy);
> }
> 
> If you are using Vtk version 3 or later, try starting from 
> the example "Sample", not "ugview2".
> 
> Best wishes,
> Nigel
> 
> 
> >  void CVtkView::OnSize(UINT nType, int cx, int cy) 
> >  {
> >    this->m_Interactor->SetSize(cx, cy);
> >    this->m_Interactor->UpdateSize(cx, cy);
> >    CView::OnSize(nType, cx, cy);
> >  }




More information about the vtkusers mailing list