View Full Version : glCopyTexSubImage2D and automatic mipmap generation

09-20-2004, 12:30 PM
Here is the situation: My program uses dynamic textures, and I use glCopyTexSubImage2D to set the texture content. Without automatic mipmap generation this goes at reasonable speeed. However, when I enable automatic texture generation (by setting GL_GENERATE_MIPMAP to GL_TRUE) the speed drops to a measly 5-7% of the speed that was obtained before. Does this sound reasonable? I expected something around 50%....

Note that this happens regardless of whether the dynamic texture is generated using the framebuffer or a pbuffer.

This happens on a 6800GT under Linux (Mandrake 2.6) with 61.11 drivers and also under Windows XP Pro with the 61.77 drivers. There is no such behavior on e.g. ATI 9800 Pro.

Any help or pointers are most appreciated.

- SFRuckus

09-20-2004, 01:06 PM
Do you mean that you lose no performance with your Radeon 9800 Pro ?

09-20-2004, 01:14 PM
That sounds like a driver bug. I'd report it to Nvidia's devrel.

09-20-2004, 01:23 PM
@vincoof: There is a performance drop on the 9800 as well, but it is of the expected 50% order.

- SFRuckus

09-20-2004, 02:04 PM
What is the format of the texture you are updating with glCopyTexSubImage2D?

09-20-2004, 02:19 PM
@jra: The format I use is GL_RGBA8.

- SFRuckus

09-20-2004, 02:36 PM
Odd, that should work fine.

Send me a demo and I will file a bug if this hasn't already been fixed.

09-20-2004, 11:48 PM
I posted an automatic mipmapping issue on GF 6800 GT some time ago, but it didn't get solved.

I'm having the same problem in both linux (61.11) and windows (up to 66.0).

Specifying image data with teximage2D and enabling automatic mipmap generation has the expected 50% overhead +/-regardless of texture internal format.
If the data is specified with copyteximage or copytexsubimage I get the same large performance drop.