From: rnv Date: Thu, 9 Jan 2014 13:45:54 +0000 (+0000) Subject: Small corrections. X-Git-Tag: V7_4_0a1~29 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=8255b59e91c60c5229c8eeda10412a61e835e4a5;p=modules%2Fgui.git Small corrections. --- diff --git a/src/VTKViewer/VTKViewer_PolyDataMapper.cxx b/src/VTKViewer/VTKViewer_PolyDataMapper.cxx index 58fbc4d16..922a0a4d8 100644 --- a/src/VTKViewer/VTKViewer_PolyDataMapper.cxx +++ b/src/VTKViewer/VTKViewer_PolyDataMapper.cxx @@ -147,7 +147,6 @@ static PFNGLDISABLEVERTEXATTRIBARRAYARBPROC vglDisableVertexAttribArrayARB = NUL bool InitializeBufferExtensions() { - vglShaderSourceARB = (PFNGLSHADERSOURCEARBPROC)GL_GetProcAddress( "glShaderSourceARB" ); if( !vglShaderSourceARB ) return false; @@ -255,6 +254,7 @@ VTKViewer_PolyDataMapper::VTKViewer_PolyDataMapper() this->MarkerScale = VTK::MS_NONE; this->MarkerId = 0; this->BallEnabled = false; + this->VertexProgram = 0; } //----------------------------------------------------------------------------- @@ -543,7 +543,7 @@ void VTKViewer_PolyDataMapper::RenderPiece( vtkRenderer* ren, vtkActor* act ) this->InitTextures(); } - if(!this->BallEnabled) { + if(!this->BallEnabled || this->ExtensionsInitialized != ES_Ok) { MAPPER_SUPERCLASS::RenderPiece( ren, act ); if( isUsePointSprites ) this->CleanupPointSprites(); @@ -982,7 +982,7 @@ int VTKViewer_PolyDataMapper::Draw( vtkRenderer* ren, vtkActor* act ) vglDeleteBuffersARB( 2, &aDiamsID ); } - } else { // there are no extensions + } else { // there are no extensions glColorPointer( 4, GL_FLOAT, sizeof(VTK::TVertex), aVertexArr ); glVertexPointer( 3, GL_FLOAT, sizeof(VTK::TVertex), (void*)((GLfloat*)((void*)(aVertexArr)) + 4));