[Mesa-dev] [Bug 110252] swr software rasterizer fall back to OpenGL 2.1

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Wed Mar 27 06:24:17 UTC 2019


https://bugs.freedesktop.org/show_bug.cgi?id=110252

            Bug ID: 110252
           Summary: swr software rasterizer fall back to OpenGL 2.1
           Product: Mesa
           Version: 19.0
          Hardware: x86-64 (AMD64)
                OS: Linux (All)
            Status: NEW
          Severity: normal
          Priority: medium
         Component: Drivers/Gallium/swr
          Assignee: mesa-dev at lists.freedesktop.org
          Reporter: wanghaipeng03 at baidu.com
        QA Contact: mesa-dev at lists.freedesktop.org

glGetString(GL_EXTENSIONS) returns no GL_EXT_framebuffer_sRGB, which is
required by OpenGL 3.0 (src/mesa/main/version.c compute_version)。so
glGetString(GL_VERSION) fall back to OpenGL 2.1。

#include <stdio.h>
#include <stdlib.h>

#define GL_GLEXT_PROTOTYPES
#include <GL/osmesa.h>
//#include <GL/glext.h>

// settings
const unsigned int SCR_WIDTH = 960;
const unsigned int SCR_HEIGHT = 562;

int main(void) {
  OSMesaContext ctx;
  ctx = OSMesaCreateContextExt(OSMESA_RGBA, 16, 0, 0, NULL);
  GLubyte *buffer = malloc(SCR_WIDTH * SCR_HEIGHT * 4 * sizeof(GLubyte));
  OSMesaMakeCurrent(ctx, buffer, GL_UNSIGNED_BYTE, SCR_WIDTH, SCR_HEIGHT);

  printf("GL_RENDERER = %s\n", (char*)glGetString(GL_RENDERER));
  printf("GL_VERSION = %s\n", (char*)glGetString(GL_VERSION));
  printf("GL_VENDOR = %s\n", (char*)glGetString(GL_VENDOR));
  printf("GL_SHADING_LANGUAGE_VERSION = %s\n",
(char*)glGetString(GL_SHADING_LANGUAGE_VERSION));
  printf("GL_EXTESIONS = %s\n", (char*)glGetString(GL_EXTENSIONS));

  return 0;
}

-- 
You are receiving this mail because:
You are the assignee for the bug.
You are the QA Contact for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20190327/3b30f416/attachment.html>


More information about the mesa-dev mailing list