VirtualBox

Ticket #5720 (new defect)

Opened 4 years ago

Last modified 2 years ago

Opengl Texturing fails in 3.1.0

Reported by: cdaragorn Owned by:
Priority: major Component: 3D support
Version: VirtualBox 3.1.0 Keywords: Textures
Cc: Guest type: other
Host type: other

Description

Calling glTexImage2d produces the following errors: OpenGL Warning: vboxCall failed with VBox status code -54 OpenGL Warning: SHCRGL_GUEST_FN_WRITE_READ (28017464) failed with ffffffdb ffffffea

An example of the code I'm using:

      glBindTexture(GL_TEXTURE_2D, mTextures[0]);

      next = VideoLayer::getImage(concat.str().c_str());
      concat.str("");

      if (next == NULL) return false;
      GLint nOfColors = next->format->BytesPerPixel;
      GLenum tFormat;
      if (nOfColors == 4)
      {
         if (next->format->Rmask == 0x000000ff)
            tFormat = GL_RGBA;
         else
            tFormat = GL_BGRA;
      }
      else
      {
         cerr << "image is not truecolor...\n";
         return false;
      }
      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST_MIPMAP_NEAREST);
      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST_MIPMAP_NEAREST);
      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_S, GL_CLAMP_TO_EDGE);
      glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_CLAMP_TO_EDGE);

      glTexEnvi(GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);

      cerr << "reading texture" << endl;

      glTexImage2D(GL_TEXTURE_2D, 0, nOfColors, next->w, next->h, 0,
        tFormat, GL_UNSIGNED_BYTE, next->pixels);
      cerr << "read" << endl;
      SDL_FreeSurface(next);

      glGenerateMipmapEXT(GL_TEXTURE_2D);

Host System: Windows 7 64-bit Guest System: Ubuntu 9.10 64-bit

This code works perfectly both under the Windows host and under the same Ubuntu guest running Vbox 3.0.12. The program continues to run past these errors, but all textures appear white. All other opengl functions seem to work fine despite the errors with texturing.

Attachments

VBox.log Download (77.7 KB) - added by cdaragorn 4 years ago.
Vbox log file
ogl_badtextures.png Download (11.2 KB) - added by Boozezela 4 years ago.

Change History

Changed 4 years ago by cdaragorn

Vbox log file

comment:1 Changed 4 years ago by Technologov

This bug looks related to bug #5710

-Technologov

comment:2 Changed 4 years ago by frank

  • Priority changed from critical to major

3D is not critical.

comment:3 Changed 4 years ago by leonid

What was the texture dimentions? Probably they're too big, 2048x2048 is about the max size right now.

comment:4 Changed 4 years ago by Boozezela

I have exactly the same problem with an OpenGL game I am betatesting.

With VBox 3.1.0 and higher all textures appears as white boxes, with VBox 3.0.14 everything works fine.

Maximum texture size is 1024x284 (but even resizing it to 100x100 does not change things), other textures range from 100x100 to 400x400.

VirtualBox's log doesn't show warnings/errors that are OpenGL related.

Since bug #5720 seems to be fixed, I suspect this is unrelated.

Host:

  • Ubuntu 10.04 with kernel 2.6.32-24-generic
  • ATI Radeon X1300 with Mesa 3D 7.7.1 (libgl1-mesa-glx 7.7.1-1ubuntu3)

Guest: Windows XP SP3

Changed 4 years ago by Boozezela

comment:5 Changed 4 years ago by Boozezela

Note that I did start with a fresh 3.2.6 installation, downgraded to 3.0.14, upgraded to 3.1.0, upgraded to 3.2.8, always reinstalling the VBox additions in safemode and replacing the files with older/newer versions as needed.

comment:6 Changed 2 years ago by j2ee_developer

It's been a while since this has been reported... Any updates/workarounds?

I'm still seeing this on 4.1.2 on Ubuntu 11.10 using jMonkey/LWJGL.

Note: See TracTickets for help on using tickets.

www.oracle.com
ContactPrivacy policyTerms of Use