From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:34036) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YruN1-0006R8-B9 for qemu-devel@nongnu.org; Mon, 11 May 2015 16:32:12 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YruMx-000409-Lh for qemu-devel@nongnu.org; Mon, 11 May 2015 16:32:11 -0400 Received: from cantor2.suse.de ([195.135.220.15]:55180 helo=mx2.suse.de) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YruMx-0003zf-CX for qemu-devel@nongnu.org; Mon, 11 May 2015 16:32:07 -0400 Message-ID: <555111C4.1070400@suse.de> Date: Mon, 11 May 2015 22:32:04 +0200 From: Alexander Graf MIME-Version: 1.0 References: <1430819017-10877-1-git-send-email-kraxel@redhat.com> <1430819017-10877-4-git-send-email-kraxel@redhat.com> <554BE6F6.8080807@suse.de> <1431066248.28862.0.camel@nilsson.home.kraxel.org> In-Reply-To: <1431066248.28862.0.camel@nilsson.home.kraxel.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Subject: Re: [Qemu-devel] [PULL 3/6] console-gl: add opengl rendering helper functions List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Gerd Hoffmann Cc: Peter Maydell , qemu-devel@nongnu.org On 08.05.15 08:24, Gerd Hoffmann wrote: > On Fr, 2015-05-08 at 00:28 +0200, Alexander Graf wrote: >> >> On 05.05.15 11:43, Gerd Hoffmann wrote: >>> Signed-off-by: Gerd Hoffmann >>> Reviewed-by: Max Reitz >>> --- >> >> [...] >> >>> +void surface_gl_create_texture(ConsoleGLState *gls, >>> + DisplaySurface *surface) >>> +{ >>> + assert(gls); >>> + assert(surface_stride(surface) % surface_bytes_per_pixel(surface= ) =3D=3D 0); >>> + >>> + switch (surface->format) { >>> + case PIXMAN_BE_b8g8r8x8: >>> + case PIXMAN_BE_b8g8r8a8: >>> + surface->glformat =3D GL_BGRA_EXT; >>> + surface->gltype =3D GL_UNSIGNED_BYTE; >>> + break; >>> + case PIXMAN_r5g6b5: >>> + surface->glformat =3D GL_RGB; >>> + surface->gltype =3D GL_UNSIGNED_SHORT_5_6_5; >>> + break; >>> + default: >>> + g_assert_not_reached(); >>> + } >>> + >>> + glGenTextures(1, &surface->texture); >>> + glEnable(GL_TEXTURE_2D); >>> + glBindTexture(GL_TEXTURE_2D, surface->texture); >>> + glPixelStorei(GL_UNPACK_ROW_LENGTH_EXT, >> >> This doesn't compile for me on SLES11: >> >> ui/console-gl.c: In function =E2=80=98surface_gl_create_texture=E2=80=99= : >> ui/console-gl.c:97:19: error: =E2=80=98GL_UNPACK_ROW_LENGTH_EXT=E2=80=99= undeclared >> (first use in this function) >> ui/console-gl.c:97:19: note: each undeclared identifier is reported on= ly >> once for each function it appears in >> ui/console-gl.c: In function =E2=80=98surface_gl_update_texture=E2=80=99= : >> ui/console-gl.c:117:19: error: =E2=80=98GL_UNPACK_ROW_LENGTH_EXT=E2=80= =99 undeclared >> (first use in this function) >> make: *** [ui/console-gl.o] Error 1 >> make: *** Waiting for unfinished jobs.... >=20 > Which mesa version is this? The one I first saw it on is a PPC SLES11 system: $ rpm -qa | grep -i mesa Mesa-libGLESv2-2-9.0.2-34.3.1.ppc64 Mesa-9.0.2-34.3.1.ppc64 Mesa-libEGL1-32bit-9.0.2-34.3.1.ppc64 Mesa-libGL1-32bit-9.0.2-34.3.1.ppc64 Mesa-libglapi-devel-9.0.2-34.3.1.ppc64 Mesa-libGLESv2-2-32bit-9.0.2-34.3.1.ppc64 Mesa-32bit-9.0.2-34.3.1.ppc64 DirectFB-Mesa-1.6.2-3.1.1.ppc64 Mesa-libGLESv2-devel-9.0.2-34.3.1.ppc64 Mesa-libglapi0-9.0.2-34.3.1.ppc64 Mesa-libGL1-9.0.2-34.3.1.ppc64 Mesa-libGL-devel-9.0.2-34.3.1.ppc64 Mesa-libGLESv1_CM-devel-9.0.2-34.3.1.ppc64 Mesa-devel-9.0.2-34.3.1.ppc64 Mesa-libGLESv1_CM1-9.0.2-34.3.1.ppc64 Mesa-libglapi0-32bit-9.0.2-34.3.1.ppc64 libOSMesa9-9.0.2-34.3.1.ppc64 Mesa-libIndirectGL1-9.0.2-34.3.1.ppc64 libOSMesa-devel-9.0.2-34.3.1.ppc64 Mesa-libIndirectGL-devel-9.0.2-34.3.1.ppc64 Mesa-demo-x-8.0.1-8.1.1.ppc64 Mesa-libEGL1-9.0.2-34.3.1.ppc64 Mesa-libEGL-devel-9.0.2-34.3.1.ppc64 But I see the same error on openSUSE 12.3 x86_64 now: x86:~ # rpm -qa | grep -i mesa Mesa-libGLESv2-2-9.0.2-34.3.1.x86_64 Mesa-libGL1-9.0.2-34.3.1.x86_64 Mesa-libGLESv2-devel-9.0.2-34.3.1.x86_64 Mesa-libglapi0-9.0.2-34.3.1.x86_64 libOSMesa9-9.0.2-34.3.1.x86_64 Mesa-libEGL1-9.0.2-34.3.1.x86_64 Mesa-9.0.2-34.3.1.x86_64 Mesa-devel-9.0.2-34.3.1.x86_64 Mesa-libIndirectGL-devel-9.0.2-34.3.1.x86_64 Mesa-libEGL-devel-9.0.2-34.3.1.x86_64 Mesa-libglapi-devel-9.0.2-34.3.1.x86_64 libOSMesa-devel-9.0.2-34.3.1.x86_64 Mesa-libGL-devel-9.0.2-34.3.1.x86_64 Mesa-libGLESv1_CM-devel-9.0.2-34.3.1.x86_64 Mesa-libIndirectGL1-9.0.2-34.3.1.x86_64 Mesa-libGLESv1_CM1-9.0.2-34.3.1.x86_64 Alex