diff options
author | Roland Scheidegger <sroland@tungstengraphics.com> | 2007-07-21 16:51:15 +0200 |
---|---|---|
committer | Roland Scheidegger <sroland@tungstengraphics.com> | 2007-07-21 16:51:15 +0200 |
commit | 36fce66034887009749c3d52587c293da2457820 (patch) | |
tree | d1d4c82a2b5fe43719ea6410cb43d985c0c6eb53 /src | |
parent | 118bd626b10d213eb022ac2618bf2efc5fe734d1 (diff) |
set the _BaseFormat for window-framebuffers, could hit some assertion otherwise
Diffstat (limited to 'src')
-rw-r--r-- | src/mesa/drivers/dri/i915tex/intel_fbo.c | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/i915tex/intel_fbo.c b/src/mesa/drivers/dri/i915tex/intel_fbo.c index 399a280c47c..04ca5ae8ba0 100644 --- a/src/mesa/drivers/dri/i915tex/intel_fbo.c +++ b/src/mesa/drivers/dri/i915tex/intel_fbo.c @@ -350,6 +350,21 @@ intel_new_renderbuffer_fb(GLuint intFormat) irb->Base.ClassID = INTEL_RB_CLASS; irb->Base.InternalFormat = intFormat; + switch (intFormat) { + case GL_RGB5: + case GL_RGBA8: + irb->Base._BaseFormat = GL_RGBA; + break; + case GL_DEPTH_COMPONENT16: + irb->Base._BaseFormat = GL_DEPTH_COMPONENT; + break; + case GL_DEPTH24_STENCIL8_EXT: + irb->Base._BaseFormat = GL_DEPTH_STENCIL_EXT; + break; + default: + assert(0); + } + /* intel-specific methods */ irb->Base.Delete = intel_delete_renderbuffer; irb->Base.AllocStorage = intel_alloc_renderbuffer_storage; |