View Issue Details Jump to Notes ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0011390VTK(No Category)public2010-11-01 16:192013-04-05 20:54
ReporterKevin H. Hobbs 
Assigned ToDavid Partyka 
PrioritynormalSeverityminorReproducibilityhave not tried
StatusclosedResolutionfixed 
PlatformOSOS Version
Product Version 
Target VersionFixed in Version 
Summary0011390: Tests must call Render before ExtensionManager
DescriptionThe tests Charts-TestMultipleScalarsToColors, TestMultiTexturing, and TestMultiTexturingTransform should call Render on the render window before checking for OpenGL extensions.

In OSMesa calling glGetString without a current context causes a segfault.

The documentation for vtkOpenGLExtensionManager clearly says that just creating the render window does not create a context and make it current.
TagsNo tags attached.
Project
Type
Attached Files

 Relationships

  Notes
(0024410)
David Partyka (developer)
2011-01-05 06:20

Looks like Marcus fixed it!
(0024415)
Marcus D. Hanwell (developer)
2011-01-05 10:32

For the web and others who might find this report - it is not enough to call Render before using the extension manager. Ideally you initialize a class on its first render, checking for the necessary extensions etc and then save the result in an ivar. You can then check the ivar after a call to render to see if the necessary extensions were present.

There are two other tests outstanding that I did not touch, and so I have not closed this bug report. Dave - are you going to look at them?
(0024416)
David Partyka (developer)
2011-01-05 10:38

Yes I will fix up the two multi-texturing tests similarly.
(0024418)
Kevin H. Hobbs (reporter)
2011-01-05 11:06

Charts-TestMultipleScalarsToColors is passing but the output is :

GL version 2 or higher is required.

So it really isn't running.

I do :

#include <stdlib.h>
#include <stdio.h>
#include "GL/osmesa.h"
#include "GL/glu.h"

static int Width = 400;
static int Height = 400;

int main( int argc, char * argv[] )
{

  OSMesaContext ctx = OSMesaCreateContext( OSMESA_RGBA, NULL );
  void *buffer;
  const char *gl_renderer;
  buffer = malloc( Width * Height * 4 * sizeof(GLubyte) );
  OSMesaMakeCurrent( ctx, buffer, GL_UNSIGNED_BYTE, Width, Height );
  gl_renderer=(const char *)glGetString(GL_VERSION);
  puts(gl_renderer);
  return 0;
}

$ gcc \
  -Xlinker "-rpath=/home/kevin/mesa_osmesa/lib" \
  -Lmesa_osmesa/lib/ \
  -lOSMesa -lGLU mesatest.c

$ ./a.out
2.1 Mesa 7.10-devel

So osmesa claims to support gl 2.1 what gives?
(0024423)
Marcus D. Hanwell (developer)
2011-01-05 11:11

The fact that it wasn't even rendering simple non power of two textures correctly, multiple test failures due to rendering issues when attempting to use simple GL 2 features led me to disable it in the 2D rendering code for now. We have had to do the same in several other 3D rendering classes too I'm afraid.

I would like to revisit this, but the final results look better when using the legacy code - with this test I would like to make things a little more granular as I think it may be supported. I wanted to verify the general approach would work.
(0024425)
Kevin H. Hobbs (reporter)
2011-01-05 11:18

Do I need to file a bug against osmesa?

I'm afraid example code for such an issue is beyond me, but "I'm all about" filing bug reports.

 Issue History
Date Modified Username Field Change
2010-11-01 16:19 Kevin H. Hobbs New Issue
2010-11-01 16:35 Marcus D. Hanwell Status backlog => tabled
2010-11-01 16:35 Marcus D. Hanwell Assigned To => Julien Finet
2011-01-05 06:20 David Partyka Assigned To Julien Finet => Marcus D. Hanwell
2011-01-05 06:20 David Partyka Note Added: 0024410
2011-01-05 10:32 Marcus D. Hanwell Note Added: 0024415
2011-01-05 10:38 David Partyka Note Added: 0024416
2011-01-05 10:48 Marcus D. Hanwell Assigned To Marcus D. Hanwell => David Partyka
2011-01-05 11:06 Kevin H. Hobbs Note Added: 0024418
2011-01-05 11:11 Marcus D. Hanwell Note Added: 0024423
2011-01-05 11:18 Kevin H. Hobbs Note Added: 0024425
2011-06-16 13:11 Zack Galbreath Category => (No Category)
2013-04-05 20:53 Berk Geveci Status backlog => tabled
2013-04-05 20:53 Berk Geveci Resolution open => fixed
2013-04-05 20:54 Berk Geveci Status tabled => closed


Copyright © 2000 - 2018 MantisBT Team