[vtkusers] [Paraview] WG: endless loop in vtkOpenGLError

Burlen Loring burlen.loring at gmail.com
Tue Dec 10 11:48:08 EST 2013


Hi Gerald,

It sounds like in your situation the underlying rendering context either 
isn't properly initialized or is getting scrambled. I couldn't reproduce 
the infinite loop you mentioned, it's probably a driver specific symptom 
when the interactor is used uninitialized. Your best bet is to 
initialize the interactor before doing any rendering. I'm not an 
authority on the use of this class but the examples I looked at all did 
this.

ParaView is using the VTK master branch which has the gl error checking. 
VTK 6 doesn't have those changes.

Burlen

On 12/10/2013 01:19 AM, Lodron, Gerald wrote:
>
> Hi
>
> I am currently compiling vtk6-0-0 to check it but thanks for the hint 
> of the test. I looked at it and copied the code to my test, and it 
> worked. I found out that the endless loop also appears on the test if 
> you add
>
> view->GetRenderer()->Render();
>
> before
>
> view->GetInteractor()->Initialize();
>
> if you use
>
> view->GetRendererWindow()->Render();
>
> instead of
>
> view->GetRenderer()->Render();
>
> it does not appear, strange behaviour...... I will test it in vtk6 
> when I compiled it, but for me it seems that pv 4.1 has a newer vtk 
> version than 6.0 since all the SetInput functions were missing...
>
> thanks
>
> best regards,
>
> *Von:*Burlen Loring [mailto:burlen.loring at gmail.com]
> *Gesendet:* Montag, 09. Dezember 2013 22:25
> *An:* Lodron, Gerald; Paraview Developer 
> (Paraview-developers at paraview.org); Paraview User (paraview at paraview.org)
> *Betreff:* Re: [Paraview] WG: endless loop in vtkOpenGLError
>
> Hi Gerald,
>
> your example isn't complete, also I had to make some substantial 
> changes(based on the TestLinePlot.cxx ctest) it to get it to work. At 
> any rate, to figure out if you're problem is self inflicted or not, to 
> keep this simple use VTK and not PV for now, cd into a VTK build and 
> run the following command:
>
> ctest -R TestLinePlot --verbose
>
> if those tests pass, then you can use TestLinePlot.cxx as an example 
> of how it should be done. If they fail then that's something we can 
> work with. report the test output from one of the failing tests. Once 
> you figure out exactly what's going on, then try using VTK that's in PV.
>
> Thanks
> Burlen
>
> On 12/09/2013 12:19 AM, Lodron, Gerald wrote:
>
>     vtkContextView* poContextView= vtkContextView::New();
>
>     poContextView->GetRenderer()->SetBackground(1.0, 1.0, 1.0);
>
>     vtkChartXY* poChart= vtkChartXY::New();
>
>     poChart->GetAxis(1)->SetTitle( "xaxis");
>
>     poChart->GetAxis(0)->SetTitle( "yaxis");
>
>     poChart->SetTitle( "Title");
>
>     poContextView->GetScene()->AddItem(poChart);
>
>     // Create a poTable with some points in it...
>
>     vtkTable* poTable= vtkTable::New();
>
>     vtkSmartPointer<vtkDoubleArray> oXAxis=
>     vtkSmartPointer<vtkDoubleArray>::New();
>
>     oXAxis->SetName("xaxis");
>
>     poTable->AddColumn(oXAxis);
>
>     //poTable->AddColumn(oXAxis);
>
>     vtkSmartPointer<vtkDoubleArray> oPositionlot=
>     vtkSmartPointer<vtkDoubleArray>::New();
>
>     oPositionlot->SetName( "Data0");
>
>     poTable->AddColumn(oPositionlot);
>
>     poTable->SetNumberOfRows( 10 );
>
>     poContextView->GetRenderWindow()->SetMultiSamples(0);
>
>     poTable->GetColumn(0)->SetName("col1");
>
>     for( size_tnRow= 0; nRow< 10; ++nRow)
>
>         {
>
>     poTable->SetValue(nRow, 0, 1);
>
>         }
>
>     vtkPlot* poPlot= poChart->AddPlot(vtkChart::LINE);
>
>     poPlot->SetInputData(poTable, 0, 0);
>
>     //poPlot->SetInput(m_poTable, 0, nColumn);
>
>     poPlot->SetColor( 1, 0, 0, 1 );
>
>     poPlot->SetWidth( 1 );
>
>     poPlot->GetPen()->SetLineType(1);
>
>     poContextView->GetRenderer()->Render();
>
>     poContextView->GetInteractor()->Initialize();
>
>     poContextView->GetInteractor()->Start();
>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.vtk.org/pipermail/vtkusers/attachments/20131210/8f3c5314/attachment.htm>


More information about the vtkusers mailing list