[Mesa-dev] [PATCH] intel: fix mapping of malloc'd renderbuffers
Brian Paul
brianp at vmware.com
Mon Jan 9 07:17:57 PST 2012
On 01/07/2012 11:37 PM, Eric Anholt wrote:
> On Sat, 7 Jan 2012 15:08:19 -0700, Brian Paul<brianp at vmware.com> wrote:
>> This fixes accum buffer operations. The accumulation buffer is the
>> only malloc-based renderbuffer for the intel drivers.
>> ---
>> src/mesa/drivers/dri/intel/intel_fbo.c | 13 +++++++++++++
>> 1 files changed, 13 insertions(+), 0 deletions(-)
>>
>> diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c
>> index b95193d..8cb6c2a 100644
>> --- a/src/mesa/drivers/dri/intel/intel_fbo.c
>> +++ b/src/mesa/drivers/dri/intel/intel_fbo.c
>> @@ -132,6 +132,13 @@ intel_map_renderbuffer(struct gl_context *ctx,
>> void *map;
>> int stride;
>>
>> + if (!irb&& rb->Data) {
>> + /* this is a malloc'd renderbuffer (accum buffer) */
>> + *out_map = rb->Data;
>> + *out_stride = rb->RowStride * _mesa_get_format_bytes(rb->Format);
>> + return;
>> + }
>
> Missing x/y handling, right?
D'oh, right.
> I think I'd rather that we just allocate a
> hardware renderbuffer -- shouldn't be hard.
OK, I'll post a new patch, but I'll leave it to you to implement a
hardware buffer if you want to do that.
-Brian
More information about the mesa-dev
mailing list