On Fri, Jul 25, 2014 at 9:45 PM, Marek Olšák <mar...@gmail.com> wrote:
> On Sat, Jul 26, 2014 at 3:36 AM, Ilia Mirkin <imir...@alum.mit.edu> wrote:
>> On Fri, Jul 25, 2014 at 9:30 PM, Marek Olšák <mar...@gmail.com> wrote:
>>> From: Marek Olšák <marek.ol...@amd.com>
>>>
>>> This is needed by the following commit which is a candidate for stable too.
>>>
>>> Cc: mesa-sta...@lists.freedesktop.org
>>> ---
>>>  src/gallium/auxiliary/util/u_prim.h | 15 +++++++++++++++
>>>  1 file changed, 15 insertions(+)
>>>
>>> diff --git a/src/gallium/auxiliary/util/u_prim.h 
>>> b/src/gallium/auxiliary/util/u_prim.h
>>> index fd95c0b..cf1a18f 100644
>>> --- a/src/gallium/auxiliary/util/u_prim.h
>>> +++ b/src/gallium/auxiliary/util/u_prim.h
>>> @@ -136,6 +136,21 @@ u_prim_vertex_count(unsigned prim)
>>>     return (likely(prim < PIPE_PRIM_MAX)) ? &prim_table[prim] : NULL;
>>>  }
>>>
>>> +/**
>>> + * Given a vertex count, return the number of primitives.
>>> + * For polygons, return the number of triangles.
>>> + */
>>> +static INLINE unsigned
>>> +u_prims_for_vertices(unsigned prim, unsigned num)
>>
>> This isn't an issue yet, but with PATCH primitives, the number of
>> vertices per primitive will be variable. (I guess it depends on the
>> stage you're at...) In my patches, I'm passing the number of patch
>> vertices via pipe_draw_info -- perhaps it would make sense to just
>> take that as an argument?
>
> I'm not really sure. I think tessellation is unrelated to the bug I'm
> fixing in the following patch.

OK. I just took a look at the rest of u_prim.h and it looks like patch
primitives are not really compatible with what it's trying to do. So
you can probably ignore my comment.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to