[Mesa-dev] hardware xvmc video decoding with nouveau

Maarten Lankhorst m.b.lankhorst at gmail.com
Fri Jul 29 16:45:43 PDT 2011


On 07/30/2011 01:05 AM, Younes Manton wrote:
> On Fri, Jul 29, 2011 at 6:46 PM, Maarten Lankhorst
> <m.b.lankhorst at gmail.com> wrote:
>>> 2nd patch isn't needed. You shouldn't call vl_video_buffer_create_ex,
>>> you should override the create_buffer hook yourself and do what you
>>> want. I'll push the 1st one later.
>> What create_buffer hook do you mean? If you mean
>> pipe_video_decoder->create_buffer, it creates a pipe_video_decode_buffer,
>> I need to create a pipe_video_buffer.
> pipe_context->create_video_buffer
My current nouveau_video_buffer_create calls vl_video_buffer_create_ex
with an extra flag set to indicate I want a linear resource. If no capable
hardware is found normal resources are used instead. Since I added a
fallback to g3dvl, it made sense to me that I just added an extra flag
during creation instead of copy pasting the video buffer implementation.

The only thing different between vl_video_buffer and
nouveau_video_buffer_create is that the latter sets
NOUVEAU_RESOURCE_FLAG_LINEAR, rest can be identical.

Cheers,
Maarten


More information about the mesa-dev mailing list