[Mesa-dev] [PATCH] nv50: implement multisample textures

Christoph Bumiller e0425955 at student.tuwien.ac.at
Fri Oct 25 23:11:17 CEST 2013


On 25.10.2013 20:35, Emil Velikov wrote:
> On 21/10/13 23:23, Bryan Cain wrote:
>> This is a port of 4da54c91d24da ("nvc0: implement multisample textures") to
>> nv50.
>>
>> When coupled with the patch to only report 16 texture samplers (to fix
>> crashes), all of the Piglit tests in spec/arb_texture_multisample pass.
>>
> Hello Bryan,
>
> Big thanks for your work. As promised here is a quick piglit summary on
> my nv96
>
> pass/fail/crash
> 69/32/27
>
> * dmesg does not spit anything nouveau related during the tests
> * any geometry shader related tests were skipped
> (piglit: info: Failed to create GL 3.2 core context)
> * all the crashes are due to the following assert
> codegen/nv50_ir_emit_nv50.cpp:1393:emitTEX: Assertion `argc <= 4' failed.

I'm not sure how you'd get > 4 arguments there (x y layer sample ?).
There's no mip maps for multisample textures.

But either way you're probably going to have to do things by hand:
E.g. MS8 textures contain contiguous 4x2 rectangles of samples for each
pixel, so you multiply x by 4 and y by 2 to arrive at the sub-rectangle
and then add the correct offsets for the sample id as seen in
get_sample_position (store the info in a constant buffer, that has to be
updated when texture changes).

You might want to use a lookup table like in nve4 compute (look for "MS
sample coordinate offsets") to map sample id to coordinate offset, that
one works for any sample count as long as you don't use the ALT modes
(nve4 doesn't need to for textures, but for images/surfaces/UAVs/RATs
where the whole VM address calculation is done by hand).

> PASS    arb_texture_multisample-*
> PASS    fb-completeness/*
> FAIL    sample-position/*
> FAIL    texelFetch fs sampler2DMS 4*
> CRASH   texelFetch fs sampler2DMSArray 4*
> FAIL    texelFetch/*-*s-isampler2DMS
> CRASH   texelFetch/*-*s-isampler2DMSArray
> PASS    textureSize/*
>
>
> Hope you find this useful :)
> No real world apps that use multisample textures were tested, yet.
>
> Cheers
> Emil
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/mesa-dev



More information about the mesa-dev mailing list