[Mesa-dev] [PATCH 4/4] intel: Allocate s8_z24 non-texture renderbuffers when using separate stencil
Chad Versace
chad at chad-versace.us
Sun Jun 19 14:51:28 PDT 2011
On Sun, 19 Jun 2011 10:15:49 -0700, Eric Anholt <eric at anholt.net> wrote:
Non-text part: multipart/signed
> On Fri, 17 Jun 2011 15:43:43 -0700, Chad Versace <chad at chad-versace.us> wrote:
> > Now all infrastructure is in place to support s8_z24 non-texture
> > renderbuffers for gen7.
> >
> > Signed-off-by: Chad Versace <chad at chad-versace.us>
> > ---
> > src/mesa/drivers/dri/intel/intel_fbo.c | 84 ++++++++++++++++++++++++++++++-
> > 1 files changed, 81 insertions(+), 3 deletions(-)
> >
> > diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c
> > index 0d49a55..72dcf8f 100644
> > --- a/src/mesa/drivers/dri/intel/intel_fbo.c
> > +++ b/src/mesa/drivers/dri/intel/intel_fbo.c
> > @@ -107,6 +107,12 @@ intel_get_pointer(struct gl_context * ctx, struct gl_renderbuffer *rb,
> > }
> >
> >
> > +static struct gl_renderbuffer *
> > +intel_create_renderbuffer_unwrapper(struct gl_context * ctx,
> > + struct gl_renderbuffer *wrapper,
> > + gl_format format);
> > +
>
> I'd probably call this intel_create_wrapped_renderbuffer now.
Oops... thanks for catching that. I forgot to rename this func.
>
> > @@ -196,6 +204,38 @@ intel_alloc_renderbuffer_storage(struct gl_context * ctx, struct gl_renderbuffer
> > width,
> > height / 2,
> > GL_TRUE);
> > + } else if (irb->Base.Format == MESA_FORMAT_S8_Z24
> > + && intel->has_separate_stencil) {
>
> itym must_use_separate_stencil?
I meant has_separate_stencil.
Gen5 and gen6 will *eventually* have:
.has_hiz = true
.has_separate_stencil = true
.must_use_separate_stencil = false
Gen7 *now* has:
.has_hiz = false
.has_separate_stencil = true
.must_use_separate_stencil = true
When hiz/separate-stencil is enabled on gen6 that branch needs to be
taken. So has_separate_stencil is the right condition to check.
>
> 1,2 are Reviewed-by: Eric Anholt <eric at anholt.net>
> 3 I haven't looked into Ken's feedback.
Non-text part: application/pgp-signature
----
Chad Versace
chad at chad-versace.us
More information about the mesa-dev
mailing list