diff options
author | Brian Paul <[email protected]> | 2005-10-01 16:06:25 +0000 |
---|---|---|
committer | Brian Paul <[email protected]> | 2005-10-01 16:06:25 +0000 |
commit | b0a0ca8bd9edc13e495a39709cc28953dd3fbd9c (patch) | |
tree | dc69a943bbabf6a4c0b5dcff908f512a37a1f5a4 /src/mesa | |
parent | 0899afae33a29d1f6d15ebc96dc6ea8a8371cdb6 (diff) |
GL_EXT_packed_depth_stencil changes
Diffstat (limited to 'src/mesa')
-rw-r--r-- | src/mesa/swrast/s_texcombine.c | 2 | ||||
-rw-r--r-- | src/mesa/swrast/s_texfilter.c | 8 |
2 files changed, 6 insertions, 4 deletions
diff --git a/src/mesa/swrast/s_texcombine.c b/src/mesa/swrast/s_texcombine.c index 2bdd4efaa20..0f662c3d2be 100644 --- a/src/mesa/swrast/s_texcombine.c +++ b/src/mesa/swrast/s_texcombine.c @@ -748,7 +748,7 @@ texture_apply( const GLcontext *ctx, if (format == GL_COLOR_INDEX || format == GL_YCBCR_MESA) { format = GL_RGBA; /* a bit of a hack */ } - else if (format == GL_DEPTH_COMPONENT) { + else if (format == GL_DEPTH_COMPONENT || format == GL_DEPTH_STENCIL_EXT) { format = texUnit->_Current->DepthMode; } diff --git a/src/mesa/swrast/s_texfilter.c b/src/mesa/swrast/s_texfilter.c index f5085c3f1bd..05618a1f802 100644 --- a/src/mesa/swrast/s_texfilter.c +++ b/src/mesa/swrast/s_texfilter.c @@ -2248,7 +2248,9 @@ sample_depth_texture( GLcontext *ctx, (void) lambda; - ASSERT(tObj->Image[0][tObj->BaseLevel]->Format == GL_DEPTH_COMPONENT); + ASSERT(tObj->Image[0][tObj->BaseLevel]->Format == GL_DEPTH_COMPONENT || + tObj->Image[0][tObj->BaseLevel]->Format == GL_DEPTH_STENCIL_EXT); + ASSERT(tObj->Target == GL_TEXTURE_1D || tObj->Target == GL_TEXTURE_2D || tObj->Target == GL_TEXTURE_RECTANGLE_NV); @@ -2649,7 +2651,7 @@ _swrast_choose_texture_sample_func( GLcontext *ctx, switch (t->Target) { case GL_TEXTURE_1D: - if (format == GL_DEPTH_COMPONENT) { + if (format == GL_DEPTH_COMPONENT || format == GL_DEPTH_STENCIL_EXT) { return &sample_depth_texture; } else if (needLambda) { @@ -2663,7 +2665,7 @@ _swrast_choose_texture_sample_func( GLcontext *ctx, return &sample_nearest_1d; } case GL_TEXTURE_2D: - if (format == GL_DEPTH_COMPONENT) { + if (format == GL_DEPTH_COMPONENT || format == GL_DEPTH_STENCIL_EXT) { return &sample_depth_texture; } else if (needLambda) { |